CView

#include <vstgui.h>

class CView;

Parent class of the CFrame class and the different CControl class.

[vst gui diagram]


CView

1.0

CView (CRect &size);

Creates a view object.


~CView

1.0

virtual ~CView ();

Destroys a view object.


redraw

1.0

void redraw ();

To redraw the view attached to a frame.


draw

1.0

virtual void draw (CDrawContext *context);


drawRect

2.2


virtual void drawRect (CDrawContext *pContext, CRect& updateRect);

To draw a specific rect inside the view.


checkUpdate

2.2


virtual bool checkUpdate (CRect& updateRect);

To check if in this rect the view needs an update.


mouse

1.0

virtual void mouse (CDrawContext * context, CPoint &where);

context
where Where the mouse click occured. Coordonates are in pixel relative to the parent's frame.

AEffGUIEditor :

Calls frame ->mouse (x, y).

See also :


update

1.0

virtual void update (CDrawContext *context);


notify

2.2

virtual long notify (CView* sender, const char* message);

Used to pass a message from one view to one other.


onKeyDown

2.2

virtual long onKeyDown (VstKeyCode& keyCode);

Called when the user hits a key.


onKeyUp

2.2

virtual long onKeyUp (VstKeyCode& keyCode);

Called when the user releases a key.


onDrop

2.1

virtual bool onDrop (void **ptrItems, long nbItems, long type, CPoint &where);

Called when during a drop the mouse is released.

ptrItems The list of items droped, depending on type :
kDropFiles : The path string (for MAC the FSSpec).
kDropText : A text string.
nbItems The number of items droped.
type A constant from CDropType
where The mouse location.
return
true : The drop is used.

onWheel

2.1

virtual bool onWheel (CDrawContext *pContext, const CPoint &where, float distance);


looseFocus

1.0

virtual void looseFocus ();

The view has no more the focus...


takeFocus

1.0

virtual void takeFocus ();

The view has now the focus on...


isDirty

2.1

virtual bool isDirty ();

Returns true if the view is dirty.


setDirty

2.1

virtual void setDirty (const bool val = true);

Sets the dirty value of the view.


setMouseEnabled

2.0

virtual void setMouseEnabled (const bool bEnable = true);

Enable or disable the action of the mouse.


getMouseEnabled

2.0

virtual bool getMouseEnabled ();

Gets the status of the mouse for this view.


setMouseableArea

2.0

virtual void setMouseableArea (const CRect &rect)

Sets the mouseable area of this view.


getMouseableArea

2.0

virtual CRect &getMouseableArea (CRect& rect);

Returns the mouseable area of this view.


hitTest

2.2

virtual bool hitTest (const CPoint& where, const long buttons);

Check whether the mouse click occured inside the view.


setTransparency

2.0

virtual void setTransparency (bool val);

Sets the transparency status of drawing mode for the pixmap.


getTransparency

2.0

virtual bool getTransparency () ;

Returns the transparency status of drawing mode for the pixmap.


getHeight

1.0

long getHeight ();

Returns the height of this view.


getWidth

1.0

long getWidth ();

Returns the width of this view.


setViewSize

2.1

virtual void setViewSize (CRect &rect);

Sets the enclosing rectangle of the View (size).


getViewSize

2.1

virtual CRect &getViewSize (CRect&rect);

Returns the enclosing rectangle of the View (size).


getParent

1.0

CFrame *getParent ();

Returns the parent frame.


setParent

2.0

virtual void setParent (CFrame *pParent);

Sets the parent frame.


setParentView

2.2

virtual void setParentView (CView *pParentView);

Sets the parent view.


getEditor

2.0

virtual void *getEditor ();

Returns the AEffGUIEditor of the view.


removed

2.1

virtual bool removed (CView *parent);

Called when this view is removed from its parent.


attached

2.1

virtual bool attached (CView *view);

It has been attached to a view.


getParentView

2.0

CView *getParentView ();

Returns the parent view of the actual one.


removed

2.1

virtual bool removed (CView *parent);

It has have been removed from parent view.


attached

2.1

virtual bool attached (CView *view);

It has been attached to a view.


forget

2.1

virtual void forget ();

Someone who was referencing this view doesn't do it anymore. When the view isn't referenced by anyone, it is destructed.


remember

2.1

virtual void remember ();

Someone is referencing this view.


getNbReference

2.1

virtual long getNbReference ();

Returns the number of objects which have a reference to this view.


Copyright ©2003 Steinberg Media Technologies GmbH. All Rights Reserved.