rubyllipse 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +21 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b90036731499e91eec0e5d85eafe84479cc2bd5440806fdb7b5d203a19e3b391
|
4
|
+
data.tar.gz: d0ee6d8b9093660c95b8d3691b61403f4a5a277d253c496bf214c9e33d18ff5a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6bdc3c2112011d28519a372a7bdd11a15c64ccefca605b8fb17affe1766d749d89d12be83c4be1a4a021f5f9988fc63aac48fba215ce1085021833ae09017f61
|
7
|
+
data.tar.gz: 5ef9142acd80b13d40971bb978bfaf73f11fdf4cacdcb54fee813248993d3e4405ceb0e9176f599707713212518597fc00f56f5677a4b37e95705336c158798a
|
data/README.md
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
# Rubyllipse
|
2
|
+
Yes, I know the name's dumb.
|
3
|
+
|
4
|
+
A simple gem for managing and playing with ellipses.
|
5
|
+
|
6
|
+
## Usage
|
7
|
+
|
8
|
+
Create a new ```Ellipse``` object: ```Rubyllipse::Ellipse::new(major_radius, minor_radius, center_coordinates)```; ```myellipse = Rubyllipse::Ellipse::new(3, 3, [0,0])```.
|
9
|
+
|
10
|
+
```myellipse.is_circle? == True``` as we can see we just created a circle. ```myellipse.area```, ```myellipse.perimeter``` will return the circle's area, perimeter.
|
11
|
+
|
12
|
+
```myellipse.move_horizontally(3)``` will move the ellipse by 3 units towards the positive horizontal way and reinitialize the ```myellipse``` object.
|
13
|
+
|
14
|
+
One of the most important aspects of an ```Ellipse``` object is the ```form``` attribute. it can be either set to ```'horizontal'``` or ```'vertical'``` and it determines if the ellipse's major-axis will be vertical or horizontal (tilted, rotated ellipses are not available yet).
|
15
|
+
|
16
|
+
Another important method is ```give_function!```. It returns a string for the purpose of mainly displaying the function of the ```Ellipse``` object.
|
17
|
+
|
18
|
+
Other methods are for accessing the object's attributes and don't need further explanation.
|
19
|
+
|
20
|
+
## Notes
|
21
|
+
If you used the module and found something odd, bad, please send me an e-mail; I am still new to Ruby.
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubyllipse
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Burzum
|
@@ -14,8 +14,10 @@ description:
|
|
14
14
|
email:
|
15
15
|
executables: []
|
16
16
|
extensions: []
|
17
|
-
extra_rdoc_files:
|
17
|
+
extra_rdoc_files:
|
18
|
+
- README.md
|
18
19
|
files:
|
20
|
+
- README.md
|
19
21
|
- lib/rubyllipse.rb
|
20
22
|
homepage:
|
21
23
|
licenses: []
|