[comp.windows.open-look] OLIT: Resizing popupWindows

fmg@cbnewsh.att.com (floyd.m.goldstein) (01/19/91)

I have a popupWindow with a widget inside that can accept resize
requests.  It seems as if the controlArea that this widget is in is not
passing the resize request down to it.

So then I tried stuffing this widget in a baseWindowShell.  The resizes
worked like a charm, but the window decorations were wrong for the kind
of window I wanted (it had a full menu with a "Quit" item that would bag
the whole application).  I wanted the so-called limited menu that the
popupWindows have.

I tried to use the undocumented SetWMDecorationHints() function.  It looks
as if the information is being set (a later GetWMDecorationHints() comes
back with the set values), but the window does not change.

Can anybody out there help?

Floyd Goldstein
AT&T Bell Labs
att!homxb!fmg

dvb@emisle.uucp (David Van Beveren) (01/19/91)

In article <1991Jan18.200706.17804@cbnewsh.att.com> fmg@cbnewsh.att.com (floyd.m.goldstein) writes:
>
>I tried to use the undocumented SetWMDecorationHints() function.  It looks
>as if the information is being set (a later GetWMDecorationHints() comes
>back with the set values), but the window does not change.
>
It has been my experience that OLWM does not recognize the normal properties
that SetWMDecorationHints sets. Try to set the OL properties directly, using
XInternAtom and XChangeProperty. It is not clearly documented, but if you
read closely, it is all there, in the OLIT Reference manual, around page 70.
(Some of the documentation I have is wrong, especially regarding the
definition of these properties. Contact sun directly for corrections. It
changed between 2.0Beta and 2.0 Release)

dvb

David Van Beveren                           INTERNET: emisle!dvb@ism.isc.com
EIS ltd. Professional Software Services     UUCP:   ..uunet!emisle!dvb
voice: (818) 587-1247

aim@Corp.Sun.COM (Amy) (01/23/91)

>>
>>
>>I have a popupWindow with a widget inside that can accept resize
>>requests.  It seems as if the controlArea that this widget is in is not
>>passing the resize request down to it.
>>
>>So then I tried stuffing this widget in a baseWindowShell.  The resizes
>>worked like a charm, but the window decorations were wrong for the kind
>>of window I wanted (it had a full menu with a "Quit" item that would bag
>>the whole application).  I wanted the so-called limited menu that the
>>popupWindows have.

Which version of the toolkit are you using?

With Release 4 of AT&T's toolkit, there is a new set of Shell resources
which should allow you to easily customize WM decorations:

	Resource		Type
	----------------------------------------------------------------

	XtNmenuType		OlDefine: OL_MENU_FULL, OL_MENU_LIMITED,
					  OL_MENU_CANCEL, OL_NONE
	XtNpushpin		OlDefine: OL_NONE, OL_OUT, OL_IN
	XtNresizeCorners	Boolean
	XtNwindowHeader		Boolean

However, these are not part of the previous release (thus the OLIT
which ships with OpenWindows V2 on the Sun platform), and unfortunately
I've not tried any of the older methods with the older version of the
toolkit.  I do know that there are some issues with the window manager
(olwm) only reading these properties at map time - so changing them
or setting them afterward will have no effect.  I'm not sure if that
is what you are running into, but it may be related.

Regards,
Amy Moore
aim@sun.com