erbook 7.1.1 → 7.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/doc/HelloWorld.input +12 -19
- data/doc/HelloWorld.spec +1 -0
- data/doc/api/apple-touch-icon.png +0 -0
- data/doc/api/classes/ERBook/Document/Node.html +6 -6
- data/doc/api/classes/ERBook/Document.html +24 -24
- data/doc/api/classes/ERBook/Template/Sandbox.html +5 -5
- data/doc/api/classes/ERBook/Template.html +20 -20
- data/doc/api/classes/RDoc/AnyMethod.html +24 -24
- data/doc/api/classes/RDoc/TopLevel.html +36 -36
- data/doc/api/classes/String.html +17 -12
- data/doc/api/created.rid +1 -1
- data/doc/api/favicon.ico +0 -0
- data/doc/api/files/CREDITS.html +1 -1
- data/doc/api/files/LICENSE.html +1 -1
- data/doc/api/files/lib/erbook/document_rb.html +3 -1
- data/doc/api/files/lib/erbook/rdoc_rb.html +4 -2
- data/doc/api/files/lib/erbook/template_rb.html +1 -1
- data/doc/api/files/lib/erbook/to_xhtml_rb.html +3 -3
- data/doc/api/files/lib/erbook_rb.html +1 -3
- data/doc/api/js/searchdoc.js +38 -15
- data/doc/api/panel/index.html +13 -5
- data/doc/api/panel/search_index.js +1 -1
- data/doc/formats.erb +18 -18
- data/doc/history.erb +66 -1
- data/doc/index.html +1282 -1023
- data/doc/theory.erb +2 -0
- data/fmt/xhtml.yaml +356 -285
- data/lib/erbook/document.rb +11 -11
- data/lib/erbook/rdoc.rb +9 -4
- data/lib/erbook/to_xhtml.rb +5 -0
- data/lib/erbook.rb +2 -3
- metadata +13 -21
@@ -49,11 +49,11 @@
|
|
49
49
|
<dd>
|
50
50
|
<ul>
|
51
51
|
|
52
|
-
<li><a href="#
|
52
|
+
<li><a href="#M000051">all_classes</a>,</li>
|
53
53
|
|
54
|
-
<li><a href="#
|
54
|
+
<li><a href="#M000053">all_methods</a>,</li>
|
55
55
|
|
56
|
-
<li><a href="#
|
56
|
+
<li><a href="#M000052">all_modules</a></li>
|
57
57
|
|
58
58
|
</ul>
|
59
59
|
</dd>
|
@@ -62,9 +62,9 @@
|
|
62
62
|
<dd>
|
63
63
|
<ul>
|
64
64
|
|
65
|
-
<li><a href="#
|
65
|
+
<li><a href="#M000055">parse</a>,</li>
|
66
66
|
|
67
|
-
<li><a href="#
|
67
|
+
<li><a href="#M000056">parse_file</a></li>
|
68
68
|
|
69
69
|
</ul>
|
70
70
|
</dd>
|
@@ -73,7 +73,7 @@
|
|
73
73
|
<dd>
|
74
74
|
<ul>
|
75
75
|
|
76
|
-
<li><a href="#
|
76
|
+
<li><a href="#M000054">refresh_all_classes_and_modules</a></li>
|
77
77
|
|
78
78
|
</ul>
|
79
79
|
</dd>
|
@@ -95,9 +95,9 @@
|
|
95
95
|
<div class="sectiontitle">Class Public methods</div>
|
96
96
|
|
97
97
|
<div class="method">
|
98
|
-
<div class="title" id="
|
98
|
+
<div class="title" id="M000051">
|
99
99
|
|
100
|
-
<a name="
|
100
|
+
<a name="M000051"></a><b>all_classes</b>()
|
101
101
|
|
102
102
|
</div>
|
103
103
|
|
@@ -113,12 +113,12 @@ Returns an array of all classes recorded thus far.
|
|
113
113
|
|
114
114
|
<div class="sourcecode">
|
115
115
|
<p class="source-link">
|
116
|
-
Source: <a href="javascript:toggleSource('
|
116
|
+
Source: <a href="javascript:toggleSource('M000051_source')" id="l_M000051_source">show</a>
|
117
117
|
|
118
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
118
|
+
| <a href="http://github.com/sunaku/erbook/blob/ef112a9767fa7e4c9b5f535ec992d1a1fd52a4ea/lib/erbook/rdoc.rb#L16" target="_blank" class="github_url">on GitHub</a>
|
119
119
|
|
120
120
|
</p>
|
121
|
-
<div id="
|
121
|
+
<div id="M000051_source" class="dyn-source">
|
122
122
|
<pre><span class="ruby-comment cmt"># File lib/erbook/rdoc.rb, line 16</span>
|
123
123
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">all_classes</span>
|
124
124
|
<span class="ruby-ivar">@all_classes</span>.<span class="ruby-identifier">values</span>
|
@@ -129,9 +129,9 @@ Returns an array of all classes recorded thus far.
|
|
129
129
|
</div>
|
130
130
|
|
131
131
|
<div class="method">
|
132
|
-
<div class="title" id="
|
132
|
+
<div class="title" id="M000053">
|
133
133
|
|
134
|
-
<a name="
|
134
|
+
<a name="M000053"></a><b>all_methods</b>()
|
135
135
|
|
136
136
|
</div>
|
137
137
|
|
@@ -148,12 +148,12 @@ representing all methods recorded thus far.
|
|
148
148
|
|
149
149
|
<div class="sourcecode">
|
150
150
|
<p class="source-link">
|
151
|
-
Source: <a href="javascript:toggleSource('
|
151
|
+
Source: <a href="javascript:toggleSource('M000053_source')" id="l_M000053_source">show</a>
|
152
152
|
|
153
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
153
|
+
| <a href="http://github.com/sunaku/erbook/blob/ef112a9767fa7e4c9b5f535ec992d1a1fd52a4ea/lib/erbook/rdoc.rb#L31" target="_blank" class="github_url">on GitHub</a>
|
154
154
|
|
155
155
|
</p>
|
156
|
-
<div id="
|
156
|
+
<div id="M000053_source" class="dyn-source">
|
157
157
|
<pre><span class="ruby-comment cmt"># File lib/erbook/rdoc.rb, line 31</span>
|
158
158
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">all_methods</span>
|
159
159
|
<span class="ruby-identifier">all_classes_and_modules</span>.<span class="ruby-identifier">map</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">c</span><span class="ruby-operator">|</span> <span class="ruby-identifier">c</span>.<span class="ruby-identifier">method_list</span> }.<span class="ruby-identifier">flatten</span>
|
@@ -164,9 +164,9 @@ representing all methods recorded thus far.
|
|
164
164
|
</div>
|
165
165
|
|
166
166
|
<div class="method">
|
167
|
-
<div class="title" id="
|
167
|
+
<div class="title" id="M000052">
|
168
168
|
|
169
|
-
<a name="
|
169
|
+
<a name="M000052"></a><b>all_modules</b>()
|
170
170
|
|
171
171
|
</div>
|
172
172
|
|
@@ -182,12 +182,12 @@ Returns an array of all modules recorded thus far.
|
|
182
182
|
|
183
183
|
<div class="sourcecode">
|
184
184
|
<p class="source-link">
|
185
|
-
Source: <a href="javascript:toggleSource('
|
185
|
+
Source: <a href="javascript:toggleSource('M000052_source')" id="l_M000052_source">show</a>
|
186
186
|
|
187
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
187
|
+
| <a href="http://github.com/sunaku/erbook/blob/ef112a9767fa7e4c9b5f535ec992d1a1fd52a4ea/lib/erbook/rdoc.rb#L23" target="_blank" class="github_url">on GitHub</a>
|
188
188
|
|
189
189
|
</p>
|
190
|
-
<div id="
|
190
|
+
<div id="M000052_source" class="dyn-source">
|
191
191
|
<pre><span class="ruby-comment cmt"># File lib/erbook/rdoc.rb, line 23</span>
|
192
192
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">all_modules</span>
|
193
193
|
<span class="ruby-ivar">@all_modules</span>.<span class="ruby-identifier">values</span>
|
@@ -198,9 +198,9 @@ Returns an array of all modules recorded thus far.
|
|
198
198
|
</div>
|
199
199
|
|
200
200
|
<div class="method">
|
201
|
-
<div class="title" id="
|
201
|
+
<div class="title" id="M000055">
|
202
202
|
|
203
|
-
<a name="
|
203
|
+
<a name="M000055"></a><b>parse</b>(code_string, file_name = __FILE__)
|
204
204
|
|
205
205
|
</div>
|
206
206
|
|
@@ -226,12 +226,12 @@ string! :-(
|
|
226
226
|
|
227
227
|
<div class="sourcecode">
|
228
228
|
<p class="source-link">
|
229
|
-
Source: <a href="javascript:toggleSource('
|
229
|
+
Source: <a href="javascript:toggleSource('M000055_source')" id="l_M000055_source">show</a>
|
230
230
|
|
231
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
231
|
+
| <a href="http://github.com/sunaku/erbook/blob/ef112a9767fa7e4c9b5f535ec992d1a1fd52a4ea/lib/erbook/rdoc.rb#L65" target="_blank" class="github_url">on GitHub</a>
|
232
232
|
|
233
233
|
</p>
|
234
|
-
<div id="
|
234
|
+
<div id="M000055_source" class="dyn-source">
|
235
235
|
<pre><span class="ruby-comment cmt"># File lib/erbook/rdoc.rb, line 65</span>
|
236
236
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">parse</span> <span class="ruby-identifier">code_string</span>, <span class="ruby-identifier">file_name</span> = <span class="ruby-keyword kw">__FILE__</span>
|
237
237
|
<span class="ruby-identifier">tl</span> = <span class="ruby-constant">TopLevel</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">file_name</span>)
|
@@ -250,9 +250,9 @@ string! :-(
|
|
250
250
|
</div>
|
251
251
|
|
252
252
|
<div class="method">
|
253
|
-
<div class="title" id="
|
253
|
+
<div class="title" id="M000056">
|
254
254
|
|
255
|
-
<a name="
|
255
|
+
<a name="M000056"></a><b>parse_file</b>(file_name)
|
256
256
|
|
257
257
|
</div>
|
258
258
|
|
@@ -277,12 +277,12 @@ extension. Otherwise, <a href="../RDoc.html">RDoc</a> will ignore the file!
|
|
277
277
|
|
278
278
|
<div class="sourcecode">
|
279
279
|
<p class="source-link">
|
280
|
-
Source: <a href="javascript:toggleSource('
|
280
|
+
Source: <a href="javascript:toggleSource('M000056_source')" id="l_M000056_source">show</a>
|
281
281
|
|
282
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
282
|
+
| <a href="http://github.com/sunaku/erbook/blob/ef112a9767fa7e4c9b5f535ec992d1a1fd52a4ea/lib/erbook/rdoc.rb#L86" target="_blank" class="github_url">on GitHub</a>
|
283
283
|
|
284
284
|
</p>
|
285
|
-
<div id="
|
285
|
+
<div id="M000056_source" class="dyn-source">
|
286
286
|
<pre><span class="ruby-comment cmt"># File lib/erbook/rdoc.rb, line 86</span>
|
287
287
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">parse_file</span> <span class="ruby-identifier">file_name</span>
|
288
288
|
<span class="ruby-identifier">parse</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">file_name</span>), <span class="ruby-identifier">file_name</span>
|
@@ -293,9 +293,9 @@ extension. Otherwise, <a href="../RDoc.html">RDoc</a> will ignore the file!
|
|
293
293
|
</div>
|
294
294
|
|
295
295
|
<div class="method">
|
296
|
-
<div class="title" id="
|
296
|
+
<div class="title" id="M000054">
|
297
297
|
|
298
|
-
<a name="
|
298
|
+
<a name="M000054"></a><b>refresh_all_classes_and_modules</b>()
|
299
299
|
|
300
300
|
</div>
|
301
301
|
|
@@ -312,12 +312,12 @@ Update the return value of the all_classes_and_modules() method to
|
|
312
312
|
|
313
313
|
<div class="sourcecode">
|
314
314
|
<p class="source-link">
|
315
|
-
Source: <a href="javascript:toggleSource('
|
315
|
+
Source: <a href="javascript:toggleSource('M000054_source')" id="l_M000054_source">show</a>
|
316
316
|
|
317
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
317
|
+
| <a href="http://github.com/sunaku/erbook/blob/ef112a9767fa7e4c9b5f535ec992d1a1fd52a4ea/lib/erbook/rdoc.rb#L39" target="_blank" class="github_url">on GitHub</a>
|
318
318
|
|
319
319
|
</p>
|
320
|
-
<div id="
|
320
|
+
<div id="M000054_source" class="dyn-source">
|
321
321
|
<pre><span class="ruby-comment cmt"># File lib/erbook/rdoc.rb, line 39</span>
|
322
322
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">refresh_all_classes_and_modules</span>
|
323
323
|
<span class="ruby-identifier">visit</span> = <span class="ruby-identifier">lambda</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">node</span><span class="ruby-operator">|</span>
|
data/doc/api/classes/String.html
CHANGED
@@ -49,9 +49,9 @@
|
|
49
49
|
<dd>
|
50
50
|
<ul>
|
51
51
|
|
52
|
-
<li><a href="#
|
52
|
+
<li><a href="#M000044">to_inline_xhtml</a>,</li>
|
53
53
|
|
54
|
-
<li><a href="#
|
54
|
+
<li><a href="#M000045">to_xhtml</a></li>
|
55
55
|
|
56
56
|
</ul>
|
57
57
|
</dd>
|
@@ -112,9 +112,9 @@ throughout the text-to-XHTML conversion process.
|
|
112
112
|
<div class="sectiontitle">Instance Public methods</div>
|
113
113
|
|
114
114
|
<div class="method">
|
115
|
-
<div class="title" id="
|
115
|
+
<div class="title" id="M000044">
|
116
116
|
|
117
|
-
<a name="
|
117
|
+
<a name="M000044"></a><b>to_inline_xhtml</b>()
|
118
118
|
|
119
119
|
</div>
|
120
120
|
|
@@ -131,12 +131,12 @@ not contain any block-level XHTML elements at the root).
|
|
131
131
|
|
132
132
|
<div class="sourcecode">
|
133
133
|
<p class="source-link">
|
134
|
-
Source: <a href="javascript:toggleSource('
|
134
|
+
Source: <a href="javascript:toggleSource('M000044_source')" id="l_M000044_source">show</a>
|
135
135
|
|
136
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
136
|
+
| <a href="http://github.com/sunaku/erbook/blob/af5b6a4baba28349d216740335a2e461728f59d5/lib/erbook/to_xhtml.rb#L50" target="_blank" class="github_url">on GitHub</a>
|
137
137
|
|
138
138
|
</p>
|
139
|
-
<div id="
|
139
|
+
<div id="M000044_source" class="dyn-source">
|
140
140
|
<pre><span class="ruby-comment cmt"># File lib/erbook/to_xhtml.rb, line 50</span>
|
141
141
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_inline_xhtml</span>
|
142
142
|
<span class="ruby-identifier">to_xhtml</span> <span class="ruby-keyword kw">true</span>
|
@@ -147,9 +147,9 @@ not contain any block-level XHTML elements at the root).
|
|
147
147
|
</div>
|
148
148
|
|
149
149
|
<div class="method">
|
150
|
-
<div class="title" id="
|
150
|
+
<div class="title" id="M000045">
|
151
151
|
|
152
|
-
<a name="
|
152
|
+
<a name="M000045"></a><b>to_xhtml</b>(inline = false)
|
153
153
|
|
154
154
|
</div>
|
155
155
|
|
@@ -172,12 +172,12 @@ at the root.
|
|
172
172
|
|
173
173
|
<div class="sourcecode">
|
174
174
|
<p class="source-link">
|
175
|
-
Source: <a href="javascript:toggleSource('
|
175
|
+
Source: <a href="javascript:toggleSource('M000045_source')" id="l_M000045_source">show</a>
|
176
176
|
|
177
|
-
| <a href="http://github.com/sunaku/erbook/blob/
|
177
|
+
| <a href="http://github.com/sunaku/erbook/blob/af5b6a4baba28349d216740335a2e461728f59d5/lib/erbook/to_xhtml.rb#L62" target="_blank" class="github_url">on GitHub</a>
|
178
178
|
|
179
179
|
</p>
|
180
|
-
<div id="
|
180
|
+
<div id="M000045_source" class="dyn-source">
|
181
181
|
<pre><span class="ruby-comment cmt"># File lib/erbook/to_xhtml.rb, line 62</span>
|
182
182
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_xhtml</span> <span class="ruby-identifier">inline</span> = <span class="ruby-keyword kw">false</span>
|
183
183
|
<span class="ruby-identifier">with_protected_tags</span>(<span class="ruby-keyword kw">self</span>, <span class="ruby-constant">VERBATIM_TAGS</span>, <span class="ruby-keyword kw">true</span>) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">text</span><span class="ruby-operator">|</span>
|
@@ -189,6 +189,11 @@ at the root.
|
|
189
189
|
<span class="ruby-keyword kw">while</span> <span class="ruby-identifier">html</span>.<span class="ruby-identifier">gsub!</span> <span class="ruby-regexp re">%r{(<pre>)<code>(.*?)</code>(</pre>)}</span><span class="ruby-identifier">m</span>, <span class="ruby-value str">'\1\2\3'</span>
|
190
190
|
<span class="ruby-keyword kw">end</span>
|
191
191
|
|
192
|
+
<span class="ruby-comment cmt"># allow "code spans" annotated with Maruku's IAL (Inline</span>
|
193
|
+
<span class="ruby-comment cmt"># Attribute List) Markdown extension to be syntax colored</span>
|
194
|
+
<span class="ruby-keyword kw">while</span> <span class="ruby-identifier">html</span>.<span class="ruby-identifier">gsub!</span> <span class="ruby-regexp re">%r{<pre[^>]+>(<code[^>]+>.*?</code>)</pre>}</span><span class="ruby-identifier">m</span>, <span class="ruby-value str">'\1'</span>
|
195
|
+
<span class="ruby-keyword kw">end</span>
|
196
|
+
|
192
197
|
<span class="ruby-comment cmt"># allow user to type <pre> blocks on single lines</span>
|
193
198
|
<span class="ruby-comment cmt"># without affecting the display of their content</span>
|
194
199
|
<span class="ruby-identifier">html</span>.<span class="ruby-identifier">gsub!</span> <span class="ruby-regexp re">%r{(<pre>)[ \t]*\r?\n|\r?\n[ \t]*(</pre>)}</span>, <span class="ruby-value str">'\1\2'</span>
|
data/doc/api/created.rid
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
Fri, 09 Oct 2009 23:55:05 -0700
|
data/doc/api/favicon.ico
ADDED
Binary file
|
data/doc/api/files/CREDITS.html
CHANGED
data/doc/api/files/LICENSE.html
CHANGED
@@ -19,7 +19,7 @@
|
|
19
19
|
</h1>
|
20
20
|
<ul class="files">
|
21
21
|
<li>lib/erbook/document.rb</li>
|
22
|
-
<li>Last modified:
|
22
|
+
<li>Last modified: 2009-10-09 23:53:53 -0700</li>
|
23
23
|
</ul>
|
24
24
|
</div>
|
25
25
|
|
@@ -39,6 +39,8 @@
|
|
39
39
|
|
40
40
|
<li>enumerator</li>
|
41
41
|
|
42
|
+
<li>ostruct</li>
|
43
|
+
|
42
44
|
</ul>
|
43
45
|
|
44
46
|
|
@@ -19,7 +19,7 @@
|
|
19
19
|
</h1>
|
20
20
|
<ul class="files">
|
21
21
|
<li>lib/erbook/rdoc.rb</li>
|
22
|
-
<li>Last modified:
|
22
|
+
<li>Last modified: 2009-10-08 19:16:01 -0700</li>
|
23
23
|
</ul>
|
24
24
|
</div>
|
25
25
|
|
@@ -42,7 +42,9 @@ Workaround for `rdoc —fmt xml` not dumping information about methods.
|
|
42
42
|
|
43
43
|
<li>rdoc/rdoc</li>
|
44
44
|
|
45
|
-
<li>rdoc/
|
45
|
+
<li>rdoc/generator/markup</li>
|
46
|
+
|
47
|
+
<li>rdoc/markup/to_html</li>
|
46
48
|
|
47
49
|
</ul>
|
48
50
|
|
@@ -19,7 +19,7 @@
|
|
19
19
|
</h1>
|
20
20
|
<ul class="files">
|
21
21
|
<li>lib/erbook/to_xhtml.rb</li>
|
22
|
-
<li>Last modified:
|
22
|
+
<li>Last modified: 2009-09-07 14:19:01 -0700</li>
|
23
23
|
</ul>
|
24
24
|
</div>
|
25
25
|
|
@@ -29,8 +29,8 @@
|
|
29
29
|
<div class="description">
|
30
30
|
<p>
|
31
31
|
This file defines the <a
|
32
|
-
href="../../../classes/String.html#
|
33
|
-
href="../../../classes/String.html#
|
32
|
+
href="../../../classes/String.html#M000045">String#to_xhtml</a> and <a
|
33
|
+
href="../../../classes/String.html#M000044">String#to_inline_xhtml</a>
|
34
34
|
methods, which are invoked to transform plain text into XHTML.
|
35
35
|
</p>
|
36
36
|
<p>
|
@@ -19,7 +19,7 @@
|
|
19
19
|
</h1>
|
20
20
|
<ul class="files">
|
21
21
|
<li>lib/erbook.rb</li>
|
22
|
-
<li>Last modified:
|
22
|
+
<li>Last modified: 2009-10-09 23:53:53 -0700</li>
|
23
23
|
</ul>
|
24
24
|
</div>
|
25
25
|
|
@@ -37,8 +37,6 @@
|
|
37
37
|
|
38
38
|
<li>erbook/document</li>
|
39
39
|
|
40
|
-
<li>ostruct</li>
|
41
|
-
|
42
40
|
</ul>
|
43
41
|
|
44
42
|
|
data/doc/api/js/searchdoc.js
CHANGED
@@ -28,6 +28,14 @@ Searchdoc.Navigation = new function() {
|
|
28
28
|
case 38: //Event.KEY_UP:
|
29
29
|
case 39: //Event.KEY_RIGHT:
|
30
30
|
case 40: //Event.KEY_DOWN:
|
31
|
+
case 73: // i - qwerty
|
32
|
+
case 74: // j
|
33
|
+
case 75: // k
|
34
|
+
case 76: // l
|
35
|
+
case 67: // c - dvorak
|
36
|
+
case 72: // h
|
37
|
+
case 84: // t
|
38
|
+
case 78: // n
|
31
39
|
this.clearMoveTimeout();
|
32
40
|
break;
|
33
41
|
}
|
@@ -37,28 +45,37 @@ Searchdoc.Navigation = new function() {
|
|
37
45
|
if (!this.navigationActive) return;
|
38
46
|
switch(e.keyCode) {
|
39
47
|
case 37: //Event.KEY_LEFT:
|
40
|
-
|
41
|
-
|
48
|
+
case 74: // j (qwerty)
|
49
|
+
case 72: // h (dvorak)
|
50
|
+
if (this.moveLeft()) e.preventDefault();
|
42
51
|
break;
|
43
52
|
case 38: //Event.KEY_UP:
|
44
|
-
|
45
|
-
|
46
|
-
|
53
|
+
case 73: // i (qwerty)
|
54
|
+
case 67: // c (dvorak)
|
55
|
+
if (e.keyCode == 38 || e.ctrlKey) {
|
56
|
+
if (this.moveUp()) e.preventDefault();
|
57
|
+
this.startMoveTimeout(false);
|
58
|
+
}
|
47
59
|
break;
|
48
60
|
case 39: //Event.KEY_RIGHT:
|
49
|
-
|
50
|
-
|
61
|
+
case 76: // l (qwerty)
|
62
|
+
case 78: // n (dvorak)
|
63
|
+
if (this.moveRight()) e.preventDefault();
|
51
64
|
break;
|
52
65
|
case 40: //Event.KEY_DOWN:
|
53
|
-
|
54
|
-
|
55
|
-
|
66
|
+
case 75: // k (qwerty)
|
67
|
+
case 84: // t (dvorak)
|
68
|
+
if (e.keyCode == 40 || e.ctrlKey) {
|
69
|
+
if (this.moveDown()) e.preventDefault();
|
70
|
+
this.startMoveTimeout(true);
|
71
|
+
}
|
56
72
|
break;
|
57
73
|
case 9: //Event.KEY_TAB:
|
58
74
|
case 13: //Event.KEY_RETURN:
|
59
75
|
if (this.$current) this.select(this.$current);
|
60
76
|
break;
|
61
77
|
}
|
78
|
+
if (e.ctrlKey && e.shiftKey) this.select(this.$current);
|
62
79
|
}
|
63
80
|
|
64
81
|
this.clearMoveTimeout = function() {
|
@@ -342,8 +359,9 @@ Searchdoc.Panel.prototype = $.extend({}, Searchdoc.Navigation, new function() {
|
|
342
359
|
this.setNavigationActive(false);
|
343
360
|
}
|
344
361
|
|
345
|
-
this.search = function(value) {
|
362
|
+
this.search = function(value, selectFirstMatch) {
|
346
363
|
value = jQuery.trim(value).toLowerCase();
|
364
|
+
this.selectFirstMatch = selectFirstMatch;
|
347
365
|
if (value) {
|
348
366
|
this.$element.removeClass('panel_tree').addClass('panel_results');
|
349
367
|
this.tree.setNavigationActive(false);
|
@@ -373,6 +391,7 @@ Searchdoc.Panel.prototype = $.extend({}, Searchdoc.Navigation, new function() {
|
|
373
391
|
this.firstRun = false;
|
374
392
|
this.$current = $(target.firstChild);
|
375
393
|
this.$current.addClass('current');
|
394
|
+
if (this.selectFirstMatch) this.select();
|
376
395
|
scrollIntoView(this.$current[0], this.$view[0])
|
377
396
|
}
|
378
397
|
if (jQuery.browser.msie) this.$element[0].className += '';
|
@@ -462,10 +481,14 @@ Searchdoc.Tree.prototype = $.extend({}, Searchdoc.Navigation, new function() {
|
|
462
481
|
}
|
463
482
|
|
464
483
|
this.select = function($li) {
|
484
|
+
this.highlight($li);
|
465
485
|
var path = $li[0].searchdoc_tree_data.path;
|
486
|
+
if (path) this.panel.open(path);
|
487
|
+
}
|
488
|
+
|
489
|
+
this.highlight = function($li) {
|
466
490
|
if (this.$current) this.$current.removeClass('current');
|
467
491
|
this.$current = $li.addClass('current');
|
468
|
-
if (path) this.panel.open(path);
|
469
492
|
}
|
470
493
|
|
471
494
|
this.toggle = function($li) {
|
@@ -479,7 +502,7 @@ Searchdoc.Tree.prototype = $.extend({}, Searchdoc.Navigation, new function() {
|
|
479
502
|
|
480
503
|
this.moveRight = function() {
|
481
504
|
if (!this.$current) {
|
482
|
-
this.
|
505
|
+
this.highlight(this.$list.find('li:first'));
|
483
506
|
return;
|
484
507
|
}
|
485
508
|
if (this.$current.hasClass('closed')) {
|
@@ -489,7 +512,7 @@ Searchdoc.Tree.prototype = $.extend({}, Searchdoc.Navigation, new function() {
|
|
489
512
|
|
490
513
|
this.moveLeft = function() {
|
491
514
|
if (!this.$current) {
|
492
|
-
this.
|
515
|
+
this.highlight(this.$list.find('li:first'));
|
493
516
|
return;
|
494
517
|
}
|
495
518
|
if (!this.$current.hasClass('closed')) {
|
@@ -507,7 +530,7 @@ Searchdoc.Tree.prototype = $.extend({}, Searchdoc.Navigation, new function() {
|
|
507
530
|
|
508
531
|
this.move = function(isDown) {
|
509
532
|
if (!this.$current) {
|
510
|
-
this.
|
533
|
+
this.highlight(this.$list.find('li:first'));
|
511
534
|
return true;
|
512
535
|
}
|
513
536
|
var next = this.$current[0];
|
data/doc/api/panel/index.html
CHANGED
@@ -28,13 +28,21 @@
|
|
28
28
|
});
|
29
29
|
|
30
30
|
$('#search')[0].value == '' && $('#search-label').show();
|
31
|
-
|
32
|
-
setInterval(function() { $('#search')[0].value != '' && $('#search-label').hide() }, 100)
|
33
31
|
}
|
34
32
|
$(function() {
|
35
|
-
|
36
|
-
|
37
|
-
|
33
|
+
placeholder();
|
34
|
+
var panel = new Searchdoc.Panel($('#panel'), search_data, tree, top.frames[1]);
|
35
|
+
$('#search').focus();
|
36
|
+
|
37
|
+
var s = window.parent.location.search.match(/\?q=([^&]+)/);
|
38
|
+
if (s) {
|
39
|
+
s = decodeURIComponent(s[1]).replace(/\+/g, ' ');
|
40
|
+
if (s.length > 0)
|
41
|
+
{
|
42
|
+
$('#search').val(s);
|
43
|
+
panel.search(s, true);
|
44
|
+
}
|
45
|
+
}
|
38
46
|
})
|
39
47
|
//]]>
|
40
48
|
</script>
|
@@ -1 +1 @@
|
|
1
|
-
var search_data = {"index":{"longSearchIndex":["lib/erbook.rb","erbook","erbook::document","erbook","erbook::template","lib/erbook/rdoc.rb","rdoc","rdoc","lib/erbook/to_xhtml.rb","erbook::template::sandbox","rdoc::toplevel","rdoc::toplevel","rdoc::toplevel","erbook::template","rdoc::anymethod","rdoc::anymethod","rdoc::anymethod","erbook::document","erbook::template","rdoc::toplevel","rdoc::toplevel","rdoc::toplevel","erbook::template","erbook::template","string","erbook::document","erbook::document::node","string","rdoc::anymethod","files/credits.html","files/license.html","files/lib/erbook_rb.html","files/lib/erbook/document_rb.html","files/lib/erbook/rdoc_rb.html","files/lib/erbook/template_rb.html","files/lib/erbook/to_xhtml_rb.html"],"info":[["ERBook","lib/erbook.rb","classes/ERBook.html"," < ","",1],["Document","ERBook","classes/ERBook/Document.html"," < Object","",1],["Node","ERBook::Document","classes/ERBook/Document/Node.html"," < OpenStruct","",1],["Template","ERBook","classes/ERBook/Template.html"," < Ember::Template","eRuby template that provides access to the underlying result buffer (which contains the result of template",1],["Sandbox","ERBook::Template","classes/ERBook/Template/Sandbox.html"," < Object","Environment for template evaluation. ",1],["RDoc","lib/erbook/rdoc.rb","classes/RDoc.html"," < ","",1],["AnyMethod","RDoc","classes/RDoc/AnyMethod.html"," < Object","",1],["TopLevel","RDoc","classes/RDoc/TopLevel.html"," < Object","",1],["String","lib/erbook/to_xhtml.rb","classes/String.html"," < Object","",1],["__block_content__","ERBook::Template::Sandbox","classes/ERBook/Template/Sandbox.html#
|
1
|
+
var search_data = {"index":{"searchIndex":["erbook","document","node","template","sandbox","rdoc","anymethod","toplevel","string","__block_content__()","all_classes()","all_methods()","all_modules()","buffer()","comment_html()","decl()","full_name()","new()","new()","parse()","parse_file()","refresh_all_classes_and_modules()","render()","render_with()","to_inline_xhtml()","to_s()","to_s()","to_xhtml()","top_level()","credits","license","erbook.rb","document.rb","rdoc.rb","template.rb","to_xhtml.rb"],"longSearchIndex":["lib/erbook.rb","erbook","erbook::document","erbook","erbook::template","lib/erbook/rdoc.rb","rdoc","rdoc","lib/erbook/to_xhtml.rb","erbook::template::sandbox","rdoc::toplevel","rdoc::toplevel","rdoc::toplevel","erbook::template","rdoc::anymethod","rdoc::anymethod","rdoc::anymethod","erbook::document","erbook::template","rdoc::toplevel","rdoc::toplevel","rdoc::toplevel","erbook::template","erbook::template","string","erbook::document","erbook::document::node","string","rdoc::anymethod","files/credits.html","files/license.html","files/lib/erbook_rb.html","files/lib/erbook/document_rb.html","files/lib/erbook/rdoc_rb.html","files/lib/erbook/template_rb.html","files/lib/erbook/to_xhtml_rb.html"],"info":[["ERBook","lib/erbook.rb","classes/ERBook.html"," < ","",1],["Document","ERBook","classes/ERBook/Document.html"," < Object","",1],["Node","ERBook::Document","classes/ERBook/Document/Node.html"," < OpenStruct","",1],["Template","ERBook","classes/ERBook/Template.html"," < Ember::Template","eRuby template that provides access to the underlying result buffer (which contains the result of template",1],["Sandbox","ERBook::Template","classes/ERBook/Template/Sandbox.html"," < Object","Environment for template evaluation. ",1],["RDoc","lib/erbook/rdoc.rb","classes/RDoc.html"," < ","",1],["AnyMethod","RDoc","classes/RDoc/AnyMethod.html"," < Object","",1],["TopLevel","RDoc","classes/RDoc/TopLevel.html"," < Object","",1],["String","lib/erbook/to_xhtml.rb","classes/String.html"," < Object","",1],["__block_content__","ERBook::Template::Sandbox","classes/ERBook/Template/Sandbox.html#M000043","(*block_args)","Returns an array of things that the given block wants to append to the buffer. If the given block does",2],["all_classes","RDoc::TopLevel","classes/RDoc/TopLevel.html#M000051","()","Returns an array of all classes recorded thus far. ",2],["all_methods","RDoc::TopLevel","classes/RDoc/TopLevel.html#M000053","()","Returns an array of RDoc::AnyMethod objects representing all methods recorded thus far. ",2],["all_modules","RDoc::TopLevel","classes/RDoc/TopLevel.html#M000052","()","Returns an array of all modules recorded thus far. ",2],["buffer","ERBook::Template","classes/ERBook/Template.html#M000041","()","Returns the result of template evaluation thus far. ",2],["comment_html","RDoc::AnyMethod","classes/RDoc/AnyMethod.html#M000060","()","Returns a HTML version of this method's comment. ",2],["decl","RDoc::AnyMethod","classes/RDoc/AnyMethod.html#M000059","()","Returns a complete method declaration with block parameters and all. ",2],["full_name","RDoc::AnyMethod","classes/RDoc/AnyMethod.html#M000058","()","Returns the fully qualified name of this method. ",2],["new","ERBook::Document","classes/ERBook/Document.html#M000046","(format_name, input_text, input_file, options = {})","==== Parameters [format_name] Either the short-hand name of a built-in format or the path to a format",2],["new","ERBook::Template","classes/ERBook/Template.html#M000039","(source, input, unindent = true, safe_level = nil)","==== Parameters [source] Replacement for the ambiguous '(erb)' identifier in stack traces; so that the",2],["parse","RDoc::TopLevel","classes/RDoc/TopLevel.html#M000055","(code_string, file_name = __FILE__)","Returns a RDoc::TopLevel object containing information parsed from the given code string. This information",2],["parse_file","RDoc::TopLevel","classes/RDoc/TopLevel.html#M000056","(file_name)","Returns a RDoc::TopLevel object containing information parsed from the code in the given file. This",2],["refresh_all_classes_and_modules","RDoc::TopLevel","classes/RDoc/TopLevel.html#M000054","()","Update the return value of the all_classes_and_modules() method to *really* include every class and every",2],["render","ERBook::Template","classes/ERBook/Template.html#M000040","()","Returns the output of evaluating this template inside the given context. If no context is given, then",2],["render_with","ERBook::Template","classes/ERBook/Template.html#M000042","(inst_vars = {})","Renders this template within a fresh sandbox that is populated with the given instance variables, whose",2],["to_inline_xhtml","String","classes/String.html#M000044","()","Transforms this string into an *inline* XHTML string (one that does not contain any block-level XHTML",2],["to_s","ERBook::Document","classes/ERBook/Document.html#M000057","()","Returns the output of this document. ",2],["to_s","ERBook::Document::Node","classes/ERBook/Document/Node.html#M000062","()","Returns the output of this node. ",2],["to_xhtml","String","classes/String.html#M000045","(inline = false)","Transforms this string into XHTML while ensuring that the result contains one or more block-level elements",2],["top_level","RDoc::AnyMethod","classes/RDoc/AnyMethod.html#M000061","()","Returns the RDoc::TopLevel object which contains this method. ",2],["CREDITS","files/CREDITS.html","files/CREDITS.html","","* Jens Vierbuchen * Maunika Gosike * [Zhang Chiyuan](http://lifegoo.pluskid.org) ",3],["LICENSE","files/LICENSE.html","files/LICENSE.html","","(the ISC license) Copyright 2006 Suraj N. Kurapati <sunaku@gmail.com> Permission to use, copy, modify,",3],["erbook.rb","files/lib/erbook_rb.html","files/lib/erbook_rb.html",""," ",3],["document.rb","files/lib/erbook/document_rb.html","files/lib/erbook/document_rb.html",""," ",3],["rdoc.rb","files/lib/erbook/rdoc_rb.html","files/lib/erbook/rdoc_rb.html","","Workaround for `rdoc --fmt xml` not dumping information about methods. ",3],["template.rb","files/lib/erbook/template_rb.html","files/lib/erbook/template_rb.html",""," ",3],["to_xhtml.rb","files/lib/erbook/to_xhtml_rb.html","files/lib/erbook/to_xhtml_rb.html","","This file defines the String#to_xhtml and String#to_inline_xhtml methods, which are invoked to transform",3]]}}
|