holy productivity spike
I got the editor fully working!!! :)
After wanting to throw my computer from a comically large height (multiple times), it finally runs: proper arrow-key navigation, a fully working cursor, soft wraps, line numbers, and so on. Vertical scrolling is now fully functional aswell.
Even some comfort features like using the Home and End keys work!
Fun stuff I found out in the process
In the process of getting this to work I also discovered things like the fact that the pdcurses getch() macro implicitly refreshes the stdscr and then… doesnt… flush it 😐
Anything still borked?
Some things also still don’t work fully, which kinda bothers me. The main example of this is navigating the cursor vertically into soft-wrapped lines; because of how I wrote the row up/down logic - which is to check in the editor buffer where the next or previous line feed is and then navigate based on that - I can’t just say “oh theres a soft line wrap lets just detect that instead of a \n” because the rendering (which does the soft line wrapping) and the I/O loop don’t communicate with each other
Sure, I could fix it by adding a shared data structure which contains all line wrappings, but for now, I just wanna get the more important stuff running.
Any plans now?
Anyways, I’m planning to finish the editor fully by adding writing text (wild concept, i know!) and syntax highlighting next.
Comments 0
No comments yet. Be the first!
Sign in to join the conversation.