markaby 0.3 → 0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (53) hide show
  1. data/Rakefile +1 -1
  2. data/lib/markaby.rb +2 -2
  3. data/lib/markaby/builder.rb +57 -33
  4. data/lib/markaby/tags.rb +1 -0
  5. data/test/test_markaby.rb +21 -16
  6. metadata +4 -63
  7. data/doc/rdoc/classes/Markaby.html +0 -192
  8. data/doc/rdoc/classes/Markaby/ActionControllerHelper.html +0 -145
  9. data/doc/rdoc/classes/Markaby/ActionControllerHelper.src/M000005.html +0 -20
  10. data/doc/rdoc/classes/Markaby/Builder.html +0 -480
  11. data/doc/rdoc/classes/Markaby/Builder.src/M000008.html +0 -44
  12. data/doc/rdoc/classes/Markaby/Builder.src/M000009.html +0 -18
  13. data/doc/rdoc/classes/Markaby/Builder.src/M000010.html +0 -19
  14. data/doc/rdoc/classes/Markaby/Builder.src/M000012.html +0 -24
  15. data/doc/rdoc/classes/Markaby/Builder.src/M000013.html +0 -18
  16. data/doc/rdoc/classes/Markaby/Builder.src/M000014.html +0 -22
  17. data/doc/rdoc/classes/Markaby/Builder.src/M000015.html +0 -38
  18. data/doc/rdoc/classes/Markaby/Builder.src/M000016.html +0 -18
  19. data/doc/rdoc/classes/Markaby/Builder.src/M000017.html +0 -18
  20. data/doc/rdoc/classes/Markaby/Builder.src/M000018.html +0 -21
  21. data/doc/rdoc/classes/Markaby/Builder.src/M000019.html +0 -24
  22. data/doc/rdoc/classes/Markaby/Builder.src/M000021.html +0 -18
  23. data/doc/rdoc/classes/Markaby/CssProxy.html +0 -177
  24. data/doc/rdoc/classes/Markaby/CssProxy.src/M000006.html +0 -19
  25. data/doc/rdoc/classes/Markaby/CssProxy.src/M000007.html +0 -33
  26. data/doc/rdoc/classes/Markaby/Template.html +0 -156
  27. data/doc/rdoc/classes/Markaby/Template.src/M000022.html +0 -18
  28. data/doc/rdoc/classes/Markaby/Template.src/M000023.html +0 -20
  29. data/doc/rdoc/classes/Markaby/View.html +0 -156
  30. data/doc/rdoc/classes/Markaby/View.src/M000024.html +0 -18
  31. data/doc/rdoc/classes/Markaby/View.src/M000025.html +0 -18
  32. data/doc/rdoc/classes/Object.html +0 -199
  33. data/doc/rdoc/classes/Object.src/M000001.html +0 -16
  34. data/doc/rdoc/classes/Object.src/M000002.html +0 -16
  35. data/doc/rdoc/classes/Object.src/M000003.html +0 -18
  36. data/doc/rdoc/classes/Object.src/M000004.html +0 -18
  37. data/doc/rdoc/created.rid +0 -1
  38. data/doc/rdoc/files/CHANGELOG.html +0 -136
  39. data/doc/rdoc/files/README.html +0 -326
  40. data/doc/rdoc/files/lib/markaby/builder_rb.html +0 -101
  41. data/doc/rdoc/files/lib/markaby/cssproxy_rb.html +0 -101
  42. data/doc/rdoc/files/lib/markaby/helper_rb.html +0 -101
  43. data/doc/rdoc/files/lib/markaby/metaid_rb.html +0 -107
  44. data/doc/rdoc/files/lib/markaby/tags_rb.html +0 -101
  45. data/doc/rdoc/files/lib/markaby/template_rb.html +0 -101
  46. data/doc/rdoc/files/lib/markaby/view_rb.html +0 -101
  47. data/doc/rdoc/files/lib/markaby_rb.html +0 -127
  48. data/doc/rdoc/fr_class_index.html +0 -33
  49. data/doc/rdoc/fr_file_index.html +0 -36
  50. data/doc/rdoc/fr_method_index.html +0 -51
  51. data/doc/rdoc/index.html +0 -24
  52. data/doc/rdoc/rdoc-style.css +0 -208
  53. data/test/example.rb +0 -48
@@ -1,44 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>new (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 38</span>
14
- 38: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">assigns</span> = {}, <span class="ruby-identifier">helpers</span> = <span class="ruby-keyword kw">nil</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 39: <span class="ruby-ivar">@stream</span> = []
16
- 40: <span class="ruby-ivar">@assigns</span> = <span class="ruby-identifier">assigns</span>
17
- 41: <span class="ruby-ivar">@builder</span> = <span class="ruby-operator">::</span><span class="ruby-constant">Builder</span><span class="ruby-operator">::</span><span class="ruby-constant">XmlMarkup</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">:indent</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value">2</span>, <span class="ruby-identifier">:target</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-ivar">@stream</span>)
18
- 42: <span class="ruby-ivar">@output_helpers</span> = <span class="ruby-keyword kw">true</span>
19
- 43:
20
- 44: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">helpers</span>.<span class="ruby-identifier">nil?</span>
21
- 45: <span class="ruby-ivar">@helpers</span> = <span class="ruby-keyword kw">nil</span>
22
- 46: <span class="ruby-keyword kw">else</span>
23
- 47: <span class="ruby-ivar">@helpers</span> = <span class="ruby-identifier">helpers</span>.<span class="ruby-identifier">dup</span>
24
- 48: <span class="ruby-keyword kw">for</span> <span class="ruby-identifier">iv</span> <span class="ruby-keyword kw">in</span> <span class="ruby-identifier">helpers</span>.<span class="ruby-identifier">instance_variables</span>
25
- 49: <span class="ruby-identifier">instance_variable_set</span>(<span class="ruby-identifier">iv</span>, <span class="ruby-identifier">helpers</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-identifier">iv</span>))
26
- 50: <span class="ruby-keyword kw">end</span>
27
- 51: <span class="ruby-keyword kw">end</span>
28
- 52:
29
- 53: <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">assigns</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span class="ruby-identifier">assigns</span>.<span class="ruby-identifier">empty?</span>
30
- 54: <span class="ruby-keyword kw">for</span> <span class="ruby-identifier">iv</span>, <span class="ruby-identifier">val</span> <span class="ruby-keyword kw">in</span> <span class="ruby-identifier">assigns</span>
31
- 55: <span class="ruby-identifier">instance_variable_set</span>(<span class="ruby-node">&quot;@#{iv}&quot;</span>, <span class="ruby-identifier">val</span>)
32
- 56: <span class="ruby-keyword kw">unless</span> <span class="ruby-ivar">@helpers</span>.<span class="ruby-identifier">nil?</span>
33
- 57: <span class="ruby-ivar">@helpers</span>.<span class="ruby-identifier">instance_variable_set</span>(<span class="ruby-node">&quot;@#{iv}&quot;</span>, <span class="ruby-identifier">val</span>)
34
- 58: <span class="ruby-keyword kw">end</span>
35
- 59: <span class="ruby-keyword kw">end</span>
36
- 60: <span class="ruby-keyword kw">end</span>
37
- 61:
38
- 62: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block</span>
39
- 63: <span class="ruby-identifier">r</span> = <span class="ruby-identifier">instance_eval</span> <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>
40
- 64: <span class="ruby-identifier">text</span>(<span class="ruby-identifier">r</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">to_s</span>.<span class="ruby-identifier">empty?</span>
41
- 65: <span class="ruby-keyword kw">end</span>
42
- 66: <span class="ruby-keyword kw">end</span></pre>
43
- </body>
44
- </html>
@@ -1,18 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>to_s (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 69</span>
14
- 69: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_s</span>
15
- 70: <span class="ruby-ivar">@builder</span>.<span class="ruby-identifier">target!</span>.<span class="ruby-identifier">join</span>
16
- 71: <span class="ruby-keyword kw">end</span></pre>
17
- </body>
18
- </html>
@@ -1,19 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>text (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 74</span>
14
- 74: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">text</span>(<span class="ruby-identifier">string</span>)
15
- 75: <span class="ruby-ivar">@builder</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-node">&quot;#{string}&quot;</span>
16
- 76: <span class="ruby-keyword kw">nil</span>
17
- 77: <span class="ruby-keyword kw">end</span></pre>
18
- </body>
19
- </html>
@@ -1,24 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>capture (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 86</span>
14
- 86: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">capture</span>(<span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 87: <span class="ruby-identifier">assigns</span> = <span class="ruby-identifier">instance_variables</span>.<span class="ruby-identifier">inject</span>({}) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">hsh</span>, <span class="ruby-identifier">iv</span><span class="ruby-operator">|</span>
16
- 88: <span class="ruby-keyword kw">unless</span> [<span class="ruby-value str">'@stream'</span>, <span class="ruby-value str">'@builder'</span>, <span class="ruby-value str">'@assigns'</span>, <span class="ruby-value str">'@helpers'</span>].<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">iv</span>)
17
- 89: <span class="ruby-identifier">hsh</span>[<span class="ruby-identifier">iv</span>[<span class="ruby-value">1</span><span class="ruby-operator">..</span><span class="ruby-value">-1</span>]] = <span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-identifier">iv</span>)
18
- 90: <span class="ruby-keyword kw">end</span>
19
- 91: <span class="ruby-identifier">hsh</span>
20
- 92: <span class="ruby-keyword kw">end</span>
21
- 93: <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">assigns</span>, <span class="ruby-ivar">@helpers</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>).<span class="ruby-identifier">to_s</span>
22
- 94: <span class="ruby-keyword kw">end</span></pre>
23
- </body>
24
- </html>
@@ -1,18 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>content_for (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 109</span>
14
- 109: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">content_for</span>(<span class="ruby-identifier">name</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 110: <span class="ruby-identifier">eval</span> <span class="ruby-node">&quot;@content_for_#{name} = (@content_for_#{name} || '') + capture(&amp;block)&quot;</span>
16
- 111: <span class="ruby-keyword kw">end</span></pre>
17
- </body>
18
- </html>
@@ -1,22 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>tag! (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 115</span>
14
- 115: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">tag</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 116: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block</span>
16
- 117: <span class="ruby-identifier">str</span> = <span class="ruby-identifier">capture</span> <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>
17
- 118: <span class="ruby-identifier">block</span> = <span class="ruby-identifier">proc</span> { <span class="ruby-identifier">text</span>(<span class="ruby-identifier">str</span>) }
18
- 119: <span class="ruby-keyword kw">end</span>
19
- 120: <span class="ruby-ivar">@builder</span>.<span class="ruby-identifier">method_missing</span>(<span class="ruby-identifier">tag</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
20
- 121: <span class="ruby-keyword kw">end</span></pre>
21
- </body>
22
- </html>
@@ -1,38 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>method_missing (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 138</span>
14
- 138: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">method_missing</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 139: <span class="ruby-identifier">args</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">arg</span><span class="ruby-operator">|</span>
16
- 140: <span class="ruby-ivar">@stream</span>.<span class="ruby-identifier">delete_if</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span>.<span class="ruby-identifier">object_id</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">arg</span>.<span class="ruby-identifier">object_id</span> }
17
- 141: <span class="ruby-keyword kw">end</span>
18
- 142: <span class="ruby-keyword kw">if</span> <span class="ruby-constant">TAGS</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">sym</span>)
19
- 143: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-keyword kw">and</span> <span class="ruby-identifier">block</span>.<span class="ruby-identifier">nil?</span>
20
- 144: <span class="ruby-keyword kw">return</span> <span class="ruby-constant">CssProxy</span>.<span class="ruby-identifier">new</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">args</span>, <span class="ruby-identifier">block</span><span class="ruby-operator">|</span>
21
- 145: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
22
- 146: <span class="ruby-keyword kw">end</span>
23
- 147: <span class="ruby-keyword kw">end</span>
24
- 148: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
25
- 149: <span class="ruby-keyword kw">elsif</span> <span class="ruby-constant">SELF_CLOSING_TAGS</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">sym</span>)
26
- 150: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
27
- 151: <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-node">&quot;@#{sym}&quot;</span>)
28
- 152: <span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-node">&quot;@#{sym}&quot;</span>)
29
- 153: <span class="ruby-keyword kw">elsif</span> <span class="ruby-ivar">@helpers</span>.<span class="ruby-identifier">respond_to?</span>(<span class="ruby-identifier">sym</span>)
30
- 154: <span class="ruby-identifier">r</span> = <span class="ruby-ivar">@helpers</span>.<span class="ruby-identifier">send</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
31
- 155: <span class="ruby-ivar">@builder</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">r</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@output_helpers</span>
32
- 156: <span class="ruby-identifier">r</span>
33
- 157: <span class="ruby-keyword kw">else</span>
34
- 158: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
35
- 159: <span class="ruby-keyword kw">end</span>
36
- 160: <span class="ruby-keyword kw">end</span></pre>
37
- </body>
38
- </html>
@@ -1,18 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>p (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 162</span>
14
- 162: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">p</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 163: <span class="ruby-identifier">method_missing</span>(<span class="ruby-identifier">:p</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
16
- 164: <span class="ruby-keyword kw">end</span></pre>
17
- </body>
18
- </html>
@@ -1,18 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>img (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 169</span>
14
- 169: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">img</span>(<span class="ruby-identifier">opts</span> = {})
15
- 170: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">:img</span>, <span class="ruby-ivar">@@default_image_tag_options</span>.<span class="ruby-identifier">merge</span>(<span class="ruby-identifier">opts</span>))
16
- 171: <span class="ruby-keyword kw">end</span></pre>
17
- </body>
18
- </html>
@@ -1,21 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>head (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 175</span>
14
- 175: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">head</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 176: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">:head</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>) <span class="ruby-keyword kw">do</span>
16
- 177: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">:meta</span>, <span class="ruby-value str">'http-equiv'</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">'Content-Type'</span>, <span class="ruby-value str">'content'</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">'text/html; charset=utf-8'</span>)
17
- 178: <span class="ruby-identifier">instance_eval</span> <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>
18
- 179: <span class="ruby-keyword kw">end</span>
19
- 180: <span class="ruby-keyword kw">end</span></pre>
20
- </body>
21
- </html>
@@ -1,24 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>html (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 185</span>
14
- 185: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">html</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 186: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">empty?</span>
16
- 187: <span class="ruby-identifier">args</span> = [<span class="ruby-value str">&quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot;</span>, <span class="ruby-value str">&quot;DTD/xhtml1-transitional.dtd&quot;</span>]
17
- 188: <span class="ruby-keyword kw">end</span>
18
- 189: <span class="ruby-ivar">@builder</span>.<span class="ruby-identifier">instruct!</span>
19
- 190: <span class="ruby-ivar">@builder</span>.<span class="ruby-identifier">declare!</span>(<span class="ruby-identifier">:DOCTYPE</span>, <span class="ruby-identifier">:html</span>, <span class="ruby-identifier">:PUBLIC</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
20
- 191: <span class="ruby-identifier">tag!</span>(<span class="ruby-identifier">:html</span>, <span class="ruby-identifier">:xmlns</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">&quot;http://www.w3.org/1999/xhtml&quot;</span>,
21
- 192: <span class="ruby-value str">&quot;xml:lang&quot;</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">&quot;en&quot;</span>, <span class="ruby-identifier">:lang</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">&quot;en&quot;</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
22
- 193: <span class="ruby-keyword kw">end</span></pre>
23
- </body>
24
- </html>
@@ -1,18 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html>
7
- <head>
8
- <title>xhtml_strict (Markaby::Builder)</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
11
- </head>
12
- <body class="standalone-code">
13
- <pre> <span class="ruby-comment cmt"># File lib/markaby/builder.rb, line 197</span>
14
- 197: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">xhtml_strict</span>(<span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
15
- 198: <span class="ruby-identifier">html</span>(<span class="ruby-value str">&quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;</span>, <span class="ruby-value str">&quot;DTD/xhtml1-strict.dtd&quot;</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
16
- 199: <span class="ruby-keyword kw">end</span></pre>
17
- </body>
18
- </html>
@@ -1,177 +0,0 @@
1
- <?xml version="1.0" encoding="iso-8859-1"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
- <head>
8
- <title>Class: Markaby::CssProxy</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
- <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
- <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
12
- <script type="text/javascript">
13
- // <![CDATA[
14
-
15
- function popupCode( url ) {
16
- window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
- }
18
-
19
- function toggleCode( id ) {
20
- if ( document.getElementById )
21
- elem = document.getElementById( id );
22
- else if ( document.all )
23
- elem = eval( "document.all." + id );
24
- else
25
- return false;
26
-
27
- elemStyle = elem.style;
28
-
29
- if ( elemStyle.display != "block" ) {
30
- elemStyle.display = "block"
31
- } else {
32
- elemStyle.display = "none"
33
- }
34
-
35
- return true;
36
- }
37
-
38
- // Make codeblocks hidden by default
39
- document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
-
41
- // ]]>
42
- </script>
43
-
44
- </head>
45
- <body>
46
-
47
-
48
-
49
- <div id="classHeader">
50
- <table class="header-table">
51
- <tr class="top-aligned-row">
52
- <td><strong>Class</strong></td>
53
- <td class="class-name-in-header">Markaby::CssProxy</td>
54
- </tr>
55
- <tr class="top-aligned-row">
56
- <td><strong>In:</strong></td>
57
- <td>
58
- <a href="../../files/lib/markaby/cssproxy_rb.html">
59
- lib/markaby/cssproxy.rb
60
- </a>
61
- <br />
62
- </td>
63
- </tr>
64
-
65
- <tr class="top-aligned-row">
66
- <td><strong>Parent:</strong></td>
67
- <td>
68
- <a href="../Object.html">
69
- Object
70
- </a>
71
- </td>
72
- </tr>
73
- </table>
74
- </div>
75
- <!-- banner header -->
76
-
77
- <div id="bodyContent">
78
-
79
-
80
-
81
- <div id="contextContent">
82
-
83
- <div id="description">
84
- <p>
85
- Class used by <a href="Builder.html">Markaby::Builder</a> to store element
86
- options. Methods called against the <a href="CssProxy.html">CssProxy</a>
87
- object are added as element classes or IDs.
88
- </p>
89
- <p>
90
- See the README for examples.
91
- </p>
92
-
93
- </div>
94
-
95
-
96
- </div>
97
-
98
- <div id="method-list">
99
- <h3 class="section-bar">Methods</h3>
100
-
101
- <div class="name-list">
102
- <a href="#M000007">method_missing</a>&nbsp;&nbsp;
103
- <a href="#M000006">new</a>&nbsp;&nbsp;
104
- </div>
105
- </div>
106
-
107
- </div>
108
-
109
-
110
- <!-- if includes -->
111
-
112
- <div id="section">
113
-
114
-
115
-
116
-
117
-
118
-
119
-
120
-
121
- <!-- if method_list -->
122
- <div id="methods">
123
- <h3 class="section-bar">Public Class methods</h3>
124
-
125
- <div id="method-M000006" class="method-detail">
126
- <a name="M000006"></a>
127
-
128
- <div class="method-heading">
129
- <a href="CssProxy.src/M000006.html" target="Code" class="method-signature"
130
- onclick="popupCode('CssProxy.src/M000006.html');return false;">
131
- <span class="method-name">new</span><span class="method-args">(opts = {}, &amp;blk)</span>
132
- </a>
133
- </div>
134
-
135
- <div class="method-description">
136
- <p>
137
- Creates a <a href="CssProxy.html">CssProxy</a> object. The <tt>opts</tt>
138
- and <tt>block</tt> passed in are stored until the element is created by
139
- Builder.tag!
140
- </p>
141
- </div>
142
- </div>
143
-
144
- <h3 class="section-bar">Public Instance methods</h3>
145
-
146
- <div id="method-M000007" class="method-detail">
147
- <a name="M000007"></a>
148
-
149
- <div class="method-heading">
150
- <a href="CssProxy.src/M000007.html" target="Code" class="method-signature"
151
- onclick="popupCode('CssProxy.src/M000007.html');return false;">
152
- <span class="method-name">method_missing</span><span class="method-args">(id_or_class, *args, &amp;blk)</span>
153
- </a>
154
- </div>
155
-
156
- <div class="method-description">
157
- <p>
158
- Adds attributes to an element. Bang methods set the :id attribute. Other
159
- methods add to the :class attribute. If a block is supplied, it is executed
160
- with a merged hash (@opts + args).
161
- </p>
162
- </div>
163
- </div>
164
-
165
-
166
- </div>
167
-
168
-
169
- </div>
170
-
171
-
172
- <div id="validator-badges">
173
- <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
174
- </div>
175
-
176
- </body>
177
- </html>