Skip to content

RLineEntity

Class in Entity Module
Header: #include <src/entity/RLineEntity.h>
Inherits: REntity

Line entity.

Scriptable: This class is available in script environments.

Shared Pointer Support: Objects can be used in QSharedPointer.

RLineEntity(const RLineEntity &other)
RLineEntity(RDocument *document, const RLineData &data)
virtual ~RLineEntity()
virtual QSharedPointer< RObject > clone() const
QSharedPointer< RLineEntity > cloneToLineEntity() const
virtual void exportEntity(RExporter &e, bool preview=false, bool forceSelected=false) const
Exports the entity to the given exporter.
double getAngle() const
double getAngleAt(double distance, RS::From from) const
virtual RLineData & getData()
virtual const RLineData & getData() const
double getDirection1() const
double getDirection2() const
RVector getEndPoint() const
double getLength() const
RVector getMiddlePoint() const
virtual QPair< QVariant, RPropertyAttributes > getProperty(RPropertyTypeId &propertyTypeId, bool humanReadable=false, bool noAttributes=false, bool showOnRequest=false)
RS::Side getSideOfPoint(const RVector &point) const
RVector getStartPoint() const
RS::Ending getTrimEnd(const RVector &trimPoint, const RVector &clickPoint)
bool reverse()
void setEndPoint(const RVector &p)
virtual bool setProperty(RPropertyTypeId propertyTypeId, const QVariant &value, RTransaction *transaction=NULL)
Sets the given property to the given value.
void setShape(const RLine &l)
void setStartPoint(const RVector &p)
bool trimEndPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)
bool trimStartPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)
static RS::EntityType getRtti()
static QSet< RPropertyTypeId > getStaticPropertyTypeIds()
static void init()
static RPropertyTypeId PropertyAngle
static RPropertyTypeId PropertyBlock
static RPropertyTypeId PropertyColor
static RPropertyTypeId PropertyCustom
static RPropertyTypeId PropertyDisplayedColor
static RPropertyTypeId PropertyDrawOrder
static RPropertyTypeId PropertyEndPointX
static RPropertyTypeId PropertyEndPointY
static RPropertyTypeId PropertyEndPointZ
static RPropertyTypeId PropertyHandle
static RPropertyTypeId PropertyLayer
static RPropertyTypeId PropertyLength
static RPropertyTypeId PropertyLinetype
static RPropertyTypeId PropertyLinetypeScale
static RPropertyTypeId PropertyLineweight
static RPropertyTypeId PropertyMiddlePointX
static RPropertyTypeId PropertyMiddlePointY
static RPropertyTypeId PropertyMiddlePointZ
static RPropertyTypeId PropertyProtected
static RPropertyTypeId PropertyStartPointX
static RPropertyTypeId PropertyStartPointY
static RPropertyTypeId PropertyStartPointZ
static RPropertyTypeId PropertyTotalLength
static RPropertyTypeId PropertyType
static RPropertyTypeId PropertyWorkingSet
virtual void print(QDebug dbg) const
Stream operator for QDebug.
RLineData data

RLineEntity::RLineEntity(const RLineEntity &other)

RLineEntity::RLineEntity(RDocument *document, const RLineData &data)

virtual RLineEntity::~RLineEntity()

virtual

virtual QSharedPointer< RObject > RLineEntity::clone() const

virtual inline const

Reimplemented from clone.

QSharedPointer< RLineEntity > RLineEntity::cloneToLineEntity() const

inline const

virtual void RLineEntity::exportEntity(RExporter &e, bool preview=false, bool forceSelected=false) const

virtual const

Exports the entity to the given exporter.

The exporter might be a file exporter, a graphics scene or any other platform one can export entities to.

Reimplemented from exportEntity.

double RLineEntity::getAngle() const

inline const

double RLineEntity::getAngleAt(double distance, RS::From from) const

inline const

virtual RLineData & RLineEntity::getData()

virtual inline

Returns: Reference to the data object of the entity.

Reimplemented from getData.

virtual const RLineData & RLineEntity::getData() const

virtual inline const

Returns: Const reference to the data object of the entity.

Reimplemented from getData.

double RLineEntity::getDirection1() const

inline const

double RLineEntity::getDirection2() const

inline const

RVector RLineEntity::getEndPoint() const

inline const

double RLineEntity::getLength() const

inline const

RVector RLineEntity::getMiddlePoint() const

inline const

virtual QPair< QVariant, RPropertyAttributes > RLineEntity::getProperty(RPropertyTypeId &propertyTypeId, bool humanReadable=false, bool noAttributes=false, bool showOnRequest=false)

virtual

Returns: The value and attributes of the given property or an invalid property if this property owner has no property with the given ID.

Reimplemented from getProperty.

RS::Side RLineEntity::getSideOfPoint(const RVector &point) const

inline const

RVector RLineEntity::getStartPoint() const

inline const

RS::Ending RLineEntity::getTrimEnd(const RVector &trimPoint, const RVector &clickPoint)

inline

bool RLineEntity::reverse()

inline

void RLineEntity::setEndPoint(const RVector &p)

inline

virtual bool RLineEntity::setProperty(RPropertyTypeId propertyTypeId, const QVariant &value, RTransaction *transaction=NULL)

virtual

Sets the given property to the given value.

If this property owner does not know a property with that ID, it is up to the property owner what happens. The property might be added into a list of dynamic properties or dropped.

Returns: True if the property owner was modified in any way, false otherwise.

Reimplemented from setProperty.

void RLineEntity::setShape(const RLine &l)

void RLineEntity::setStartPoint(const RVector &p)

inline

bool RLineEntity::trimEndPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)

inline

bool RLineEntity::trimStartPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)

inline

static RS::EntityType RLineEntity::getRtti()

static inline

static QSet< RPropertyTypeId > RLineEntity::getStaticPropertyTypeIds()

static inline

static void RLineEntity::init()

static

static RPropertyTypeId RLineEntity::PropertyAngle

static

static RPropertyTypeId RLineEntity::PropertyBlock

static

static RPropertyTypeId RLineEntity::PropertyColor

static

static RPropertyTypeId RLineEntity::PropertyCustom

static

All rights reserved.

This file is part of the QCAD project.

QCAD is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

QCAD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with QCAD.

static RPropertyTypeId RLineEntity::PropertyDisplayedColor

static

static RPropertyTypeId RLineEntity::PropertyDrawOrder

static

static RPropertyTypeId RLineEntity::PropertyEndPointX

static

static RPropertyTypeId RLineEntity::PropertyEndPointY

static

static RPropertyTypeId RLineEntity::PropertyEndPointZ

static

static RPropertyTypeId RLineEntity::PropertyHandle

static

static RPropertyTypeId RLineEntity::PropertyLayer

static

static RPropertyTypeId RLineEntity::PropertyLength

static

static RPropertyTypeId RLineEntity::PropertyLinetype

static

static RPropertyTypeId RLineEntity::PropertyLinetypeScale

static

static RPropertyTypeId RLineEntity::PropertyLineweight

static

static RPropertyTypeId RLineEntity::PropertyMiddlePointX

static

static RPropertyTypeId RLineEntity::PropertyMiddlePointY

static

static RPropertyTypeId RLineEntity::PropertyMiddlePointZ

static

static RPropertyTypeId RLineEntity::PropertyProtected

static

static RPropertyTypeId RLineEntity::PropertyStartPointX

static

static RPropertyTypeId RLineEntity::PropertyStartPointY

static

static RPropertyTypeId RLineEntity::PropertyStartPointZ

static

static RPropertyTypeId RLineEntity::PropertyTotalLength

static

static RPropertyTypeId RLineEntity::PropertyType

static

static RPropertyTypeId RLineEntity::PropertyWorkingSet

static

virtual void RLineEntity::print(QDebug dbg) const

virtual const protected

Stream operator for QDebug.

Reimplemented from print.

RLineData RLineEntity::data

protected