home *** CD-ROM | disk | FTP | other *** search
- Path: uunet!cs.utexas.edu!sun-barr!cronkite.Central.Sun.COM!exodus!soliado.East.Sun.COM
- From: sdo@soliado.East.Sun.COM (Scott Oaks - Sun Consulting NYC)
- Newsgroups: comp.sources.x
- Subject: v14i007: olvwm - Open Look Virtual Window Manager, Patch2, Part01/03
- Message-ID: <19073@exodus.Eng.Sun.COM>
- Date: 27 Aug 91 05:59:29 GMT
- References: <csx-14i007-olvwm@uunet.UU.NET>
- Sender: news@exodus.Eng.Sun.COM
- Lines: 999
- Approved: argv@sun.com
-
- Submitted-by: sdo@soliado.East.Sun.COM (Scott Oaks - Sun Consulting NYC)
- Posting-number: Volume 14, Issue 7
- Archive-name: olvwm/patch2.01
- Patch-To: olvwm: Volume 12, Issues 57-72
- Patch-To: olvwm: Volume 14, Issues 6
-
- This patch contains a number of changes which are listed in the first part
- of this patchfile. Most of the changes deal with new ways to move around
- in the desktop, and there are several minor bug fixes.
-
- There are three files to this patch, they must all be applied in order
- for the new version to work.
-
- Prereq: 1
- *** build/patchlevel.h Sat Jun 22 20:52:43 1991
- --- src/patchlevel.h Sat Jun 22 20:57:44 1991
- ***************
- *** 1 ****
- ! #define PATCHLEVEL 1
- --- 1 ----
- ! #define PATCHLEVEL 2
- *** build/CHANGES Sat Jun 22 21:04:02 1991
- --- src/CHANGES Sat Jun 22 14:28:29 1991
- ***************
- *** 0 ****
- --- 1,107 ----
- + FUNCTIONAL CHANGES:
- +
- + 1) New ways to move the desktop, including:
- + A) If a motion key is shifted, motion amount is doubled
- + B) If a motion key is pressed with the CTRL key, motion amount is halved
- + C) If a motion key is pressed with SHIFT/CTRL, motion amount is multiplied
- + by 20, which should take it to the nearest edge
- + D) The function keys 1-10 can be used to move to a specific screen:
- + screens are number across and then down from 1 to 10.
- + E) If a motion key is pressed with the META key, then it will work no
- + matter where the keyboard focus is.
- + F) The MENU button within the VDM brings up a (pinnable) menu allowing
- + motions.
- +
- + 2) Virtual Windows now react to mouse events and Front/Open keystrokes like
- + any other window; they can be grouped, their frame menu displayed, etc.
- +
- + 3) New RelativePosition attribute added
- +
- + In past versions, by default, when the user specified a window
- + placement, that position was used in absolute co-ordinates, and
- + when a program specified a window placement, that position was
- + used in relative co-ordinates.
- +
- + Some programs (frame and mailtool, for example) save some window
- + states somewhere (frame does it in the document, mailtool in
- + the .mailtool-init file) and then brings up these windows with
- + user-specified co-ordinates. This means that if you start these
- + programs in another part of the Virtual Desktop, some frames will
- + come up in the wrong area of the screen -- they will come up
- + where they last were rather than where you are now.
- +
- + Setting the RelativePosition attribute to True (its default) will
- + make all window placement strings be relative to the current
- + screen.
- +
- + The only time this setting should be a problem is if you are
- + any place other than the upper-left corner and you want to bring
- + up a window in absolute co-ordinates. But since absolute
- + co-ordinates are normally only useful for things brought up in
- + your .xinitrc/.openwin-init file, that shouldn't normally be
- + a problem.
- +
- + 4) You can now specify sticky applications by the first word in their
- + WM_NAME attribute as well as their WM_CLASS/WM_INSTANCE attribute.
- + For some tools (eg Mailtool), the WM_NAME is multi-word:
- + Mail Tool - /var/spool/mail/sdo for example; use only the first
- + word (Mail) in the list as xrdb is incapable of imbedding spaces
- + in the list.
- +
- + This allows (most) XView applications and pinned menus to be sticky.
- + Note that the XView clock has by default no WM_NAME either; but
- + it (and all XView applications) can set their name on the command
- + line with -Wl <name>.
- +
- + 5) The VDM now displays a grid (by default, but it can be turned off by
- + setting VirtualGrid to None) for screen sizes. When the grid
- + is on, dragging the mouse to move the desktop is constrained to move
- + between whole screen regions (unless the CTRL button is pressed
- + while dragging the mouse, in which case arbitrary positioning of
- + the desktop is enabled). If the grid is off, you can move the desktop
- + by arbitrary amounts unless the CTRL button is pressed, in which case
- + movement will be constrained to full screens.
- +
- + BUG FIXES
- +
- + 6) Windows which don't register with the Window manager and are raised
- + by the "Front" key no longer core dump.
- +
- + 7) The Save Workspace command now correctly saves non-Xview applications.
- +
- + 8) When olvwm is in MinimalDecor, it will resize correctly.
- +
- + 9) Clients like xterm can now receive input focus if click-to-type is in
- + effect and the inside of the window is clicked.
- +
- + 10) Icons can now be moved into the VDM when SnapToGrid is in effect.
- +
- + 11) Applications which start sticky can be unstuck.
- +
- + 12) Moving multiple windows into the VDM no longer collapses the windows
- + onto each other.
- +
- + 13) The root now correctly inherits keyboard events when shells exit.
- +
- + 14) Menus can now have embedded environmental variables
- +
- + 15) Sub-frames now inherit the stickyness of their parent. Note that in
- + the OPEN LOOK paradigm, this means that command frames and pinned
- + menus will inherit the stickyness of their parent but any other
- + base frames (e.g. the compose window from mailtool) will not.
- +
- + 16) olvwm now avoids the OW2.0 server bug for small windows on CG3 displays
- + which used to cause the server to crash.
- +
- + 17) Windows can no longer be dropped into obscured portions of the VDM
- +
- + SOURCE FIXES
- +
- + 18) Imakefile now lists resources1.o
- + [Okay, I said I was no Imake user . . .]
- +
- + 19) Imakefile no longer tries to install openwin-menu
- +
- + 20) Imakefile correctly installs man page
- +
- + 21) New Imakefile for those without MIT XView but with OpenWindows
- *** build/Imakefile Sat Jun 22 20:08:33 1991
- --- src/Imakefile Sat Jun 22 20:56:21 1991
- ***************
- *** 14,24 ****
- defaults.h events.h globals.h group.h list.h mem.h menu.h notice.h \
- olcursor.h olwm.h resources.h slots.h st.h win.h
-
- - INFOFILES =
- - MANPAGES = olvwm.man
- BITMAPS = iconbitmap.h vdm.icon
- - SCRIPTS =
- - MISC = openwin-menu
-
- SRCS = \
- Debug.c Notice.c Error.c \
- --- 14,20 ----
- ***************
- *** 38,44 ****
- usermenu.o usleep.o win.o winbusy.o winbutton.o wincolor.o \
- winframe.o wingframe.o winicon.o winipane.o winmenu.o \
- winnofoc.o winpane.o winpush.o winresize.o winroot.o \
- ! virtual.o
-
- ALLFILES = \
- ${HEADERS} ${BITMAPS} ${SRCS} \
- --- 34,40 ----
- usermenu.o usleep.o win.o winbusy.o winbutton.o wincolor.o \
- winframe.o wingframe.o winicon.o winipane.o winmenu.o \
- winnofoc.o winpane.o winpush.o winresize.o winroot.o \
- ! virtual.o resources1.o
-
- ALLFILES = \
- ${HEADERS} ${BITMAPS} ${SRCS} \
- ***************
- *** 45,53 ****
- ${MISC} ${INFOFILES} ${MANPAGES} ${SCRIPTS}
-
- ComplexProgramTarget(olvwm)
- -
- - InstallNonExecList($(MISC),$(LIBRARY_DEST))
- -
- - InstallManPage($(MANPAGES),$(MANDIR))
-
- #include <XView.prog>
- --- 41,45 ----
- *** build/Imakefile.sun Sat Jun 22 21:04:22 1991
- --- src/Imakefile.sun Tue Apr 30 18:43:17 1991
- ***************
- *** 0 ****
- --- 1,18 ----
- + OLGXLIB = -L$(OPENWINHOME)/lib -lolgx
- + INCLUDES = -I$(OPENWINHOME)/include -I$(TOP)
- + DEPLIBS = $(DEPXLIB)
- + LOCAL_LIBRARIES = $(OLGXLIB) $(XLIB) -lm
- +
- + SRCS = \
- + Debug.c Notice.c Error.c \
- + InitGraphics.c RubberWin.c Select.c WinInfo.c \
- + atom.c client.c defaults.c events.c group.c list.c \
- + mem.c menu.c olwm.c resources.c services.c slots.c st.c states.c \
- + usermenu.c usleep.c win.c winbusy.c winbutton.c wincolor.c \
- + winframe.c wingframe.c winicon.c winipane.c winmenu.c \
- + winnofoc.c winpane.c winpush.c winresize.c winroot.c \
- + virtual.c resources1.c
- +
- + OBJS = $(SRCS:.c=.o)
- +
- + ComplexProgramTarget(olvwm)
- *** build/LEGAL_NOTICE Sat Jun 22 20:08:53 1991
- --- src/LEGAL_NOTICE Sun May 19 20:05:34 1991
- ***************
- *** 1,7 ****
- This code is based on the OLWM code distributed with X11R4. In addition,
- I looked heavily at the public versions of tvtwm (though none of that code
- is included directly, and hence the copyright notice from Solboure is
- ! included more for safety than anything else).
-
- NOTICE TO USER: The source code, including the glyphs or icons
- forming a par of the OPEN LOOK TM Graphic User Interface, on this
- --- 1,9 ----
- This code is based on the OLWM code distributed with X11R4. In addition,
- I looked heavily at the public versions of tvtwm (though none of that code
- is included directly, and hence the copyright notice from Solboure is
- ! included more for safety than anything else). All code not covered by
- ! the copyrights listed below is (c) Copyright 1991 by Scott Oaks and may
- ! be used royalty-free in non-commercial software.
-
- NOTICE TO USER: The source code, including the glyphs or icons
- forming a par of the OPEN LOOK TM Graphic User Interface, on this
- *** build/Makefile.sunpro Sat Jun 22 20:08:33 1991
- --- src/Makefile.sunpro Sat Jun 22 21:13:46 1991
- ***************
- *** 1,6 ****
- .KEEP_STATE:
-
- ! DEBUG = -O
- CFLAGS = ${DEBUG} -I${OPENWINHOME}/include
- LDFLAGS = -L${OPENWINHOME}/lib ${DEBUG}
- LIBS = -lolgx -lX11 -lm
- --- 1,6 ----
- .KEEP_STATE:
-
- ! DEBUG = -O4
- CFLAGS = ${DEBUG} -I${OPENWINHOME}/include
- LDFLAGS = -L${OPENWINHOME}/lib ${DEBUG}
- LIBS = -lolgx -lX11 -lm
- *** build/README Sat Jun 22 20:08:34 1991
- --- src/README Fri Apr 26 17:30:33 1991
- ***************
- *** 19,24 ****
- --- 19,29 ----
- or corrections of this code, please send the new code (or diffs) to me
- and I will try to include them in later versions.
-
- + olvwm is compatible with and X11R4 server (though it's only been tested
- + on Sun OPENWINDOWS 2.0 and the Sun X11R4 MIT server). It should run
- + on Sun's OPENWINDOWS 3.0-beta (if you're lucky enough to be a beta site)
- + but it does not manage NeWS windows in any OPENWINDOWS release.
- +
- Please read the LEGAL_NOTICE for information about distributing this
- code.
-
- *** build/RubberWin.c Sat Jun 22 20:09:29 1991
- --- src/RubberWin.c Sat Jun 22 20:56:14 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[]= "@(#)RubberWin.c 1.2 olvwm version 3/30/91";
-
- /*
- * Based on
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[]= "@(#)RubberWin.c 1.3 olvwm version 6/22/91";
-
- /*
- * Based on
- ***************
- *** 51,60 ****
- static int VDMLocX, VDMLocY;
- static int check_vdm;
- extern Window VDM, VDMFrame;
- extern int VDMWidth, VDMHeight;
- ! extern int VDMOutlineX, VDMOutlineY;
- ! static int InVDM = 0;
- ! static int StartInVDM = 0;
-
- #ifndef TRUE
- #define FALSE 0
- --- 51,61 ----
- static int VDMLocX, VDMLocY;
- static int check_vdm;
- extern Window VDM, VDMFrame;
- + extern int VirtualDesktopX, VirtualDesktopY;
- + extern int VirtualDesktopWidth, VirtualDesktopHeight;
- extern int VDMWidth, VDMHeight;
- ! extern int VDMOutlineX, VDMOutlineY;
- ! int InVDM;
-
- #ifndef TRUE
- #define FALSE 0
- ***************
- *** 143,151 ****
- mstuff.initX = first->xbutton.x_root;
- mstuff.initY = first->xbutton.y_root;
-
- - InVDM = 0;
- - StartInVDM = 0;
- -
- if (first->xbutton.state & ShiftMask) {
- invertMoveWindow = True;
- GRV.DragWindow = !GRV.DragWindow;
- --- 144,149 ----
- ***************
- *** 240,270 ****
- if (!GRV.DragWindow)
- (void) ListApply(mstuff->winlist, drawOneBox, mstuff);
-
- ! if (check_vdm) {
- ! switch(InVDM) {
- ! case 1:
- ! if (event->xmotion.x_root < VDMLocX ||
- ! event->xmotion.x_root > VDMLocX + VDMWidth ||
- ! event->xmotion.y_root < VDMLocY ||
- ! event->xmotion.y_root > VDMLocY + VDMHeight) {
- ! InVDM = 0;
- ! }
- ! break;
- ! case 0:
- ! if (event->xmotion.x_root > VDMLocX &&
- ! event->xmotion.x_root < VDMLocX + VDMWidth &&
- ! event->xmotion.y_root > VDMLocY &&
- ! event->xmotion.y_root < VDMLocY + VDMHeight) {
- ! InVDM = 1;
- ! }
- ! break;
- ! }
- ! }
-
- ! mstuff->offX = (event->xmotion.x_root - mstuff->initX
- + mstuff->rounder) / mstuff->divider;
- ! mstuff->offY = (event->xmotion.y_root - mstuff->initY
- + mstuff->rounder) / mstuff->divider;
-
- if ((event->xmotion.state & ControlMask) != 0) {
- if (ABS(mstuff->offX) > ABS(mstuff->offY))
- --- 238,265 ----
- if (!GRV.DragWindow)
- (void) ListApply(mstuff->winlist, drawOneBox, mstuff);
-
- ! if (check_vdm)
- ! if (event->xmotion.subwindow == VDMFrame)
- ! InVDM = 1;
- ! else
- ! InVDM = 0;
- ! else InVDM = 0;
-
- !
- ! if (InVDM) {
- ! mstuff->offX = (event->xmotion.x_root - VDMLocX) *
- ! (GRV.VDMScale / mstuff->divider) -
- ! mstuff->initX + VirtualDesktopX;
- ! mstuff->offY = (event->xmotion.y_root - VDMLocY) *
- ! (GRV.VDMScale / mstuff->divider) -
- ! mstuff->initY + VirtualDesktopY;
- ! }
- ! else {
- ! mstuff->offX = (event->xmotion.x_root - mstuff->initX
- + mstuff->rounder) / mstuff->divider;
- ! mstuff->offY = (event->xmotion.y_root - mstuff->initY
- + mstuff->rounder) / mstuff->divider;
- + }
-
- if ((event->xmotion.state & ControlMask) != 0) {
- if (ABS(mstuff->offX) > ABS(mstuff->offY))
- ***************
- *** 300,326 ****
- {
- int pixw = DisplayWidth(win->core.client->dpy, win->core.client->screen);
- int pixy = DisplayHeight(win->core.client->dpy, win->core.client->screen);
- ! int hpoint;
-
- - if (check_vdm && InVDM) {
- - if (StartInVDM) {
- - *pox = mstuff->offX * GRV.VDMScale + VDMOutlineX;
- - *poy = mstuff->offY * GRV.VDMScale + VDMOutlineY;
- - }
- - else {
- - *pox = (mstuff->initX + mstuff->offX - VDMLocX - VDMOutlineX)
- - * GRV.VDMScale - win->core.x;
- - *poy = (mstuff->initY + mstuff->offY - VDMLocY - VDMOutlineY)
- - * GRV.VDMScale - win->core.y;
- - }
- - return;
- - }
- - else if (StartInVDM) {
- - *pox = mstuff->initX + mstuff->offX - win->core.x;
- - *poy = mstuff->initY + mstuff->offY - win->core.y;
- - return;
- - }
- -
- if (mstuff->offX == 0)
- {
- *pox = 0;
- --- 295,302 ----
- {
- int pixw = DisplayWidth(win->core.client->dpy, win->core.client->screen);
- int pixy = DisplayHeight(win->core.client->dpy, win->core.client->screen);
- ! int hpoint;
-
- if (mstuff->offX == 0)
- {
- *pox = 0;
- ***************
- *** 328,347 ****
- else if (mstuff->offX > 0)
- {
- hpoint = pixw - win->core.x - win->core.width;
- ! if ((mstuff->offX >= hpoint) && (mstuff->offX <= hpoint + GRV.EdgeThreshold))
- *pox = hpoint;
- ! else if (mstuff->offX >= hpoint+win->core.width-Resize_width)
- ! *pox = hpoint+win->core.width-Resize_width;
- ! else
- ! *pox = mstuff->offX;
- }
- else if (mstuff->offX < 0)
- {
- ! if ((mstuff->offX <= -win->core.x) &&
- (mstuff->offX >= -win->core.x - GRV.EdgeThreshold))
- *pox = -win->core.x;
- ! else if (mstuff->offX <= -win->core.x - win->core.width + Resize_width)
- ! *pox = -win->core.x - win->core.width + Resize_width;
- else
- *pox = mstuff->offX;
- }
- --- 304,330 ----
- else if (mstuff->offX > 0)
- {
- hpoint = pixw - win->core.x - win->core.width;
- ! if (!InVDM && (mstuff->offX >= hpoint) &&
- ! (mstuff->offX <= hpoint + GRV.EdgeThreshold))
- *pox = hpoint;
- ! else {
- ! hpoint = VirtualDesktopWidth + VirtualDesktopX -
- ! win->core.x - win->core.width;
- ! if (mstuff->offX >= hpoint + win->core.width - Resize_width)
- ! *pox = hpoint + win->core.width - Resize_width;
- ! else
- ! *pox = mstuff->offX;
- ! }
- }
- else if (mstuff->offX < 0)
- {
- ! if (!InVDM && (mstuff->offX <= -win->core.x) &&
- (mstuff->offX >= -win->core.x - GRV.EdgeThreshold))
- *pox = -win->core.x;
- ! else if (mstuff->offX <= -win->core.x - win->core.width +
- ! Resize_width + VirtualDesktopX)
- ! *pox = -win->core.x - win->core.width +
- ! Resize_width + VirtualDesktopX;
- else
- *pox = mstuff->offX;
- }
- ***************
- *** 353,371 ****
- else if (mstuff->offY > 0)
- {
- hpoint = pixy - win->core.y - win->core.height;
- ! if ((mstuff->offY >= hpoint) && (mstuff->offY <= hpoint + GRV.EdgeThreshold))
- *poy = hpoint;
- ! else if (mstuff->offY >= hpoint+win->core.height-Resize_height)
- ! *poy = hpoint+win->core.height-Resize_height;
- ! else
- ! *poy = mstuff->offY;
- }
- else if (mstuff->offY < 0)
- {
- ! if ((mstuff->offY <= -win->core.y) && (mstuff->offY >= (-win->core.y - GRV.EdgeThreshold)))
- *poy = -win->core.y;
- ! else if (mstuff->offY <= (-win->core.y-win->core.height+Resize_height))
- ! *poy = (-win->core.y-win->core.height+Resize_height);
- else
- *poy = mstuff->offY;
- }
- --- 336,362 ----
- else if (mstuff->offY > 0)
- {
- hpoint = pixy - win->core.y - win->core.height;
- ! if (!InVDM && (mstuff->offY >= hpoint) &&
- ! (mstuff->offY <= hpoint + GRV.EdgeThreshold))
- *poy = hpoint;
- ! else {
- ! hpoint = VirtualDesktopHeight + VirtualDesktopY -
- ! win->core.y - win->core.height;
- ! if (mstuff->offY >= hpoint+win->core.height-Resize_height)
- ! *poy = hpoint+win->core.height-Resize_height;
- ! else
- ! *poy = mstuff->offY;
- ! }
- }
- else if (mstuff->offY < 0)
- {
- ! if (!InVDM && (mstuff->offY <= -win->core.y) &&
- ! (mstuff->offY >= (-win->core.y - GRV.EdgeThreshold)))
- *poy = -win->core.y;
- ! else if (mstuff->offY <= -win->core.y - win->core.height +
- ! Resize_height + VirtualDesktopY)
- ! *poy = -win->core.y - win->core.height +
- ! Resize_height + VirtualDesktopY;
- else
- *poy = mstuff->offY;
- }
- ***************
- *** 390,397 ****
- win->core.x + offX,
- win->core.y + offY);
- XMoveWindow(mstuff->dpy, cli->virtualWindow,
- ! (win->core.x + offX) / GRV.VDMScale + VDMOutlineX,
- ! (win->core.y + offY) / GRV.VDMScale + VDMOutlineY);
- return (void *) 0;
- }
-
- --- 381,388 ----
- win->core.x + offX,
- win->core.y + offY);
- XMoveWindow(mstuff->dpy, cli->virtualWindow,
- ! (win->core.x + offX - VirtualDesktopX) / GRV.VDMScale,
- ! (win->core.y + offY - VirtualDesktopY) / GRV.VDMScale);
- return (void *) 0;
- }
-
- ***************
- *** 415,422 ****
- w->core.y + offY,
- w->core.width, w->core.height);
- drawDouble(mstuff->dpy, VDM, RootGC,
- ! (w->core.x + offX) / GRV.VDMScale + VDMOutlineX,
- ! (w->core.y + offY) / GRV.VDMScale + VDMOutlineY,
- w->core.width / GRV.VDMScale,
- w->core.height / GRV.VDMScale);
- return (void *) 0;
- --- 406,413 ----
- w->core.y + offY,
- w->core.width, w->core.height);
- drawDouble(mstuff->dpy, VDM, RootGC,
- ! (w->core.x + offX - VirtualDesktopX) / GRV.VDMScale,
- ! (w->core.y + offY - VirtualDesktopY) / GRV.VDMScale,
- w->core.width / GRV.VDMScale,
- w->core.height / GRV.VDMScale);
- return (void *) 0;
- ***************
- *** 527,534 ****
- (diff > (i2) ? ((i)-diff) : (-diff)) \
- )
-
- - InVDM = 0;
- - StartInVDM = 0;
- /* set initial position and size */
- startx = newx = winFrame->core.x;
- starty = newy = winFrame->core.y;
- --- 518,523 ----
- ***************
- *** 983,1071 ****
- XFlush(dpy);
- *timestamp = event.xbutton.time;
- return True;
- - }
- -
- - UserMoveVirtualWindow(dpy, first, cli)
- - Display *dpy;
- - XEvent *first;
- - Client *cli;
- - {
- - static movestuff_t mstuff;
- - List *winlist = NULL_LIST;
- - unsigned int modmask;
- -
- - /*
- - * Set up where the vdm is to check if we move into it during the move
- - */
- - {
- - int x,y;
- - unsigned int w, h, bw, d;
- - Window root;
- - Client *vdm_cli, *VirtualGetClient();
- -
- - if ((vdm_cli = VirtualGetClient(dpy, VDM)) != NULL &&
- - vdm_cli->wmState != IconicState && vdm_cli != cli) {
- - check_vdm = TRUE;
- - XGetGeometry(dpy, VDMFrame, &root, &x, &y, &w, &h, &bw, &d);
- - VDMLocX = x;
- - VDMLocY = y;
- - XGetGeometry(dpy, VDM, &root, &x, &y, &w, &h, &bw, &d);
- - VDMLocX += x;
- - VDMLocY += y;
- - }
- - else check_vdm = FALSE;
- - }
- -
- - mstuff.dpy = dpy;
- - mstuff.offX = 0;
- - mstuff.offY = 0;
- - mstuff.initX = first->xbutton.x_root;
- - mstuff.initY = first->xbutton.y_root;
- -
- - InVDM = 1;
- - StartInVDM = 1;
- -
- - if (first->xbutton.state & ShiftMask) {
- - invertMoveWindow = True;
- - GRV.DragWindow = !GRV.DragWindow;
- - }
- -
- - /*
- - * If a meta key is held down, slow down the dragging by a factor of ten.
- - */
- -
- - modmask = FindModifierMask(XKeysymToKeycode(dpy,XK_Meta_L)) |
- - FindModifierMask(XKeysymToKeycode(dpy,XK_Meta_R));
- -
- - if (first->xbutton.state & modmask) {
- - mstuff.rounder = 5;
- - mstuff.divider = 10;
- - } else {
- - mstuff.rounder = 0;
- - mstuff.divider = 1;
- - }
- -
- - if (cli->wmState == IconicState)
- - winlist = ListCons(cli->iconwin, NULL);
- - else
- - winlist = ListCons(cli->framewin, NULL);
- - mstuff.winlist = winlist;
- -
- - XGrabPointer(dpy, DefaultRootWindow(dpy), False,
- - (ButtonReleaseMask | PointerMotionMask),
- - GrabModeAsync, GrabModeAsync,
- - (GRV.AllowMoveIntoDesktop) ? None : VDM,
- - GRV.MovePointer, CurrentTime);
- - /* REMIND - use first.xbutton.time? */
- -
- - InstallInterposer( movewinInterposer, &mstuff );
- -
- - /*
- - * If we're dragging the outlines, we must also grab the server and draw
- - * the initial set of bounding boxes.
- - */
- - if (!GRV.DragWindow) {
- - XGrabServer(dpy);
- - (void) ListApply(mstuff.winlist, drawOneBox, &mstuff);
- - }
- }
- --- 972,975 ----
- Common subdirectories: build/SCCS and src/SCCS
- *** build/events.c Sat Jun 22 20:09:06 1991
- --- src/events.c Sat Jun 22 20:56:14 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)events.c 1.2 olvwm version 3/30/91";
-
- /*
- * Based on
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)events.c 1.3 olvwm version 6/22/91";
-
- /*
- * Based on
- ***************
- *** 141,147 ****
-
- if (winInfo == NULL)
- {
- ! if (IsVirtual(event->xany.window))
- VirtualEvents(dpy, event);
- /* REMIND should we do anything with these events? */
- else if (GRV.PrintOrphans)
- --- 141,147 ----
-
- if (winInfo == NULL)
- {
- ! if (IsVirtual(dpy, event->xany.window))
- VirtualEvents(dpy, event);
- /* REMIND should we do anything with these events? */
- else if (GRV.PrintOrphans)
- ***************
- *** 167,173 ****
- {
- (*evFunc)(dpy, event, winInfo);
- }
- ! else if (IsVirtual(event->xany.window))
- VirtualEvents(dpy, event);
- else
- if (GRV.PrintOrphans)
- --- 167,173 ----
- {
- (*evFunc)(dpy, event, winInfo);
- }
- ! else if (IsVirtual(dpy, event->xany.window))
- VirtualEvents(dpy, event);
- else
- if (GRV.PrintOrphans)
- *** build/globals.h Sat Jun 22 20:08:41 1991
- --- src/globals.h Sat Jun 22 20:56:14 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! /* @(#)globals.h 1.4 olvwm version 4/17/91 */
-
- /* Based on @(#) globals.h 1.13 90/05/31 Crucible */
-
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! /* @(#)globals.h 1.5 olvwm version 6/22/91 */
-
- /* Based on @(#) globals.h 1.13 90/05/31 Crucible */
-
- ***************
- *** 103,108 ****
- --- 103,113 ----
- int AutoRootMenuY;
- Bool VirtualIconic;
- List *StickyList;
- + Bool RelativePosition;
- + Bool GrabVirtualKeys;
- + unsigned long VirtualPixmapColor;
- + int VirtualGrid;
- + unsigned long VirtualGridColor;
- } GlobalResourceVariables;
-
- extern GlobalResourceVariables GRV;
- *** build/list.c Sat Jun 22 20:08:43 1991
- --- src/list.c Sat Jun 22 20:56:15 1991
- ***************
- *** 205,210 ****
- --- 205,234 ----
- }
- }
-
- + List *
- + ListDestroyCellByValue(val, l)
- + void *val;
- + List *l;
- + {
- + List *cell, *last;
- +
- + for (cell = l, last = NULL; cell; last = cell, cell = cell->next)
- + if (cell->value == val)
- + break;
- + if (!cell)
- + return l;
- + if (last) {
- + last->next = cell->next;
- + freeCell(cell);
- + }
- + else {
- + l = l->next;
- + freeCell(cell);
- + }
- + return l;
- + }
- +
- +
- /* global function
- * void ListApply(List *l,void *(*f)(),void*c)
- *
- *** build/list.h Sat Jun 22 20:08:43 1991
- --- src/list.h Sat Jun 22 20:56:15 1991
- ***************
- *** 38,43 ****
- --- 38,48 ----
- * reference to point to the next cell.
- */
-
- + extern List *ListDestroyCellByValue(); /* void *val, List *l */
- + /* deletes the given cell from the list and passes back the
- + * (possibly modified) new list
- + */
- +
- extern void *ListApply(); /* List *l, (void *)(*f)(), void *c */
- /* iteratively calls the function f with list values and the
- * closure, until it returns a non-NULL value. Returns this non-Null
- *** build/winnofoc.c Sat Jun 22 20:08:59 1991
- --- src/winnofoc.c Sat Jun 22 20:56:19 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)winnofoc.c 1.2 olvwm version 3/30/91";
-
- /*
- * Based on
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)winnofoc.c 1.3 olvwm version 6/22/91";
-
- /*
- * Based on
- ***************
- *** 60,65 ****
- --- 60,66 ----
- XDestroyWindow(dpy, winInfo->core.self);
- WIUninstallInfo(winInfo->core.self);
- MemFree(winInfo);
- + NoFocusWin = NULL;
- }
-
-
- ***************
- *** 162,168 ****
- Display *dpy;
- Time evtime;
- {
- ! XSetInputFocus(dpy, NoFocusWin, RevertToParent, evtime);
- }
-
- /*
- --- 163,170 ----
- Display *dpy;
- Time evtime;
- {
- ! if (NoFocusWin)
- ! XSetInputFocus(dpy, NoFocusWin, RevertToParent, evtime);
- }
-
- /*
- *** build/winpane.c Sat Jun 22 20:09:12 1991
- --- src/winpane.c Sat Jun 22 20:56:19 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)winpane.c 1.2 olvwm version 3/30/91";
-
- /*
- * Based on
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)winpane.c 1.3 olvwm version 6/22/91";
-
- /*
- * Based on
- ***************
- *** 423,429 ****
- * ColormapChangeMask -- to track colormaps accurately
- * EnterWindowMask -- to install colormaps appropriately
- */
- ! if (!IsVirtual(win)) {
- mask = PropertyChangeMask | StructureNotifyMask |
- ColormapChangeMask | EnterWindowMask;
- XSelectInput(cli->dpy, win, mask);
- --- 423,429 ----
- * ColormapChangeMask -- to track colormaps accurately
- * EnterWindowMask -- to install colormaps appropriately
- */
- ! if (!IsVirtual(cli->dpy, win)) {
- mask = PropertyChangeMask | StructureNotifyMask |
- ColormapChangeMask | EnterWindowMask;
- XSelectInput(cli->dpy, win, mask);
- *** build/winroot.c Sat Jun 22 20:09:16 1991
- --- src/winroot.c Sat Jun 22 20:56:20 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)winroot.c 1.2 olvwm version 3/30/91";
-
- /*
- * Based on
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)winroot.c 1.3 olvwm version 6/22/91";
-
- /*
- * Based on
- ***************
- *** 124,137 ****
- Client *childClient;
- Bool samescreen;
- int destX, destY;
-
- ! samescreen = XTranslateCoordinates(dpy,
- ! DefaultRootWindow(dpy), DefaultRootWindow(dpy),
- ! pEvent->xkey.x, pEvent->xkey.y, &destX, &destY, &child );
-
- if (!samescreen)
- return;
-
- if (pEvent->type == KeyPress && child != None &&
- matchKeystrokeToSpec(pEvent, &(GRV.FrontKey))) {
- XWindowChanges xwc;
- --- 124,152 ----
- Client *childClient;
- Bool samescreen;
- int destX, destY;
- + extern Window VDMFrame;
- + int inVDM = False;
-
- ! if (CheckVDMMove(dpy, pEvent))
- ! return;
-
- + do {
- + samescreen = XTranslateCoordinates(dpy,
- + DefaultRootWindow(dpy), DefaultRootWindow(dpy),
- + pEvent->xkey.x, pEvent->xkey.y, &destX, &destY, &child );
- + if (child == VDMFrame) {
- + TranslateVirtualCoords(dpy, &pEvent->xkey.x, &pEvent->xkey.y,
- + NULL, NULL);
- + inVDM = True;
- + }
- + } while (child == VDMFrame);
- +
- if (!samescreen)
- return;
-
- + if (inVDM && child == None)
- + child = VDMFrame;
- +
- if (pEvent->type == KeyPress && child != None &&
- matchKeystrokeToSpec(pEvent, &(GRV.FrontKey))) {
- XWindowChanges xwc;
- ***************
- *** 138,146 ****
- xwc.stack_mode = Opposite;
- XConfigureWindow( dpy, child, CWStackMode, &xwc );
- childInfo = WIGetInfo(child);
- ! childClient = childInfo->core.client;
- ! if (childClient && childClient->virtualWindow) {
- ! XConfigureWindow(dpy, childClient->virtualWindow, CWStackMode, &xwc);
- }
- } else if (matchKeystrokeToSpec(pEvent, &(GRV.HelpKey))) {
- redistributeKeystroke( dpy, pEvent );
- --- 153,164 ----
- xwc.stack_mode = Opposite;
- XConfigureWindow( dpy, child, CWStackMode, &xwc );
- childInfo = WIGetInfo(child);
- ! if (childInfo) {
- ! childClient = childInfo->core.client;
- ! if (childClient && childClient->virtualWindow) {
- ! XConfigureWindow(dpy,
- ! childClient->virtualWindow, CWStackMode, &xwc);
- ! }
- }
- } else if (matchKeystrokeToSpec(pEvent, &(GRV.HelpKey))) {
- redistributeKeystroke( dpy, pEvent );
- *** build/olwm.c Sat Jul 27 21:35:49 1991
- --- src/olwm.c Sat Jul 27 21:33:43 1991
- ***************
- *** 6,12 ****
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)olwm.c 1.4 olvwm version 4/25/91";
-
- /*
- * Based on
- --- 6,12 ----
- * Written for Sun Microsystems by Crucible, Santa Cruz, CA.
- */
-
- ! static char sccsid[] = "@(#)olwm.c 1.5 olvwm version 7/27/91";
-
- /*
- * Based on
- ***************
- *** 725,730 ****
- --- 725,735 ----
- --DeadChildren;
- }
- (void) sigsetmask(oldmask);
- + /*
- + * Following is only needed for SYSV, but it doesn't hurt in BSD
- + * either . . .
- + */
- + signal(SIGCHLD, HandleChildSignal);
- }
-
- /*
-
- --
- Dan Heller
- O'Reilly && Associates Z-Code Software Comp-sources-x:
- Senior Writer President comp-sources-x@uunet.uu.net
- argv@ora.com argv@zipcode.com
-