ramaze 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (195) hide show
  1. data/Rakefile +4 -12
  2. data/bin/ramaze +95 -171
  3. data/doc/CHANGELOG +387 -4
  4. data/doc/README +81 -13
  5. data/doc/meta/announcement.txt +51 -8
  6. data/doc/meta/configuration.txt +17 -34
  7. data/doc/meta/internals.txt +34 -4
  8. data/doc/migrate/1110_to_1111.txt +131 -0
  9. data/doc/readme_chunks/features.txt +81 -12
  10. data/doc/readme_chunks/installing.txt +0 -1
  11. data/doc/tutorial/todolist.html +293 -65
  12. data/doc/tutorial/{todolist.txt → todolist.mkd} +251 -51
  13. data/examples/blog/main.rb +1 -1
  14. data/examples/blog/src/model.rb +0 -1
  15. data/examples/hello.rb +2 -5
  16. data/examples/templates/template/external.haml +5 -5
  17. data/examples/templates/template/external.liquid +1 -1
  18. data/examples/templates/template/external.mab +8 -8
  19. data/examples/templates/template/external.rem +30 -0
  20. data/examples/templates/template/external.rhtml +6 -7
  21. data/examples/templates/template/external.zmr +13 -9
  22. data/examples/templates/template_amrita2.rb +8 -8
  23. data/examples/templates/template_erubis.rb +11 -11
  24. data/examples/templates/template_ezamar.rb +9 -11
  25. data/examples/templates/template_haml.rb +13 -13
  26. data/examples/templates/template_liquid.rb +10 -10
  27. data/examples/templates/template_markaby.rb +13 -10
  28. data/examples/templates/template_remarkably.rb +59 -0
  29. data/examples/todolist/main.rb +1 -7
  30. data/examples/todolist/src/controller/main.rb +26 -13
  31. data/examples/todolist/src/element/page.rb +5 -0
  32. data/examples/whywiki/main.rb +1 -1
  33. data/lib/proto/main.rb +0 -8
  34. data/lib/proto/public/css/ramaze_error.css +12 -4
  35. data/lib/proto/public/error.zmr +6 -25
  36. data/lib/ramaze.rb +35 -245
  37. data/lib/ramaze/action.rb +21 -0
  38. data/lib/ramaze/adapter.rb +94 -29
  39. data/lib/ramaze/adapter/base.rb +57 -0
  40. data/lib/ramaze/adapter/mongrel.rb +12 -19
  41. data/lib/ramaze/adapter/webrick.rb +21 -20
  42. data/lib/ramaze/cache.rb +47 -3
  43. data/lib/ramaze/cache/memcached.rb +22 -0
  44. data/lib/ramaze/cache/yaml_store.rb +19 -0
  45. data/lib/ramaze/controller.rb +47 -271
  46. data/lib/ramaze/controller/error.rb +43 -0
  47. data/lib/ramaze/controller/render.rb +90 -0
  48. data/lib/ramaze/controller/resolve.rb +147 -0
  49. data/lib/ramaze/dispatcher.rb +41 -9
  50. data/lib/ramaze/dispatcher/file.rb +1 -1
  51. data/lib/ramaze/global.rb +73 -158
  52. data/lib/ramaze/global/dsl.rb +29 -0
  53. data/lib/ramaze/global/globalstruct.rb +90 -0
  54. data/lib/ramaze/helper.rb +1 -1
  55. data/lib/ramaze/helper/aspect.rb +39 -179
  56. data/lib/ramaze/helper/cache.rb +8 -9
  57. data/lib/ramaze/helper/cgi.rb +23 -0
  58. data/lib/ramaze/helper/file.rb +3 -0
  59. data/lib/ramaze/helper/inform.rb +3 -0
  60. data/lib/ramaze/helper/link.rb +56 -63
  61. data/lib/ramaze/helper/nitroform.rb +4 -0
  62. data/lib/ramaze/helper/redirect.rb +1 -1
  63. data/lib/ramaze/inform.rb +6 -2
  64. data/lib/ramaze/inform/analogger.rb +5 -1
  65. data/lib/ramaze/inform/hub.rb +1 -1
  66. data/lib/ramaze/inform/informing.rb +7 -0
  67. data/lib/ramaze/snippets/kernel/aquire.rb +2 -0
  68. data/lib/ramaze/snippets/kernel/constant.rb +2 -0
  69. data/lib/ramaze/snippets/kernel/pretty_inspect.rb +2 -0
  70. data/lib/ramaze/snippets/object/traits.rb +4 -0
  71. data/lib/ramaze/snippets/openstruct/temp.rb +3 -0
  72. data/lib/ramaze/snippets/string/DIVIDE.rb +2 -0
  73. data/lib/ramaze/snippets/string/camel_case.rb +2 -0
  74. data/lib/ramaze/snippets/string/color.rb +2 -0
  75. data/lib/ramaze/snippets/string/each.rb +2 -0
  76. data/lib/ramaze/snippets/string/snake_case.rb +3 -0
  77. data/lib/ramaze/snippets/struct/fill.rb +8 -2
  78. data/lib/ramaze/snippets/struct/values_at.rb +16 -0
  79. data/lib/ramaze/snippets/symbol/to_proc.rb +3 -0
  80. data/lib/ramaze/sourcereload.rb +89 -0
  81. data/lib/ramaze/template.rb +21 -12
  82. data/lib/ramaze/template/amrita2.rb +6 -6
  83. data/lib/ramaze/template/erubis.rb +4 -9
  84. data/lib/ramaze/template/ezamar.rb +13 -57
  85. data/lib/ramaze/template/ezamar/element.rb +10 -12
  86. data/lib/ramaze/template/ezamar/engine.rb +40 -101
  87. data/lib/ramaze/template/ezamar/morpher.rb +3 -3
  88. data/lib/ramaze/template/haml.rb +3 -6
  89. data/lib/ramaze/template/liquid.rb +4 -9
  90. data/lib/ramaze/template/markaby.rb +16 -22
  91. data/lib/ramaze/template/remarkably.rb +28 -0
  92. data/lib/ramaze/tool/mime.rb +2 -0
  93. data/lib/ramaze/tool/record.rb +6 -0
  94. data/lib/ramaze/trinity/request.rb +44 -54
  95. data/lib/ramaze/trinity/response.rb +1 -1
  96. data/lib/ramaze/trinity/session.rb +15 -37
  97. data/lib/ramaze/version.rb +1 -1
  98. data/rake_tasks/gem.rake +2 -2
  99. data/rake_tasks/maintaince.rake +42 -1
  100. data/rake_tasks/spec.rake +45 -0
  101. data/spec/examples/caching.rb +1 -1
  102. data/spec/examples/simple.rb +1 -1
  103. data/spec/examples/templates/template_amrita2.rb +1 -0
  104. data/spec/examples/templates/template_erubis.rb +2 -1
  105. data/spec/examples/templates/template_ezamar.rb +1 -1
  106. data/spec/examples/templates/template_haml.rb +2 -1
  107. data/spec/examples/templates/template_liquid.rb +2 -1
  108. data/spec/examples/templates/template_markaby.rb +2 -1
  109. data/spec/examples/templates/template_remarkably.rb +22 -0
  110. data/spec/examples/todolist.rb +125 -0
  111. data/spec/helper.rb +2 -23
  112. data/spec/helper/minimal.rb +20 -0
  113. data/spec/helper/mock_http.rb +24 -30
  114. data/spec/helper/simple_http.rb +2 -2
  115. data/spec/helper/wrap.rb +6 -9
  116. data/spec/ramaze/adapter.rb +1 -1
  117. data/spec/ramaze/adapter/record.rb +31 -0
  118. data/spec/ramaze/cache.rb +41 -54
  119. data/spec/ramaze/controller.rb +121 -137
  120. data/spec/ramaze/controller/template/list.xhtml +1 -0
  121. data/spec/ramaze/controller/template/other/greet/other.xhtml +1 -0
  122. data/spec/ramaze/controller/template_resolving.rb +27 -3
  123. data/spec/ramaze/element.rb +11 -7
  124. data/spec/ramaze/error.rb +1 -1
  125. data/spec/ramaze/gestalt.rb +2 -0
  126. data/spec/ramaze/helper/aspect.rb +30 -21
  127. data/spec/ramaze/helper/auth.rb +1 -1
  128. data/spec/ramaze/helper/cache.rb +2 -1
  129. data/spec/ramaze/helper/form.rb +14 -11
  130. data/spec/ramaze/helper/link.rb +18 -41
  131. data/spec/ramaze/localize.rb +29 -2
  132. data/spec/ramaze/morpher.rb +23 -12
  133. data/spec/ramaze/params.rb +46 -24
  134. data/spec/ramaze/request.rb +6 -2
  135. data/spec/ramaze/store/yaml.rb +5 -0
  136. data/spec/ramaze/template.rb +22 -27
  137. data/spec/ramaze/template/amrita2.rb +1 -2
  138. data/spec/ramaze/template/erubis.rb +1 -1
  139. data/spec/ramaze/template/ezamar.rb +1 -2
  140. data/spec/ramaze/template/haml.rb +2 -2
  141. data/spec/ramaze/template/haml/with_vars.haml +1 -1
  142. data/spec/ramaze/template/liquid.rb +1 -1
  143. data/spec/ramaze/template/markaby.rb +1 -1
  144. data/spec/ramaze/template/remarkably.rb +56 -0
  145. data/spec/ramaze/template/remarkably/external.rem +8 -0
  146. data/spec/ramaze/template/remarkably/sum.rem +1 -0
  147. metadata +38 -63
  148. data/doc/README.html +0 -637
  149. data/doc/allison/LICENSE +0 -184
  150. data/doc/allison/README +0 -37
  151. data/doc/allison/allison.css +0 -299
  152. data/doc/allison/allison.gif +0 -0
  153. data/doc/allison/allison.js +0 -307
  154. data/doc/allison/allison.rb +0 -287
  155. data/doc/allison/cache/BODY +0 -588
  156. data/doc/allison/cache/CLASS_INDEX +0 -4
  157. data/doc/allison/cache/CLASS_PAGE +0 -1
  158. data/doc/allison/cache/FILE_INDEX +0 -4
  159. data/doc/allison/cache/FILE_PAGE +0 -1
  160. data/doc/allison/cache/FONTS +0 -1
  161. data/doc/allison/cache/FR_INDEX_BODY +0 -1
  162. data/doc/allison/cache/IMGPATH +0 -1
  163. data/doc/allison/cache/INDEX +0 -1
  164. data/doc/allison/cache/JAVASCRIPT +0 -307
  165. data/doc/allison/cache/METHOD_INDEX +0 -4
  166. data/doc/allison/cache/METHOD_LIST +0 -1
  167. data/doc/allison/cache/SRC_PAGE +0 -1
  168. data/doc/allison/cache/STYLE +0 -321
  169. data/doc/allison/cache/URL +0 -1
  170. data/doc/changes.txt +0 -3375
  171. data/doc/changes.xml +0 -3378
  172. data/examples/todolist/conf/benchmark.yaml +0 -35
  173. data/examples/todolist/conf/debug.yaml +0 -34
  174. data/examples/todolist/conf/live.yaml +0 -33
  175. data/examples/todolist/conf/silent.yaml +0 -31
  176. data/examples/todolist/conf/stage.yaml +0 -33
  177. data/examples/todolist/public/css/coderay.css +0 -105
  178. data/examples/todolist/public/css/ramaze_error.css +0 -42
  179. data/lib/proto/conf/benchmark.yaml +0 -21
  180. data/lib/proto/conf/debug.yaml +0 -21
  181. data/lib/proto/conf/live.yaml +0 -21
  182. data/lib/proto/conf/silent.yaml +0 -21
  183. data/lib/proto/conf/stage.yaml +0 -21
  184. data/lib/proto/public/css/coderay.css +0 -105
  185. data/lib/ramaze/http_status.rb +0 -66
  186. data/lib/ramaze/snippets/hash/keys_to_sym.rb +0 -19
  187. data/lib/ramaze/snippets/kernel/method.rb +0 -26
  188. data/lib/ramaze/snippets/method/name.rb +0 -22
  189. data/lib/ramaze/snippets/ramaze/autoreload.rb +0 -135
  190. data/lib/ramaze/snippets/rdoc/usage_no_exit.rb +0 -65
  191. data/spec/all.rb +0 -32
  192. data/spec/ramaze/conf/locale_de.yaml +0 -6
  193. data/spec/ramaze/conf/locale_en.yaml +0 -6
  194. data/spec/ramaze/dependencies.rb +0 -16
  195. data/spec/ramaze/global.rb +0 -44
@@ -1,184 +0,0 @@
1
- Academic Free License (AFL) v. 3.0
2
-
3
- This Academic Free License (the "License") applies to any original work
4
- of authorship (the "Original Work") whose owner (the "Licensor") has
5
- placed the following licensing notice adjacent to the copyright notice
6
- for the Original Work:
7
-
8
- Licensed under the Academic Free License version 3.0
9
-
10
- 1) Grant of Copyright License. Licensor grants You a worldwide,
11
- royalty-free, non-exclusive, sublicensable license, for the duration of
12
- the copyright, to do the following:
13
-
14
- a) to reproduce the Original Work in copies, either alone or as part of
15
- a collective work;
16
-
17
- b) to translate, adapt, alter, transform, modify, or arrange the
18
- Original Work, thereby creating derivative works ("Derivative Works")
19
- based upon the Original Work;
20
-
21
- c) to distribute or communicate copies of the Original Work and
22
- Derivative Works to the public, under any license of your choice that
23
- does not contradict the terms and conditions, including Licensor's
24
- reserved rights and remedies, in this Academic Free License;
25
-
26
- d) to perform the Original Work publicly; and
27
-
28
- e) to display the Original Work publicly.
29
-
30
- 2) Grant of Patent License. Licensor grants You a worldwide,
31
- royalty-free, non-exclusive, sublicensable license, under patent claims
32
- owned or controlled by the Licensor that are embodied in the Original
33
- Work as furnished by the Licensor, for the duration of the patents, to
34
- make, use, sell, offer for sale, have made, and import the Original Work
35
- and Derivative Works.
36
-
37
- 3) Grant of Source Code License. The term "Source Code" means the
38
- preferred form of the Original Work for making modifications to it and
39
- all available documentation describing how to modify the Original Work.
40
- Licensor agrees to provide a machine-readable copy of the Source Code of
41
- the Original Work along with each copy of the Original Work that
42
- Licensor distributes. Licensor reserves the right to satisfy this
43
- obligation by placing a machine-readable copy of the Source Code in an
44
- information repository reasonably calculated to permit inexpensive and
45
- convenient access by You for as long as Licensor continues to distribute
46
- the Original Work.
47
-
48
- 4) Exclusions From License Grant. Neither the names of Licensor, nor the
49
- names of any contributors to the Original Work, nor any of their
50
- trademarks or service marks, may be used to endorse or promote products
51
- derived from this Original Work without express prior permission of the
52
- Licensor. Except as expressly stated herein, nothing in this License
53
- grants any license to Licensor's trademarks, copyrights, patents, trade
54
- secrets or any other intellectual property. No patent license is granted
55
- to make, use, sell, offer for sale, have made, or import embodiments of
56
- any patent claims other than the licensed claims defined in Section 2.
57
- No license is granted to the trademarks of Licensor even if such marks
58
- are included in the Original Work. Nothing in this License shall be
59
- interpreted to prohibit Licensor from licensing under terms different
60
- from this License any Original Work that Licensor otherwise would have a
61
- right to license.
62
-
63
- 5) External Deployment. The term "External Deployment" means the use,
64
- distribution, or communication of the Original Work or Derivative Works
65
- in any way such that the Original Work or Derivative Works may be used
66
- by anyone other than You, whether those works are distributed or
67
- communicated to those persons or made available as an application
68
- intended for use over a network. As an express condition for the grants
69
- of license hereunder, You must treat any External Deployment by You of
70
- the Original Work or a Derivative Work as a distribution under section
71
- 1(c).
72
-
73
- 6) Attribution Rights. You must retain, in the Source Code of any
74
- Derivative Works that You create, all copyright, patent, or trademark
75
- notices from the Source Code of the Original Work, as well as any
76
- notices of licensing and any descriptive text identified therein as an
77
- "Attribution Notice." You must cause the Source Code for any Derivative
78
- Works that You create to carry a prominent Attribution Notice reasonably
79
- calculated to inform recipients that You have modified the Original
80
- Work.
81
-
82
- 7) Warranty of Provenance and Disclaimer of Warranty. Licensor warrants
83
- that the copyright in and to the Original Work and the patent rights
84
- granted herein by Licensor are owned by the Licensor or are sublicensed
85
- to You under the terms of this License with the permission of the
86
- contributor(s) of those copyrights and patent rights. Except as
87
- expressly stated in the immediately preceding sentence, the Original
88
- Work is provided under this License on an "AS IS" BASIS and WITHOUT
89
- WARRANTY, either express or implied, including, without limitation, the
90
- warranties of non-infringement, merchantability or fitness for a
91
- particular purpose. THE ENTIRE RISK AS TO THE QUALITY OF THE ORIGINAL
92
- WORK IS WITH YOU. This DISCLAIMER OF WARRANTY constitutes an essential
93
- part of this License. No license to the Original Work is granted by this
94
- License except under this disclaimer.
95
-
96
- 8) Limitation of Liability. Under no circumstances and under no legal
97
- theory, whether in tort (including negligence), contract, or otherwise,
98
- shall the Licensor be liable to anyone for any indirect, special,
99
- incidental, or consequential damages of any character arising as a
100
- result of this License or the use of the Original Work including,
101
- without limitation, damages for loss of goodwill, work stoppage,
102
- computer failure or malfunction, or any and all other commercial damages
103
- or losses. This limitation of liability shall not apply to the extent
104
- applicable law prohibits such limitation.
105
-
106
- 9) Acceptance and Termination. If, at any time, You expressly assented
107
- to this License, that assent indicates your clear and irrevocable
108
- acceptance of this License and all of its terms and conditions. If You
109
- distribute or communicate copies of the Original Work or a Derivative
110
- Work, You must make a reasonable effort under the circumstances to
111
- obtain the express assent of recipients to the terms of this License.
112
- This License conditions your rights to undertake the activities listed
113
- in Section 1, including your right to create Derivative Works based upon
114
- the Original Work, and doing so without honoring these terms and
115
- conditions is prohibited by copyright law and international treaty.
116
- Nothing in this License is intended to affect copyright exceptions and
117
- limitations (including "fair use" or "fair dealing"). This License shall
118
- terminate immediately and You may no longer exercise any of the rights
119
- granted to You by this License upon your failure to honor the conditions
120
- in Section 1(c).
121
-
122
- 10) Termination for Patent Action. This License shall terminate
123
- automatically and You may no longer exercise any of the rights granted
124
- to You by this License as of the date You commence an action, including
125
- a cross-claim or counterclaim, against Licensor or any licensee alleging
126
- that the Original Work infringes a patent. This termination provision
127
- shall not apply for an action alleging patent infringement by
128
- combinations of the Original Work with other software or hardware.
129
-
130
- 11) Jurisdiction, Venue and Governing Law. Any action or suit relating
131
- to this License may be brought only in the courts of a jurisdiction
132
- wherein the Licensor resides or in which Licensor conducts its primary
133
- business, and under the laws of that jurisdiction excluding its
134
- conflict-of-law provisions. The application of the United Nations
135
- Convention on Contracts for the International Sale of Goods is expressly
136
- excluded. Any use of the Original Work outside the scope of this License
137
- or after its termination shall be subject to the requirements and
138
- penalties of copyright or patent law in the appropriate jurisdiction.
139
- This section shall survive the termination of this License.
140
-
141
- 12) Attorneys' Fees. In any action to enforce the terms of this License
142
- or seeking damages relating thereto, the prevailing party shall be
143
- entitled to recover its costs and expenses, including, without
144
- limitation, reasonable attorneys' fees and costs incurred in connection
145
- with such action, including any appeal of such action. This section
146
- shall survive the termination of this License.
147
-
148
- 13) Miscellaneous. If any provision of this License is held to be
149
- unenforceable, such provision shall be reformed only to the extent
150
- necessary to make it enforceable.
151
-
152
- 14) Definition of "You" in This License. "You" throughout this License,
153
- whether in upper or lower case, means an individual or a legal entity
154
- exercising rights under, and complying with all of the terms of, this
155
- License. For legal entities, "You" includes any entity that controls, is
156
- controlled by, or is under common control with you. For purposes of this
157
- definition, "control" means (i) the power, direct or indirect, to cause
158
- the direction or management of such entity, whether by contract or
159
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
160
- outstanding shares, or (iii) beneficial ownership of such entity.
161
-
162
- 15) Right to Use. You may use the Original Work in all ways not
163
- otherwise restricted or conditioned by this License or by law, and
164
- Licensor promises not to interfere with or be responsible for such uses
165
- by You.
166
-
167
- 16) Modification of This License. This License is Copyright (c) 2005
168
- Lawrence Rosen. Permission is granted to copy, distribute, or
169
- communicate this License without modification. Nothing in this License
170
- permits You to modify this License as applied to the Original Work or to
171
- Derivative Works. However, You may modify the text of this License and
172
- copy, distribute or communicate your modified version (the "Modified
173
- License") and apply it to other original works of authorship subject to
174
- the following conditions: (i) You may not indicate in any way that your
175
- Modified License is the "Academic Free License" or "AFL" and you may not
176
- use those names in the name of your Modified License; (ii) You must
177
- replace the notice specified in the first paragraph above with the
178
- notice "Licensed under <insert your license name here>" or with a notice
179
- of your own that is not confusingly similar to the notice in this
180
- License; and (iii) You may not claim that your original works are open
181
- source software unless your Modified License has been approved by Open
182
- Source Initiative (OSI) and You comply with its license review and
183
- certification process.
184
-
@@ -1,37 +0,0 @@
1
-
2
- COPYRIGHT
3
-
4
- Allison template for RDoc, copyright 2006 Cloudburst, LLC (see the LICENSE file)
5
-
6
- DETAILED DOCUMENTATION
7
-
8
- http://blog.evanweaver.com/articles/2006/06/02/allison
9
-
10
- QUICKSTART
11
-
12
- The best way to use the template is to set up a Rake task for your Ruby project or Rails app:
13
- in Rakefile
14
-
15
- require 'rake/rdoctask'
16
-
17
- Rake::RDocTask.new do |rdoc|
18
- files = ['README', 'LICENSE', 'COPYING', 'lib/**/*.rb',
19
- 'doc/**/*.rdoc', 'test/*.rb']
20
- rdoc.rdoc_files.add(files)
21
- rdoc.main = "README" # page to start on
22
- rdoc.title = "My App's Documentation"
23
- rdoc.template = "/path/to/allison/allison.rb"
24
- rdoc.rdoc_dir = 'doc' # rdoc output folder
25
- rdoc.options << '--line-numbers' << '--inline-source'
26
- end
27
-
28
- Then you can run rake rdoc to invoke the task and everything will be super awesome.
29
-
30
- Note, pop-up source view is not supported. You have to use --inline-source.
31
-
32
- CHANGELOG
33
-
34
- 2.2 how come "require_gem" isn't called "activate_gem", since that's what it does. bah.
35
- 2.1 hack to make gem versioning work
36
- 2. caching in order to remove Markaby dependency
37
- 1. first release
@@ -1,299 +0,0 @@
1
- /* Stylesheet for Allison RDoc template */
2
- /* Copyright 2006 Cloudburst LLC */
3
-
4
- /* default styles */
5
-
6
- * {
7
- margin: 0
8
- padding: 0
9
- border: none
10
- }
11
-
12
- a {
13
- color: @dark_teal = "#244"
14
- font-weight: bold
15
- text-decoration: none
16
- }
17
-
18
- a:hover {
19
- text-decoration: underline
20
- } a:visited {
21
- font-weight: normal
22
- }
23
-
24
- html, body {
25
- color: @body_color = "#270f2b"
26
- background-color: @background_teal = "#eeffff"
27
- text-align: center
28
- margin: 0
29
- padding: 0
30
- }
31
-
32
- p, ul, ol, li {
33
- line-height: @lh = "1.4em"
34
- margin: .4em
35
- } p {
36
- margin: @lh
37
- } h1 {
38
- margin-top: .4em
39
- } #item_name {
40
- margin-top: -.4em
41
- }
42
-
43
- h2 {
44
- font-size: 2em
45
- margin-top: 1em
46
- margin-right: -1em
47
- }
48
-
49
-
50
- /* center everything */
51
-
52
- #container {
53
- margin: 20px auto 0 auto
54
- width: @width = 900
55
- text-align: left
56
- }
57
-
58
-
59
- @buffer = 10
60
-
61
- /* header stuff */
62
-
63
- #header {
64
- padding: @buffer
65
- padding-top: 0
66
- width: @width - @buffer * 2
67
- height: @d= 91 - @buffer * 2
68
- _height: @d + @buffer
69
- margin-bottom: 25px
70
- vertical-align: baseline
71
- background: url('data:image/gif;base64,%allison.gif%') no-repeat top right
72
- background-color: @red_purple = "#cee"
73
- overflow: hidden
74
- } .curve {
75
- background-color: @red_purple
76
- margin: 0
77
- padding: 0
78
- height: 1px
79
- overflow: hidden /* again, ie problem */
80
- }
81
-
82
- def curve(div_id, curve_array, width); s = ""; curve_array.length.times {|n| s += "\n##{div_id}#{curve_array.length - 1 - n}{border-left: #{curve_array[n]}px solid #{@background_teal}; border-right: #{curve_array[n]}px solid #{@background_teal}; width: #{width - curve_array[n]*2}px; _width: #{width - 20}px; }"}; s; end
83
- @curves = [0, 1, 1, 1, 2, 2, 3, 4, 5, 7, 10]
84
-
85
- curve("preheader_curve_", @curves, @width)
86
-
87
- #header h1 {
88
- color: @white = "#122"
89
- font-size: 3em
90
- margin: 0
91
- } #header p {
92
- margin: 0
93
- padding: 0
94
- padding-left: 3px
95
- color: @white
96
- } #header a {
97
- color: @white
98
- text-decoration: none
99
- font-weight: bold
100
- }
101
-
102
- /* basic layout and navigation bars */
103
-
104
- #left {
105
- background-color: @deep_purple = "#cdd"
106
- width: @left_width = 220
107
- float: left
108
- _width: @left_width - @buffer * 2
109
- } #left a {
110
- line-height: 1.2em
111
- } #left div.curve {
112
- float: left
113
- background-color: @deep_purple
114
- }
115
-
116
- /* navigation bar colors and text styles */
117
-
118
- .navigation {
119
- width: @left_width - @buffer * 4
120
- margin: @buffer
121
- padding: @buffer
122
- text-align: left
123
- background-color: @background_teal
124
- overflow: hidden
125
- } .navigation a, {
126
- margin-left: @buffer
127
- } .navigation h3 {
128
- font-weight: bold
129
- margin-bottom: 5px
130
- } .dark {
131
- background-color: @gray_purple = "#bcc"
132
- } .dark a, .dark span {
133
- color: @white
134
- margin-left: @buffer
135
- } span.bpink {
136
- color: @dark_teal
137
- font-weight: bold
138
- margin-left: @buffer
139
- } span.bpink a, .dark span a {
140
- margin-left: 0
141
- } #spacer {
142
- background-color: @background_teal
143
- height: @buffer * 3
144
- display: none
145
- }
146
-
147
- #content {
148
- padding: @content_padding = 20
149
- width: @width - @left_width - @content_padding * 2
150
- background-color: @background_teal
151
- float: left
152
- }
153
-
154
- .clear {
155
- clear: both
156
- }
157
-
158
- #footer {
159
- margin: 0 auto
160
- text-align: right
161
- background-color: @background_teal
162
- font-size: .8em
163
- padding: @buffer
164
- } #footer a {
165
- font-weight: normal
166
- color: @gray_purple
167
- }
168
-
169
- /* for that dumb redirect index page I can't avoid */
170
-
171
- #redirect {
172
- text-align: center
173
- } #redirect a {
174
- color: @deep_purple
175
- }
176
-
177
- /* tables */
178
-
179
- table {
180
- width: @width - @left_width - @buffer * 8
181
- border-collapse: collapse
182
- }
183
- td, th {
184
- background-color: @background_teal
185
- text-align: left
186
- padding-left: @td = @buffer / 2
187
- padding-right: @td
188
- padding-top: @td
189
- line-height: 1.2em
190
- } th {
191
- color: @white
192
- background-color: @red_purple
193
- } th.description {
194
- text-align: center
195
- } td.highlight {
196
- color: @dark_teal
197
- } td.first, th.first {
198
- background-color: @red_purple
199
- }
200
-
201
-
202
- /* method details */
203
-
204
- div.a_method {
205
- background: @red_purple
206
- padding: @buffer
207
- margin-left: @buffer * 2 + 2
208
- } div.a_method h3 {
209
- color: @dark_teal
210
- } div.a_method div {
211
- background: #bdd
212
- padding-left: @buffer
213
- } div.a_method a.small {
214
- font-size: .1em
215
- line-height: .1em
216
- } div.a_method p {
217
- margin: .6em
218
- margin-left: @lh
219
- }
220
-
221
- div.section_spacer {
222
- height: 0
223
- margin-top: @buffer * 2
224
- }
225
-
226
-
227
- /* index includes on the navigation bar */
228
-
229
- div.index a {
230
- font-size: .8em
231
- } #method {
232
- display: none
233
- } #file, #class {
234
- display: block
235
- } div.list_header {
236
- float: left
237
- } div.list_header_link {
238
- float: right
239
- padding-top: 3px
240
- } div.list_header_link a {
241
- font-weight: normal
242
- } #method_wrapper {
243
- margin-bottom: 0
244
- }
245
-
246
- .index label {
247
- font-size: 0.8em
248
- } .index form input {
249
- width: @left_width - @buffer * 11
250
- } .index form {
251
- margin-bottom: @buffer
252
- }
253
-
254
- curve("left_curve_", @curves.reverse, @left_width)
255
-
256
- ol, ul {
257
- margin-left: @buffer * 5
258
- } ul {
259
- list-style-type: square
260
- }
261
-
262
- p.source_link a {
263
- text-align: right
264
- font-weight: normal
265
- } div.source {
266
- display: none
267
- } pre {
268
- color: black
269
- font-weight: normal
270
- /* font-family: Courier, Courier New, monospace */
271
- font-size: .8em
272
- padding: @buffer
273
- margin-left: @buffer * 2
274
- overflow: auto
275
- /* next 4 lines because IE sucks */
276
- _position: relative
277
- _width: @width - @left_width - (@buffer * 11 + 3)
278
- _overflow-x:scroll
279
- _overflow-y:visible
280
- } div.source pre {
281
- margin-left: 0
282
- } p.source_link {
283
- text-align: center
284
- }
285
-
286
- /* source code highlighting */
287
-
288
- pre .ruby-value, pre .ruby-symbol {
289
- color: @blue = "#1104bb"
290
- } pre .ruby-value.str, pre .ruby-node {
291
- color: @dark_teal #red = "#d20000"
292
- } pre .ruby-ivar, pre .ruby-cvar {
293
- } pre .ruby-comment {
294
- color: @green = "#009500"
295
- } pre .ruby-constant {
296
- color: @orange = "#cd8802"
297
- } pre .ruby-keyword {
298
- color: @purple = "#8d04aa"
299
- }