Commit Graph

13 Commits

Author SHA1 Message Date
649bcb66e1 a bit of refactoring to allow addition of more tests 2025-03-22 05:18:25 +00:00
287dc5548d progress implementing searchList data structure 2024-11-11 13:23:37 +00:00
a35c0803fb fix 'getStartLineBefore' in text-window.sml, where we always decrement 'lineNum' variable when encountering \n, and use 'Int.max (lineNum - 1, 0)' to clip lineNum to 0 if it happens to go below 0 2024-11-07 11:57:32 +00:00
6b9cf8dbc2 amend problem with TextWindow.getStartLineBefore, where we were not following rule mentioned in previous commits to not count (graphical-chr -> \n) as line break 2024-11-06 12:46:53 +00:00
2df8f88452 improvements to TextWindow.isCursorVisible (no need to do binary search; in fact, that leads to an exception, because we are meant to use Vector.sub to access the relative line instead) 2024-11-02 12:54:34 +00:00
2a8e02ff3a when pressing fcore/text-window.sml to match pair, only recentre text window if matching pair is not currently visible on screen 2024-11-02 12:34:23 +00:00
33f2bf7b58 partial implementation of TextWindow.isCursorVisible 2024-11-01 03:44:12 +00:00
1316cdfe13 fill in todo where strIdx is in tl, in text-window.sml function 'getStartLineWithCursorCentered 2024-10-30 11:12:12 +00:00
601a341992 add functionality to move to end of line 2024-10-30 10:54:55 +00:00
308d042deb add functionality to centre text window to cursor 2024-10-30 10:05:16 +00:00
5e1e39ca69 fixed two issues. First is that an exception occurred when sometimes moving cursor forwards. Cause of this issue was that callee functions depended on LineGap being moved to start of line, but this did not always happen (and now it does always happen). Second issue was that moving cursor down did not scroll as expected when line wrapped. The reason for this second issue was that the 'getStartLineAfter' function did not increment 'startLine' value in loop when line wrap occurred. Both issues are now fixed. 2024-10-28 22:54:28 +00:00
0ed5a23ade some progress moving textWindow, but it is not perfect yet 2024-10-28 10:59:18 +00:00
4b1ee33954 begin moving text window when cursor goes off screen (currently, we only move the window when cursor goes backwards but this works fine and as expected) 2024-10-28 09:34:55 +00:00