version 1.23, 2004/01/25 19:35:13
|
version 1.24, 2004/02/02 14:15:23
|
Line 37 Variable indentlevel
|
Line 37 Variable indentlevel
|
Variable tag-option |
Variable tag-option |
s" " tag-option $! |
s" " tag-option $! |
|
|
|
: .type ( addr u -- ) |
|
bounds ?DO I c@ |
|
case |
|
'& of ." &" endof |
|
'< of ." <" endof |
|
dup emit |
|
endcase |
|
LOOP ; |
|
|
: tag ( addr u -- ) '< emit type tag-option $@ type '> emit |
: tag ( addr u -- ) '< emit type tag-option $@ type '> emit |
s" " tag-option $! ; |
s" " tag-option $! ; |
: tag/ ( addr u -- ) s" /" tag-option $+! tag ; |
: tag/ ( addr u -- ) s" /" tag-option $+! tag ; |
: /tag ( addr u -- ) '< emit '/ emit type '> emit ; |
: /tag ( addr u -- ) '< emit '/ emit type '> emit ; |
: tagged ( addr1 u1 addr2 u2 -- ) 2dup 2>r tag type 2r> /tag ; |
: tagged ( addr1 u1 addr2 u2 -- ) 2dup 2>r tag .type 2r> /tag ; |
|
|
: opt ( addr u opt u -- ) s" " tag-option $+! |
: opt ( addr u opt u -- ) s" " tag-option $+! |
tag-option $+! s' ="' tag-option $+! tag-option $+! |
tag-option $+! s' ="' tag-option $+! tag-option $+! |
Line 243 s" Gforth" environment? [IF] s" 0.5.0" s
|
Line 252 s" Gforth" environment? [IF] s" 0.5.0" s
|
\ line handling |
\ line handling |
|
|
: char? ( -- c ) >in @ char swap >in ! ; |
: char? ( -- c ) >in @ char swap >in ! ; |
|
|
: parse-tag ( addr u char -- ) |
: parse-tag ( addr u char -- ) |
>r r@ parse type |
>r r@ parse .type |
r> parse 2swap tagged ; |
r> parse 2swap tagged ; |
|
|
: .text ( -- ) >in @ >r char drop |
: .text ( -- ) >in @ >r char drop |
source r@ /string >in @ r> - nip |
source r@ /string >in @ r> - nip .type ; |
bounds ?DO I c@ |
|
case |
|
'& of ." &" endof |
|
'< of ." <" endof |
|
dup emit |
|
endcase |
|
LOOP ; |
|
|
|
Create do-words $100 0 [DO] ' .text , [LOOP] |
Create do-words $100 0 [DO] ' .text , [LOOP] |
|
|
Line 502 Variable css-file
|
Line 505 Variable css-file
|
s" Content-Type" s" http-equiv" opt |
s" Content-Type" s" http-equiv" opt |
s" text/xhtml; charset=iso-8859-1" s" content" opt |
s" text/xhtml; charset=iso-8859-1" s" content" opt |
s" meta" tag/ |
s" meta" tag/ |
css-file @ IF css-file $@len IF |
css-file @ IF css-file $@len IF |
s" StyleSheet" s" rel" opt |
s" StyleSheet" s" rel" opt |
css-file $@ href= |
css-file $@ href= |
s" text/css" s" type" opt s" link" tag/ |
s" text/css" s" type" opt s" link" tag/ |
THEN THEN |
THEN THEN |
s" title" tagged cr |
s" title" tagged cr |
-env ; |
-env ; |
|
|