[Lazarus] GTK2 is now the default widgetset

Aleš Katona almindor at gmail.com
Wed Oct 8 11:09:26 CEST 2008


To everyone who might experience Gtk2 speed issues:

Here are the possible reasons for slowdowns and some personal
observations...

1. Video card drivers make a big difference. Proprietary ATI and Nvidia
drivers are very bad at some 2d operations, while the OSS
reverse-engineered counterparts usually are "consistently" slower on
each operation, but faster globally. E.g: my total time for OSS gtkperf
(see below) test with OSS reverse engineered ati driver was less than
the proprietary one, even if all but one tests were slower. This one
test took ~0.5s with the OSS driver, but 50s with the proprietary one
(canvas ellipse drawing)

2. Gtk+ version can cause differences in performance, newer are better

3. UTF-8 bugs can cause slowdowns in editor (see if you don't get gtk
criticals with utf-8 errors)

4. Some themes are much slower in Gtk2, some are outright bugged. There
was a page with tests for this but I lost it :(

To test what causes your slowness get GtkPerf from
http://gtkperf.sourceforge.net/ and install it (compile AND install). We
can post our results somewhere on the forums or such to identify
culprits. Try out different themes too and see the impact.

I'm using a customized Crux theme with special border theme (kind of
Next/Apple-ish) and the proprietary ATI driver. Text draw and custom
canvas draw speed suffers because of the driver, but otherwise I get
very nice performance, even with Gtk2 lazarus editor (less than 100% cpu
while scrolling by the line).

I hope this helps you fix some issues, and shows you that Gtk2 or
LCL/gtk2 speed issues can be caused by things beyond our control.

Ales




More information about the Lazarus mailing list