Index: ossp-pkg/sugar/BRAINSTORM.txt RCS File: /v/ossp/cvs/ossp-pkg/sugar/BRAINSTORM.txt,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/BRAINSTORM.txt,v' | diff -u /dev/null - -L'ossp-pkg/sugar/BRAINSTORM.txt' 2>/dev/null --- ossp-pkg/sugar/BRAINSTORM.txt +++ - 2024-05-15 18:12:08.706649969 +0200 @@ -0,0 +1,336 @@ + +Konzepte: +- headers Author: ... +- 1d-block foo XX bar XX quux +- 2d-block XX ... +- table ++ | .. | +- XX tags XX +- entities ..{xxx}.. + +Examples: + + o '' XX foo + bar + baz + quux + + XX is applied to "foo bar baz", not to "quux". + + o '' XX foo XX bar + quux + + XX is applied to "foo", not to "bar quux" + + o '' foo bar XX quux + + XX is applied to "quux" __and__ "foo bar", because + not closed XX environment wraps around at end of paragraph. + With this the following is equvalent: + + '' XX foo + bar quux XX + + '' XX foo + bar quux + + '' foo + bar quux XX + + this way headings are not special case: + + '' ==heading== + + '' ==heading + + '' heading== + + '' heading + == + + '' heading + ======= + + begins a 2d block with head tag and ends (explicitly + or implicitly) with the same tag's markup, the 2d block + is treated as a "head line" (for table of contents, etc.) + Else is is treated as "paragraph heading" (not included + in table of contents). + +Brainstormings with Christian Reiber: + +1. Scanner erkennt die Intentation, strippt sie + weg, berechnet aber durch sie die "schliessenden + Klammern" zu den 2d-tags. + +2. Scanner erkennt auch die Unterschiede zwischen + 1d und 2d tags, da der Parser ja keinerlei + Unterscheidung treffen kann (spaces/indent nicht mehr da) + +3. Scanner hat einen Look-Ahead von 1 Zeile plus + ihrem Indent + +4. Das Parsen von Headern "(====)" geht einfach: + Der Scanner erkennt nur das "^========" und + ein Baumtransformator haengt spaeter + die Sohn-Sequenz " x ..... y
" + um in "
x ... y", d.h. + der transformator geht bis zum letzten Paraphraph + Knoten zurueck. + + If the "text" on hyperlinks is missing in links, the reference is printed + instead. For internal links the text is chapter and pagenumber + (except for HTML, there exists real hyperlinks). + +Stichworte: + +Whatever | Irgendwas +---------- | ----------------------------- +Brain Dump | VHIT (Vom Hirn ins Terminal) +Blabla | ASCII WYSIWYG + +Design-Grundsaetze +------------------ +1. KISS bei der Sprache (Beschreibung geht auf eine Seite und ist ISO-Latin-1!) +2. KISS bei der Implementierung (Code-Groesse <= 80KB) +3. Wir implementieren nur das, was wir _WIRKLICH_ brauchen. +4. Sugar ist wie Unix: Wenige Konzepte existieren und + werden konsequent durchgezogen +5. Sugar hat *keine* GUI, sondern ist ein Filter! + Beispielaufruf: + $ cat test.txt | sugar --html -otest.html +6. Sugar ist stand-alone (bis auf Postscript), + man braucht also nicht 1001 Tools bei der Installation +7. Release early, release often (Eric S. Raymond) +8. Jedes Markup kann immer eindeutig formuliert werden (=non-magic), + nur sieht es dann eventuell nicht so schoen aus. + Wenn man sich an bestimmte Regeln haelt, kann man + im Magic Mode ASCII-Aesthetik pur nutzen. + Non-Magic ist immer nutzbar und aktiviert, Magic-Mode per default an, aber + kann abgeschalten werden (per -xx und/oder inline tag) Idee: -xx im + Dokument direkt eingeben ala vi/less + +Was Sugar nicht ist +------------------- +1. Sugar ist _keine_ Textverarbeitung oder ein DTP-Tool +2. Sugar ist keine Markup-Sprache (der Text ist bereits das Endprodukt) +3. Sugars Brother is more/less and not nroff (i.e. Sugar is fast!) + +Anwendungsfeld +-------------- +1. Technische Dokumentation fuer mehrere Darstellungsplatformen: + Plain ASCII (= Sugar Quelle), roff/-man (Unix), HTML (= Online), PS (= Print) +2. Brain Dump! + +Optionale Zusatzfeatures +------------------------ +- ToC: Automatische Generierung +- Numerierung von Headern +- Index +- Aufrufen von Makroprozessor: m4 + +Tabellen: +--------- + o Tabellen sind Bloecke und werden mit ++ eingeleitet wie + andere Bloecke auch, d.h. Ende ist bei Ausrueckung oder + selber Level. + o Jede Tabellenzeile faengt mit einem | an und immer in der selben Spalte. + o Die |'s der ersten Zeile geben die Gesamtanzahl und die Normposition + der Spalten an. + o Besteht die erste Zeile nur aus |'s (und keinem Inhalt), dann + ist sie eine _reine_ Normungszeile und erzeugt auch keine Leerzeile. + Ansonsten (Zeile 2, ...) kann man so selbstverstanelich eine + Leerreihe erzeigen. + o Spaltentrennungs-| koennen an belieber Stelle stehen, wenn + genuegend da sind. + o Folgespalten sind dadurch gekennzeichnet, dasz ihr | eingerueckt + erscheint. + o Multicolums liegen vor, wenn weniger |'s auftreten, als die + Normungszeile vorgibt. Die Erkennung der Span's erfolgt dabei ueber die + Position der |'s, d.h. sie muessen die |'s der Normunszeile matchen. + Zusaetzlich kann die Normungszeile beliebig oft wiederhlt werden. + Aber dabei darf sich nur die Position der |'s aendern, aber + nicht die Anzahl (klar!). + o Leerzeilen bestehen aus nur einem |' am Anfang und sonst nichts. + o Normungszielen haben mind.(!) 2 |'s. + o Leerzeilen erzeugen im Output soviele |'s wie die Normungszeile + vorgibt. Fuer andere Layouting-Dinge muss man z.B. ``| \_'' schreiben. + o In einer Tabelle koennen alle Zeichenformatierungen genutzt werden. + o In der Normungszeile kann mit den Zeichenformatierung-Tags + die Formatierung der Tabellenspalten angegeben werden! + o Wie gibt man Tabellenzeilen an, die als Headers gelten? + Eventuell gar nicht, wenn man Tabellen nicht umbrechen laesst, + denn dann muss man diese headerzeilen auch nicht wiederholen + und muss deshalb solche nicht explizit auszeichnen + + ++ | ((** | %% | )) | + | foo | quux | bar | + | foooooooo | quux | + +3. Block-Konzept + + Es gibt zwei Blockkonzepte: + - character block (eindimensional) und + - line block (zweidimensional). + + Der //character block// wird durch das Tag eingeleitet und wieder beendet. Das + Paragraph Ende beendet in jedem Fall den character block. + + Der //line block// beginnt mit dem Tag __ausgerückt__, wobei davor keine + Leerzeile stehen muß (ein \n und ggf. \s davor reicht). Er enthält ganze + Zeilen und zwar solange, wie Text in der Zeile mindestens zwei Leerzeichen + weiter rechts beginnt als das einleitende Tag. Achtung: Tags stellen selbst + __nicht__ den Zeilenanfang dar! Damit kann ich also line blocks schachteln. + (Anders gesagt: Es geht nicht um den linken Rand der Textdatein, sondern um + den linken Rand des übergeordneten Line Blocks.) + + Automatischer reflow durch den Editor ist bei character blocks **kein** + Problem, da das Tag keine positionsabhängige Bedeutung hat (daher wurde + auch verworfen, daß ein Tag am Zeilenanfang, aber nicht ausgerückt, am + Zeilenende beendet wird). Das Start-Tag beim line block wird vom Editor + nicht versetzt (wenn er was taugt). + + Möglicherweise kann für bestimmte Tags das Ende des char blocks auch das + Zeilenende (nicht das Para. Ende) sein. Gedacht ist an Kommandos: + + Gehen sich nach http://laber.lall + Das ist ## eine blöde Zeile und ich will daß ##das## unterstrichen ist + ''##das ist ungut## + ##das ist intuitiver, bedeutet aber Kommandoende=Zeilenende + + Das wäre dann eine Eigenschaft des Tags, d.h. es verhält sich dann + //immer// so (und nicht mal so und mal anders). + + Beispiele: + + 1. ''Dies ist ein Beispiel für einen Text, __in dem der zweite + Halbsatz unterstrichen wird__, obwohl er sich über eine + Zeilengrenze erstreckt. + + o. ''__In diesem Fall wird der line block unterstrichen. Das + geht solange, bis der Text wieder ausgerückt wird. + + Auch Leerzeilen stellen da kein Hindernis dar. + + Diese Zeile beendet den Line Block. + + o. ''Ein Sonderfall: __Dieser Text hat kein Ende-1d-Tag. + Er wird dann durch das Paragraph-Ende beendet. + + Ab hier also keine Unterstreichung mehr. + + Das haben wir gemacht, weil sonst bei vergessenen Endetags + das Restdokument fehlformatiert wird. + +o Native-Output-Stuff + xxxx + + ``jdjlasdjajlad`` + skd asdk s + dsö ksaölkdaös## + + dfkdjsdal + html + + xxxx + + ##endif + + xxxx + +o Comments + ##// + ##/* + ##*/ + +5. Inline-Images + - Source ist immer Bitmap-Grafik im GIF Format! + (Fuer ASCII: gifscii, Fuer HTML: Direkt, Fuer PS: gif2ps) + + ##img xx.gif size=jsjs s=xx + +- UNBEDINGT Unicode und UTF-8 unterstutezen von anfang an! + +Idea for homogenous tags: +- any XX tags can be repeated multiple times, ie XXXXX is valid also +- any begin XX tag at the end of a paragraph wraps around its scope, ie + it is applied to the whole paragraph as it would stand at the start + of the block (marged out?). +Results: +- headlines are marked equally with blocks + +------------------------------------------------------------------------------ + +OSSP Sugar Brainstorming Meeting 27-06-2001 @ C&W +================================================= + +gewuenschter output: html (online), text, pdf/ps (print) + |sugar, soll schnell sein fuer preview, 1-2sec +gewuenschter input: simple (20-30 tags), wenig Stilmittel, aehnlich textoutput + +*eindeutige* Tags in SXML +SRML invisible markup + +pre-processing + pass 1: include, macros, + pass 2: area substitution, diversion +meta-information + author, mtime, ctime, title, abstract, subject, version + parameters passthrough for backends +2d-block + headings 1-4 + paragraph + align left, right, centered, indented(?) + preformatting + lists, ordered/callout, unordered, description + import extern(URL)/embedded vs. include + figures format(EPS,PNG,TXT), scaling + tables, titlerow, rows, columns, cells, spanning, hlines, vlines, nesting + caption +2+1d block + verbatim + boxed, striked, tele-typed + logical markup (emphasize, nonbreaking) + notes foot, end, margin + shellescape +1d-block + bold, italic, underline + escaping(?) + linebreaks(?) + subscript, superscript + anchores, references intern, extern + index items + word-breaking + entitities (ISO chars, newline, etc.) + +o no align (left, center, right, indented) in general + only needed in tables + idea: first line specified table layout like TeX +o eventuell: kein escaping, man koennte verbatim hernehmen + aber: wie escape ich dann verbatim tag! +o eventuell kein linebreak, da normaler linebreak + eher neuer paragrpah sein sollte und fuer andere + preformatted ausreicht! + +o generell sugar koennte immer SXML sein, aber + abkuerzend koennte es SRML Teile enthalten +o + +------------------------------------------------------------------------------ + +Ideas from AFT: + +- non-intended verbatim mode with optional filtering for pretty-printing + | ^<<[filter] + | ^>> + +- a pre-formatted mode would be cool, too. + +------------------------------------------------------------------------------ + XML-FO + + panda+pandascript (C API, Perl API, Shell API, GPL) + http://www.stillhq.com/cgi-bin/getpage?area=panda&page=index.htm + + pdflib http://www.pdflib.com/ + clibpdf http://www.fastio.com/ + Index: ossp-pkg/sugar/FEATURES.txt RCS File: /v/ossp/cvs/ossp-pkg/sugar/FEATURES.txt,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/FEATURES.txt,v' | diff -u /dev/null - -L'ossp-pkg/sugar/FEATURES.txt' 2>/dev/null --- ossp-pkg/sugar/FEATURES.txt +++ - 2024-05-15 18:12:08.709427973 +0200 @@ -0,0 +1,69 @@ + + SXML SRML +o document information + - title Title: + - subtitle Subtitle: + - author Author: + - date Date: + - abstract Abstract: + +o heading + - levels 1-4 == -- ~~ .. + +o list + - unordered list
    o - * + - ordered list
      o. -. *. + . list items
    1. + - description list
      + . description term
      .. :: + . description text
      + +o table ++ + - table rows + - table columns/cells | + - column/row spanning + - column title + +o character formatting + - logical formatting + . emphasized text !! + . tele-typed text '' or || + - visual formatting + . bold text ** + . underlined text
        __ + . italic text // or '' + . boxed text [[ + . super-scripting ^^ + . sub-scripting ;; + +o text formatting + . line break
        \\ + . aligned (( %% )) + . indented >> + . pre-formatted && or $$ or §§ or "" or °° or ?? + +o cross-referencing + - anchor (+..+) + - reference ->..(..) or ->[..:]..<- + +o comments ## + +o entities {{name[ param=value ...]}} + - figure {{figure src="..." format=eps}} + - embedded object {{eo src=".."}} + - passed-through {{pass format=html value="
        "}} + +# o 1d-Blocks +# +# +# +# o 2d-Blocks +# +# [ ] +# : +# tags am Ende eines 1-dim Blocks wrappen an den Anfang! +# tags koennen 2 oder mehr ihrer Sonderzeichen lang sein +# (tags koennen auch in reverse order sein fuer symmetrie (+ +) -> <-) +# ende von 1d-block ist leerzeile +# ende von 2d-block ist ausrueckung + Index: ossp-pkg/sugar/Makefile RCS File: /v/ossp/cvs/ossp-pkg/sugar/Makefile,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/Makefile,v' | diff -u /dev/null - -L'ossp-pkg/sugar/Makefile' 2>/dev/null --- ossp-pkg/sugar/Makefile +++ - 2024-05-15 18:12:08.712000938 +0200 @@ -0,0 +1,9 @@ + +all: validate transform + +validate: + xmllint --valid --noout test.sxml + +transform: + xsltproc --nonet sxml2html.xsl test.sxml + Index: ossp-pkg/sugar/README RCS File: /v/ossp/cvs/ossp-pkg/sugar/README,v rcsdiff -q -kk '-r1.1' '-r1.2' -u '/v/ossp/cvs/ossp-pkg/sugar/README,v' 2>/dev/null --- README 2000/09/14 15:51:52 1.1 +++ README 2002/03/13 09:19:03 1.2 @@ -4,8 +4,33 @@ |___/\__,_|\__, |\__,_|_| __________ |___/ ___________________________________________________ - Sugar -- The Markup Language With Invisible Syntactic Sugar + OSSP sugar -- The Markup Language With Invisible Syntactic Sugar + Copyright (c) 1999-2002 Ralf S. Engelschall + Copyright (c) 1999-2002 Christian Reiber - Copyright (c) 1999-2000 Ralf S. Engelschall - Copyright (c) 1999-2000 Christian Reiber + o Extensible Markup Language (XML) + http://www.w3.org/XML/ + http://www.xml.com/ + + o Extensible Stylesheet Language (XSL) + http://www.w3.org/Style/XSL/ + http://www.xslt.com/ + + o XML 1.0 Specification + http://www.w3.org/TR/2000/REC-xml-20001006 + + o XSL 1.0 Specification + http://www.w3.org/TR/xsl/ + + o XSL Transformations 1.0 Specification + http://www.w3.org/TR/xslt/ + + o XPath 1.0 Specification + http://www.w3.org/TR/xpath + + o XLink 1.0 Specification + http://www.w3.org/TR/2001/REC-xlink-20010627/ + + o XPointer 1.0 Specification + http://www.w3.org/TR/2001/WD-xptr-20010108/ Index: ossp-pkg/sugar/srml2sxml RCS File: /v/ossp/cvs/ossp-pkg/sugar/srml2sxml,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/srml2sxml,v' | diff -u /dev/null - -L'ossp-pkg/sugar/srml2sxml' 2>/dev/null --- ossp-pkg/sugar/srml2sxml +++ - 2024-05-15 18:12:08.718423215 +0200 @@ -0,0 +1,265 @@ +#!/usr/bin/perl +## +## srml2sxml -- Sugar SRML to SXML Translation +## Copyright (c) 1999-2002 Ralf S. Engelschall +## + +require 5.005; +$|++; + +my $tags1d = { + '==' => [ '', '' ], + '--' => [ '', '' ], + '~~' => [ '', '' ], + '..' => [ '', '' ], + + '**' => [ '', '' ], + '//' => [ '', '' ], + '__' => [ '
          ', '
        ' ], + '[[' => [ '', '' ], + '||' => [ '', '' ], + '!!' => [ '', '' ], + + '(+' => [ '', '' ], + '->' => [ '', '' ], +}; + +my $alias1d = { + '+)' => '(+', + '<-' => '->', + ']]' => '[[', +}; + +my $tags2d = { + '==' => [ '

        ', '

        ' ], + '--' => [ '

        ', '

        ' ], + '~~' => [ '

        ', '

        ' ], + '..' => [ '

        ', '

        ' ], + '**' => [ '', '' ], + '//' => [ '', '' ], + '__' => [ '
          ', '
        ' ], + '[[' => [ '', '' ], + '||' => [ '
        ',             '
        ' ], + '!!' => [ '', '' ], + + '>>' => [ '
        ', '
        ' ], + '((' => [ '', '' ], + '%%' => [ '', '' ], + '))' => [ '', '' ], + + '++' => [ '', '
        ' ], + '##' => [ '', '' ], + + '$$' => [ '', '' ], + 'o ' => [ '', '' ], + '- ' => [ '', '' ], + 'o.' => [ '', '' ], + '-.' => [ '', '' ], + '::' => [ '', '' ], + + 'Title:' => [ '', '' ], + 'Author:' => [ '', '' ], + 'Genesis:' => [ '', '' ], + 'Date:' => [ '', '' ], + 'Abstract:' => [ '', '' ], +}; + +my $alias2d = { + '[]' => '[[', +}; + +my $escapes = { + '&' => '&', + '<' => '<', + '>' => '>', +}; + +# assemble mega-regex which matches all 1d-tags +my $tag1d = &assemble_regex((keys(%{$tags1d}),keys(%{$alias1d}))); +my $tag2d = &assemble_regex((keys(%{$tags2d}),keys(%{$alias2d}))); +sub assemble_regex { + my (@tags) = @_; + my $regex = '(?:'; + foreach $tag (sort(@tags)) { + $regex .= quotemeta($tag)."+|"; + } + $regex =~ s/\+\|$//; + $regex .= ')'; + return $regex; +} + +my $escape = '(?:'; +foreach $e (sort(%{$escapes})) { + $escape .= quotemeta($e)."|"; +} +$escape =~ s/\|$//; +$escape .= ')'; + +sub expandtab { + my ($ts, $str) = @_; + my $i = 0; + my $k; + $str =~ s|(.) + |($1 eq "\t" + ? ($k = $i % $ts, + $i += ($ts - $k), + "*" x ($ts - $k) ) + : ($i++, $1) + ) + |sgex; + return $str; +} + +# ::= * +# ::= * +# ::= | <2d-block> +# <2d-block> ::= <2d-tag> +# <2d-tag> ::= m/^\s*XY+\s+/ +# ::= <1d-block>* +# +# und koennen degenerieren +# auf genau einen, d.h. z.B. +# == 1 oder == 1 <1d-block> +# +# 1d-block: +# foo bar +# **baz +# quux +# +# 2d-block +# ** baz +# quux +# +# -> blank lines zwischen 2d-blocks koennen entfallen! +# -> blank lines wenn da sind markieren paragraphen +# und schliessen 1d block ab + +sub parse_srml { + my ($srml) = @_; + my $sxml = ''; + + while ($srml ne '') { + # stop at end of input + if ($srml =~ m|^(\s*)$|s) { + $sxml .= $1; + $srml = ''; + last; + } + + # pass through blank lines + elsif ($srml =~ m|^((?: *\n)+)(.*)$|s) { + $sxml .= $1; + $srml = $2; + } + + # recognize 2-dimensional block start + elsif ($srml =~ m|^( *)($tag2d)( +[^\n]*)?(.*)$|s) { + my ($prefix, $tag, $block) = ($1, $2, $3); + $block = $prefix . $block; + $srml = $4; + + # reduce tag to canonical 2-character form + $tag =~ s|^(.)(.)\2+$|$1$2|s; + if (defined($alias2d->{$tag})) { + $tag = $alias2d->{$tag}; + } + + # gather block lines + # (same or less indent indicates end) + my $minindent = length($prefix)+1; + while ($srml =~ m/^((?: *| {$minindent,}[^\n]+)\n)(.*)$/s) { + $block .= $1; + $srml = $2; + } + $block = &parse_srml($block); + $block =~ s|^(\s*)(.*?)(\s*)$| + $1 . $tags2d->{$tag}->[0] . + $2 . $tags2d->{$tag}->[1] . $3|se; + $sxml .= $block; + } + + # anything else we treat as a 1-dimensional block start + else { + # gather block lines + # (a blank line indicates end) + my $block = ''; + while ($srml =~ m/^( *[^ \n][^\n]*\n)(.*)$/s) { + $block .= $1; + $srml = $2; + } + + print STDERR "1D<<$block>>\n"; + + # escape special XML characters + $block =~ s|($escape)|$escapes->{$1}|sge; + + # sequencially walk through 1-dimensional block + my $sxml_local = ''; + my @active = (); + while ($block =~ m|^(.*?)($tag1d)(.*)$|s) { + my ($prolog, $tag, $epilog) = ($1, $2, $3); + $sxml_local .= $prolog; + $block = $epilog; + + # reduce tag to canonical 2-character form + $tag =~ s|^(.)(.)\2+$|$1$2|s; + if (defined($alias1d->{$tag})) { + $tag = $alias1d->{$tag}; + } + + # look on stack of still active tags + my $active = ''; + if ($#active > -1) { + $active = pop(@active); + } + + if ($active eq $tag) { + # close the currently active tag + $sxml_local .= $tags1d->{$tag}->[1]; + } + else { + # open a new active tag + if ($block =~ m|^\s*$|s) { + # tag wraps around + $sxml_local =~ s|^(\s*)(.*?)(\s*)$| + $1 . $tags1d->{$tag}->[0] . + $2 . $tags1d->{$tag}->[1] . $3|se; + } + else { + $sxml_local .= $tags1d->{$tag}->[0]; + push(@active, $active) if ($active ne ''); + push(@active, $tag); + } + } + } + + # post-processing for implicitly to-be-closed tags + my $trailer = ''; + if ($block =~ m|^(.*)(\s+)$|s) { + ($block, $trailer) = ($1, $2); + } + $sxml_local .= $block; + while ($#active > -1) { + my $active = pop(@active); + $sxml_local .= $tags1d->{$active}->[1]; + } + $sxml_local .= $trailer; + + $sxml .= $sxml_local; + } + } + return $sxml; +} + +my $srml = ''; +$srml .= $_ while (); +$srml =~ s|\n$||s; +$srml .= "\n"; +$srml = &expandtab(8, $srml); + +my $sxml = ''; +$sxml .= ""; +$sxml .= &parse_srml($srml); +$sxml .= "\n"; +print $sxml; + Index: ossp-pkg/sugar/sugar.fig RCS File: /v/ossp/cvs/ossp-pkg/sugar/sugar.fig,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sugar.fig,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sugar.fig' 2>/dev/null --- ossp-pkg/sugar/sugar.fig +++ - 2024-05-15 18:12:08.721094655 +0200 @@ -0,0 +1,225 @@ +#FIG 3.2 +Landscape +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +0 32 #f0f0ff +0 33 #d0d0e0 +0 34 #a0a0c0 +0 35 #cccccc +0 36 #999999 +0 37 #cccccc +0 38 #999999 +0 39 #b2b2b2 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 6000 900 7200 900 7200 2100 6000 2100 6000 900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 5400 1500 6000 1500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 6600 2100 6600 2700 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 6000 3900 7200 3900 7200 5100 6000 5100 6000 3900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 6600 3300 6600 3900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 4 + 6600 4050 6375 4200 6225 4425 6150 4725 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 4 + 6600 4050 6825 4200 6900 4425 6975 4725 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 3 + 6825 4200 6750 4425 6750 4725 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 6600 4200 6675 4350 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 4 + 6600 4050 6600 4200 6525 4350 6600 4575 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 6375 4200 6450 4425 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 6600 5100 6600 5700 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 5400 1800 4200 1800 4200 1200 5400 1200 5400 1800 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 3600 1500 4200 1500 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 2400 900 3600 900 3600 2100 2400 2100 2400 900 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 7200 6300 6000 6300 6000 5700 7200 5700 7200 6300 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 7200 3300 6000 3300 6000 2700 7200 2700 7200 3300 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 7200 6000 7800 6000 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 8100 5400 9300 5400 9300 6600 8100 6600 8100 5400 +2 1 2 4 0 7 50 0 -1 7.500 0 1 -1 0 0 2 + 8700 8250 8700 8550 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 8100 6900 9300 6900 9300 8100 8100 8100 8100 6900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 9300 4500 9900 4500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 9300 7500 9900 7500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 9300 6000 9900 6000 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 7650 4500 7650 7500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 7650 4500 8100 4500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 7500 6000 8100 6000 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 7650 7500 8100 7500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 5400 6000 6000 6000 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 4200 2700 5400 2700 5400 3300 4200 3300 4200 2700 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 5400 3000 6000 3000 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 5400 5100 5700 5100 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 5400 6900 5700 6900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2 + 5700 5100 5700 6900 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 4200 5700 5400 5700 5400 6300 4200 6300 4200 5700 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 4200 4800 5400 4800 5400 5400 4200 5400 4200 4800 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 4200 6600 5400 6600 5400 7200 4200 7200 4200 6600 +2 1 2 4 0 7 50 0 -1 7.500 0 1 -1 0 0 2 + 4800 7350 4800 7650 +2 2 2 1 34 7 50 0 -1 1.000 0 0 -1 0 0 5 + 4050 900 5550 900 5550 7800 4050 7800 4050 900 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 11100 4800 9900 4800 9900 4200 11100 4200 11100 4800 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 11100 6300 9900 6300 9900 5700 11100 5700 11100 6300 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 11100 7800 9900 7800 9900 7200 11100 7200 11100 7800 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 11100 6000 11700 6000 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 11100 7500 11700 7500 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 11100 4500 11700 4500 +2 2 0 1 29 30 100 0 20 0.000 0 0 -1 0 0 5 + 11700 3900 12900 3900 12900 5100 11700 5100 11700 3900 +2 2 0 1 33 32 100 0 20 0.000 0 0 -1 0 0 5 + 11700 5400 12900 5400 12900 6600 11700 6600 11700 5400 +2 2 0 1 29 30 100 0 20 0.000 0 0 -1 0 0 5 + 11700 6900 12900 6900 12900 8100 11700 8100 11700 6900 +2 2 0 1 29 30 100 0 20 0.000 0 0 -1 0 0 5 + 8100 3900 9300 3900 9300 5100 8100 5100 8100 3900 +2 2 0 1 29 30 100 0 20 0.000 0 0 -1 0 0 5 + 13500 6150 14700 6150 14700 7350 13500 7350 13500 6150 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 12900 5550 13500 5550 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 12900 7950 13500 7950 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 14700 8400 13500 8400 13500 7800 14700 7800 14700 8400 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 14700 5700 13500 5700 13500 5100 14700 5100 14700 5700 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 14100 5700 14100 6150 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 14100 7800 14100 7350 +2 4 0 1 34 33 200 0 20 0.000 0 0 7 0 0 5 + 7350 6900 5850 6900 5850 2550 7350 2550 7350 6900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 3000 450 3000 900 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 6600 450 6600 900 +2 1 0 1 37 7 50 0 -1 0.000 0 0 -1 1 0 4 + 1 1 2.00 60.00 120.00 + 11100 6150 11400 6150 11400 7350 11700 7350 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 9300 8025 9900 8025 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 11100 7950 11700 7950 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 11100 8175 9900 8175 9900 7875 11100 7875 11100 8175 +2 2 0 1 29 30 100 0 20 0.000 0 0 -1 0 0 5 + 11700 8400 12900 8400 12900 9600 11700 9600 11700 8400 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 + 1 1 2.00 60.00 120.00 + 11100 8700 11700 8700 +2 4 0 1 34 33 100 0 20 0.000 0 0 7 0 0 5 + 11100 8850 9900 8850 9900 8550 11100 8550 11100 8850 +2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 3 + 1 1 2.00 60.00 120.00 + 9000 8100 9300 8700 9900 8700 +4 0 0 50 0 16 12 0.0000 4 180 990 6150 3225 XML parser\001 +4 0 0 50 0 18 12 0.0000 4 135 510 6300 2925 libxml\001 +4 0 0 50 0 16 12 0.0000 4 135 525 6375 1950 SXML\001 +4 0 0 50 0 12 10 0.0000 4 105 270 6450 4725 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 780 6225 5025 XML tree\001 +4 0 0 50 0 16 12 0.0000 4 180 1095 6075 6225 XSLT engine\001 +4 0 0 50 0 18 12 0.0000 4 135 525 6300 5925 libxslt\001 +4 0 0 50 0 18 12 0.0000 4 135 915 4350 1575 srml2sxml\001 +4 0 0 50 0 12 10 0.0000 4 135 810 2625 1350 _ _foo_ _\001 +4 0 0 50 0 16 12 0.0000 4 135 510 2700 2025 SRML\001 +4 0 0 50 0 12 10 0.0000 4 120 1080 6150 1350
          foo
        \001 +4 0 0 50 0 12 10 0.0000 4 120 900 8325 4275 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 510 8400 5025 HTML\001 +4 0 0 50 0 12 10 0.0000 4 135 1350 8100 5925 \\underline{foo}\001 +4 0 0 50 0 16 12 0.0000 4 135 555 8400 6525 LaTeX\001 +4 0 0 50 0 16 12 0.0000 4 135 750 8325 8025 XML-FO\001 +4 0 0 50 0 12 10 0.0000 4 120 1620 7950 7350 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 960 4350 3075 SXML DTD\001 +4 0 0 50 0 16 10 0.0000 4 120 945 4350 5025 SXML2HTML\001 +4 0 0 50 0 16 10 0.0000 4 120 945 4350 5925 SXML2LaTeX\001 +4 0 0 50 0 16 12 0.0000 4 180 870 4350 6150 Stylesheet\001 +4 0 0 50 0 16 12 0.0000 4 180 870 4350 5250 Stylesheet\001 +4 0 0 50 0 16 10 0.0000 4 120 1065 4350 6825 SXML2XMLFO\001 +4 0 0 50 0 16 12 0.0000 4 180 870 4350 7050 Stylesheet\001 +4 0 0 50 0 18 12 0.0000 4 135 600 10200 7425 xmltex\001 +4 0 0 50 0 16 10 0.0000 4 150 885 10125 7650 (PassiveTex)\001 +4 0 0 50 0 18 12 0.0000 4 180 840 10125 6075 [pdf]latex\001 +4 0 0 50 0 18 12 0.0000 4 135 435 10275 4575 w3m\001 +4 0 0 50 0 12 10 0.0000 4 105 270 12150 4425 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 345 12075 5025 Text\001 +4 0 0 50 0 12 10 0.0000 4 105 270 12150 5925 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 315 12075 6525 DVI\001 +4 0 0 50 0 12 10 0.0000 4 105 270 12150 7425 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 375 12150 8025 PDF\001 +4 0 0 50 0 16 12 0.0000 4 180 810 13725 7275 Postscript\001 +4 0 0 50 0 12 10 0.0000 4 105 270 13875 6600 foo\001 +4 0 0 50 0 18 12 0.0000 4 150 210 13950 8100 gs\001 +4 0 0 50 0 18 12 0.0000 4 180 480 13875 5475 dvips\001 +4 0 0 50 0 16 10 0.0000 4 150 945 13650 8250 (Ghostscript)\001 +4 0 0 50 0 18 24 0.0000 4 360 3360 9300 1200 Sugar Architecture\001 +4 0 34 50 0 16 10 0.0000 4 150 1260 4200 7950 to be implemented\001 +4 0 0 50 0 18 12 0.0000 4 135 840 6225 6750 sxml2xxx\001 +4 0 0 50 0 16 10 0.0000 4 150 3330 9300 1425 OSSP Sugar \001 +4 0 0 50 0 18 12 0.0000 4 135 375 10275 8100 FOP\001 +4 0 0 50 0 12 10 0.0000 4 105 270 12150 8850 foo\001 +4 0 0 50 0 16 12 0.0000 4 135 345 12150 9525 RTF\001 +4 0 0 50 0 18 12 0.0000 4 180 300 10350 8775 jfor\001 Index: ossp-pkg/sugar/sugar.sug RCS File: /v/ossp/cvs/ossp-pkg/sugar/sugar.sug,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sugar.sug,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sugar.sug' 2>/dev/null --- ossp-pkg/sugar/sugar.sug +++ - 2024-05-15 18:12:08.723728558 +0200 @@ -0,0 +1,237 @@ + + Sugar - The Markup Language With Invisible Syntactic Sugar + ========================================================== + + Title: Sugar + Subtitle: The Markup Language With Invisible Syntactic Sugar + Author: Ralf S. Engelschall + Author: Christian Reiber + Genesis: 12-Mar-1999 + Date: 08-Mar-2002 + + Introduction + ------------ + + Sugar is a markup language and corresponding translator tool for + writing technical documentation that uses mostly invisible markup + tags (the so-called //syntactic sugar// in compiler construction folk + terminology). + + The general idea is that the markup text looks already mostly like + the textual output of the translator phase, that is, the Sugar source + can be already treated as its text output format ("ASCII WYSIWYG"). + Additionally the Sugar markup language is considered intuitive enough + to be recognized easily, so writing technical documentation is mainly + just a matter of performing a brain dump. + + So, Sugars syntactic principle is "keep it simple, stupid" (KISS) + but still powerful enough to allow one to produce high-quality + output. Sugars goal is not to provide all features of a full-featured + documentation system. Instead it provides only a few markup concepts + but those are streched to their maximum. + + Sugar Grammar + ------------- + + A Sugar document is described by the following grammar: + + ++ | | | | + | | ::= | * | + | | ::= | \| | + | | ::= | <1d-block> \| <2d-block> | + | <1d-block> | ::= | <1d-tag> | + | <2d-block> | ::= | <2d-tag> | + | <1d-tag> | ::= | "!!##!!" \| "!!\|\!!|" \| "!!``!!" \| "!!''!!" \| ... | + | <2d-tag> | ::= | "!!**!!" \| ... | + + where is defined visually as a rectangular block + of continued text inside the document, that is a paragraph of + text (without any blank lines) where each line starts at the same + indentation position. + + Block Concept + ------------- + + \n\s*\s+ -> <2d-tag> + -> <1d-tag> + + Markup Language + --------------- + + The Sugar markup language consists of markup tags grouped into a few + classes: + + o ..Formatting.. + + For visual formatting of text the following tags exists. They can + be used either as a <1d-tag>, inlined in a paragraph by using them + twice (to delimit begin and end) or as a <2d-tag> for marking + up a whole block by using them in marched-out way (to delimit + the indented block). The tags (and any number of concatenated + repetitions of them) are also allowed to be placed at the end of a + <1d-block>. Then they conver the whole (preceeding) block text. + + ++ | tag | formatting | allowed context | + | !!__!! | underline | inline | + | !!**!! | bold | inline | + | !!//!! | italics | inline | + | !!''!! | code | inline, block | + | !!==!! | header (level I) | block | + | !!--!! | header (level II) | block | + | !!~~!! | header (level III)| block | + | !!..!! | header (level IV) | block | + | !!\!\!!! | verbatim | inline, block | + | !![[!! | boxed | block | + | !!>>!! | indented | block | + | !!%%!! | centered | block | + | !!))!! | right flushed | block | + | !!((!! | left flushed | block | + + Example: + + !! A headline + ========== + + This line contains //italic// and **bold** words. + >> '' And this paragraph contains + indented code. + And this line again is __non-indented__ text. + + o ..Links and References.. + + For referencing textual locations (both document internal and to + external documents), links can be specified. + + ++ | construct | description | + | !!->!![//text//]!!(!!//scheme//!!:!!//path//!!)!! | + external hyperlink via URL | + | !!->!!//text//!!(!!//ref//!!)!! | + internal hyperlink via anchor name | + | !!(+!!//ref//!!+)!! | + internal anchor definition | + + Example: + + !! Header A (+hA+) + -------- + + This is text of header A. For B see ->header B(hB). + For Sugar go to ->(http://www.ossp.org/pkg/tool/sugar/). + + Header B (+hB+) + -------- + + This is text of header B. For A see ->header A(hA). + For other neat things watch ->OSSP(http://www.ossp.org/). + + o ..List Environment.. + + Three types of list environments can be used. They are identified + by the first non-blank word in the first line of each list item. + For ordered lists the start position is selectable by specifying an + explicit digit instead of the generic item character. + + ++ | construct | alternatives | type | + | !!-!! | !!o!!, !!*!! | unordered | + | !!-.!! | !!o.!!, !!*.!!, m/[0-9]+\./ | ordered | + | !!::!! | | itemized | + + Example: + + !! A Sugar list: + 1. foo + o. bar + - baz + - foobar + o. quux + + o ..Table Environment.. + + A generic table environment is provided for any type of data which + has to be rendered in a tabular layout. A table is a <2d-block> + starting with a !!++!! tag. + + The contents of the <2d-block> consists of a 2-dimensional table + specified by cells. The table cells are seperated by ''|'' + characters. Every row has to start with a ''|'' at the same + horizontal position. The number of columns is indicated by the + first table row. This first row can be either a complete (all cells + are specified) and regular (the contents is used) row, or (in case + the first //regular// row is not a complete one, that is, it has + multi-column cell spans), the first row can be an empty row (all + cells are specified for indication but are left blank). + + The ''|'' marks can be placed arbitrary in each row, but if + multi-column spans exists, the surrounding ''|'' marks have to be + placed exactly at the same horizontal character position as the + first table row has (else the multi-column cells are ambiguous). + Empty rows can be indicated by using just the starting ''|'' mark. + + Example: + + !! + ++ | | | | + | foo | !!bar | quux | + | + | foo | baz + bar | quux | + | bazfoo + fjfjkwq + rwrqwd sddksjk + | dsdjks + | foo | + | dsdsds | + +____ + + o ..Special Formatting.. + + '' quotemeta + ## command (charblock until EOL) + `` shell command (charblock until EOL) + + o ..Escaping and Special Characters.. + + -- em-dash (ger. "Gedankenstrich") + \_ strong blank (prevents line break as in HTML's  ) + \n line break (as in HTML's
        ) + \\ a backslash (there no block concept!) + \X escapes following character X + \{name} + + o ..Commands (all charblock until EOL).. + + ##! + ##include + ##// line comment + ##/* block comment anfang + ##*/ block comment ende + ##if + ##elsif + ##endif + ##img ... + ## [range] + + + Sugar Output Formatting + ----------------------- + + The Sugar transformation tool parses a Sugar source text, transforms + it into an internal abstracted syntax tree and finally applies to it a + particular output formatting module in order to transform the abstract + syntax tree into target markup language. The target language then is + either already an end-user document (HTML, Text, etc.) or intended for + post-processing by external programs (LaTeX, PDF, etc.). + + The following outputs are supported: + + ++ | sugar output | post-processor(s) | final output | + | Text | - | Text | + | HTML | - | HTML | + | Roff | nroff | Text | + | Lout | lout | Postscript | + | PDF | pdflib | PDF | + | LaTeX | latex, dvips | DVI, Postscript, PDF | + | XML | docbook | ... | + | POD | pod2xxx | ... | + Index: ossp-pkg/sugar/sugar.txt RCS File: /v/ossp/cvs/ossp-pkg/sugar/Attic/sugar.txt,v co -q -kk -p'1.4' '/v/ossp/cvs/ossp-pkg/sugar/Attic/sugar.txt,v' | diff -u - /dev/null -L'ossp-pkg/sugar/sugar.txt' 2>/dev/null --- ossp-pkg/sugar/sugar.txt +++ /dev/null 2024-05-15 18:11:00.000000000 +0200 @@ -1,238 +0,0 @@ - - Sugar -- The Markup Language With Invisible Syntactic Sugar - =========================================================== - - Ralf S. Engelschall ,&{br} - Christian Reiber - - ++ | Genesis: | 12-Mar-1999 | - | Last Update: | 08-Nov-2000 | - - Introduction - ------------ - - Sugar is a markup language and corresponding translator tool for - writing technical documentation that uses mostly invisible markup - tags (the so-called //syntactic sugar// in compiler construction folk - terminology). - - The general idea is that the markup text looks already like the - textual output of the translator phase, that is, the Sugar source - can be already treated as its text output format ("ASCII WYSIWYG"). - Additionally the Sugar markup language is considered intuitive enough - to be recognized easily, so writing technical documentation is mainly - just a matter of performing a brain dump. - - So Sugars syntactic principle is "keep it simple'n'stupid" (KISS) - but still powerful enough to allow one to produce high-quality - output. Sugars goal is not to provide all features of a full featured - documentation system. Instead it provides only a few markup concepts - but those are streched to a maximum. - - Sugar Grammar - ------------- - - A Sugar document is described by the following grammar: - - ++ | | | | - | | ::= | * | - | | ::= | \| | - | | ::= | <1d-block> \| <2d-block> | - | <1d-block> | ::= | <1d-tag> | - | <2d-block> | ::= | <2d-tag> | - | <1d-tag> | ::= | "!!##!!" \| "!!\|\!!|" \| "!!``!!" \| "!!''!!" \| ... | - | <2d-tag> | ::= | "!!**!!" \| ... | - - where is defined visually as a rectangular block - of continued text inside the document, that is a paragraph of - text (without any blank lines) where each line starts at the same - indentation position. - - Markup Language - --------------- - - The Sugar markup language consists of markup tags grouped into a few - classes: - - o ..Visual Formatting:.. - - For visual formatting of text the following <1d-tag> exists. They - can be used either inlined in a paragraph by using them twice (to - delimit begin and end) or for marking up a whole block by using them - in marched-out way (to delimit indented block). - - ++ | tag | formatting | application | - | !!__!! | underline | inline, block | - | !!**!! | bold | inline, block | - | !!//!! | italics | inline, block | - | !!''!! | code | inline, block | - | !!>>!! | indented | block | - | !!==!! | paragraph header | block | - | !!\!\!!! | verbatim | inline, block (charblock only until EOL) | - | !![[!! | boxed | inline, block | - | !!%%!! | centered | block | - | !!))!! | right flushed | block | - | !!((!! | left flushed | block | - - Example: - - !! This line contains //italics// and **bold** words. - >> '' And this paragraph contains - indented verbatim code. - And this line again is __non-indented__ text. - - o ..Links and References:.. - - For referencing textual locations (both document internal and to - external documents), links can be specified. - - ++ | construct | description | - | !!->!![//text//]!!(!!//scheme//!!:!!//path//!!)!! | - external hyperlink via URL | - | !!->!!//text//!!(!!//ref//!!)!! | - internal hyperlink via anchor-name | - | !!(+!!//ref//!!+)!! | - internal anchor definition | - - Example: - - !! Header A (+hA+) - -------- - - This is text of header A. For B see ->header B(hB). - For Sugar go to ->(http://www.ossp.org/pkg/sugar/). - - Header B (+hB) - -------- - - This is text of header B. For A see ->header A(hA). - For other neat things watch ->OSSP(http://www.ossp.org/). - - o ..Headers:.. - - Up to four levels of headlines can be marked up by placing the - following character sequences (or any number of concatenated - repetitions of them) at the end of a text block: - - ++ | sequence | level | - | !!==!! | I. | - | !!--!! | II. | - | !!~~!! | III. | - | !!..!! | IV. | - - Example: - - !! A header line - ============= - - o ..List Environments:.. - - Three types of list environments can be used. They are identified - by the first non-blank word in the first line of each list item. - For ordered lists the start position is selectable by specifying an - explicit digit instead of the generic item character. - - ++ | construct | alternatives | type | - | !!-!! | !!o!!, !!*!! | unordered | - | !!-.!! | !!o.!!, !!*.!!, m/[0-9]+\./ | ordered | - | !!::!! | | itemized | - - Example: - - !! A Sugar list: - 1. foo - o. bar - - baz - - foobar - o. quux - - o ..Table Environment:.. - - A generic table environment is provided for any type of data which - has to be rendered in a tabular layout. A table is a <2d-block> - starting with a !!++!! tag. - - The contents of the <2d-block> consists of a 2-dimensional table - specified by cells. The table cells are seperated by ''|'' - characters. Every row has to start with a ''|'' at the same - horizontal position. The number of columns is indicated by the - first table row. This first row can be either a complete (all cells - are specified) and regular (the contents is used) row, or (in case - the first //regular// row is not a complete one, that is, it has - multi-column cell spans), the first row can be an empty row (all - cells are specified for indication but are left blank). - - The ''|'' marks can be placed arbitrary in each row, but if - multi-column spans exists, the surrounding ''|'' marks have to be - placed exactly at the same horizontal character position as the - first table row has (else the multi-column cells are ambiguous). - Empty rows can be indicated by using just the starting ''|'' mark. - - Example: - - !! - ++ | | | | - | foo | !!bar | quux | - | - | foo | baz - bar | quux | - | bazfoo - fjfjkwq - rwrqwd sddksjk - | dsdjks - | foo | - | dsdsds | - -____ - - o ..Special Formatting:.. - - '' quotemeta - ## command (charblock until EOL) - `` shell command (charblock until EOL) - - o ..Escaping and Special Characters:.. - - -- em-dash (ger. "Gedankenstrich") - \_ strong blank (prevents line break as in HTML's  ) - \n line break (as in HTML's
        ) - \\ a backslash (there no block concept!) - \X escapes following character X - \{name} - - o Commands (all charblock until EOL): - - ##! - ##include - ##// line comment - ##/* block comment anfang - ##*/ block comment ende - ##if - ##elsif - ##endif - ##img ... - ## [range] - - - Sugar Output Formatting - ----------------------- - - The Sugar transformation tool parses a Sugar source text, transforms - it into an internal abstracted syntax tree and finally applies to it a - particular output formatting module in order to transform the abstract - syntax tree into target markup language. The target language then is - either already an end-user document (HTML, Text, etc.) or intended for - post-processing by external programs (LaTeX, PDF, etc.). - - The following outputs are supported: - - ++ | sugar output | post-processor(s) | final output | - | Text | - | Text | - | HTML | - | HTML | - | Roff | nroff | Text | - | Lout | lout | Postscript | - | PDF | pdflib | PDF | - | LaTeX | latex, dvips | DVI, Postscript, PDF | - | XML | docbook | ... | - | POD | pod2xxx | ... | - Index: ossp-pkg/sugar/sxml.cat RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml.cat,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml.cat,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml.cat' 2>/dev/null --- ossp-pkg/sugar/sxml.cat +++ - 2024-05-15 18:12:08.740418034 +0200 @@ -0,0 +1,7 @@ + + +PUBLIC "-//OSSP//DTD Sugar XML 0.1.0//EN" "sxml.dtd" + Index: ossp-pkg/sugar/sxml.dtd RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml.dtd,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml.dtd,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml.dtd' 2>/dev/null --- ossp-pkg/sugar/sxml.dtd +++ - 2024-05-15 18:12:08.742979956 +0200 @@ -0,0 +1,122 @@ + + + + + + + + + + + %ISO.entities; +]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Index: ossp-pkg/sugar/sxml.iso RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml.iso,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml.iso,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml.iso' 2>/dev/null --- ossp-pkg/sugar/sxml.iso +++ - 2024-05-15 18:12:08.745583018 +0200 @@ -0,0 +1,1085 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Index: ossp-pkg/sugar/sxml2fo.xsl RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml2fo.xsl,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml2fo.xsl,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml2fo.xsl' 2>/dev/null --- ossp-pkg/sugar/sxml2fo.xsl +++ - 2024-05-15 18:12:08.748870729 +0200 @@ -0,0 +1,2 @@ + + Index: ossp-pkg/sugar/sxml2html.xsl RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml2html.xsl,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml2html.xsl,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml2html.xsl' 2>/dev/null --- ossp-pkg/sugar/sxml2html.xsl +++ - 2024-05-15 18:12:08.751392757 +0200 @@ -0,0 +1,30 @@ + + + + + + + + + + + + +

        +
        + + + Abstract +
        +
        + +
        +
        + +
        + Index: ossp-pkg/sugar/sxml2latex.xsl RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml2latex.xsl,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml2latex.xsl,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml2latex.xsl' 2>/dev/null --- ossp-pkg/sugar/sxml2latex.xsl +++ - 2024-05-15 18:12:08.753934436 +0200 @@ -0,0 +1,2 @@ + + Index: ossp-pkg/sugar/sxml2roff.xsl RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml2roff.xsl,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml2roff.xsl,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml2roff.xsl' 2>/dev/null --- ossp-pkg/sugar/sxml2roff.xsl +++ - 2024-05-15 18:12:08.756475387 +0200 @@ -0,0 +1,2 @@ + + Index: ossp-pkg/sugar/sxml2xxx RCS File: /v/ossp/cvs/ossp-pkg/sugar/sxml2xxx,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/sxml2xxx,v' | diff -u /dev/null - -L'ossp-pkg/sugar/sxml2xxx' 2>/dev/null --- ossp-pkg/sugar/sxml2xxx +++ - 2024-05-15 18:12:08.758996230 +0200 @@ -0,0 +1,5 @@ +#!/usr/bin/perl +## +## sxml2xxx -- Sugar XML to Output Translator +## + Index: ossp-pkg/sugar/test.srml RCS File: /v/ossp/cvs/ossp-pkg/sugar/test.srml,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/test.srml,v' | diff -u /dev/null - -L'ossp-pkg/sugar/test.srml' 2>/dev/null --- ossp-pkg/sugar/test.srml +++ - 2024-05-15 18:12:08.761515335 +0200 @@ -0,0 +1,64 @@ + + Sugar - The Markup Language With Invisible Syntactic Sugar + ========================================================== + + Title: Sugar - The Markup Language With Invisible Syntactic Sugar + Author: Ralf S. Engelschall + Author: Christian Reiber + Genesis: 12-Mar-1999 + Date: 26-Jun-2000 + + Introduction + ------------ + + Me & you Sugar is a markup language and corresponding translator tool for + writing technical documentation that uses mostly invisible markup + tags (the so-called //syntactic sugar// in compiler construction folk + terminology). See ->foo<- **foo** + + The general idea is that the markup text looks already like the + textual output of the translator phase, that is, the Sugar source + can be already treated as its text output format ("ASCII WYSIWYG"). + Additionally the Sugar markup language is considered intuitive enough + to be recognized easily, so writing technical documentation is mainly + just a matter of performing a brain dump. (+foo+) + + || Special Block For testing + + o. foo + bar + + o baz1 + o baz2 + + -. quux + + purposes only. + + So Sugars syntactic principle is "keep it simple'n'stupid" (KISS) + but still powerful enough to allow one to produce high-quality + output. Sugars goal is not to **provide** all features of a full featured + documentation system. Instead it provides only a few markup concepts + but those are streched to a **maximum. + + Sugar Grammar + ------------- + + A Sugar document is described by the following grammar: + + ++ table + foo bar + quux + + where is defined visually as a rectangular block + of continued text inside the document, that is a paragraph of + + ** BOLD TEXT + + text (without any blank lines) where each line starts at the same + + ** BOLD TEXT + A SECOND TIME + + indentation position. + Index: ossp-pkg/sugar/test.sxml RCS File: /v/ossp/cvs/ossp-pkg/sugar/test.sxml,v co -q -kk -p'1.1' '/v/ossp/cvs/ossp-pkg/sugar/test.sxml,v' | diff -u /dev/null - -L'ossp-pkg/sugar/test.sxml' 2>/dev/null --- ossp-pkg/sugar/test.sxml +++ - 2024-05-15 18:12:08.764057832 +0200 @@ -0,0 +1,17 @@ + + + + + A Sample Sugar XML Document + Ralf S. Engelschall + + Foobar abstract + + + +

        Header 1

        + Hallo 1! +

        Header 2

        + Hallo 2! + +