KiCad PCB EDA Suite
Loading...
Searching...
No Matches
POLYGON_EDGE_DRAG_POLICY Class Reference

#include <edit_relations.h>

Public Member Functions

 POLYGON_EDGE_DRAG_POLICY (EDIT_LINE &aLine, EDIT_POINTS &aPoints, POLYGON_LINE_MODE aMode=POLYGON_LINE_MODE::CONVERGING)
 
void Apply (EDIT_LINE &aHandle, const GRID_HELPER &aGrid)
 
POLYGON_LINE_MODE GetMode () const
 
void SetMode (POLYGON_LINE_MODE aMode)
 
const VECTOR2IGetOriginalCenter () const
 
const VECTOR2IGetPerpVector () const
 

Private Member Functions

void applyConverging (EDIT_LINE &aHandle)
 
void applyFixedLength (EDIT_LINE &aHandle)
 

Private Attributes

POLYGON_LINE_MODE m_mode
 
EDIT_POINTSm_editPoints
 
VECTOR2I m_originSideDirection
 
VECTOR2I m_endSideDirection
 
VECTOR2I m_draggedVector
 
VECTOR2I m_originalCenter
 
VECTOR2I m_perpVector
 
double m_halfLength
 
bool m_originCollinear
 
bool m_endCollinear
 
EDIT_POINTm_prevOrigin
 
EDIT_POINTm_nextEnd
 
VECTOR2I m_convergencePoint
 

Detailed Description

Definition at line 104 of file edit_relations.h.

Constructor & Destructor Documentation

◆ POLYGON_EDGE_DRAG_POLICY()

Member Function Documentation

◆ Apply()

◆ applyConverging()

◆ applyFixedLength()

void POLYGON_EDGE_DRAG_POLICY::applyFixedLength ( EDIT_LINE & aHandle)
private

◆ GetMode()

POLYGON_LINE_MODE POLYGON_EDGE_DRAG_POLICY::GetMode ( ) const
inline

Definition at line 112 of file edit_relations.h.

References m_mode.

Referenced by BOOST_AUTO_TEST_CASE(), and PCB_POINT_EDITOR::OnSelectionChange().

◆ GetOriginalCenter()

const VECTOR2I & POLYGON_EDGE_DRAG_POLICY::GetOriginalCenter ( ) const
inline

Definition at line 115 of file edit_relations.h.

References m_originalCenter.

Referenced by PCB_POINT_EDITOR::OnSelectionChange().

◆ GetPerpVector()

const VECTOR2I & POLYGON_EDGE_DRAG_POLICY::GetPerpVector ( ) const
inline

Definition at line 116 of file edit_relations.h.

References m_perpVector.

Referenced by PCB_POINT_EDITOR::OnSelectionChange().

◆ SetMode()

void POLYGON_EDGE_DRAG_POLICY::SetMode ( POLYGON_LINE_MODE aMode)
inline

Definition at line 113 of file edit_relations.h.

References m_mode.

Referenced by PCB_POINT_EDITOR::OnSelectionChange(), and PCB_POINT_EDITOR::setAltConstraint().

Member Data Documentation

◆ m_convergencePoint

VECTOR2I POLYGON_EDGE_DRAG_POLICY::m_convergencePoint
private

Definition at line 134 of file edit_relations.h.

Referenced by Apply(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_draggedVector

VECTOR2I POLYGON_EDGE_DRAG_POLICY::m_draggedVector
private

◆ m_editPoints

EDIT_POINTS& POLYGON_EDGE_DRAG_POLICY::m_editPoints
private

Definition at line 123 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_endCollinear

bool POLYGON_EDGE_DRAG_POLICY::m_endCollinear
private

Definition at line 131 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_endSideDirection

VECTOR2I POLYGON_EDGE_DRAG_POLICY::m_endSideDirection
private

Definition at line 125 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_halfLength

double POLYGON_EDGE_DRAG_POLICY::m_halfLength
private

Definition at line 129 of file edit_relations.h.

Referenced by applyFixedLength(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_mode

POLYGON_LINE_MODE POLYGON_EDGE_DRAG_POLICY::m_mode
private

Definition at line 122 of file edit_relations.h.

Referenced by Apply(), GetMode(), POLYGON_EDGE_DRAG_POLICY(), and SetMode().

◆ m_nextEnd

EDIT_POINT* POLYGON_EDGE_DRAG_POLICY::m_nextEnd
private

Definition at line 133 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_originalCenter

VECTOR2I POLYGON_EDGE_DRAG_POLICY::m_originalCenter
private

Definition at line 127 of file edit_relations.h.

Referenced by Apply(), GetOriginalCenter(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_originCollinear

bool POLYGON_EDGE_DRAG_POLICY::m_originCollinear
private

Definition at line 130 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_originSideDirection

VECTOR2I POLYGON_EDGE_DRAG_POLICY::m_originSideDirection
private

Definition at line 124 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_perpVector

VECTOR2I POLYGON_EDGE_DRAG_POLICY::m_perpVector
private

Definition at line 128 of file edit_relations.h.

Referenced by Apply(), GetPerpVector(), and POLYGON_EDGE_DRAG_POLICY().

◆ m_prevOrigin

EDIT_POINT* POLYGON_EDGE_DRAG_POLICY::m_prevOrigin
private

Definition at line 132 of file edit_relations.h.

Referenced by applyConverging(), and POLYGON_EDGE_DRAG_POLICY().


The documentation for this class was generated from the following files: