webby 0.9.0 → 0.9.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (76) hide show
  1. data/History.txt +11 -0
  2. data/Manifest.txt +45 -2
  3. data/Rakefile +1 -2
  4. data/examples/webby/content/css/site.css +1 -1
  5. data/examples/webby/content/learn/index.txt +1 -1
  6. data/examples/webby/content/release-notes/index.txt +21 -0
  7. data/examples/webby/content/release-notes/rel-0-9-0/index.txt +1 -0
  8. data/examples/webby/content/release-notes/rel-0-9-1/index.txt +93 -0
  9. data/examples/webby/content/tips_and_tricks/index.txt +14 -13
  10. data/examples/webby/content/tutorial/index.txt +13 -9
  11. data/examples/webby/content/user-manual/index.txt +8 -8
  12. data/examples/webby/layouts/default.txt +1 -1
  13. data/lib/webby.rb +2 -1
  14. data/lib/webby/apps/main.rb +25 -13
  15. data/lib/webby/auto_builder.rb +2 -0
  16. data/lib/webby/builder.rb +2 -5
  17. data/lib/webby/filters.rb +5 -13
  18. data/lib/webby/renderer.rb +7 -5
  19. data/lib/webby/resources.rb +54 -14
  20. data/lib/webby/resources/db.rb +4 -4
  21. data/lib/webby/resources/layout.rb +14 -23
  22. data/lib/webby/resources/meta_file.rb +208 -0
  23. data/lib/webby/resources/page.rb +21 -58
  24. data/lib/webby/resources/partial.rb +10 -4
  25. data/lib/webby/resources/resource.rb +68 -27
  26. data/lib/webby/resources/static.rb +6 -22
  27. data/lib/webby/stelan/paginator.rb +17 -2
  28. data/spec/data/Sitefile +9 -0
  29. data/spec/data/content/_partial.txt +10 -0
  30. data/spec/data/content/css/coderay.css +111 -0
  31. data/spec/data/content/css/site.css +67 -0
  32. data/spec/data/content/css/tumblog.css +308 -0
  33. data/spec/data/content/images/tumblog/permalink.gif +0 -0
  34. data/spec/data/content/images/tumblog/rss.gif +0 -0
  35. data/spec/data/content/index.txt +19 -0
  36. data/spec/data/content/photos.txt +21 -0
  37. data/spec/data/content/tumblog/200806/the-noble-chicken/index.txt +12 -0
  38. data/spec/data/content/tumblog/200807/historical-perspectives-on-the-classic-chicken-joke/index.txt +12 -0
  39. data/spec/data/content/tumblog/200807/mad-city-chickens/index.txt +10 -0
  40. data/spec/data/content/tumblog/200807/the-wisdom-of-the-dutch/index.txt +11 -0
  41. data/spec/data/content/tumblog/200807/up-a-tree/index.txt +13 -0
  42. data/spec/data/content/tumblog/index.txt +37 -0
  43. data/spec/data/content/tumblog/rss.txt +37 -0
  44. data/spec/data/hooligans/bad_meta_data_1.txt +34 -0
  45. data/spec/data/hooligans/bad_meta_data_2.txt +34 -0
  46. data/spec/data/layouts/default.txt +58 -0
  47. data/spec/data/layouts/tumblog/default.txt +44 -0
  48. data/spec/data/layouts/tumblog/post.txt +15 -0
  49. data/spec/data/lib/breadcrumbs.rb +28 -0
  50. data/spec/data/lib/tumblog_helper.rb +32 -0
  51. data/spec/data/tasks/tumblog.rake +30 -0
  52. data/spec/data/templates/_partial.erb +10 -0
  53. data/spec/data/templates/atom_feed.erb +40 -0
  54. data/spec/data/templates/page.erb +18 -0
  55. data/spec/data/templates/presentation.erb +40 -0
  56. data/spec/data/templates/tumblog/conversation.erb +12 -0
  57. data/spec/data/templates/tumblog/link.erb +10 -0
  58. data/spec/data/templates/tumblog/photo.erb +13 -0
  59. data/spec/data/templates/tumblog/post.erb +12 -0
  60. data/spec/data/templates/tumblog/quote.erb +11 -0
  61. data/spec/spec_helper.rb +37 -0
  62. data/spec/webby/apps/generator_spec.rb +4 -0
  63. data/spec/webby/apps/main_spec.rb +16 -3
  64. data/spec/webby/filters/textile_spec.rb +20 -0
  65. data/spec/webby/renderer_spec.rb +139 -0
  66. data/spec/webby/resources/db_spec.rb +250 -0
  67. data/spec/webby/resources/layout_spec.rb +83 -0
  68. data/spec/webby/resources/meta_file_spec.rb +157 -0
  69. data/spec/webby/resources/page_spec.rb +111 -0
  70. data/spec/webby/resources/partial_spec.rb +58 -0
  71. data/spec/webby/resources/resource_spec.rb +214 -0
  72. data/spec/webby/resources/static_spec.rb +49 -0
  73. data/spec/webby/resources_spec.rb +55 -3
  74. metadata +64 -6
  75. data/lib/webby/resources/file.rb +0 -221
  76. data/spec/webby/resources/file_spec.rb +0 -104
@@ -9,22 +9,22 @@ module Webby::Resources
9
9
  #
10
10
  class Page < Resource
11
11
 
12
- # Resource page number (if needed)
13
- attr_reader :number
14
-
15
12
  # call-seq:
16
13
  # Resource.new( path )
17
14
  #
18
15
  # Creates a new page object from the full path to the page file.
19
16
  #
20
- def initialize( fn )
21
- super
22
- @number = nil
23
-
24
- @mdata = ::Webby::Resources::File.meta_data(@path)
25
- @mdata ||= {}
26
- @mdata = ::Webby.site.page_defaults.merge(@mdata)
27
- @mdata.sanitize!
17
+ def initialize( fn, meta_data = nil )
18
+ super(fn)
19
+
20
+ if meta_data.instance_of?(Hash)
21
+ @_meta_data = meta_data
22
+ else
23
+ @_meta_data = MetaFile.meta_data(@path)
24
+ @_meta_data ||= {}
25
+ end
26
+ @_meta_data = ::Webby.site.page_defaults.merge(@_meta_data)
27
+ @_meta_data.sanitize!
28
28
  end
29
29
 
30
30
  # call-seq:
@@ -46,51 +46,13 @@ class Page < Resource
46
46
  # is returned for layouts.
47
47
  #
48
48
  def url
49
- return @url if defined? @url and @url
49
+ return @url unless @url.nil?
50
50
 
51
- @url = destination.sub(::Webby.site.output_dir, '')
52
- @url = File.dirname(@url) if filename == 'index' and number.nil?
51
+ @url = super
52
+ @url = File.dirname(@url) if filename == 'index'
53
53
  @url
54
54
  end
55
55
 
56
- # call-seq:
57
- # page.number = Integer
58
- #
59
- # Sets the page number for the current resource to the given integer. This
60
- # number is used to modify the output destination for resources that
61
- # require pagination.
62
- #
63
- def number=( num )
64
- @number = num
65
- @url = @dest = nil
66
- end
67
-
68
- # call-seq:
69
- # destination => string
70
- #
71
- # Returns the path in the output directory where the rendered page should
72
- # be stored. This path is used to determine if the page is dirty and in
73
- # need of rendering.
74
- #
75
- # The destination for a page can be overridden by explicitly setting
76
- # the 'destination' property in the page's meta-data.
77
- #
78
- def destination
79
- return @dest if defined? @dest and @dest
80
-
81
- @dest = if @mdata.has_key? 'destination' then @mdata['destination']
82
- else ::File.join(dir, filename) end
83
-
84
- @dest = ::File.join(::Webby.site.output_dir, @dest)
85
- @dest << @number.to_s if @number
86
-
87
- ext = extension
88
- unless ext.nil? or ext.empty?
89
- @dest << '.' << ext
90
- end
91
- @dest
92
- end
93
-
94
56
  # call-seq:
95
57
  # extension => string
96
58
  #
@@ -102,14 +64,15 @@ class Page < Resource
102
64
  # * the extension of this page file
103
65
  #
104
66
  def extension
105
- return @mdata['extension'] if @mdata.has_key? 'extension'
67
+ return _meta_data['extension'] if _meta_data.has_key? 'extension'
106
68
 
107
- if @mdata.has_key? 'layout'
108
- lyt = ::Webby::Resources.find_layout(@mdata['layout'])
109
- ext = lyt ? lyt.extension : nil
110
- return ext if ext
69
+ if _meta_data.has_key? 'layout'
70
+ lyt = ::Webby::Resources.find_layout(_meta_data['layout'])
71
+ lyt_ext = lyt ? lyt.extension : nil
72
+ return lyt_ext if lyt_ext
111
73
  end
112
- @ext
74
+
75
+ ext
113
76
  end
114
77
 
115
78
  end # class Page
@@ -24,9 +24,9 @@ class Partial < Resource
24
24
  def initialize( fn )
25
25
  super
26
26
 
27
- @mdata = ::Webby::Resources::File.meta_data(@path)
28
- @mdata ||= {}
29
- @mdata.sanitize!
27
+ @_meta_data = MetaFile.meta_data(@path)
28
+ @_meta_data ||= {}
29
+ @_meta_data.sanitize!
30
30
  end
31
31
 
32
32
  # call-seq:
@@ -37,7 +37,7 @@ class Partial < Resource
37
37
  # copied (if a static file) to the output directory.
38
38
  #
39
39
  def dirty?
40
- return @mdata['dirty'] if @mdata.has_key? 'dirty'
40
+ return _meta_data['dirty'] if _meta_data.has_key? 'dirty'
41
41
 
42
42
  # if the destination file does not exist, then we are dirty
43
43
  return true unless test(?e, destination)
@@ -73,6 +73,12 @@ class Partial < Resource
73
73
  nil
74
74
  end
75
75
 
76
+ # :stopdoc:
77
+ def _read
78
+ MetaFile.read(@path)
79
+ end
80
+ # :startdoc:
81
+
76
82
  end # class Partial
77
83
  end # module Webby::Resources
78
84
 
@@ -16,31 +16,34 @@ class Resource
16
16
  # The full path to the resource file
17
17
  attr_reader :path
18
18
 
19
+ # The name of the file excluding the directory and extension
20
+ attr_reader :name
21
+
19
22
  # The directory of the resource excluding the content directory
20
23
  attr_reader :dir
21
24
 
22
- # The resource filename excluding path and extension
23
- attr_reader :filename
24
-
25
25
  # Extesion of the resource file
26
26
  attr_reader :ext
27
27
 
28
28
  # Resource file modification time
29
29
  attr_reader :mtime
30
30
 
31
+ attr_reader :_meta_data #:nodoc:
32
+
31
33
  # call-seq:
32
34
  # Resource.new( filename ) => resource
33
35
  #
34
36
  # Creates a new resource object given the _filename_.
35
37
  #
36
38
  def initialize( fn )
37
- @path = fn
38
- @dir = ::Webby::Resources::File.dirname(@path)
39
- @filename = ::Webby::Resources::File.basename(@path)
40
- @ext = ::Webby::Resources::File.extname(@path)
41
- @mtime = ::File.mtime @path
42
-
43
- @mdata = @@mdata ||= {}
39
+ @path = fn
40
+ @dir = ::Webby::Resources.dirname(@path)
41
+ @name = ::Webby::Resources.basename(@path)
42
+ @ext = ::Webby::Resources.extname(@path)
43
+ @mtime = ::File.mtime @path
44
+
45
+ @_meta_data = {}
46
+ self._reset
44
47
  end
45
48
 
46
49
  # call-seq:
@@ -51,7 +54,7 @@ class Resource
51
54
  #
52
55
  def equal?( other )
53
56
  return false unless other.kind_of? ::Webby::Resources::Resource
54
- @path == other.path
57
+ self.destination == other.destination
55
58
  end
56
59
  alias :== :equal?
57
60
  alias :eql? :equal?
@@ -65,7 +68,7 @@ class Resource
65
68
  #
66
69
  def <=>( other )
67
70
  return unless other.kind_of? ::Webby::Resources::Resource
68
- @path <=> other.path
71
+ self.destination <=> other.destination
69
72
  end
70
73
 
71
74
  # call-seq:
@@ -75,7 +78,7 @@ class Resource
75
78
  # converted into a string.
76
79
  #
77
80
  def []( key )
78
- @mdata[key.to_s]
81
+ _meta_data[key.to_s]
79
82
  end
80
83
 
81
84
  # call-seq:
@@ -85,7 +88,7 @@ class Resource
85
88
  # string.
86
89
  #
87
90
  def []=( key, value )
88
- @mdata[key.to_s] = value
91
+ _meta_data[key.to_s] = value
89
92
  end
90
93
 
91
94
  # call-seq:
@@ -97,7 +100,7 @@ class Resource
97
100
  # meta-data item is returned; otherwise, +nil+ is returned.
98
101
  #
99
102
  def method_missing( name, *a, &b )
100
- @mdata[name.to_s]
103
+ _meta_data[name.to_s]
101
104
  end
102
105
 
103
106
  # call-seq:
@@ -108,7 +111,7 @@ class Resource
108
111
  # copied (if a static file) to the output directory.
109
112
  #
110
113
  def dirty?
111
- return @mdata['dirty'] if @mdata.has_key? 'dirty'
114
+ return _meta_data['dirty'] if _meta_data.has_key? 'dirty'
112
115
 
113
116
  # if the destination file does not exist, then we are dirty
114
117
  return true unless test(?e, destination)
@@ -120,8 +123,8 @@ class Resource
120
123
 
121
124
  # check to see if the layout is dirty, and if it is then we
122
125
  # are dirty, too
123
- if @mdata.has_key? 'layout'
124
- lyt = ::Webby::Resources.find_layout(@mdata['layout'])
126
+ if _meta_data.has_key? 'layout'
127
+ lyt = ::Webby::Resources.find_layout(_meta_data['layout'])
125
128
  unless lyt.nil?
126
129
  return true if lyt.dirty?
127
130
  end
@@ -131,24 +134,62 @@ class Resource
131
134
  false
132
135
  end
133
136
 
134
- # call-seq
135
- # url => string or nil
137
+ # The resource filename excluding path and extension. This will either be
138
+ # the name of the file or the 'filename' attribute from the meta-data if
139
+ # present.
136
140
  #
137
- # Returns a string suitable for use as a URL linking to this page. Nil
138
- # is returned for layouts.
141
+ def filename
142
+ return _meta_data['filename'] if _meta_data.has_key? 'filename'
143
+ name
144
+ end
145
+
146
+ # The resource file extension. This will either be the extension of the
147
+ # file or the 'extension' attribute from the meta-data if present.
148
+ #
149
+ def extension
150
+ return _meta_data['extension'] if _meta_data.has_key? 'extension'
151
+ ext
152
+ end
153
+
154
+ # The location of this resource in the directory structure. This directory
155
+ # does not include the content folder or the output folder.
156
+ #
157
+ def directory
158
+ return _meta_data['directory'] if _meta_data.has_key? 'directory'
159
+ dir
160
+ end
161
+
162
+ # Returns the path in the output directory where the resource will be
163
+ # generated. This path is used to determine if the resource is dirty
164
+ # and in need of generating.
165
+ #
166
+ def destination
167
+ return @destination unless @destination.nil?
168
+
169
+ @destination = ::File.join(::Webby.site.output_dir, directory, filename)
170
+ ext = extension
171
+ unless ext.nil? or ext.empty?
172
+ @destination << '.' << ext
173
+ end
174
+ @destination
175
+ end
176
+
177
+ # Returns a string suitable for use as a URL linking to this resource.
139
178
  #
140
179
  def url
141
- return @url if defined? @url and @url
180
+ return @url unless @url.nil?
142
181
  @url = destination.sub(::Webby.site.output_dir, '')
143
182
  end
144
183
 
145
184
  # :stopdoc:
146
- def destination
147
- raise NotImplementedError
185
+ def _read
186
+ MetaFile.read(@path)
148
187
  end
149
188
 
150
- def extension
151
- raise NotImplementedError
189
+ def _reset( meta_data = nil )
190
+ _meta_data.replace(meta_data) if meta_data.instance_of?(Hash)
191
+ @url = nil
192
+ @destination = nil
152
193
  end
153
194
  # :startdoc:
154
195
 
@@ -9,18 +9,13 @@ module Webby::Resources
9
9
  #
10
10
  class Static < Resource
11
11
 
12
- # call-seq:
13
- # render => string
14
- #
15
12
  # Returns the contents of the file.
16
13
  #
17
14
  def render
18
- ::File.read(path)
15
+ Webby.deprecated "render", "it is being replaced by the Renderer#render() method"
16
+ self._read
19
17
  end
20
18
 
21
- # call-seq:
22
- # dirty? => true or false
23
- #
24
19
  # Returns +true+ if this static file is newer than its corresponding output
25
20
  # product. The static file needs to be copied to the output directory.
26
21
  #
@@ -29,22 +24,11 @@ class Static < Resource
29
24
  @mtime > ::File.mtime(destination)
30
25
  end
31
26
 
32
- # call-seq:
33
- # destination => string
34
- #
35
- # Returns the path in the output directory where the static file should
36
- # be copied. This path is used to determine if the static file is dirty
37
- # and in need of copying to the output file.
38
- #
39
- def destination
40
- return @dest if defined? @dest and @dest
41
-
42
- @dest = ::File.join(::Webby.site.output_dir, dir, filename)
43
- @dest << '.' << @ext if @ext and !@ext.empty?
44
- @dest
27
+ # :stopdoc:
28
+ def _read
29
+ ::File.read(path)
45
30
  end
46
-
47
- alias :extension :ext
31
+ # :startdoc:
48
32
 
49
33
  end # class Layout
50
34
  end # module Webby::Resources
@@ -18,7 +18,7 @@ class Paginator
18
18
  class MissingCountError < ArgumentError; end
19
19
  class MissingSelectError < ArgumentError; end
20
20
 
21
- attr_reader :per_page, :count, :resource
21
+ attr_reader :per_page, :count, :resource, :filename, :directory
22
22
 
23
23
  # Instantiate a new Paginator object
24
24
  #
@@ -31,6 +31,9 @@ class Paginator
31
31
  # convenience, if the arity is 2)
32
32
  def initialize(count, per_page, resource, &select)
33
33
  @count, @per_page, @resource = count, per_page, resource
34
+ @meta_data = @resource._meta_data.dup
35
+ @filename = @resource.filename
36
+ @directory = @resource.directory
34
37
  unless select
35
38
  raise MissingSelectError, "Must provide block to select data for each page"
36
39
  end
@@ -68,6 +71,11 @@ class Paginator
68
71
  @select.call(*args)
69
72
  })
70
73
  end
74
+
75
+ # Finalizer method that should be called when the paginator is finished
76
+ def done
77
+ resource._reset(@meta_data)
78
+ end
71
79
 
72
80
  # Page object
73
81
  #
@@ -84,7 +92,14 @@ class Paginator
84
92
  @offset = (number - 1) * pager.per_page
85
93
  @select = select
86
94
 
87
- @pager.resource.number = (number == 1 ? nil : number)
95
+ @pager.resource._reset
96
+ if number > 1
97
+ if ::Webby.site.create_mode == 'directory'
98
+ @pager.resource['directory'] = File.join(@pager.directory, number.to_s)
99
+ else
100
+ @pager.resource['filename'] = @pager.filename + number.to_s
101
+ end
102
+ end
88
103
  @url = @pager.resource.url
89
104
  end
90
105
 
@@ -0,0 +1,9 @@
1
+
2
+ task :default => :build
3
+
4
+ desc 'deploy the site to the webserver'
5
+ task :deploy => [:build, 'deploy:rsync']
6
+
7
+ SITE.create_mode = 'directory'
8
+
9
+ # EOF
@@ -0,0 +1,10 @@
1
+ ---
2
+ filter: erb
3
+ ---
4
+ A partial has access to the page from which it was called. The title below will be the title of the page in which this partial is rendered.
5
+
6
+ <%%= h(@page.title) %>
7
+
8
+ A partial does not have access to it's own meta-data. The partial meta-data is used primarily for finding partials or for use in other pages. The filter(s) specified in the meta-data will be applied to the partial text when it is rendered.
9
+
10
+ A partial does not require meta-data at all. They can contain just text.
@@ -0,0 +1,111 @@
1
+ .CodeRay {
2
+ padding: 0.5em;
3
+ margin-bottom: 1.3em;
4
+ background-color: #eee;
5
+ border: 1px solid #aaa;
6
+ font: 1.1em Monaco, 'Courier New', 'Terminal', monospace;
7
+ color: #100;
8
+ }
9
+ .CodeRay pre {
10
+ padding: 0px;
11
+ margin: 0px;
12
+ overflow: auto;
13
+ background-color: transparent;
14
+ border: none;
15
+ }
16
+
17
+ div.CodeRay { }
18
+
19
+ span.CodeRay { white-space: pre; border: 0px; padding: 2px }
20
+
21
+ table.CodeRay { border-collapse: collapse; width: 100%; padding: 2px }
22
+ table.CodeRay td { padding: 2px 4px; vertical-align: top }
23
+
24
+ .CodeRay .line_numbers, .CodeRay .no {
25
+ background-color: #def;
26
+ color: gray;
27
+ text-align: right;
28
+ }
29
+ .CodeRay .line_numbers tt { font-weight: bold }
30
+ .CodeRay .no { padding: 0px 4px }
31
+
32
+ ol.CodeRay { font-size: 10pt }
33
+ ol.CodeRay li { white-space: pre }
34
+
35
+ .CodeRay .debug { color:white ! important; background:blue ! important; }
36
+
37
+ .CodeRay .af { color:#00C }
38
+ .CodeRay .an { color:#007 }
39
+ .CodeRay .av { color:#700 }
40
+ .CodeRay .aw { color:#C00 }
41
+ .CodeRay .bi { color:#509; font-weight:bold }
42
+ .CodeRay .c { color:#666; }
43
+
44
+ .CodeRay .ch { color:#04D }
45
+ .CodeRay .ch .k { color:#04D }
46
+ .CodeRay .ch .dl { color:#039 }
47
+
48
+ .CodeRay .cl { color:#B06; font-weight:bold }
49
+ .CodeRay .co { color:#036; font-weight:bold }
50
+ .CodeRay .cr { color:#0A0 }
51
+ .CodeRay .cv { color:#369 }
52
+ .CodeRay .df { color:#099; font-weight:bold }
53
+ .CodeRay .di { color:#088; font-weight:bold }
54
+ .CodeRay .dl { color:black }
55
+ .CodeRay .do { color:#970 }
56
+ .CodeRay .ds { color:#D42; font-weight:bold }
57
+ .CodeRay .e { color:#666; font-weight:bold }
58
+ .CodeRay .en { color:#800; font-weight:bold }
59
+ .CodeRay .er { color:#F00; background-color:#FAA }
60
+ .CodeRay .ex { color:#F00; font-weight:bold }
61
+ .CodeRay .fl { color:#60E; font-weight:bold }
62
+ .CodeRay .fu { color:#06B; font-weight:bold }
63
+ .CodeRay .gv { color:#d70; font-weight:bold }
64
+ .CodeRay .hx { color:#058; font-weight:bold }
65
+ .CodeRay .i { color:#00D; font-weight:bold }
66
+ .CodeRay .ic { color:#B44; font-weight:bold }
67
+
68
+ .CodeRay .il { background: #eee }
69
+ .CodeRay .il .il { background: #ddd }
70
+ .CodeRay .il .il .il { background: #ccc }
71
+ .CodeRay .il .idl { font-weight: bold; color: #888 }
72
+
73
+ .CodeRay .in { color:#B2B; font-weight:bold }
74
+ .CodeRay .iv { color:#33B }
75
+ .CodeRay .la { color:#970; font-weight:bold }
76
+ .CodeRay .lv { color:#963 }
77
+ .CodeRay .oc { color:#40E; font-weight:bold }
78
+ .CodeRay .of { color:#000; font-weight:bold }
79
+ .CodeRay .op { }
80
+ .CodeRay .pc { color:#038; font-weight:bold }
81
+ .CodeRay .pd { color:#369; font-weight:bold }
82
+ .CodeRay .pp { color:#579 }
83
+ .CodeRay .pt { color:#339; font-weight:bold }
84
+ .CodeRay .r { color:#080; font-weight:bold }
85
+
86
+ .CodeRay .rx { background-color:#fff0ff }
87
+ .CodeRay .rx .k { color:#808 }
88
+ .CodeRay .rx .dl { color:#404 }
89
+ .CodeRay .rx .mod { color:#C2C }
90
+ .CodeRay .rx .fu { color:#404; font-weight: bold }
91
+
92
+ .CodeRay .s { background-color:#fff0f0 }
93
+ .CodeRay .s .s { background-color:#ffe0e0 }
94
+ .CodeRay .s .s .s { background-color:#ffd0d0 }
95
+ .CodeRay .s .k { color:#D20 }
96
+ .CodeRay .s .dl { color:#710 }
97
+
98
+ .CodeRay .sh { background-color:#f0fff0 }
99
+ .CodeRay .sh .k { color:#2B2 }
100
+ .CodeRay .sh .dl { color:#161 }
101
+
102
+ .CodeRay .sy { color:#A60 }
103
+ .CodeRay .sy .k { color:#A60 }
104
+ .CodeRay .sy .dl { color:#630 }
105
+
106
+ .CodeRay .ta { color:#070 }
107
+ .CodeRay .tf { color:#070; font-weight:bold }
108
+ .CodeRay .ts { color:#D70; font-weight:bold }
109
+ .CodeRay .ty { color:#339; font-weight:bold }
110
+ .CodeRay .v { color:#036 }
111
+ .CodeRay .xt { color:#444 }