You may return to the Cvo Object Documenation Index from this document. This document contains the following sections describing the Cvo_PeelOff object:
Cvo_PeelOff
Cvo_Window
#include
<Cvo/PeelOff.h++>
new
Cvo_PeelOff ( char *resource_name,
{ Cvo_Object *parent | Display *display },
Cvo_Window *peelwin )
A Cvo_PeelOff object is a button with an icon which is used to peel
off a window from the screen. The peelwin argument specifies which
window is going to be peeled off. Typically the Cvo_PeelOff object is
a child of Cvo_Object peelwin, but does not have to be. When the
Cvo_PeelOff button is pressed in, a wire frame the size of the window
occupied by object peelwin is displayed. The user may drag this
frame to the appropriate place on the screen and then release the
button. When the button is released a CvoPeelOffEvent
is generated
which contains the coordinates of where the window was "dropped," as
well as peelwin.
This object does not, however, actually move the window specified by peelwin. Rather, this object generates the wire frame, tracks it, and generates an event. The programmer must do the rest once the event is generated.
This object defines the following Cvo Events in addition to those defined by its parent and ancestor objects.
CvoPeelOffEvent
struct
Cvo_PeelOffEvent
int x, y,
Cvo_Window *peelwin
The x and y elements indicate the location where the peeled off window should be placed.
The peelwin element indicates which window should be peeled off.
This object defines the following event translations in addition to those defined by its parent and ancestor objects.
<ButtonPress>
:
Press()
The Press
translation draws a wire frame for the window to be peeled.
<ButtonMotion>
:
Press()
The Drag
translation drags the wire frame around the screen.
<ButtonRelease>
:
Release()
The Release
translation generates the CvoPeelOffEvent and removes
the wire frame.
This object uses the following X resources in addition to those used by its parent and ancestor objects.
*CvoPeelOff.filename
(class:
Filename
)See the example source code for an example of how to use this object.
See the legend for information about the conventions used in this documentation.