T.R | Title | User | Personal Name | Date | Lines |
---|
2322.1 | setvalues | TOOLEY::B_WACKER | | Wed Feb 21 1990 11:15 | 1 |
| Have you tried setvalues on DwtNx,DwtNy, etc?
|
2322.2 | XtMoveWidget and XtResizeWidget | OPHION::MIKEY | Mike Yang | Wed Feb 21 1990 13:43 | 1 |
| Have you tried XtMoveWidget and/or XtResizeWidget?
|
2322.3 | You can always use Xlib | KAOU35::DLEROUX | | Wed Feb 21 1990 14:34 | 22 |
|
If you can't get it done with the other suggestions you can always
use xlib and set WM Hints.
For some reason XtResize and XtMove didn't work for me so
I used the following.
void set_size( Widget w, int x, int y )
{
XSizeHints xsh;
xsh.x = x;
xsh.y = y;
xsh.flags = USPosition|PPosition;
XSetNormalHints( XtDisplay( w ), XtWindow( w ), &xsh );
}
Check out the documentation on Window Manager Hints for more info.
Dan
|
2322.4 | According to the Intrinsics "bible" | LEOVAX::TREGGIARI | | Wed Feb 21 1990 17:10 | 5 |
| The "official" Intrinsics directive is to use XtSetValues on the shell
to change the XtNx and XtNy, and to use XtSetValues on the shell's
child to change XtNwidth and XtNheight.
Leo
|
2322.5 | "official things" never works ! | SUOSW4::GEISELHART | | Thu Feb 22 1990 03:03 | 11 |
| Thanks for the hints, I had tried to use XtSetValues before, but it doesn't
work. When I set XtNallowShellResize true, the positions DwtNx,y don't
change and if I try to resize a child, the main window, the program never
returns from xtsetvalues.I tried to set XtNallowShellResize before creation
and after, also to set the positions before and after, allways when I have
set XtNallowShellResize to true the program hangs in the next XtSetValue
on the top-Window or on a child.
Is there any help out there???
Thank You Bianca
|
2322.6 | | VIA::FINNEGAN | All of the best intentions are less than one good act. | Fri Mar 09 1990 11:41 | 15 |
| The cardfiler used use
XtSetArg (args [xtnumber], XtNx, x); xtnumber++;
XtSetArg (args [xtnumber], XtNy, y); xtnumber++;
if (xtnumber > 0) XtSetValues (cardparent, args, xtnumber);
to set the position of the card window if it was not defined by the user in the
defaults file.
This worked in V1.0 (VMS 5.1) and broke in V2.0 (VMS 5.3 and later). I think I
qared this (I at leasted worked with Mike on it) but it was never fixed.
Is there a work around?
Neal
|
2322.7 | Set the shell's x and y also | DECWIN::KLEIN | | Fri Mar 09 1990 13:55 | 12 |
| >Is there a work around?
I think that setting the x and y on the parent of the main window (its shell)
IN ADDITION TO setting the x and y of the main window will work under both
V1 and V2. This is what I've resorted to. In V2, setting just the shell's
x and y works, and in V1, setting the main window's x and y works.
In fact, when my programs start up, they do an XtSetValues of x and y of
the shell to whatever the x and y of the main window is. This seems to
work under both versions and is pretty "transparent".
-steve-
|
2322.8 | XSetNormalHints works under MWM too! | ELMST::DELISE | | Wed Mar 28 1990 12:07 | 7 |
| FYI -
The XSetNormalHints approach in .3 has one advantage: it works correctly
with Motif *and* DECwindows window managers, on PMAX and VMS. The other
approach (0.7) doesn't move the window under Mwm.
Chris
|