Re: [PATCH] Use Glade + GtkBuilder for file-png.c save_dialog()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Right now GIMP has virtuall all of the UI imperatively constructed with 
code. This has a few problems:

* Tweaking the UI requires re-building the app
* A lot of code duplication
* Not very modern

The patch I am replying to ports the PNG save dialog to Glade and uses 
GtkBuilder to construct the UI. The purpose of this change is to 
introduce declarative construction of UIs in GIMP to give us experience 
in this area. The benefits of using Glade is:

* Tweaking the UI doesn't requires re-bulding the app
* Less code
* Easier to start using a script language like JavaScript in the core
* We make the GIMP code base more modern
* UIs can be constructed through drag-and-drop with Glade

There are a few things that should be noted:

* Translations still works
* Mnemonics still works
* The tooltip is still there (although only on the spinner, not scale)
* We use GtkBuilder, not the deprecated libglade
* There is no need for any proprocessing, GtkBuilder reads direct XML
* We don't rely on any extra tool, XML files can be written manually

And a warning:
* Order of XML properties, see GtkAdjustment comment in file-png.glade


So, do people think this is a step in the right direction? Personally
I do and would like to commit the patch. Opinions?

Regards,
Martin


-- 

My GIMP Blog:
http://www.chromecode.com/
"Best way to keep up with GIMP from git"
_______________________________________________
Gimp-developer mailing list
Gimp-developer@xxxxxxxxxxxxxxxxxxxxxx
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux