martling@helix.cshl.org (Jim Martling) (03/28/91)
PLEASE HELP ME (X11 stuff)!
Here is my situation:
I have four xterm (actually aixterm) windows in my root window, each
occupying a quadrant:
--------------------------
| | |
| 1 | 2 |
| | |
--------------------------
| | |
| 3 | 4 |
| | |
--------------------------
We have an application that runs in the aixterm windows using curses.
This works fine. aixterm provides a feature that allows changing
the size and font of the window. From the aixterm menu, you choose
"Reduced", and the window will change to the "reduced" font, chosen
from either the -fr option on the aixterm command line, or from a
keyword in the .Xdefaults file.
We use this feature to provide a "zoom" capability. By setting the
"reduced" font to a Larger Font, and binding the "reduced" funtion
(size(toggle) in the .Xdefaults file), we enable the user to ZOOM
the window to full screen, and back again. This is great, works
fine, no problem. The problem? Well, if you ZOOM the window in
position 1, it works fine. If you ZOOM the window in the other
three quadrants, the ZOOM works fine, but the window is anchored
at the northwest (topleft) corner. Thus the window is from 1/4 to
3/4 off the screen, and must be repositioned using the mouse.
Please correct me if I am wrong, but I believe this is the win_gravity
attribute of the window that controls the "anchor" spot. I think
that if I could change the win_gravity of window 2 to be NorthEast,
and 3 to SouthWest, and 4 to SouthEast, this would solve this problem.
1) Is my analysis correct? (that the win_gravity is the culprit?)
2) How The Heck Can I change the win_gravity of a window without
changing the source that created it?
(More General...)
3) Given: An application running in an xterm shell.
Query: Is there any way that the application can connect to X, and
change the window attributes (size, location, font,
win_gravity) of the xterm its running in? Any way at all?
--- Groveling and Pleading to Follow ----
Please help me, O Great Programmers of the Net, O Please Help.
---- My Address ----
Please respond to: James Lester Martling
martling@cshl.org