mireru 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4af6b308832832e50dca8694b82fa42b30620a10
4
- data.tar.gz: ff89a104fb6b23923092d96215abfa0a0e96afe1
3
+ metadata.gz: 7e3e728d1894d1cd4d3f2cd20ab8d67126b5eefd
4
+ data.tar.gz: bc13b2befe7e25a93bdb3037e50a5bbd05cf4d97
5
5
  SHA512:
6
- metadata.gz: ebfdd64bdfd0b9fd2806cbf721952a3175c75982a45f4179649190e714d4525fa4f800713797a5b5f47097c3dfb772ec06c20dccf6922ab574f2264c14d77c7e
7
- data.tar.gz: d8a4448a9adb13d360aa2f0dfc8ef326502911a3e831063d8f3ac6a90aa6c95ac7c574a0b7cb5182cd6727315eced4c3fcb88a9628c1710bf6465af7434d122d
6
+ metadata.gz: ee30693193ae406c33776fbdae8230c2c6c8b1a43c2c918943ad2968221b27ea8f6b332bc8d892b1616d888eaeeea40393316f3bd5fbffa5af378f5f72eae554
7
+ data.tar.gz: cb1becdf6fb35f496b14d9bc93044e7b112e76e93b1bc61dad4e58d20d84d9e94e824b31325ffbe9e0366033458b200285fcdc1c045fe315cdcab191aff23675
data/NEWS.md CHANGED
@@ -1,6 +1,15 @@
1
1
  # NEWS
2
2
 
3
- ## mireru 0.1.2: 2013-05-09
3
+ ## 0.1.3: 2013-07-09
4
+
5
+ Supported to keybinds of expansion and reduction!
6
+
7
+ ### Changes
8
+
9
+ * Improvements
10
+ * Supported to scale-keybinds for image-view and text-view.
11
+
12
+ ## 0.1.2: 2013-05-09
4
13
 
5
14
  Improve Font handling.
6
15
 
data/README.md CHANGED
@@ -18,41 +18,42 @@ If no argument, then search current directory.
18
18
 
19
19
  ### Options
20
20
 
21
- -d, --deep
21
+ -d, --deep<br />
22
22
  deep search as "**/*"
23
23
 
24
- -f, --font
24
+ -f, --font NAME<br />
25
25
  set font such as "Monospace 16"
26
26
 
27
27
  ### Keybind
28
28
 
29
29
  #### Common
30
30
 
31
- n: next
32
-
33
- p: prev
34
-
35
- r: reload
36
-
37
- e: expand path
38
-
39
- q: quit
31
+ n: next<br />
32
+ p: prev<br />
33
+ r: reload<br />
34
+ e: expand path<br />
35
+ q: quit<br />
40
36
 
41
37
  #### Scroll
42
38
 
43
- h: left
44
-
45
- j: down
39
+ h: left<br />
40
+ j: down<br />
41
+ k: up<br />
42
+ l: right<br />
46
43
 
47
- k: up
44
+ #### Scale
48
45
 
49
- l: right
46
+ +: larger<br />
47
+ -: smaller<br />
50
48
 
51
49
  #### Image
52
50
 
53
- f: fits window size
51
+ f: fits window size<br />
52
+ o: original size<br />
53
+
54
+ #### Text
54
55
 
55
- o: original size
56
+ f: change font (at random)<br />
56
57
 
57
58
  ## Contributing
58
59
 
@@ -93,7 +93,7 @@ module Mireru
93
93
  Options:
94
94
  -d, --deep
95
95
  deep search as "**/*"
96
- -f, --font
96
+ -f, --font NAME
97
97
  set font such as "Monospace 16"
98
98
  Keybind:
99
99
  n: next
@@ -108,9 +108,16 @@ Keybind:
108
108
  k: up
109
109
  l: right
110
110
 
111
+ scale:
112
+ +: larger
113
+ -: smaller
114
+
111
115
  image:
112
116
  f: fits window size
113
117
  o: original size
118
+
119
+ text:
120
+ f: change font (at random)
114
121
  EOM
115
122
  @logger.info(message)
116
123
  end
@@ -130,7 +137,7 @@ Warning: file not found.
130
137
  Options:
131
138
  -d, --deep
132
139
  deep search as "**/*"
133
- -f, --font
140
+ -f, --font NAME
134
141
  set font such as "Monospace 16"
135
142
  EOM
136
143
  @logger.error(message)
@@ -1,3 +1,3 @@
1
1
  module Mireru
2
- VERSION = "0.1.2"
2
+ VERSION = "0.1.3"
3
3
  end
@@ -47,6 +47,36 @@ module Mireru
47
47
  pixbuf = Gdk::Pixbuf.new(@file)
48
48
  @widget.pixbuf = pixbuf
49
49
  end
50
+ when Gdk::Keyval::GDK_KEY_plus
51
+ if Mireru::Widget.image?(@file)
52
+ width = @widget.pixbuf.width
53
+ height = @widget.pixbuf.height
54
+ scale = 1.1
55
+ pixbuf = Gdk::Pixbuf.new(@file,
56
+ width * scale,
57
+ height * scale)
58
+ @widget.pixbuf = pixbuf
59
+ elsif @widget.is_a?(Gtk::TextView)
60
+ font = @widget.pango_context.font_description.to_s
61
+ font_size = font.scan(/\d+\z/).first.to_i
62
+ font = font.sub(/\d+\z/, (font_size + 1).to_s)
63
+ @widget.override_font(Pango::FontDescription.new(font))
64
+ end
65
+ when Gdk::Keyval::GDK_KEY_minus
66
+ if Mireru::Widget.image?(@file)
67
+ width = @widget.pixbuf.width
68
+ height = @widget.pixbuf.height
69
+ scale = 0.9
70
+ pixbuf = Gdk::Pixbuf.new(@file,
71
+ width * scale,
72
+ height * scale)
73
+ @widget.pixbuf = pixbuf
74
+ elsif @widget.is_a?(Gtk::TextView)
75
+ font = @widget.pango_context.font_description.to_s
76
+ font_size = font.scan(/\d+\z/).first.to_i
77
+ font = font.sub(/\d+\z/, (font_size - 1).to_s)
78
+ @widget.override_font(Pango::FontDescription.new(font))
79
+ end
50
80
  when Gdk::Keyval::GDK_KEY_h
51
81
  @scroll.hadjustment.value -= 17
52
82
  when Gdk::Keyval::GDK_KEY_j
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mireru
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Masafumi Yokoyama
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-05-09 00:00:00.000000000 Z
11
+ date: 2013-07-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gtk3
@@ -164,7 +164,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
164
164
  version: '0'
165
165
  requirements: []
166
166
  rubyforge_project:
167
- rubygems_version: 2.0.0
167
+ rubygems_version: 2.0.3
168
168
  signing_key:
169
169
  specification_version: 4
170
170
  summary: Flexible File Viewer Keyboard Friend