editor bug fix
parent
9c5360cdba
commit
257c21f9de
|
@ -76,7 +76,6 @@
|
|||
|
||||
+ sequences
|
||||
|
||||
- dipping 2nmap, 2each
|
||||
- array sort
|
||||
- nappend: instead of using push, enlarge the sequence with set-length
|
||||
then add set the elements with set-nth
|
||||
|
|
|
@ -33,7 +33,8 @@ TUPLE: editor line caret ;
|
|||
dup 0 [ + ] accumulate swap 2 v/n v+ ;
|
||||
|
||||
: x>offset ( x font str -- offset )
|
||||
run-char-widths [ <= ] find-with drop ;
|
||||
dup >r run-char-widths [ <= ] find-with drop dup -1 =
|
||||
[ drop r> length ] [ r> drop ] ifte ;
|
||||
|
||||
: set-caret-x ( x editor -- )
|
||||
#! Move the caret to a clicked location.
|
||||
|
|
Loading…
Reference in New Issue