# HG changeset patch # User Gerd Moellmann # Date 984502273 0 # Node ID 2f7bd108e82fe6275391fec7d2528a2b7fd8992c # Parent 249d3e1ba6171402c10739ac1127c1f58e0ad72c (make_menu_in_widget): Remove code forcing LessTif to recompute centered text; it works fine without with current LessTif. diff -r 249d3e1ba617 -r 2f7bd108e82f lwlib/lwlib-Xm.c --- a/lwlib/lwlib-Xm.c Tue Mar 13 16:30:15 2001 +0000 +++ b/lwlib/lwlib-Xm.c Tue Mar 13 16:51:13 2001 +0000 @@ -493,7 +493,8 @@ old_children = XtCompositeChildren (widget, &old_num_children); /* Allocate the children array */ - for (num_children = 0, cur = val; cur; num_children++, cur = cur->next); + for (num_children = 0, cur = val; cur; num_children++, cur = cur->next) + ; children = (Widget*)XtMalloc (num_children * sizeof (Widget)); /* WIDGET should be a RowColumn. */ @@ -610,12 +611,6 @@ if (button) XtVaSetValues (widget, XmNmenuHelpWidget, button, NULL); - /* LessTif apparently doesn't recompute centered text when more - widgets are added. So, do it after all widgets have been - created. */ - if (title) - XtVaSetValues (title, XmNalignment, XmALIGNMENT_CENTER, NULL); - if (num_children) XtManageChildren (children, num_children); @@ -1906,7 +1901,6 @@ XtPointer call_data; { widget_instance *instance = (widget_instance *) closure; - fprintf (stderr, "%p\n", call_data); if ((!instance->pop_up_p && XtParent (widget) == instance->widget) || XtParent (widget) == instance->parent)