Skip to Main Content
Volume 7A: XView Programming Manual
book

Volume 7A: XView Programming Manual

by Dan Heller
October 1994
Intermediate to advanced content levelIntermediate to advanced
770 pages
22h 58m
English
O'Reilly Media, Inc.
Content preview from Volume 7A: XView Programming Manual
F
Example Programs
This appendix contains nine example programs that supplement the programs in the chapters:
item_move.c
scroll_cells2.c
menu_dir2.c
type_font.c
fonts.c
x_draw.c
Logo.c
Bitmap.c
panel_dnd.c
Some of these programs are extensions to programs presented earlier in this book; they are
listed here to demonstrate extended usage. Other programs in this appendix attempt to inte-
grate features from unrelated XView packages that exceeded the scope of a particular chap-
ter.
F.1 item_move.c
The first program demonstrates how you can use an event handler within a panel to allow the
user to create panel items, move them around within the panel, and delete them. Chapter 7,
Panels, discusses specifics about how panels work. Chapter 5, Canvases and Openwin, dis-
cusses the canvas and openwin issues, since the panel is subclassed from those packages.
Example F-1. The item_move.c program
/*
* item_move.c
* Move items around in a panel using an interpose event handler
* specific to the panel. Two panels are created -- the left panel
* contains panel buttons that allow you to create certain types of
* items that are put in the second panel. Use the MENU (right)
Example Programs
Example Programs 713
Example F-1. The item_move.c program (continued)
* mouse button to move items around in the seco
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Volume 6A: Motif Programming Manual

Volume 6A: Motif Programming Manual

David Brennan, Dan Heller, Paula Ferguson
Java™ Media APIs: Cross-Platform Imaging, Media, and Visualization

Java™ Media APIs: Cross-Platform Imaging, Media, and Visualization

Alejandro Terrazas, John Ostuni, Michael Barlow

Publisher Resources

ISBN: 9780937175873