summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ee293e0)
raw | patch | inline | side by side (parent: ee293e0)
author | tavmjong-free <tavmjong@free.fr> | |
Thu, 13 May 2010 12:16:04 +0000 (14:16 +0200) | ||
committer | tavmjong-free <tavmjong@free.fr> | |
Thu, 13 May 2010 12:16:04 +0000 (14:16 +0200) |
src/ege-select-one-action.cpp | patch | blob | history | |
src/widgets/toolbox.cpp | patch | blob | history |
index 32c1ef9b482df739da42d2efa287e85b7606170f..199b0cf68bac9946e115f90ffb83c3a5261473f1 100644 (file)
gchar* sss = 0;
g_object_get( G_OBJECT(action), "short_label", &sss, NULL );
- if (sss) {
+ // If short_label not defined, g_object_get will return label.
+ // This hack allows a label to be used with a drop-down menu when
+ // no label is used with a set of icons that are self-explanatory.
+ if (sss && strcmp( sss, "NotUsed" ) != 0 ) {
GtkWidget* lbl;
lbl = gtk_label_new(sss);
gtk_box_pack_start( GTK_BOX(holder), lbl, FALSE, FALSE, 4 );
index 8aed18d7b093f2411873254295cf9f7894afbc0b..6a5ac6ebef4d8da85aa5ed95f25e3bd299c91034 100644 (file)
--- a/src/widgets/toolbox.cpp
+++ b/src/widgets/toolbox.cpp
@@ -7304,7 +7304,7 @@ static void sp_text_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions
_("Text Alignment"), // Tooltip
NULL, // StockID
GTK_TREE_MODEL(model) ); // Model
- g_object_set( act, "short_label", _("Align"), NULL );
+ g_object_set( act, "short_label", "NotUsed", NULL );
gtk_action_group_add_action( mainActions, GTK_ACTION(act) );
g_object_set_data( holder, "TextAlignAction", act );
@@ -7346,7 +7346,7 @@ static void sp_text_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions
NULL, // StockID
GTK_TREE_MODEL(model) ); // Model
- g_object_set( act, "short_label", _("O:"), NULL );
+ g_object_set( act, "short_label", "NotUsed", NULL );
gtk_action_group_add_action( mainActions, GTK_ACTION(act) );
g_object_set_data( holder, "TextOrientationAction", act );