Sections
Section allows you to split your code into several sections. It's like files... well kinda.
To create a section use the following format: ## My section name [syntax] (syntax is optional).
## Controller
class MyController < ApplicationController
end
## View [html_rails]
<h2><%= @title %></h2>
## Javascript [javascript]
var Page = {
hide: function(page) {
$(page).hide();
}
};
First section will render in the code syntax (language) and labelled Controller. The second one will be labelled View and highlighted as HTML for Rails.
Syntaxes
A syntax describes how the code should be highlighted. For example, Ruby code could have ruby_on_rails syntax. Syntax is just a little more specific. Here's the list of supported syntax:
- actionscript
- active4d
- active4d_html
- active4d_ini
- active4d_library
- ada
- antlr
- apache
- applescript
- asp
- asp_vb.net
- bibtex
- blog_html
- blog_markdown
- blog_text
- blog_textile
- build
- bulletin_board
- c
- c++
- cake
- camlp4
- cm
- coldfusion
- context_free
- cs
- css
- css_experimental
- csv
- d
- diff
- dokuwiki
- dot
- doxygen
- dylan
- eiffel
- erlang
- f-script
- fortran
- fxscript
- greasemonkey
- gri
- groovy
- gtd
- gtdalt
- haml
- haskell
- html
- html-asp
- html_django
- html_for_asp.net
- html_mason
- html_rails
- html_tcl
- icalendar
- inform
- ini
- installer_distribution_script
- io
- java
- javaproperties
- javascript
- javascript_+_prototype
- javascript_+_prototype_bracketed
- jquery_javascript
- json
- languagedefinition
- latex
- latex_beamer
- latex_log
- latex_memoir
- lexflex
- lighttpd
- lilypond
- lisp
- literate_haskell
- logo
- logtalk
- lua
- m
- macports_portfile
- makefile
- man
- markdown
- mediawiki
- mel
- mips
- mod_perl
- modula-3
- moinmoin
- mootools
- movable_type
- multimarkdown
- objective-c
- objective-c++
- ocaml
- ocamllex
- ocamlyacc
- opengl
- pascal
- perl
- php
- plain_text
- pmwiki
- postscript
- processing
- prolog
- property_list
- python
- python_django
- qmake_project
- qt_c++
- quake3_config
- r
- r_console
- ragel
- rd_r_documentation
- regexp
- regular_expressions_oniguruma
- regular_expressions_python
- release_notes
- remind
- restructuredtext
- rez
- ruby
- ruby_experimental
- ruby_on_rails
- s5
- scheme
- scilab
- setext
- shell-unix-generic
- slate
- smarty
- sql
- sql_rails
- ssh-config
- standard_ml
- strings_file
- subversion_commit_message
- sweave
- swig
- tcl
- template_toolkit
- tex
- tex_math
- textile
- tsv
- twiki
- txt2tags
- vectorscript
- xhtml_1.0
- xml
- xml_strict
- xsl
- yaml
- yui_javascript