diff options
author | Gerd Moellmann <[email protected]> | 2001-03-23 11:12:25 +0000 |
---|---|---|
committer | Gerd Moellmann <[email protected]> | 2001-03-23 11:12:25 +0000 |
commit | d3a785fff56bb784c1cdb1413e64331979c79614 (patch) | |
tree | a115b7dcf45a8a3ba10352c0baba753cc3be424f | |
parent | 4c8d5b4b784cadd5ae39df3beeab13aa5f4b194f (diff) |
(x_print_complete_resource_name) [0]: New function.
-rw-r--r-- | lwlib/lwlib-Xlw.c | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/lwlib/lwlib-Xlw.c b/lwlib/lwlib-Xlw.c index 4f29ab2b3e..7a56559577 100644 --- a/lwlib/lwlib-Xlw.c +++ b/lwlib/lwlib-Xlw.c @@ -30,6 +30,34 @@ Boston, MA 02111-1307, USA. */ #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 |