version 1.54, 2008/04/08 09:04:21
|
version 1.59, 2008/10/12 13:15:23
|
Line 1
|
Line 1
|
\ wiki forth |
\ wiki forth |
|
|
\ Copyright (C) 2003,2004,2005,2006,2007 Free Software Foundation, Inc. |
\ Copyright (C) 2003,2004,2005,2006,2007,2008 Free Software Foundation, Inc. |
|
|
\ This file is part of Gforth. |
\ This file is part of Gforth. |
|
|
Line 272 Defer parse-line
|
Line 272 Defer parse-line
|
|
|
: get-icon ( addr u -- ) iconpath @ IF 2drop EXIT THEN |
: get-icon ( addr u -- ) iconpath @ IF 2drop EXIT THEN |
link-suffix $! s" .*" link-suffix $+! |
link-suffix $! s" .*" link-suffix $+! |
icon-prefix $@ open-dir throw >r |
icon-prefix $@ open-dir IF drop EXIT THEN >r |
BEGIN |
BEGIN |
pad $100 r@ read-dir throw WHILE |
pad $100 r@ read-dir throw WHILE |
pad swap 2dup link-suffix $@ filename-match |
pad swap 2dup link-suffix $@ filename-match |
Line 380 Create do-words $100 0 [DO] ' .text , [
|
Line 380 Create do-words $100 0 [DO] ' .text , [
|
: >tag '\ parse type '\ parse tag ; |
: >tag '\ parse type '\ parse tag ; |
|
|
char>tag * b |
char>tag * b |
|
char>tag / i |
char>tag _ em |
char>tag _ em |
char>tag # code |
char>tag # code |
:noname '~ parse .type '~ parse .type ; '~ cells do-words + ! |
:noname '~ parse .type '~ parse .type ; '~ cells do-words + ! |
Line 462 Create nav-buf 0 c,
|
Line 463 Create nav-buf 0 c,
|
ELSE dup 'a 'z 1+ within IF nav+ |
ELSE dup 'a 'z 1+ within IF nav+ |
ELSE dup '0 '9 1+ within IF nav+ |
ELSE dup '0 '9 1+ within IF nav+ |
ELSE dup bl = over '- = or IF '- nav+ |
ELSE dup bl = over '- = or IF '- nav+ |
ELSE nav+ |
ELSE drop |
THEN THEN THEN THEN |
THEN THEN THEN THEN |
LOOP ; |
LOOP ; |
: >nav ( addr u -- addr' u' ) |
: >nav ( addr u -- addr' u' ) |
Line 531 true Value toc-image
|
Line 532 true Value toc-image
|
IF -env cr s" p" >env THEN ; |
IF -env cr s" p" >env THEN ; |
|
|
: print-toc ( -- ) toc-index off cr |
: print-toc ( -- ) toc-index off cr |
toc-image IF s" img-menu" ELSE s" menu" THEN id= |
toc-image IF s" img-menu" ELSE s" menu" THEN class= |
s" div" >env cr s" p" >env |
s" div" >env cr s" p" >env |
0 parse |
0 parse |
dup 0= IF toc-name $! 0 ELSE |
dup 0= IF toc-name $! 0 ELSE |
Line 579 longtags set-current
|
Line 580 longtags set-current
|
: p<< s" p" >env ; |
: p<< s" p" >env ; |
: << +env ; |
: << +env ; |
: <* s" center" class= ; |
: <* s" center" class= ; |
: <red s" p" >env s" #ff0000" s" color" opt s" font" >env parse-par ; |
: <red s" red" class= s" p" >env parse-par ; |
: red> -env -env ; |
: red> -env ; |
: >> -env ; |
: >> -env ; |
: *> ; |
: *> ; |
: :: interpret ; |
: :: interpret ; |
Line 740 Variable orig-date
|
Line 741 Variable orig-date
|
'< sword -trailing mail-name $! '> sword mail $! ; |
'< sword -trailing mail-name $! '> sword mail $! ; |
: pgp-key ( -- ) |
: pgp-key ( -- ) |
bl sword -trailing public-key $! ; |
bl sword -trailing public-key $! ; |
: charset ( -- ) s" text/xhtml; charset=" content $! |
: charset ( -- ) s" application/xhtml+xml; charset=" content $! |
bl sword -trailing 2dup content $+! _charset $! ; |
bl sword -trailing 2dup content $+! _charset $! ; |
|
|
charset iso-8859-1 |
charset iso-8859-1 |