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 128013 - glade_flags_from_string() can't handle spaces
glade_flags_from_string() can't handle spaces
Status: RESOLVED FIXED
Product: libglade
Classification: Deprecated
Component: general
CVS HEAD
Other other
: Normal normal
: ---
Assigned To: James Henstridge
James Henstridge
: 113763 113889 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2003-11-26 21:18 UTC by Damon Chaplin
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch from Pedro Abelleira Seco (note that '//' isn't portable) (756 bytes, patch)
2003-11-28 13:23 UTC, Damon Chaplin
none Details | Review
Better patch with Unicode support and a bug fix (1.36 KB, patch)
2003-11-28 14:14 UTC, Damon Chaplin
none Details | Review

Description Damon Chaplin 2003-11-26 21:18:05 UTC
Glade uses spaces to separate flags like this:

<property name="events">GDK_BUTTON_MOTION_MASK |
GDK_BUTTON_PRESS_MASK</property>

But it looks like glade_flags_from_string() doesn't handle that.

Also it seems to silently fail. It may be better to output a warning
if the flags are not valid.
Comment 1 Damon Chaplin 2003-11-28 13:23:29 UTC
Created attachment 21894 [details] [review]
Patch from Pedro Abelleira Seco (note that '//' isn't portable)
Comment 2 Damon Chaplin 2003-11-28 14:14:31 UTC
Created attachment 21896 [details] [review]
Better patch with Unicode support and a bug fix
Comment 3 Damon Chaplin 2003-11-28 14:16:24 UTC
The same function is also in Glade, so I've updated it there as well.
I've tested it out a fair bit and it seems fine.
It also outputs a warning for unknown flags.
Comment 4 Damon Chaplin 2004-01-30 15:58:29 UTC
*** Bug 113763 has been marked as a duplicate of this bug. ***
Comment 5 Damon Chaplin 2004-01-30 16:00:51 UTC
*** Bug 113889 has been marked as a duplicate of this bug. ***