GNOME's Christian Hergert: Faster Numbers and Sidebars in Libpanel
-
Christian Hergert: Faster Numbers
The venerable GtkSourceView project provides a
GtkWidget
for various code languages. It has a number of features including the most basic, showing a line number next to your line of text.It turns out that takes a lot more effort than you might think, particularly when you want to do it at 240hz with kinetic scrolling on crappy hardware that may barely have enough engine for the GL driver.
First, you need to have the line number as a string to be rendered. For a few years now, GtkSourceView has code which will optimizes the translation from number to strings with minimal overhead. If you
g_snprintf()
, you’re gonna be slow. -
Christian Hergert: Sidebars in Libpanel
One of the more recent design trends in GNOME has been the use of sidebars. It looks great, it’s functional, and it gives separation of content from hierarchy.
Builder, on the other hand, has been stuck a bit closer to the old-hat design of IDEs where the hierarchy falls strictly from the headerbar. This is simply because libpanel was designed before that design trend. Some attempt was made in Builder to make it look somewhat sidebar’ish, but that was the extent of it given available time.