Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!bellcore!spectral!sjs From: sjs@spectral.ctt.bellcore.com (Stan Switzer) Newsgroups: comp.windows.news Subject: Re: multi-screen programming Keywords: NeWS multiple monitors frame buffer programming idea Message-ID: <16948@bellcore.bellcore.com> Date: 20 Jun 89 14:10:50 GMT References: <191@m2cs.uu.no> Sender: news@bellcore.bellcore.com Reply-To: sjs@ctt.bellcore.com (Stan Switzer) Organization: Bellcore Lines: 50 Frode L. Odegard (frode@m2cs.uu.no) writes: > I've been speculating...maybe framebuffer could become a function > that actually returns 'currentframebuffer' and maybe 'currentframebuffer' > could be set when the user moves the cursor from one monitor to another? > I haven't been really deep into the low-level code for event handling > but it'd be fun to hear what the NeWS experts have to say on this. Most of what you need is in WinWin. It turns out to be a bit difficult because you have to take care of a number of things: 1) As noted, you have to replace "framebuffer" with something that returns the current framebuffer. 2) You have to start a new window manager to handle root damage and to provide a root menu. 3) You have to fork a new server for the new device if you want to be able to create UNIX-initiated windows in it. 4) You have to replace "forkunix" with something that connects to the right server. This is messy because the forkunix primitive has already been autobound into various things, notably the root menu procs. You'll have to undo this. 5) You have to redefine "fboverlay" to correspond to the proper framebuffer. 6) Unlike all others canvases, NeWS makes children of "framebuffer" transparent and, if B&W, retained. This probably applies to children of any "device" canvas, but you should check. 7) If you use a window class that shares menus (like, for instance "neatwin" or "quickwin" you will have to deal with the fact that menus retain canvases and that the canvases are parented to one framebuffer or another. I jammed in some code to reparent them. 8) You'll have to figure out what you want "AllWin" to do. 9) You'll have to figure out where you want to put these changes. There is no way to replace a process's "systemdict" so you may have to play games like keeping "framebuffer" as a variable in "userdict" and aranging to propogate it in the "server" process. 10) You'll have to figure out how to warp the mouse to another framebuffer. 11) When you get it done, send me a copy! Stan Switzer sjs@ctt.bellcore.com