[Source] Paneledit: interactive editor for SunView panels
Mark Phillips
mbp at lakisis.umd.edu
Mon Oct 2 07:11:57 AEST 1989
Here is a piece of code which I call "paneledit" that can save SunView
programmers hours of development time. It allows you to reposition any
panel item in your program interactively. It is not a standalone program,
but rather can be incorporated into any SunView program at any time by
simply adding one line to the program's source code and recompiling. It
allows you to switch between the program's normal operational mode and a
special "editing" mode, in which you can use the mouse to drag panel items
around and find out their new x,y coordinates. You can switch modes as
often as you like.
Paneledit incorporates a procedure called "move_item" by Chuck Musciano
(posted to Sun-Spots in July '88) in a way that frees you from having to
explicitly change your code to reference move_item. You just add one line
to your program, and poof!, you can drag panel items around to your
heart's content, without interfering with the normal functionality of the
program.
The code, instructions, and a short example program are in the shar file
below. Enjoy!
Ed's Note: Hostname : titan.rice.edu
Directory: sun-source
Filename : paneledit.shar
Mark Phillips mbp at lakisis.umd.edu
Department of Mathematics (301) 454-6550
University of Maryland
College Park, Maryland 20742
USA
More information about the Comp.sys.sun
mailing list