21#ifndef __VSELECTION_H__
22#define __VSELECTION_H__
31#include <koffice_export.h>
38typedef TQPtrList<VObject> VObjectList;
39typedef TQPtrListIterator<VObject> VObjectListIterator;
86 void draw( VPainter* painter,
double zoomFactor )
const;
115 bool append(
const KoRect& rect,
bool selectObjects =
true,
bool exclusive =
true );
126 bool take(
const KoRect& rect,
bool selectObjects =
true,
bool exclusive =
true );
136 const VObjectList&
objects()
const {
return m_objects; }
144 TQPtrList<VSegment> getSegments(
const KoRect& rect );
151 void selectNodes(
bool select =
true );
159 VHandleNode handleNode(
const KoPoint &point )
const;
166 void showHandle(
bool handle =
true ) { m_showhandle = handle; }
173 virtual void setSelectObjects(
bool selectObjects =
true ) { m_selectObjects = selectObjects; }
175 static void setHandleSize( uint size )
176 { m_handleNodeSize = size; }
178 static uint handleSize()
179 {
return m_handleNodeSize; }
189 bool m_selectObjects;
194 VObjectList m_objects;
200 KoRect *m_handleRect;
205 static uint m_handleNodeSize;
VObject(VObject *parent, VState state=edit)
Constructs a new object that is child of parent and has the given state.
virtual VObject * clone() const =0
Create an exact copy of this object.
VObject * parent() const
Returns pointer to current parent object.
virtual void accept(VVisitor &)
Accept a VVisitor.
virtual const KoRect & boundingBox() const
Calculates the tightest bounding box around the object.
virtual void draw(VPainter *painter, const KoRect *rect=0L) const
Draw the object to a painting device.
A class representing lines and beziers.
const VObjectList & objects() const
Read only access to the selected objects.
void append()
Adds all objects to the selection.
void clear()
Removes the references to all objects, not the objects themselves.
virtual void setSelectObjects(bool selectObjects=true)
Toggles selection of objects/nodes.
void showHandle(bool handle=true)
Toggle selection handles on/off.
VSelection(VObject *parent=0L)
Constructs a vselection with the specified parent.
void take(VObject &object)
Removes the reference to the object, not the object itself.
The abstract visitor class.
VVisitor()
Constructs a new visitor class.