report menu gone?

Christian Stimming stimming@tuhh.de
Wed, 23 Oct 2002 23:16:16 +0200


-----BEGIN PGP SIGNED MESSAGE-----

On Mittwoch, 23. Oktober 2002 21:41, Herbert Thoma wrote:
> with current cvs I don't get the report menu anymore.
>
> Instead a bunch of assertion failures:

Right, this is a bug and was fixed right now. The bug didn't show up before 
somebody would actually translate newly introduced menu items, so that's why 
it showed up right now.

For other developers: The gnome menu item creation and lookup functions have a 
major caveat here. Recall that a menu item is usually created with the 
shortcut key underlined as in "_Action". Now as long as there is no 
translation, the menu item lookup code accepts both the string without 
("Action") and the string with underscore ("_Action") as valid match. As soon 
as there *is* a translation, *only* the exact matching string with the 
underscore ("_Action") is accepted as valid match!

This means that every developer who looks up a menu item has to be ABSOLUTELY 
sure that the lookup string for the menu item is the EXACT match, including 
the underscore.

The other way round it means if somebody decides to change the underscore, 
then he needs to make sure to update EVERY place in the gnucash source where 
this item is looked up.

Unfortunately the only solution here would be to get rid of the underscore 
notation due to this obvious shortcomings, but that's not in our control. We 
will have follow the convention of exact match for the time being. Uh well.

Christian

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iQCVAwUBPbcRpmXAi+BfhivFAQHDYwP+KEr7UxWDGkjqXPHy+dDmpSgOk6/Ad8az
7gvNHivDsaAVAH+RU5pSRrEK99hx1mWcs9cz1lhJgcLk11i5Zcb17j+iBXu4oi1e
jCdFAsMC33WCCZNXCRF6PuTFrgoI6brhb7v42Wyq4STvoa9lRWN0w1La9yc0OIgJ
BaSgPUtWKuE=
=vQkL
-----END PGP SIGNATURE-----