term_canvas 0.2.7 → 0.2.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/term_canvas/object.rb +10 -1
- data/lib/term_canvas/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 33853245ed29b4a787585c5e610c334eae76e9846bbd94070df5d6a0099f521f
|
4
|
+
data.tar.gz: a3746e4a3d28fac284990d911d592c74a580af3ab7bf55e4086c1f96f5eaf830
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1310d61417f6340492c9ff18b637a14a387664ca226fc0955abf211e6ea0024cb016a3c1a6cb288596a0629268af47f4a5782ca8b5cf6984072bfca3243e4a67
|
7
|
+
data.tar.gz: af48ceb20c7e95af6436bdbc22a5e4a77f938ea0546c320a03902eebc178876004ebb3eaa2fbee3e7b8224afa2f052c1b47a03d065e93f8603ddcf0d391f1bfa
|
data/Gemfile.lock
CHANGED
data/lib/term_canvas/object.rb
CHANGED
@@ -10,10 +10,19 @@ module TermCanvas
|
|
10
10
|
# @param x [Integer] Offset of x
|
11
11
|
# @param y [Integer] Offset of y
|
12
12
|
# @return self
|
13
|
-
def
|
13
|
+
def position_offset(x: nil, y: nil)
|
14
14
|
@x += x if x
|
15
15
|
@y += y if y
|
16
16
|
self
|
17
17
|
end
|
18
|
+
|
19
|
+
# @param x [Integer] New x
|
20
|
+
# @param y [Integer] New y
|
21
|
+
# @return self
|
22
|
+
def position_override(x: nil, y: nil)
|
23
|
+
@x = x if x
|
24
|
+
@y = y if y
|
25
|
+
self
|
26
|
+
end
|
18
27
|
end
|
19
28
|
end
|
data/lib/term_canvas/version.rb
CHANGED