[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: gaf.git: branch: master updated (1.5.3-20090829-3-gb1f7256)



The branch, master has been updated
       via  b1f7256890fe8ff48ae077d1fa3cdfcf29ccdc0f (commit)
      from  d388f5370c4b264df90e79a412968589706402c4 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 gschem/src/gschem_accel_label.c |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)


=================
 Commit Messages
=================

commit b1f7256890fe8ff48ae077d1fa3cdfcf29ccdc0f
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Commit: Peter Clifton <pcjc2@xxxxxxxxx>

    gschem: Substitute spaces for underscores in displayed accelerator strings
    
    This makes accelerators such as "Page_Up" display as "Page Up", in line
    with how normal GTK accelerators are displayed.

:100644 100644 ab1419d... 8dc75a5... M	gschem/src/gschem_accel_label.c

=========
 Changes
=========

commit b1f7256890fe8ff48ae077d1fa3cdfcf29ccdc0f
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Commit: Peter Clifton <pcjc2@xxxxxxxxx>

    gschem: Substitute spaces for underscores in displayed accelerator strings
    
    This makes accelerators such as "Page_Up" display as "Page Up", in line
    with how normal GTK accelerators are displayed.

diff --git a/gschem/src/gschem_accel_label.c b/gschem/src/gschem_accel_label.c
index ab1419d..8dc75a5 100644
--- a/gschem/src/gschem_accel_label.c
+++ b/gschem/src/gschem_accel_label.c
@@ -274,6 +274,19 @@ gschem_accel_label_expose_event (GtkWidget      *widget,
   return FALSE;
 }
 
+/* Underscores in key names are better displayed as spaces
+ * E.g., Page_Up should be "Page Up"
+ */
+static void
+substitute_underscores (char *str)
+{
+  char *p;
+
+  for (p = str; *p; p++)
+    if (*p == '_')
+      *p = ' ';
+}
+
 
 /**
  * gschem_accel_label_set_accel_string:
@@ -293,6 +306,7 @@ gschem_accel_label_set_accel_string (GschemAccelLabel *accel_label,
 
   if (accel_string) {
     accel_label->accel_string = g_strdup (accel_string);
+    substitute_underscores (accel_label->accel_string);
   } else {
     accel_label->accel_string = NULL;
   }




_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs