mirror of
https://github.com/hsoft/collapseos.git
synced 2024-11-02 04:10:56 +11:00
Compare commits
No commits in common. "bc951a5ff1f451023caa09fa68f23ac6bd127799" and "c16c5c98ce56b7707adad3f71bdbd095feaf0dbe" have entirely different histories.
bc951a5ff1
...
c16c5c98ce
4
blk/101
4
blk/101
@ -12,5 +12,5 @@ F xxx: find typed FBUF in block, starting from current
|
|||||||
position+1. If not found, don't move.
|
position+1. If not found, don't move.
|
||||||
I xxx: insert typed IBUF at cursor. "I" shadows core word. Use
|
I xxx: insert typed IBUF at cursor. "I" shadows core word. Use
|
||||||
"i" to access it.
|
"i" to access it.
|
||||||
Y: Copy n characters after cursor into IBUF, n being length of
|
X ( n -- ): Delete X chars after cursor and place in IBUF.
|
||||||
FBUF. (cont.)
|
E: Run X with n = length of FBUF.
|
||||||
|
2
blk/102
2
blk/102
@ -1,2 +0,0 @@
|
|||||||
X ( n -- ): Delete X chars after cursor and place in IBUF.
|
|
||||||
E: Run X with n = length of FBUF.
|
|
2
blk/112
2
blk/112
@ -8,4 +8,4 @@
|
|||||||
SWAP 0 FILL
|
SWAP 0 FILL
|
||||||
EDPOS @ 64 / _pln ;
|
EDPOS @ 64 / _pln ;
|
||||||
: E FBUF _blen X ;
|
: E FBUF _blen X ;
|
||||||
: Y FBUF _blen icpy ;
|
|
||||||
|
2
blk/121
2
blk/121
@ -13,4 +13,4 @@ saved beforehand.
|
|||||||
|
|
||||||
'[' and ']' advances the selected block by "modifier".
|
'[' and ']' advances the selected block by "modifier".
|
||||||
|
|
||||||
(cont.)
|
';' resets the modifier. 'q' quits. (cont.)
|
||||||
|
8
blk/122
8
blk/122
@ -6,11 +6,11 @@
|
|||||||
'w' moves forward by "modifier" words. 'b' moves backward.
|
'w' moves forward by "modifier" words. 'b' moves backward.
|
||||||
'W' moves to end-of-word. 'B', backwards.
|
'W' moves to end-of-word. 'B', backwards.
|
||||||
|
|
||||||
'I', 'F', 'Y', 'X' and 'E' invoke the corresponding command
|
'I', 'F', 'X' and 'E' invoke the corresponding command from the
|
||||||
from the Block Editor (B100). Refer to documentation there.
|
Block Editor (B100). Refer to documentation there.
|
||||||
|
|
||||||
'o' inserts a blank line after the cursor. 'O', before.
|
'o' inserts a blank line after the cursor. 'O', before.
|
||||||
|
|
||||||
'D' deletes "modifier" lines at the cursor. The first of those
|
'D' deletes "modifier" lines at the cursor.
|
||||||
lines is copied to IBUF.
|
|
||||||
(cont.)
|
(cont.)
|
||||||
|
3
blk/126
3
blk/126
@ -1,6 +1,7 @@
|
|||||||
CREATE CMD 2 C, '$' C, 0 C,
|
CREATE CMD 2 C, '$' C, 0 C,
|
||||||
VARIABLE PREVPOS
|
VARIABLE PREVPOS
|
||||||
: acc@ ACC @ 1 MAX ;
|
: 0acc 0 ACC ! ;
|
||||||
|
: acc@ ACC @ 1 MAX 0acc ;
|
||||||
: num ACC @ SWAP _pdacc IF DROP ELSE ACC ! THEN ;
|
: num ACC @ SWAP _pdacc IF DROP ELSE ACC ! THEN ;
|
||||||
: nspcs ( n -- , spit n space ) 0 DO SPC LOOP ;
|
: nspcs ( n -- , spit n space ) 0 DO SPC LOOP ;
|
||||||
: aty 0 SWAP AT-XY ;
|
: aty 0 SWAP AT-XY ;
|
||||||
|
8
blk/128
8
blk/128
@ -1,12 +1,12 @@
|
|||||||
: $g ACC @ selblk ;
|
: $; 0acc ;
|
||||||
|
: $g ACC @ selblk 0acc ;
|
||||||
: $[ BLK> @ acc@ - selblk ;
|
: $[ BLK> @ acc@ - selblk ;
|
||||||
: $] BLK> @ acc@ + selblk ;
|
: $] BLK> @ acc@ + selblk ;
|
||||||
: $I mode! 'I' EMIT IBUF 1 buftype _I contents mode! SPC ;
|
: $I mode! 'I' EMIT IBUF 1 buftype _I contents mode! SPC ;
|
||||||
: $F mode! 'F' EMIT FBUF 2 buftype _F setpos mode! SPC ;
|
: $F mode! 'F' EMIT FBUF 2 buftype _F setpos mode! SPC ;
|
||||||
: $Y Y ;
|
|
||||||
: $E E contents ;
|
: $E E contents ;
|
||||||
: $X acc@ X contents ;
|
: $X acc@ X contents ;
|
||||||
: $h -1 cmv ; : $l 1 cmv ; : $k -64 cmv ; : $j 64 cmv ;
|
: $h -1 cmv ; : $l 1 cmv ; : $k -64 cmv ; : $j 64 cmv ;
|
||||||
: $H EDPOS @ 0x3c0 AND pos! ;
|
: $H 0acc EDPOS @ 0x3c0 AND pos! ;
|
||||||
: $L EDPOS @ 0x3f OR pos! ;
|
: $L 0acc EDPOS @ 0x3f OR pos! ;
|
||||||
|
|
||||||
|
3
blk/130
3
blk/130
@ -10,6 +10,5 @@
|
|||||||
: $O EDPOS @ 0x3c0 ( 15 * 64 ) >= IF EXIT THEN
|
: $O EDPOS @ 0x3c0 ( 15 * 64 ) >= IF EXIT THEN
|
||||||
_U EDPOS @ 0x3c0 AND DUP pos! _cpos _zbuf BLK!! contents ;
|
_U EDPOS @ 0x3c0 AND DUP pos! _cpos _zbuf BLK!! contents ;
|
||||||
: $o EDPOS @ 64 < IF EXIT THEN EDPOS @ 64 + EDPOS ! $O ;
|
: $o EDPOS @ 64 < IF EXIT THEN EDPOS @ 64 + EDPOS ! $O ;
|
||||||
: $D $H 64 icpy
|
: $D acc@ 0 DO 16 EDPOS @ 64 / DO i _mvln- LOOP LOOP
|
||||||
acc@ 0 DO 16 EDPOS @ 64 / DO i _mvln- LOOP LOOP
|
|
||||||
BLK!! contents ;
|
BLK!! contents ;
|
||||||
|
4
blk/131
4
blk/131
@ -1,7 +1,7 @@
|
|||||||
: handle ( c -- f )
|
: handle ( c -- f )
|
||||||
DUP '0' '9' =><= IF num 0 EXIT THEN
|
DUP '0' '9' =><= IF num 0 EXIT THEN
|
||||||
DUP CMD 2+ C! CMD FIND IF EXECUTE ELSE DROP THEN
|
DUP CMD 2+ C! CMD FIND IF EXECUTE ELSE DROP THEN
|
||||||
0 ACC ! UPPER 'Q' = ;
|
UPPER 'Q' = ;
|
||||||
: bufp ( buf -- )
|
: bufp ( buf -- )
|
||||||
DUP 64 + SWAP DO i C@ 0x20 MAX EMIT LOOP ;
|
DUP 64 + SWAP DO i C@ 0x20 MAX EMIT LOOP ;
|
||||||
: bufs
|
: bufs
|
||||||
@ -9,6 +9,6 @@
|
|||||||
2 aty ." F: " FBUF bufp ;
|
2 aty ." F: " FBUF bufp ;
|
||||||
: c<over KEY DUP EMIT DUP 0x0a = IF DROP 0x0d THEN ;
|
: c<over KEY DUP EMIT DUP 0x0a = IF DROP 0x0d THEN ;
|
||||||
: VE ['] c<over 0x08 ( C< override ) RAM+ !
|
: VE ['] c<over 0x08 ( C< override ) RAM+ !
|
||||||
clrscr 0 ACC ! 0 PREVPOS ! contents
|
clrscr 0acc 0 PREVPOS ! contents
|
||||||
BEGIN status bufs setpos KEY handle UNTIL
|
BEGIN status bufs setpos KEY handle UNTIL
|
||||||
0 0x08 RAM+ ! 19 aty ;
|
0 0x08 RAM+ ! 19 aty ;
|
||||||
|
Loading…
Reference in New Issue
Block a user