--- gforth/wf.fs 2008/04/08 09:04:21 1.54 +++ gforth/wf.fs 2008/10/12 13:15:23 1.59 @@ -1,6 +1,6 @@ \ 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. @@ -272,7 +272,7 @@ Defer parse-line : get-icon ( addr u -- ) iconpath @ IF 2drop EXIT THEN link-suffix $! s" .*" link-suffix $+! - icon-prefix $@ open-dir throw >r + icon-prefix $@ open-dir IF drop EXIT THEN >r BEGIN pad $100 r@ read-dir throw WHILE pad swap 2dup link-suffix $@ filename-match @@ -380,6 +380,7 @@ Create do-words $100 0 [DO] ' .text , [ : >tag '\ parse type '\ parse tag ; char>tag * b +char>tag / i char>tag _ em char>tag # code :noname '~ parse .type '~ parse .type ; '~ cells do-words + ! @@ -462,7 +463,7 @@ Create nav-buf 0 c, ELSE dup 'a 'z 1+ within IF nav+ ELSE dup '0 '9 1+ within IF nav+ ELSE dup bl = over '- = or IF '- nav+ - ELSE nav+ + ELSE drop THEN THEN THEN THEN LOOP ; : >nav ( addr u -- addr' u' ) @@ -531,7 +532,7 @@ true Value toc-image IF -env cr s" p" >env THEN ; : 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 0 parse dup 0= IF toc-name $! 0 ELSE @@ -579,8 +580,8 @@ longtags set-current : p<< s" p" >env ; : << +env ; : <* s" center" class= ; -: env s" #ff0000" s" color" opt s" font" >env parse-par ; -: red> -env -env ; +: env parse-par ; +: red> -env ; : >> -env ; : *> ; : :: interpret ; @@ -740,7 +741,7 @@ Variable orig-date '< sword -trailing mail-name $! '> sword mail $! ; : pgp-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 $! ; charset iso-8859-1