progress with viJ to move cursor downwards

This commit is contained in:
2024-10-20 21:30:06 +01:00
parent 47f4d452fe
commit 6b3d322c1c
5 changed files with 188 additions and 29 deletions

View File

@@ -4,38 +4,24 @@ struct
fun bufferAndSize (app: app_type, newBuffer, newWidth, newHeight) =
let
val
{ buffer = _
, windowWidth = _
, windowHeight = _
, startLine
, cursorIdx
, preferredColumn
} = app
val {buffer = _, windowWidth = _, windowHeight = _, startLine, cursorIdx} =
app
in
{ buffer = newBuffer
, windowWidth = newWidth
, windowHeight = newHeight
, startLine = startLine
, cursorIdx = cursorIdx
, preferredColumn = preferredColumn
}
end
fun bufferAndCursorIdx (app: app_type, newBuffer, newCursorIdx, newColumn) =
fun bufferAndCursorIdx (app: app_type, newBuffer, newCursorIdx) =
let
val
{ buffer = _
, cursorIdx = _
, preferredColumn = _
, windowWidth
, windowHeight
, startLine
} = app
val {buffer = _, cursorIdx = _, windowWidth, windowHeight, startLine} =
app
in
{ buffer = newBuffer
, cursorIdx = newCursorIdx
, preferredColumn = newColumn
, windowWidth = windowWidth
, windowHeight = windowHeight
, startLine = startLine