Following on my previous post, I've finally got around to do some more updates to my nodoka rewrite and blog about it ;-) This time it's about the Entry widget. While last time I complained "only" about difficulties with exterior focus in Button widgets this time around it's many times worse even.
First of all, exterior focus behaves slightly different from how it behaves in Button widget, so I had to do another slightly different workaround for Entry. Well, it took me some time before I "reverse-engineered" the behaviour to work with all exterior-focus, focus-line-width and focus-padding settings as I'd like it to, but I seem to have figured it out. This is probably connected with the fact that focus for entry is drawn via the draw_focus functions only if its exterior, so I had to skip this one and render the focus along when drawing the actual widget to keep at least some consistency in the code.
To make engine coding for entries even harder, the state_type sent to the drawing functions is wrong when the widget is insensitive... That makes another, albeit simple hack :(
And because of the way entry is implemented in GTK, there are up to four GdkWindows (one main for the whole entry, one for the text, and up to two for side icons), which aren't transparent and furthermore filled not with what's behind them but with base colour, one has to: repaint the background to be hopefully the correct one (which of course breaks when the entry is on toolbar with gradient) and from the inside windows check their relative position to the main window and paint the entry once more (to allow nice smooth rounded corners and bigger paddings for inner focus). This means you either sacrifice design or speed, I sacrificed the speed, but am seriously playing with the thought of introducing an engine option to disable this hack for gtkrc designers that prefer speed and are willing to give up some of the design freedom.
Now this is all nice but there are (at least) two applications that are even worse -- evolution and epiphany has their location/search bar composed of actually two entries and some icons and "guessing" from the inner entry where the outer one is is beyond my willingness to implement... Luckily enough, evolution behaves pretty decent with wide range of settings and epiphany got fixed in 2.28.
And now some screenshots:
As you can see it's still miles from done, but I try to keep it fully functional (and as much bug free as I can). For those who actually would like to test it I recommend building from git but there's a chance I'll put my locally built testing rpms on fedorapeople if there would be enough requests ;-)
On a completely unrelated note, I've just discovered freely (and legally) downloadable new recording of Bach's Brandenburg Concertos in FLAC. Yay, kudos for the Czech Radio. Actually I've been listening to the Czech Radio D-Dur station live broadcast (ogg 256kbit) for quite a few days now and I am both more than happy with both the quality of the selected music as well as the quality of the broadcast (further more in OGG Vorbis!). But back to Brandenburg Concertos -- I'm about half done with the listening and I have to say that while the style seemed a bit unusual at first it won me over after a one or two movements and I consider it one of the better Brandenburg Concertos recordings I've heard.