Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
52 lines (40 sloc) 2.01 KB

Block HTML

(not referred to yet)

BlockHTML = Pre | Blockquote | TableHTML | Div | HeaderHTML ;

String Types

This text came from Meta-Wiki. It's not immediately compatible with the surrounding text (it's EBNF, rather than BNF, for a start). However it is much more precise about the nature of lines and captures rules about whitespace normalisation. Fundamental strings
WikiMarkupCharacters = "|" | "[" | "]" | "*" | "#" | ":" | ";" | "<" | ">" | "=" | "'" | "{" | "}" ;
UnicodeCharacter = ? all supported Unicode characters ? - Whitespaces ;
UnicodeWiki = UnicodeCharacter - WikiMarkupCharacters ;
PlainText = UnicodeWiki
          | "<nowiki><nowiki></nowiki>" { "|" | "[" | "]" | "<" | ">" | "{" | "}" } "<nowiki></nowiki></nowiki>"
          | UnicodeWiki { " " } ( "*" | "#" | ":" | ";" )
          | UnicodeWiki [ " " ] "=" [ " " ] UnicodeWiki
          | UnicodeWiki "'"
          | " '" UnicodeWiki ;
WhiteSpaces =  " " | NewLine | ? carriage return ? | ? line feed ? | ? tab ? | ? variants of spaces ? ;
NewLine = ? carriage return and line feed ? ;
Article strings
Line = PlainText { PlainText } { " " { " " } PlainText { PlainText } } ;
Text = Line { Line } { NewLine { NewLine } Line { Line } } ;
Titles
PageName = TitleCharacter , { [ " " ] TitleCharacter } ;
PageNameLink = TitleCharacter , { [ " " | "_" ] TitleCharacter } ;
SectionTitle = ( SectionLinkCharacter - "=" ) { [ " " ] ( SectionLinkCharacter - "=" ) } ;
SectionLink = SectionLinkCharacter { [ "_" ] SectionLinkCharacter } ;
LinkTitle = { UnicodeCharacter { " " } } ( UnicodeCharacter - "]" ) ;

TitleCharacter = UnicodeCharacter - BadTitleCharacters ;
BadTitleCharacters = "[" | "]" | "{" | "}" | "<" | ">" | "_" | "|" | "#" ;
SectionLinkCharacter = UnicodeCharacter - BadSectionLinkCharacters ;
BadSectionLinkCharacters = "[" | "]" | "|" ;


BNF/Article