From d3a785fff56bb784c1cdb1413e64331979c79614 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Fri, 23 Mar 2001 11:12:25 +0000 Subject: [PATCH] (x_print_complete_resource_name) [0]: New function. --- lwlib/lwlib-Xlw.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/lwlib/lwlib-Xlw.c b/lwlib/lwlib-Xlw.c index 4f29ab2b3e8..7a565595774 100644 --- a/lwlib/lwlib-Xlw.c +++ b/lwlib/lwlib-Xlw.c @@ -30,6 +30,34 @@ Boston, MA 02111-1307, USA. */ #include #include "xlwmenu.h" +#if 0 + +#include + +/* 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 -- 2.39.2