From e36d23a85ebff914d74bb541558c2b6082b78edb Mon Sep 17 00:00:00 2001 From: dan miller Date: Sat, 20 Oct 2007 02:49:29 +0000 Subject: sqlite source (unix build) added to libraries --- libraries/sqlite/unix/sqlite-3.5.1/www/common.tcl | 90 +++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 libraries/sqlite/unix/sqlite-3.5.1/www/common.tcl (limited to 'libraries/sqlite/unix/sqlite-3.5.1/www/common.tcl') diff --git a/libraries/sqlite/unix/sqlite-3.5.1/www/common.tcl b/libraries/sqlite/unix/sqlite-3.5.1/www/common.tcl new file mode 100644 index 0000000..07129f8 --- /dev/null +++ b/libraries/sqlite/unix/sqlite-3.5.1/www/common.tcl @@ -0,0 +1,90 @@ +# This file contains TCL procedures used to generate standard parts of +# web pages. +# + +proc header {txt} { + puts "$txt" + puts {
} + puts \ +{ + + + + + + + + +
+ + + + + + +
+ + +
} + puts
+} + +proc footer {{rcsid {}}} { + puts { + + +
} + set date [lrange $rcsid 3 4] + if {$date!=""} { + puts "This page last modified on $date" + } + puts {} +} + + +# The following proc is used to ensure consistent formatting in the +# HTML generated by lang.tcl and pragma.tcl. +# +proc Syntax {args} { + puts {} + foreach {rule body} $args { + puts "" + regsub -all < $body {%LT} body + regsub -all > $body {%GT} body + regsub -all %LT $body {} body + regsub -all %GT $body {} body + regsub -all {[]|[*?]} $body {&} body + regsub -all "\n" [string trim $body] "
\n" body + regsub -all "\n *" $body "\n\\ \\ \\ \\ " body + regsub -all {[|,.*()]} $body {&} body + regsub -all { = } $body { = } body + regsub -all {STAR} $body {*} body + ## These metacharacters must be handled to undo being + ## treated as SQL punctuation characters above. + regsub -all {RPPLUS} $body {
)+} body + regsub -all {LP} $body {(} body + regsub -all {RP} $body {)} body + ## Place the left-hand side of the rule in the 2nd table column. + puts "" + } + puts {
" + puts "$rule ::=$body
} +} -- cgit v1.1