Well, it was a minor set of changes over the month, but the text editor needed quite a bit of work. In specific, the problems I had last month with accented characters blew up pretty badly over the month. The novella I was working on happened to have a character with an umlaut, which meant the program crashed every time I navigated through that characters name.
This ended up being a very interesting problem. I use Pango to both render the lines of text but also to handle navigating. So when the user uses the right arrow, I use Pango# to determine how many pixels to move over.
Unlike Gtk#, Pango# doesn't deal with character indexes from C#. It appears to give (and require) UTF-8 encoding. So, the third character in a string of "ééééé" (according to C#) is actually character index 6 according to Pango#. This took me a while to figure out, mainly because I would have never guessed UTF-8 encoding, but it seems to work.
- Reworked how cursor movement and caret rendering took into account with how Pango works with Unicode characters. +Changed
- Better handling of trailing glyph edges while navigating to reduce the jumping of a single character while moving. +Changed