fix bugs in implementing and using text buffer. Some functions did not save the drawMsg to the app's state, which we means we didn't draw in those cases. The text builder functions also drew cursors on characters even when the cursor is not at this position. Both of these bugs are fixed.
This commit is contained in:
@@ -270,8 +270,8 @@ struct
|
||||
let
|
||||
val acc =
|
||||
if absIdx = cursorIdx then
|
||||
Utils.makeCursor (posX, posY, env)
|
||||
:: Utils.makeCursorOnChr (chr, posX, posY, env) :: acc
|
||||
Utils.makeCursorOnChr (chr, posX, posY, env)
|
||||
:: Utils.makeCursor (posX, posY, env) :: acc
|
||||
else if Utils.isInSearchRange (absIdx, searchPos, env) then
|
||||
Utils.makeHighlightChr (chr, posX, posY, env)
|
||||
:: Utils.makeHighlight (posX, posY, env) :: acc
|
||||
|
||||
Reference in New Issue
Block a user