franco@alberta.uucp (Franco Carlacci) (12/20/89)
I'm trying to modify xdvi so that it can read another .dvi file.
I'm reading this filename via a popup menu. I've created the popup
using the following code:
int num_args;
Arg arglist[5];
num_args = 0;
XtSetArg(arglist[num_args], XtNallowShellResize, TRUE);
num_args++;
popup_shell = XtCreatePopupShell("pop",transientShellWidgetClass,
top_level, arglist, num_args);
viewp = XtCreateManagedWidget("mess",dialogWidgetClass,popup_shell,cargs,
XtNumber(cargs));
button = XtCreateManagedWidget("accept",commandWidgetClass,viewp,bargs,
XtNumber(bargs));
button1 = XtCreateManagedWidget("cancel",commandWidgetClass,viewp,
dargs,XtNumber(dargs));
To actually get it to pop, I use the left button and the following
code:
if (event->button == 1) {
XtWidgetGeometry loc,ret;
Bool status;
loc.request_mode = CWX | CWY;
loc.x = event->x;
loc.y = event->y;
XtMakeGeometryRequest(popup_shell,&loc,NULL);
XtPopup(popup_shell,XtGrabExclusive);
This brings up the popup.
My problem is that I cannot get any text I type to go into the popup.
Anything I type ends up as input to the main window. The buttons do
respond, but that's about it.
Any pointers would be appreciated.
franco
Franco Carlacci | "No distance of place or lapse of time can
VOX: (403)492-2428 or -2821 | lessen the friendship of those who are thor-
UUCP: franco@alberta.uucp | oughly persuaded of each other's worth"
CDNnet :franco@cs.ualberta.ca | Robert Southey
Franco Carlacci | "No distance of place or lapse of time can
VOX: (403)492-2428 or -2821 | lessen the friendship of those who are thor-
UUCP: franco@alberta.uucp | oughly persuaded of each other's worth"
CDNnet :franco@cs.ualberta.ca | Robert Southey kit@EXPO.LCS.MIT.EDU (Chris D. Peterson) (01/05/90)
> I'm reading this filename via a popup menu. I've created the popup > using the following code: [ deleted ] > My problem is that I cannot get any text I type to go into the popup. > Anything I type ends up as input to the main window. The buttons do > respond, but that's about it. Try setting setting the "input" resource to True on your popup widget. Chris D. Peterson MIT X Consortium Net: kit@expo.lcs.mit.edu Phone: (617) 253 - 9608 Address: MIT - Room NE43-213