fix compiler warniungs in normal-mode/normal-finish.sml, which resulted from reimplementing text-builder functionality
This commit is contained in:
@@ -29,7 +29,7 @@ struct
|
|||||||
(* move buffer to new startLine as required by TextBuilder.build *)
|
(* move buffer to new startLine as required by TextBuilder.build *)
|
||||||
val buffer = LineGap.goToLine (startLine, buffer)
|
val buffer = LineGap.goToLine (startLine, buffer)
|
||||||
|
|
||||||
val msgs = TextBuilder.build
|
val drawMsg = NormalModeTextBuilder.build
|
||||||
( startLine
|
( startLine
|
||||||
, cursorIdx
|
, cursorIdx
|
||||||
, buffer
|
, buffer
|
||||||
@@ -37,8 +37,10 @@ struct
|
|||||||
, windowHeight
|
, windowHeight
|
||||||
, searchList
|
, searchList
|
||||||
, searchString
|
, searchString
|
||||||
, msgs
|
, visualScrollColumn
|
||||||
)
|
)
|
||||||
|
val drawMsg = Vector.concat drawMsg
|
||||||
|
val drawMsg = DrawMsg.DRAW_TEXT drawMsg
|
||||||
|
|
||||||
val mode = NORMAL_MODE ""
|
val mode = NORMAL_MODE ""
|
||||||
in
|
in
|
||||||
@@ -90,18 +92,20 @@ struct
|
|||||||
val visualScrollColumn =
|
val visualScrollColumn =
|
||||||
TextScroll.getScrollColumn (buffer, cursorIdx, windowWidth)
|
TextScroll.getScrollColumn (buffer, cursorIdx, windowWidth)
|
||||||
val newBuffer = LineGap.goToLine (startLine, newBuffer)
|
val newBuffer = LineGap.goToLine (startLine, newBuffer)
|
||||||
val lineIdx = TextBuilder.getLineAbsIdx (startLine, buffer)
|
val lineIdx = TextBuilderUtils.getLineAbsIdxFromBuffer (startLine, buffer)
|
||||||
|
|
||||||
val drawMsg = TextBuilder.build
|
val drawMsg = NormalModeTextBuilder.build
|
||||||
( startLine
|
( startLine
|
||||||
, cursorIdx
|
, cursorIdx
|
||||||
, newBuffer
|
, buffer
|
||||||
, newWidth
|
, windowWidth
|
||||||
, newHeight
|
, windowHeight
|
||||||
, searchList
|
, searchList
|
||||||
, searchString
|
, searchString
|
||||||
, []
|
, visualScrollColumn
|
||||||
)
|
)
|
||||||
|
val drawMsg = Vector.concat drawMsg
|
||||||
|
val drawMsg = DrawMsg.DRAW_TEXT drawMsg
|
||||||
in
|
in
|
||||||
NormalModeWith.bufferAndSize
|
NormalModeWith.bufferAndSize
|
||||||
( app
|
( app
|
||||||
@@ -137,10 +141,10 @@ struct
|
|||||||
(buffer, startLine, cursorIdx, windowWidth, windowHeight)
|
(buffer, startLine, cursorIdx, windowWidth, windowHeight)
|
||||||
|
|
||||||
(* move buffer to new startLine as required by TextBuilder.build
|
(* move buffer to new startLine as required by TextBuilder.build
|
||||||
* and move searchList to idx where line starts as well *)
|
* and move searchList to idx where line starts as well *)
|
||||||
val buffer = LineGap.goToLine (startLine, buffer)
|
val buffer = LineGap.goToLine (startLine, buffer)
|
||||||
|
|
||||||
val drawMsg = TextBuilder.build
|
val drawMsg = NormalModeTextBuilder.build
|
||||||
( startLine
|
( startLine
|
||||||
, cursorIdx
|
, cursorIdx
|
||||||
, buffer
|
, buffer
|
||||||
@@ -148,8 +152,10 @@ struct
|
|||||||
, windowHeight
|
, windowHeight
|
||||||
, searchList
|
, searchList
|
||||||
, searchString
|
, searchString
|
||||||
, []
|
, visualScrollColumn
|
||||||
)
|
)
|
||||||
|
val drawMsg = Vector.concat drawMsg
|
||||||
|
val drawMsg = DrawMsg.DRAW_TEXT drawMsg
|
||||||
|
|
||||||
val mode = NORMAL_MODE ""
|
val mode = NORMAL_MODE ""
|
||||||
in
|
in
|
||||||
@@ -177,6 +183,7 @@ struct
|
|||||||
, searchList
|
, searchList
|
||||||
, searchString
|
, searchString
|
||||||
, bufferModifyTime
|
, bufferModifyTime
|
||||||
|
, visualScrollColumn
|
||||||
, ...
|
, ...
|
||||||
} = app
|
} = app
|
||||||
val buffer = LineGap.goToIdx (cursorIdx, buffer)
|
val buffer = LineGap.goToIdx (cursorIdx, buffer)
|
||||||
@@ -185,9 +192,7 @@ struct
|
|||||||
(buffer, cursorIdx, origLine, windowWidth, windowHeight div 2)
|
(buffer, cursorIdx, origLine, windowWidth, windowHeight div 2)
|
||||||
|
|
||||||
val buffer = LineGap.goToLine (startLine, buffer)
|
val buffer = LineGap.goToLine (startLine, buffer)
|
||||||
val lineIdx = TextBuilder.getLineAbsIdx (startLine, buffer)
|
val drawMsg = NormalModeTextBuilder.build
|
||||||
|
|
||||||
val drawMsg = TextBuilder.build
|
|
||||||
( startLine
|
( startLine
|
||||||
, cursorIdx
|
, cursorIdx
|
||||||
, buffer
|
, buffer
|
||||||
@@ -195,8 +200,10 @@ struct
|
|||||||
, windowHeight
|
, windowHeight
|
||||||
, searchList
|
, searchList
|
||||||
, searchString
|
, searchString
|
||||||
, []
|
, visualScrollColumn
|
||||||
)
|
)
|
||||||
|
val drawMsg = Vector.concat drawMsg
|
||||||
|
val drawMsg = DrawMsg.DRAW_TEXT drawMsg
|
||||||
in
|
in
|
||||||
let
|
let
|
||||||
val _ = raise Fail "centering to line is unimplemented\n"
|
val _ = raise Fail "centering to line is unimplemented\n"
|
||||||
|
|||||||
Reference in New Issue
Block a user