version 1.30, 2004/12/31 13:23:58
|
version 1.32, 2005/01/16 13:29:21
|
Line 34 require string.fs
|
Line 34 require string.fs
|
|
|
\ character recoding |
\ character recoding |
|
|
[IFDEF] 8-bit-io 8-bit-io [THEN] |
[IFDEF] maxascii $100 to maxascii 8-bit-io [THEN] |
\ UTF-8 IO fails with .type: |
\ UTF-8 IO fails with .type: |
|
|
: .type ( addr u -- ) |
: .type ( addr u -- ) |
Line 232 Variable icon-tmp
|
Line 232 Variable icon-tmp
|
|
|
Variable do-size |
Variable do-size |
Variable do-icon |
Variable do-icon |
|
Variable do-expand |
|
|
Defer parse-line |
Defer parse-line |
|
|
Line 295 Defer parse-line
|
Line 296 Defer parse-line
|
THEN ; |
THEN ; |
|
|
: link-options ( addr u -- addr' u' ) |
: link-options ( addr u -- addr' u' ) |
do-size off do-icon on |
do-size off do-icon on do-expand off |
over c@ '% = over 0> and IF do-size on 1 /string THEN |
over c@ '% = over 0> and IF do-size on 1 /string THEN |
over c@ '\ = over 0> and IF do-icon off 1 /string THEN ; |
over c@ '\ = over 0> and IF do-icon off 1 /string THEN |
|
over c@ '* = over 0> and IF do-expand on 1 /string THEN ; |
|
|
s" Gforth" environment? [IF] s" 0.5.0" str= [IF] |
s" Gforth" environment? [IF] s" 0.5.0" str= [IF] |
: parse-string ( c-addr u -- ) \ core,block |
: parse-string ( c-addr u -- ) \ core,block |
Line 312 s" Gforth" environment? [IF] s" 0.5.0" s
|
Line 314 s" Gforth" environment? [IF] s" 0.5.0" s
|
['] parse-line catch pop-file throw ; |
['] parse-line catch pop-file throw ; |
[THEN] [THEN] |
[THEN] [THEN] |
|
|
|
Variable expand-link |
|
Variable expand-prefix |
|
Variable expand-postfix |
|
|
|
: ?expand ( addr u -- ) expand-link $! |
|
do-expand @ IF |
|
expand-prefix $@ expand-link 0 $ins |
|
expand-postfix $@ expand-link $+! THEN |
|
expand-link $@ ; |
|
|
: .link ( addr u -- ) dup >r '| -$split dup r> = IF 2swap THEN |
: .link ( addr u -- ) dup >r '| -$split dup r> = IF 2swap THEN |
link-options link $! |
link-options link $! |
link $@len 0= IF 2dup link $! ( s" .html" link $+! ) THEN |
link $@len 0= IF 2dup link $! ( s" .html" link $+! ) THEN |
link $@ href= s" a" tag link-icon? |
link $@ ?expand |
|
href= s" a" tag link-icon? |
parse-string s" a" /tag link-size? link-sig? link-warn? ; |
parse-string s" a" /tag link-size? link-sig? link-warn? ; |
: >link ( -- ) '[ parse type '] parse .link ; |
: >link ( -- ) '[ parse type '] parse .link ; |
|
|
Line 388 wordlist Constant autoreplacements
|
Line 401 wordlist Constant autoreplacements
|
\ paragraph handling |
\ paragraph handling |
|
|
: parse-par ( -- ) |
: parse-par ( -- ) |
BEGIN parse-line+ cr refill WHILE |
BEGIN |
|
parse-line+ cr refill WHILE |
source nip 0= UNTIL THEN ; |
source nip 0= UNTIL THEN ; |
|
|
: par ( addr u -- ) env? |
: par ( addr u -- ) env? |
Line 599 definitions
|
Line 613 definitions
|
ELSE source nip IF >in off s" p" par THEN THEN ; |
ELSE source nip IF >in off s" p" par THEN THEN ; |
: parse-section ( -- ) end-sec off |
: parse-section ( -- ) end-sec off |
BEGIN refill WHILE |
BEGIN refill WHILE |
section-par end-sec @ UNTIL THEN ; |
section-par end-sec @ UNTIL THEN ; |
|
|
\ HTML head |
\ HTML head |
|
|
Line 653 Variable orig-date
|
Line 667 Variable orig-date
|
bl sword orig-date $! ; |
bl sword orig-date $! ; |
: icons |
: icons |
bl sword icon-prefix $! ; |
bl sword icon-prefix $! ; |
|
: expands '# sword expand-prefix $! bl sword expand-postfix $! ; |
|
|
icons icons |
icons icons |
|
|
Variable style$ |
Variable style$ |