| |
|
| : cygwin? ( -- flag ) s" TERM" getenv s" cygwin" str= ; |
: cygwin? ( -- flag ) s" TERM" getenv s" cygwin" str= ; |
| : at-xy? ( -- x y ) |
: at-xy? ( -- x y ) |
| key? drop |
|
| #esc emit ." [6n" 0 0 |
#esc emit ." [6n" 0 0 |
| BEGIN key dup 'R <> WHILE |
BEGIN key dup 'R <> WHILE |
| dup '; = IF drop swap ELSE |
dup '; = IF drop swap ELSE |
| |
|
| : xretype ( max span addr pos1 -- max span addr pos1 ) |
: xretype ( max span addr pos1 -- max span addr pos1 ) |
| restore-cursor screenw @ >r save-cursor |
restore-cursor screenw @ >r save-cursor |
| .all 2 pick r@ / 1+ screenw @ r> - * 0 max spaces .rest false ; |
.all 2 pick r@ / screenw @ r> - * 0 max spaces .rest false ; |
| |
|
| \ In the following, addr max is the buffer, addr span is the current |
\ In the following, addr max is the buffer, addr span is the current |
| \ string in the buffer, and pos1 is the cursor position in the buffer. |
\ string in the buffer, and pos1 is the cursor position in the buffer. |