After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 133369 - intltool-merge hadnling of schema files with a default tag containing a list is broken.
intltool-merge hadnling of schema files with a default tag containing a list ...
Status: RESOLVED FIXED
Product: intltool
Classification: Deprecated
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: intltool maintainers
intltool maintainers
: 121330 138646 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2004-02-04 05:29 UTC by Callum McKenzie
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: 2.5/2.6



Description Callum McKenzie 2004-02-04 05:29:32 UTC
intltool-merge strips any string of the form [.*] from the beginning of the
<default> tags in a gconf schema file. This is apparently done, according
to bug #94611, to accomodate allow descriptions to be entered in string
values. Unfortunately it also removes gconf arrays (which use the syntax
[foo, bar, baz]) from the C locale <default> entry in the output file. 

The line that does this is: 

	$c_default_block =~ s/default>\[.*?\]/default>/s;

in intltool-merge.

I'm not sure what the best answer is, but checking the type of the schema
may be a good start.

I can work around this for the moment by prepending a space before the
opening [.

For an example of where arrays that need translation are used (and I think
the only place in core GNOME it is used) see gtali.schemas.in in the
gnome-games package. It is used to encode a list of names.
Comment 1 Kenneth Rohde Christiansen 2004-02-04 12:09:26 UTC
I am kind of voting for changing that line:

$c_default_block =~ s/default>\[.*?\]/default>/s;

because I dont really see any use of it. Well I guess we agreed that
this is not a good way to add comments to xml files, and all it does
it break things for others.

Feel free to remove that line (or comment it out) and commit.

Kenneth
Comment 2 Callum McKenzie 2004-02-04 19:54:45 UTC
OK, I've removed the line in CVS. Things seem to work fine for me now.
Comment 3 Yanko Kaneti 2004-02-24 13:02:22 UTC
FWIW the use of the bracketed text in the values was explained in bug
#94611 - point 3 of the first comment there.
Removing it removes the feature. So now there is no way to resolve a
conflict between two identical msgids(both default gconf values)
requiring different translation.

Perhaps the better fix would have been to change the markers.

Anyway...
Comment 4 Callum McKenzie 2004-02-24 22:24:47 UTC
How about using xml comments ? C comments are abused in this way so
why not abuse xml comments in the same way ? Using [] breaks an
already existing feature of gconf. They can't come back. Besides I
couldn't actually find any examples of a schema file using them, not
in core gnome-desktop anyway.
Comment 5 Malcolm Tredinnick 2004-04-26 21:45:28 UTC
*** Bug 121330 has been marked as a duplicate of this bug. ***
Comment 6 Rodney Dawes 2004-05-29 16:53:04 UTC
*** Bug 138646 has been marked as a duplicate of this bug. ***