changeset 36955:ebb6774c41db

(x_print_complete_resource_name) [0]: New function.
author Gerd Moellmann <gerd@gnu.org>
date Fri, 23 Mar 2001 11:12:25 +0000
parents 798d1ac75e95
children 22c5aa03d4aa
files lwlib/lwlib-Xlw.c
diffstat 1 files changed, 28 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lwlib/lwlib-Xlw.c	Fri Mar 23 10:45:20 2001 +0000
+++ b/lwlib/lwlib-Xlw.c	Fri Mar 23 11:12:25 2001 +0000
@@ -30,6 +30,34 @@
 #include <X11/Shell.h>
 #include "xlwmenu.h"
 
+#if 0
+
+#include <stdio.h>
+
+/* Print the complete X resource name of widget WIDGET to stderr.
+   This is sometimes handy to have available.  */
+
+void
+x_print_complete_resource_name (widget)
+     Widget widget;
+{
+  int i;
+  String names[100];
+
+  for (i = 0; i < 100 && widget != NULL; ++i)
+    {
+      names[i] = XtName (widget);
+      widget = XtParent (widget);
+    }
+
+  for (--i; i >= 1; --i)
+    fprintf (stderr, "%s.", names[i]);
+  fprintf (stderr, "%s\n", names[0]);
+}
+
+#endif /* 0 */
+
+
 /* Menu callbacks */
 
 /* Callback XtNhighlightCallback for Lucid menus.  W is the menu