gnome vs gnome-utils

Christian Stimming stimming at tuhh.de
Sun Mar 7 07:30:17 EST 2010


Am Sonntag, 7. März 2010 schrieb Geert Janssens:
> Simple question: when should code go into the gnome directory and when in
> gnome-utils ?
> 
> Both are obviously for gui related code, but I don't see when to use which.

From the LDFLAGS the criterion goes as follows: 
* If your code depends on the non-GUI (non-GTK) gnucash parts, plus src/app-
utils, plus the system's GTK, libglade, libgnome, but nothing else of gnucash, 
it should go into gnome-utils

* If the code depends on the above plus any of the other GUI modules in 
gnucash, i.e. register-gnome, report-gnome, html, it should go into gnome.

In particular, the main window by definition depends on all the widgets it is 
going to display (register-gnome, report-gnome, html etc), and it is in 
"gnome". Everything else doesn't need to be in "gnome", except if it in turn 
has a dependency on the main window.

> Background: I added some code to use a keychain or keyring for db passwords
>  on systems that have such a thing available. For me this is utility
>  function, so I put it in gnome-utils. But if no keychain/ring if found to
>  lookup a password, this code calls the GnuCash built-in username/password
>  dialog to get one. But this code is in gnome. I just don't understand why.
>  That seems like a utility to me as well.

To me, this sounds as if the previous username/pw dialog could have been moved 
to gnome-utils as well. But maybe it has some non-obvious dependency into the 
main window, in which case it needs to be in gnome, and your code could just 
go into there as well even though it wouldn't require that by itself.

Regards,

Christian


More information about the gnucash-devel mailing list