RLineEntity
Class in Entity Module
Header: #include <src/entity/RLineEntity.h>
Inherits: REntity
Description
Section titled “Description”Line entity.
Scriptable: This class is available in script environments.
Shared Pointer Support: Objects can be used in QSharedPointer.
Public Functions
Section titled “Public Functions”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) constExports 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 Public Functions
Section titled “Static Public Functions”| static RS::EntityType | getRtti() |
| static QSet< RPropertyTypeId > | getStaticPropertyTypeIds() |
| static void | init() |
Static Public Attributes
Section titled “Static Public Attributes”Protected Functions
Section titled “Protected Functions”| virtual void | print(QDebug dbg) constStream operator for QDebug. |
Protected Attributes
Section titled “Protected Attributes”| RLineData | data |
Member Documentation
Section titled “Member Documentation”RLineEntity
Section titled “RLineEntity”RLineEntity::RLineEntity(const RLineEntity &other)RLineEntity
Section titled “RLineEntity”RLineEntity::RLineEntity(RDocument *document, const RLineData &data)~RLineEntity
Section titled “~RLineEntity”virtual RLineEntity::~RLineEntity()virtual
virtual QSharedPointer< RObject > RLineEntity::clone() constvirtual inline const
Reimplemented from clone.
cloneToLineEntity
Section titled “cloneToLineEntity”QSharedPointer< RLineEntity > RLineEntity::cloneToLineEntity() constinline const
exportEntity
Section titled “exportEntity”virtual void RLineEntity::exportEntity(RExporter &e, bool preview=false, bool forceSelected=false) constvirtual 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.
getAngle
Section titled “getAngle”double RLineEntity::getAngle() constinline const
getAngleAt
Section titled “getAngleAt”double RLineEntity::getAngleAt(double distance, RS::From from) constinline const
getData
Section titled “getData”virtual RLineData & RLineEntity::getData()virtual inline
Returns: Reference to the data object of the entity.
Reimplemented from getData.
getData
Section titled “getData”virtual const RLineData & RLineEntity::getData() constvirtual inline const
Returns: Const reference to the data object of the entity.
Reimplemented from getData.
getDirection1
Section titled “getDirection1”double RLineEntity::getDirection1() constinline const
getDirection2
Section titled “getDirection2”double RLineEntity::getDirection2() constinline const
getEndPoint
Section titled “getEndPoint”RVector RLineEntity::getEndPoint() constinline const
getLength
Section titled “getLength”double RLineEntity::getLength() constinline const
getMiddlePoint
Section titled “getMiddlePoint”RVector RLineEntity::getMiddlePoint() constinline const
getProperty
Section titled “getProperty”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.
getSideOfPoint
Section titled “getSideOfPoint”RS::Side RLineEntity::getSideOfPoint(const RVector &point) constinline const
getStartPoint
Section titled “getStartPoint”RVector RLineEntity::getStartPoint() constinline const
getTrimEnd
Section titled “getTrimEnd”RS::Ending RLineEntity::getTrimEnd(const RVector &trimPoint, const RVector &clickPoint)inline
reverse
Section titled “reverse”bool RLineEntity::reverse()inline
setEndPoint
Section titled “setEndPoint”void RLineEntity::setEndPoint(const RVector &p)inline
setProperty
Section titled “setProperty”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.
setShape
Section titled “setShape”void RLineEntity::setShape(const RLine &l)setStartPoint
Section titled “setStartPoint”void RLineEntity::setStartPoint(const RVector &p)inline
trimEndPoint
Section titled “trimEndPoint”bool RLineEntity::trimEndPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)inline
trimStartPoint
Section titled “trimStartPoint”bool RLineEntity::trimStartPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)inline
getRtti
Section titled “getRtti”static RS::EntityType RLineEntity::getRtti()static inline
getStaticPropertyTypeIds
Section titled “getStaticPropertyTypeIds”static QSet< RPropertyTypeId > RLineEntity::getStaticPropertyTypeIds()static inline
static void RLineEntity::init()static
PropertyAngle
Section titled “PropertyAngle”static RPropertyTypeId RLineEntity::PropertyAnglestatic
PropertyBlock
Section titled “PropertyBlock”static RPropertyTypeId RLineEntity::PropertyBlockstatic
PropertyColor
Section titled “PropertyColor”static RPropertyTypeId RLineEntity::PropertyColorstatic
PropertyCustom
Section titled “PropertyCustom”static RPropertyTypeId RLineEntity::PropertyCustomstatic
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.
PropertyDisplayedColor
Section titled “PropertyDisplayedColor”static RPropertyTypeId RLineEntity::PropertyDisplayedColorstatic
PropertyDrawOrder
Section titled “PropertyDrawOrder”static RPropertyTypeId RLineEntity::PropertyDrawOrderstatic
PropertyEndPointX
Section titled “PropertyEndPointX”static RPropertyTypeId RLineEntity::PropertyEndPointXstatic
PropertyEndPointY
Section titled “PropertyEndPointY”static RPropertyTypeId RLineEntity::PropertyEndPointYstatic
PropertyEndPointZ
Section titled “PropertyEndPointZ”static RPropertyTypeId RLineEntity::PropertyEndPointZstatic
PropertyHandle
Section titled “PropertyHandle”static RPropertyTypeId RLineEntity::PropertyHandlestatic
PropertyLayer
Section titled “PropertyLayer”static RPropertyTypeId RLineEntity::PropertyLayerstatic
PropertyLength
Section titled “PropertyLength”static RPropertyTypeId RLineEntity::PropertyLengthstatic
PropertyLinetype
Section titled “PropertyLinetype”static RPropertyTypeId RLineEntity::PropertyLinetypestatic
PropertyLinetypeScale
Section titled “PropertyLinetypeScale”static RPropertyTypeId RLineEntity::PropertyLinetypeScalestatic
PropertyLineweight
Section titled “PropertyLineweight”static RPropertyTypeId RLineEntity::PropertyLineweightstatic
PropertyMiddlePointX
Section titled “PropertyMiddlePointX”static RPropertyTypeId RLineEntity::PropertyMiddlePointXstatic
PropertyMiddlePointY
Section titled “PropertyMiddlePointY”static RPropertyTypeId RLineEntity::PropertyMiddlePointYstatic
PropertyMiddlePointZ
Section titled “PropertyMiddlePointZ”static RPropertyTypeId RLineEntity::PropertyMiddlePointZstatic
PropertyProtected
Section titled “PropertyProtected”static RPropertyTypeId RLineEntity::PropertyProtectedstatic
PropertyStartPointX
Section titled “PropertyStartPointX”static RPropertyTypeId RLineEntity::PropertyStartPointXstatic
PropertyStartPointY
Section titled “PropertyStartPointY”static RPropertyTypeId RLineEntity::PropertyStartPointYstatic
PropertyStartPointZ
Section titled “PropertyStartPointZ”static RPropertyTypeId RLineEntity::PropertyStartPointZstatic
PropertyTotalLength
Section titled “PropertyTotalLength”static RPropertyTypeId RLineEntity::PropertyTotalLengthstatic
PropertyType
Section titled “PropertyType”static RPropertyTypeId RLineEntity::PropertyTypestatic
PropertyWorkingSet
Section titled “PropertyWorkingSet”static RPropertyTypeId RLineEntity::PropertyWorkingSetstatic
virtual void RLineEntity::print(QDebug dbg) constvirtual const protected
Stream operator for QDebug.
Reimplemented from print.
RLineData RLineEntity::dataprotected