vedeu 0.6.68 → 0.6.69
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +34 -66
- data/docs/api.md +3 -3
- data/docs/borders.md +3 -3
- data/docs/cursors.md +109 -10
- data/docs/debugging.md +2 -2
- data/docs/dsl.md +2 -2
- data/docs/events/application.md +1 -1
- data/docs/events/document.md +9 -9
- data/docs/events/drb.md +7 -7
- data/docs/events/focus.md +3 -3
- data/docs/events/menu.md +10 -10
- data/docs/events/movement.md +5 -3
- data/docs/events/refresh.md +5 -5
- data/docs/events/system.md +8 -8
- data/docs/events/view.md +4 -4
- data/docs/events/visibility.md +10 -32
- data/docs/input.md +1 -1
- data/lib/vedeu/colours/background.rb +4 -9
- data/lib/vedeu/colours/foreground.rb +4 -9
- data/lib/vedeu/colours/translator.rb +8 -3
- data/lib/vedeu/cursors/all.rb +1 -0
- data/lib/vedeu/{geometries → cursors}/coordinate.rb +4 -4
- data/lib/vedeu/cursors/cursor.rb +10 -10
- data/lib/vedeu/cursors/dsl.rb +3 -27
- data/lib/vedeu/cursors/reposition.rb +4 -4
- data/lib/vedeu/esc/esc.rb +13 -17
- data/lib/vedeu/geometries/{alignment.rb → alignment/alignment.rb} +0 -0
- data/lib/vedeu/geometries/alignment/all.rb +11 -0
- data/lib/vedeu/geometries/{horizontal_alignment.rb → alignment/horizontal_alignment.rb} +0 -0
- data/lib/vedeu/geometries/{vertical_alignment.rb → alignment/vertical_alignment.rb} +0 -0
- data/lib/vedeu/geometries/all.rb +4 -12
- data/lib/vedeu/geometries/area/all.rb +12 -0
- data/lib/vedeu/geometries/{area.rb → area/area.rb} +0 -0
- data/lib/vedeu/geometries/{dimension.rb → area/dimension.rb} +0 -0
- data/lib/vedeu/geometries/{x_dimension.rb → area/x_dimension.rb} +0 -0
- data/lib/vedeu/geometries/{y_dimension.rb → area/y_dimension.rb} +0 -0
- data/lib/vedeu/geometries/dsl/all.rb +11 -0
- data/lib/vedeu/geometries/{dsl.rb → dsl/dsl.rb} +0 -0
- data/lib/vedeu/geometries/{grid.rb → dsl/grid.rb} +0 -0
- data/lib/vedeu/geometries/{validator.rb → dsl/validator.rb} +0 -0
- data/lib/vedeu/input/raw.rb +5 -0
- data/lib/vedeu/input/read.rb +2 -2
- data/lib/vedeu/output/compressor.rb +1 -1
- data/lib/vedeu/output/compressor_cache.rb +7 -0
- data/lib/vedeu/terminal/terminal.rb +4 -4
- data/lib/vedeu/version.rb +1 -1
- data/test/lib/vedeu/{geometries/coordinate.rb → cursors/coordinate_test.rb} +4 -4
- data/test/lib/vedeu/esc/esc_test.rb +18 -0
- data/test/lib/vedeu/geometries/{alignment_test.rb → alignment/alignment_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{horizontal_alignment_test.rb → alignment/horizontal_alignment_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{vertical_alignment_test.rb → alignment/vertical_alignment_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{area_test.rb → area/area_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{dimension_test.rb → area/dimension_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{x_dimension_test.rb → area/x_dimension_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{y_dimension_test.rb → area/y_dimension_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{dsl_test.rb → dsl/dsl_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{grid_test.rb → dsl/grid_test.rb} +0 -0
- data/test/lib/vedeu/geometries/{validator_test.rb → dsl/validator_test.rb} +0 -0
- data/vedeu.gemspec +2 -2
- metadata +42 -39
@@ -36,6 +36,24 @@ module Vedeu
|
|
36
36
|
end
|
37
37
|
end
|
38
38
|
|
39
|
+
describe '.clear' do
|
40
|
+
it { described.clear.must_equal("\e[39m\e[49m\e[2J") }
|
41
|
+
end
|
42
|
+
|
43
|
+
describe '.screen_init' do
|
44
|
+
let(:expected) { "\e[0m\e[39m\e[49m\e[2J\e[?25l\e[?9h" }
|
45
|
+
|
46
|
+
it { described.screen_init.must_equal(expected) }
|
47
|
+
end
|
48
|
+
|
49
|
+
describe '.screen_exit' do
|
50
|
+
before { Vedeu::Terminal.stubs(:size).returns([80, 25]) }
|
51
|
+
|
52
|
+
let(:expected) { "\e[?9l\e[?25h\e[39m\e[49m\e[0m\e[80;25H\n" }
|
53
|
+
|
54
|
+
it { described.screen_exit.must_equal(expected) }
|
55
|
+
end
|
56
|
+
|
39
57
|
describe '.string' do
|
40
58
|
context 'when the style is not provided' do
|
41
59
|
it { described.string.must_equal('') }
|
File without changes
|
File without changes
|
data/test/lib/vedeu/geometries/{vertical_alignment_test.rb → alignment/vertical_alignment_test.rb}
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/vedeu.gemspec
CHANGED
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
|
|
24
24
|
spec.add_development_dependency 'guard-minitest', '2.4.4'
|
25
25
|
spec.add_development_dependency 'guard-rubocop', '1.2.0'
|
26
26
|
spec.add_development_dependency 'minitest', '5.8.3'
|
27
|
-
spec.add_development_dependency 'minitest-reporters', '1.1.
|
27
|
+
spec.add_development_dependency 'minitest-reporters', '1.1.7'
|
28
28
|
spec.add_development_dependency 'mocha', '1.1.0'
|
29
29
|
spec.add_development_dependency 'pry', '0.10.3'
|
30
30
|
spec.add_development_dependency 'rubocop', '0.35.1'
|
@@ -37,5 +37,5 @@ Gem::Specification.new do |spec|
|
|
37
37
|
spec.add_dependency 'rake', '~> 10.4'
|
38
38
|
spec.add_dependency 'ruby-prof', '0.15.8'
|
39
39
|
spec.add_dependency 'thor', '0.19.1'
|
40
|
-
spec.add_dependency 'vedeu_cli', '0.0.
|
40
|
+
spec.add_dependency 'vedeu_cli', '0.0.8'
|
41
41
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vedeu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.69
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gavin Laking
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-11-
|
11
|
+
date: 2015-11-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: guard
|
@@ -72,14 +72,14 @@ dependencies:
|
|
72
72
|
requirements:
|
73
73
|
- - '='
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: 1.1.
|
75
|
+
version: 1.1.7
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - '='
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: 1.1.
|
82
|
+
version: 1.1.7
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: mocha
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -240,14 +240,14 @@ dependencies:
|
|
240
240
|
requirements:
|
241
241
|
- - '='
|
242
242
|
- !ruby/object:Gem::Version
|
243
|
-
version: 0.0.
|
243
|
+
version: 0.0.8
|
244
244
|
type: :runtime
|
245
245
|
prerelease: false
|
246
246
|
version_requirements: !ruby/object:Gem::Requirement
|
247
247
|
requirements:
|
248
248
|
- - '='
|
249
249
|
- !ruby/object:Gem::Version
|
250
|
-
version: 0.0.
|
250
|
+
version: 0.0.8
|
251
251
|
description: A framework for building GUI/TUI terminal/console applications.
|
252
252
|
email:
|
253
253
|
- gavinlaking@gmail.com
|
@@ -356,6 +356,7 @@ files:
|
|
356
356
|
- lib/vedeu/configuration/api.rb
|
357
357
|
- lib/vedeu/configuration/configuration.rb
|
358
358
|
- lib/vedeu/cursors/all.rb
|
359
|
+
- lib/vedeu/cursors/coordinate.rb
|
359
360
|
- lib/vedeu/cursors/cursor.rb
|
360
361
|
- lib/vedeu/cursors/dsl.rb
|
361
362
|
- lib/vedeu/cursors/refresh.rb
|
@@ -411,22 +412,24 @@ files:
|
|
411
412
|
- lib/vedeu/events/event.rb
|
412
413
|
- lib/vedeu/events/repository.rb
|
413
414
|
- lib/vedeu/events/trigger.rb
|
414
|
-
- lib/vedeu/geometries/alignment.rb
|
415
|
+
- lib/vedeu/geometries/alignment/alignment.rb
|
416
|
+
- lib/vedeu/geometries/alignment/all.rb
|
417
|
+
- lib/vedeu/geometries/alignment/horizontal_alignment.rb
|
418
|
+
- lib/vedeu/geometries/alignment/vertical_alignment.rb
|
415
419
|
- lib/vedeu/geometries/all.rb
|
416
|
-
- lib/vedeu/geometries/area.rb
|
417
|
-
- lib/vedeu/geometries/
|
418
|
-
- lib/vedeu/geometries/dimension.rb
|
419
|
-
- lib/vedeu/geometries/
|
420
|
+
- lib/vedeu/geometries/area/all.rb
|
421
|
+
- lib/vedeu/geometries/area/area.rb
|
422
|
+
- lib/vedeu/geometries/area/dimension.rb
|
423
|
+
- lib/vedeu/geometries/area/x_dimension.rb
|
424
|
+
- lib/vedeu/geometries/area/y_dimension.rb
|
425
|
+
- lib/vedeu/geometries/dsl/all.rb
|
426
|
+
- lib/vedeu/geometries/dsl/dsl.rb
|
427
|
+
- lib/vedeu/geometries/dsl/grid.rb
|
428
|
+
- lib/vedeu/geometries/dsl/validator.rb
|
420
429
|
- lib/vedeu/geometries/geometry.rb
|
421
|
-
- lib/vedeu/geometries/grid.rb
|
422
|
-
- lib/vedeu/geometries/horizontal_alignment.rb
|
423
430
|
- lib/vedeu/geometries/move.rb
|
424
431
|
- lib/vedeu/geometries/position.rb
|
425
432
|
- lib/vedeu/geometries/repository.rb
|
426
|
-
- lib/vedeu/geometries/validator.rb
|
427
|
-
- lib/vedeu/geometries/vertical_alignment.rb
|
428
|
-
- lib/vedeu/geometries/x_dimension.rb
|
429
|
-
- lib/vedeu/geometries/y_dimension.rb
|
430
433
|
- lib/vedeu/groups/all.rb
|
431
434
|
- lib/vedeu/groups/clear.rb
|
432
435
|
- lib/vedeu/groups/dsl.rb
|
@@ -560,6 +563,7 @@ files:
|
|
560
563
|
- test/lib/vedeu/common_test.rb
|
561
564
|
- test/lib/vedeu/configuration/api_test.rb
|
562
565
|
- test/lib/vedeu/configuration/configuration_test.rb
|
566
|
+
- test/lib/vedeu/cursors/coordinate_test.rb
|
563
567
|
- test/lib/vedeu/cursors/cursor_test.rb
|
564
568
|
- test/lib/vedeu/cursors/dsl_test.rb
|
565
569
|
- test/lib/vedeu/cursors/refresh_test.rb
|
@@ -601,21 +605,20 @@ files:
|
|
601
605
|
- test/lib/vedeu/events/event_test.rb
|
602
606
|
- test/lib/vedeu/events/repository_test.rb
|
603
607
|
- test/lib/vedeu/events/trigger_test.rb
|
604
|
-
- test/lib/vedeu/geometries/alignment_test.rb
|
605
|
-
- test/lib/vedeu/geometries/
|
606
|
-
- test/lib/vedeu/geometries/
|
607
|
-
- test/lib/vedeu/geometries/
|
608
|
-
- test/lib/vedeu/geometries/
|
608
|
+
- test/lib/vedeu/geometries/alignment/alignment_test.rb
|
609
|
+
- test/lib/vedeu/geometries/alignment/horizontal_alignment_test.rb
|
610
|
+
- test/lib/vedeu/geometries/alignment/vertical_alignment_test.rb
|
611
|
+
- test/lib/vedeu/geometries/area/area_test.rb
|
612
|
+
- test/lib/vedeu/geometries/area/dimension_test.rb
|
613
|
+
- test/lib/vedeu/geometries/area/x_dimension_test.rb
|
614
|
+
- test/lib/vedeu/geometries/area/y_dimension_test.rb
|
615
|
+
- test/lib/vedeu/geometries/dsl/dsl_test.rb
|
616
|
+
- test/lib/vedeu/geometries/dsl/grid_test.rb
|
617
|
+
- test/lib/vedeu/geometries/dsl/validator_test.rb
|
609
618
|
- test/lib/vedeu/geometries/geometry_test.rb
|
610
|
-
- test/lib/vedeu/geometries/grid_test.rb
|
611
|
-
- test/lib/vedeu/geometries/horizontal_alignment_test.rb
|
612
619
|
- test/lib/vedeu/geometries/move_test.rb
|
613
620
|
- test/lib/vedeu/geometries/position_test.rb
|
614
621
|
- test/lib/vedeu/geometries/repository_test.rb
|
615
|
-
- test/lib/vedeu/geometries/validator_test.rb
|
616
|
-
- test/lib/vedeu/geometries/vertical_alignment_test.rb
|
617
|
-
- test/lib/vedeu/geometries/x_dimension_test.rb
|
618
|
-
- test/lib/vedeu/geometries/y_dimension_test.rb
|
619
622
|
- test/lib/vedeu/groups/clear_test.rb
|
620
623
|
- test/lib/vedeu/groups/dsl_test.rb
|
621
624
|
- test/lib/vedeu/groups/group_test.rb
|
@@ -776,6 +779,7 @@ test_files:
|
|
776
779
|
- test/lib/vedeu/common_test.rb
|
777
780
|
- test/lib/vedeu/configuration/api_test.rb
|
778
781
|
- test/lib/vedeu/configuration/configuration_test.rb
|
782
|
+
- test/lib/vedeu/cursors/coordinate_test.rb
|
779
783
|
- test/lib/vedeu/cursors/cursor_test.rb
|
780
784
|
- test/lib/vedeu/cursors/dsl_test.rb
|
781
785
|
- test/lib/vedeu/cursors/refresh_test.rb
|
@@ -817,21 +821,20 @@ test_files:
|
|
817
821
|
- test/lib/vedeu/events/event_test.rb
|
818
822
|
- test/lib/vedeu/events/repository_test.rb
|
819
823
|
- test/lib/vedeu/events/trigger_test.rb
|
820
|
-
- test/lib/vedeu/geometries/alignment_test.rb
|
821
|
-
- test/lib/vedeu/geometries/
|
822
|
-
- test/lib/vedeu/geometries/
|
823
|
-
- test/lib/vedeu/geometries/
|
824
|
-
- test/lib/vedeu/geometries/
|
824
|
+
- test/lib/vedeu/geometries/alignment/alignment_test.rb
|
825
|
+
- test/lib/vedeu/geometries/alignment/horizontal_alignment_test.rb
|
826
|
+
- test/lib/vedeu/geometries/alignment/vertical_alignment_test.rb
|
827
|
+
- test/lib/vedeu/geometries/area/area_test.rb
|
828
|
+
- test/lib/vedeu/geometries/area/dimension_test.rb
|
829
|
+
- test/lib/vedeu/geometries/area/x_dimension_test.rb
|
830
|
+
- test/lib/vedeu/geometries/area/y_dimension_test.rb
|
831
|
+
- test/lib/vedeu/geometries/dsl/dsl_test.rb
|
832
|
+
- test/lib/vedeu/geometries/dsl/grid_test.rb
|
833
|
+
- test/lib/vedeu/geometries/dsl/validator_test.rb
|
825
834
|
- test/lib/vedeu/geometries/geometry_test.rb
|
826
|
-
- test/lib/vedeu/geometries/grid_test.rb
|
827
|
-
- test/lib/vedeu/geometries/horizontal_alignment_test.rb
|
828
835
|
- test/lib/vedeu/geometries/move_test.rb
|
829
836
|
- test/lib/vedeu/geometries/position_test.rb
|
830
837
|
- test/lib/vedeu/geometries/repository_test.rb
|
831
|
-
- test/lib/vedeu/geometries/validator_test.rb
|
832
|
-
- test/lib/vedeu/geometries/vertical_alignment_test.rb
|
833
|
-
- test/lib/vedeu/geometries/x_dimension_test.rb
|
834
|
-
- test/lib/vedeu/geometries/y_dimension_test.rb
|
835
838
|
- test/lib/vedeu/groups/clear_test.rb
|
836
839
|
- test/lib/vedeu/groups/dsl_test.rb
|
837
840
|
- test/lib/vedeu/groups/group_test.rb
|