Age | Commit message (Collapse) | Author |
|
|
|
This makes the editor behave more like vi, with a seperate insert mode.
This also refactors the keyboard input code to pass the SDL_Keysym
structure to input.c and to use the SDL_TEXTINPUT event for editing
text.
SDL's text input event already fixes typing capital letters with shift,
and should make it possible to enter text using an IME, however most
unicode characters aren't properly rendered.
|
|
|
|
|
|
Previously the editor would resize itself upon startup by finding the
size of the current terminal window, but now that it is running in an
actual window it should get the number of rows and columns from there.
This also adds parameters for the window size in rows and columns to the
window_init() function.
|
|
This is based off of snaptoken's "Build Your Own Text Editor" tutorial
at https://viewsourcecode.org/snaptoken/kilo/.
|