You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
diff --git a/programs/EditDemo.hs b/programs/EditDemo.hs
index f300f88..05ad2f0 100644
--- a/programs/EditDemo.hs
+++ b/programs/EditDemo.hs
@@ -62,6 +62,7 @@ appEvent st ev =
V.EvKey V.KEsc [] -> M.halt st
V.EvKey (V.KChar '\t') [] -> M.continue $ switchEditors st
V.EvKey V.KBackTab [] -> M.continue $ switchEditors st
+ V.EvKey (V.KChar ' ') [] -> M.continue st { _edit2 = (E.editor secondEditor (str . unlines) Nothing "hello\nworld")}
_ -> M.continue =<< T.handleEventLensed st (currentEditorL st) ev
initialState :: St
Then run it, press "TAB" (optional), then press SPACE to re-initialize/modify the 2nd editor widget to have the contents "hello\nworld". Although the words are rendered correctly (world being on the 2nd line), the cursor thinks that it's all on one line. It looks as if the cursor is hovering over extra blank space if you press Right arrow, but that appears to be the buffer where the word world is stored.
Tested on the latest 0.6.1 version by using cabal sandbox on GHC 7.10.3.
The text was updated successfully, but these errors were encountered:
listx
changed the title
re-initializing Editor widget with contents results in cursor location being stuck at 1st line
re-initializing Editor widget with contents results in cursor being stuck at 1st line
May 19, 2016
Example (apply this diff to EditDemo.hs):
Then run it, press "TAB" (optional), then press SPACE to re-initialize/modify the 2nd editor widget to have the contents "hello\nworld". Although the words are rendered correctly (
world
being on the 2nd line), the cursor thinks that it's all on one line. It looks as if the cursor is hovering over extra blank space if you press Right arrow, but that appears to be the buffer where the wordworld
is stored.Tested on the latest 0.6.1 version by using cabal sandbox on GHC 7.10.3.
The text was updated successfully, but these errors were encountered: