interner aufbau - erster teil

master
Denis Knauf 2011-01-21 11:31:43 +01:00
parent f6b668d701
commit f8969fb504
2 changed files with 64 additions and 4 deletions

View File

@ -210,6 +210,19 @@ ptype-reset
: <li> ( -- addr u0 , xt-{li} 0 ) ['] {li} , here 0 , 0 ;
: {/li} ( addr -- addr ) cr ;
: </li> ( addr len -- , xt-{/li} ) ['] {/li} , swap ! ;
33 constant table-color
: {|} ( addr -- addr )
dup @ dup ptype-cursorx@ - \ addr > >-i
dup 1 < if
drop
else
1- spaces
endif
ptype-curx ! table-color sgr ." |" 39 sgr cell+
;
: <|> ( i -- addr , xt-{|} i ) ['] {|} , , ;
: {-} ( addr -- addr ) cr dup @ 0 table-color sgr +do [char] - emit loop 39 sgr cell+ cr ;
: <-> ( i -- addr , xt-{-} i ) ['] {-} , , ;
variable enumerationCount ( -- addr )
: {||} ( addr -- addr ) \ increments enumeration count and prints prefix
@ -272,15 +285,15 @@ Create line-buffer max-line 2 + allot
showLines printsource cr
;
: {source} ( -- ) ;
: {source} ( -- ) ;
: <source> ( -- , xt-{source} ) ['] {source} , ;
: {/source} ( -- ) dup dup dup dup @ swap cell + @ 2swap cell 2 * +
: {/source} ( -- ) dup dup dup dup @ swap cell + @ 2swap cell 2 * +
@ swap cell 3 * + @ 1 printCodeHeader 4 cells + ;
: </source> ( -- , xt-{/source} ) ['] {/source} , , , , , ;
: {file} ( -- ) ;
: {file} ( -- ) ;
: <file> ( -- , xt-{file} ) ['] {file} , ;
: {/file} ( -- ) dup dup dup dup @ swap cell + @ 2swap cell 2 * +
: {/file} ( -- ) dup dup dup dup @ swap cell + @ 2swap cell 2 * +
@ swap cell 3 * + @ 0 printCodeHeader 4 cells + ;
: </file> ( -- , xt-{/file} ) ['] {/file} , , , , , ;

View File

@ -97,6 +97,53 @@
<li> !" Vordergrundfarbe: " <f> s\" Brown <fc> !\" text\" </fc> " !! </f> !" : " Brown <fc> !\" text" </fc> </li>
<p> !" 8 Farben sind moeglich:" </p>
<p> farbendemo </p>
<np>
<h> !" Interner Aufbau" </h>
<p>
71 <->
1 <|> <b> !" Beschreibung" </b> 18 <|> 56 <|> <b> !" in forth" </b> 71 <|>
71 <->
1 <|> 18 <|> 56 <|> 71 <|>
71 <->
</p>
<np>
<h> !" Interner Aufbau" </h>
<p>
71 <->
1 <|> !" Beschreibung" 18 <|> 56 <|> !" in forth" 71 <|>
71 <->
1 <|> <b> !" Speicheraufbau" </b> 18 <|> 56 <|> <b> !\" here-\"stack\"" </b> 71 <|>
71 <->
</p>
<np>
<h> !" Interner Aufbau" </h>
<p>
71 <->
1 <|> !" Beschreibung" 18 <|> <b> s\" ... <p> <i> !\" text \" </i> </p> ..." !! </b> 56 <|> !" in forth" 71 <|>
71 <->
1 <|> !" Speicheraufbau" 18 <|> 56 <|> !\" here-\"stack\"" 71 <|>
71 <->
</p>
<np>
<h> !" Interner Aufbau" </h>
<p>
71 <->
1 <|> !" Beschreibung" 18 <|> s\" ... <p> <i> !\" text \" </i> </p> ..." !! 56 <|> !" in forth" 71 <|>
71 <->
1 <|> !" Speicheraufbau" 18 <|> <b> s\" {p} 5 {i} {!!} addr len {/i} {/p} " !! </b> 56 <|> !\" here-\"stack\"" 71 <|>
71 <->
</p>
<np>
<h> !" Interner Aublauf" </h>
<p>
71 <->
1 <|> !" Speicheraufbau" 18 <|> s\" {p} 5 {i} {!!} addr len {/i} {/p} " !! 56 <|> !\" here-\"stack\"" 71 <|>
<br>
1 <|> !" Execute" 18 <|> <b> s\" ^" !! </b> 56 <|> 71 <|>
71 <->
</p>
<np>
<p>
<h> !" Zeit für Makros!!" </h>