diff --git a/Rakefile b/Rakefile index b6b3a37..b4b03d8 100755 --- a/Rakefile +++ b/Rakefile @@ -75,7 +75,8 @@ module PrototypeHelper PDoc::Runner.new(temp_path, { :output => DOC_DIR, :templates => File.join(TEMPLATES_DIR, "html"), - :index_page => 'README.markdown' + :index_page => 'README.markdown', + :syntax_highlighter => :pygments }).run rm_rf temp_path diff --git a/templates/html/assets/stylesheets/pygments.css b/templates/html/assets/stylesheets/pygments.css new file mode 100644 index 0000000..0857737 --- /dev/null +++ b/templates/html/assets/stylesheets/pygments.css @@ -0,0 +1,195 @@ +.highlight { + background: #fff; +} +.highlight .c { + color: #998; + font-style: italic; +} +.highlight .err { + color: #a61717; + background-color: #e3d2d2; +} +.highlight .k { + font-weight: bold; +} +.highlight .o { + font-weight: bold; +} +.highlight .cm { + color: #998; + font-style: italic; +} +.highlight .cp { + color: #999; + font-weight: bold; +} +.highlight .c1 { + color: #998; + font-style: italic; +} +.highlight .cs { + color: #999; + font-weight: bold; + font-style: italic; +} +.highlight .gd { + color: #000; + background-color: #fdd; +} +.highlight .gd .x { + color: #000; + background-color: #faa; +} +.highlight .ge { + font-style: italic; +} +.highlight .gr { + color: #a00; +} +.highlight .gh { + color: #999; +} +.highlight .gi { + color: #000; + background-color: #dfd; +} +.highlight .gi .x { + color: #000; + background-color: #afa; +} +.highlight .go { + color: #888; +} +.highlight .gp { + color: #555; +} +.highlight .gs { + font-weight: bold; +} +.highlight .gu { + color: #aaa; +} +.highlight .gt { + color: #a00; +} +.highlight .kc { + font-weight: bold; +} +.highlight .kd { + font-weight: bold; +} +.highlight .kp { + font-weight: bold; +} +.highlight .kr { + font-weight: bold; +} +.highlight .kt { + color: #458; + font-weight: bold; +} +.highlight .m { + color: #099; +} +.highlight .s { + color: #d14; +} +.highlight .na { + color: #008080; +} +.highlight .nb { + color: #0086B3; +} +.highlight .nc { + color: #458; + font-weight: bold; +} +.highlight .no { + color: #008080; +} +.highlight .ni { + color: #800080; +} +.highlight .ne { + color: #900; + font-weight: bold; +} +.highlight .nf { + color: #900; + font-weight: bold; +} +.highlight .nn { + color: #555; +} +.highlight .nt { + color: #000080; +} +.highlight .nv { + color: #008080; +} +.highlight .ow { + font-weight: bold; +} +.highlight .w { + color: #bbb; +} +.highlight .mf { + color: #099; +} +.highlight .mh { + color: #099; +} +.highlight .mi { + color: #099; +} +.highlight .mo { + color: #099; +} +.highlight .sb { + color: #d14; +} +.highlight .sc { + color: #d14; +} +.highlight .sd { + color: #d14; +} +.highlight .s2 { + color: #d14; +} +.highlight .se { + color: #d14; +} +.highlight .sh { + color: #d14; +} +.highlight .si { + color: #d14; +} +.highlight .sx { + color: #d14; +} +.highlight .sr { + color: #009926; +} +.highlight .s1 { + color: #d14; +} +.highlight .ss { + color: #990073; +} +.highlight .bp { + color: #999; +} +.highlight .vc { + color: #008080; +} +.highlight .vg { + color: #008080; +} +.highlight .vi { + color: #008080; +} +.highlight .il { + color: #099; +} diff --git a/templates/html/layout.erb b/templates/html/layout.erb index 6e6aed8..8624389 100644 --- a/templates/html/layout.erb +++ b/templates/html/layout.erb @@ -7,10 +7,10 @@ <%= javascript_include_tag "prototype" %> - <%= javascript_include_tag "application", "code_highlighter", "tabs" %> + <%= javascript_include_tag "application", "tabs" %> <%= javascript_include_tag "item_index" %> - <%= stylesheet_link_tag "api" %> + <%= stylesheet_link_tag "api", "pygments" %>