TERM-CAPTURE-CONTROLS
( -- var-ptr )
=> [FORTH]
enable/disable common visualization of terminal control sequences.
primitive code = [p4_term_capture_controls]
(TERM-CAPTURE-ON)
=> [FORTH]
(no description)
primitive code = [p4_paren_term_capture_on]
(TERM-CAPTURE-OFF)
=> [FORTH]
(no description)
primitive code = [p4_paren_term_capture_off]
(TERM-CAPTURE-BUFFER)
=> [FORTH]
(no description)
primitive code = [p4_paren_term_capture_buffer]
(TERM-CAPTURE-RESULT)
=> [FORTH]
(no description)
primitive code = [p4_paren_term_capture_result]
TERM-CAPTURE-ON
( capturebuffer-ptr capturebuffer-len -- )
=> [FORTH]
init/start capturing terminal output
: TERM-CAPTURE-ON (TERM-CAPTURE-BUFFER) (TERM-CAPTURE-ON) ;
primitive code = [p4_term_capture_on]
TERM-CAPTURE-OFF
( -- capturebuffer-ptr capturebuffer-len )
=> [FORTH]
shutdown capturing terminal output
: TERM-CAPTURE-OFF (TERM-CAPTURE-OFF) (TERM-CAPTURE-RESULT) ;
primitive code = [p4_term_capture_off]
TERMCATCH
( str-ptr str-len some-xt* -- str-ptr str-len' catch-code# )
=> [FORTH]
create a catch-domain around the token to be executed. This works
the same as CATCH
. Additionally all terminal output of that word
is being captured to the buffer being provided as an argument. The
maximum length input argument is modified flagging the actual length
of captured output stream as the output argument. Note that in most
cases a POCKET-PAD
is just not big enough, atleast many error
condition notifications tend to be quite lengthy for byte counted
forth strings.
: TERMCATCH TERM-CAPTURE-ON CATCH >R TERM-CAPTURE-OFF R> ;
primitive code = [p4_termcatch]