static void do_genwin_panel_posn(QSP_ARG_DECL const char *s, int x, int y) { Panel_Obj *po; po=get_panel_obj(s); if( po != NULL ) { SET_PO_X(po, x); SET_PO_Y(po, y); posn_panel(po); } return; }
static void navp_genwin_posn(QSP_ARG_DECL const char *s, int x, int y) { Nav_Panel *np_p; np_p=GET_NAV_PANEL(s); if( np_p != NO_NAV_PANEL ) { //SET_NAVP_X(np_p, x); //SET_NAVP_Y(np_p, y); SET_PO_X(NAVP_PANEL(np_p), x); SET_PO_Y(NAVP_PANEL(np_p), y); posn_panel(NAVP_PANEL(np_p)); } return; }
void show_panel(QSP_ARG_DECL Panel_Obj *po) { #ifdef HAVE_MOTIF if( PANEL_MAPPED(po) ){ sprintf(ERROR_STRING,"show_panel: panel %s is already mapped!?",PO_NAME(po)); WARN(ERROR_STRING); return; } // On the mac (and linux???), when we unshow, and re-show a panel, // it moves down by the thickness of the top of the window??? posn_panel(po); /* if widget has already been realized, then just map it; otherwise realize it and set the flag */ if (!(po->po_realized)) { XtRealizeWidget(po->po_frame_obj); po->po_realized = 1; #ifdef FOOBAR /* This must be the first time we see this thing - lets * reset the positions of all the screen objects... */ lp=po->po_children; np=lp->l_head; while(np!=NO_NODE){ sop=np->n_data; if( sop != NULL ){ reposition(sop); } np=np->n_next; } #endif /* FOOBAR */ } else { XtMapWidget(po->po_frame_obj); } /* Now wait until it really is mapped */ #ifdef CAUTIOUS if( ! XtIsRealized(po->po_frame_obj) ) NERROR1("CAUTIOUS: show_panel: object not realized!?"); #endif /* CAUTIOUS */ /* get the window id */ while( ! panel_mapped(po) ) ; po->po_flags |= PANEL_SHOWN; #endif /* HAVE_MOTIF */ } /* end show_panel */