LibrePCB Developers Documentation
PackageEditorState Class Referenceabstract

The PackageEditorState class is the base class of all package editor FSM states. More...

#include <packageeditorstate.h>

+ Inheritance diagram for PackageEditorState:
+ Collaboration diagram for PackageEditorState:

Public Types

using Context = PackageEditorFsm::Context
 

Signals

void availableFeaturesChanged ()
 
void statusBarMessageChanged (const QString &message, int timeoutMs=-1)
 

Public Member Functions

 PackageEditorState ()=delete
 
 PackageEditorState (const PackageEditorState &other)=delete
 
 PackageEditorState (Context &context) noexcept
 
virtual ~PackageEditorState () noexcept
 
virtual bool entry () noexcept
 
virtual bool exit () noexcept
 
virtual QSet< EditorWidgetBase::FeaturegetAvailableFeatures () const noexcept=0
 
virtual bool processKeyPressed (const QKeyEvent &e) noexcept
 
virtual bool processKeyReleased (const QKeyEvent &e) noexcept
 
virtual bool processGraphicsSceneMouseMoved (QGraphicsSceneMouseEvent &e) noexcept
 
virtual bool processGraphicsSceneLeftMouseButtonPressed (QGraphicsSceneMouseEvent &e) noexcept
 
virtual bool processGraphicsSceneLeftMouseButtonReleased (QGraphicsSceneMouseEvent &e) noexcept
 
virtual bool processGraphicsSceneLeftMouseButtonDoubleClicked (QGraphicsSceneMouseEvent &e) noexcept
 
virtual bool processGraphicsSceneRightMouseButtonReleased (QGraphicsSceneMouseEvent &e) noexcept
 
virtual bool processSelectAll () noexcept
 
virtual bool processCut () noexcept
 
virtual bool processCopy () noexcept
 
virtual bool processPaste () noexcept
 
virtual bool processMove (Qt::ArrowType direction)
 
virtual bool processRotate (const Angle &rotation) noexcept
 
virtual bool processMirror (Qt::Orientation orientation) noexcept
 
virtual bool processSnapToGrid () noexcept
 
virtual bool processFlip (Qt::Orientation orientation) noexcept
 
virtual bool processRemove () noexcept
 
virtual bool processEditProperties () noexcept
 
virtual bool processGenerateOutline () noexcept
 
virtual bool processGenerateCourtyard () noexcept
 
virtual bool processImportDxf () noexcept
 
virtual bool processAbortCommand () noexcept
 
PackageEditorStateoperator= (const PackageEditorState &rhs)=delete
 

Protected Member Functions

const PositiveLengthgetGridInterval () const noexcept
 
const LengthUnitgetLengthUnit () const noexcept
 

Static Protected Member Functions

static const QSet< const Layer * > & getAllowedTextLayers () noexcept
 
static const QSet< const Layer * > & getAllowedCircleAndPolygonLayers () noexcept
 

Protected Attributes

ContextmContext
 

Detailed Description

The PackageEditorState class is the base class of all package editor FSM states.

Member Typedef Documentation

◆ Context

Constructor & Destructor Documentation

◆ PackageEditorState() [1/3]

PackageEditorState ( )
delete

◆ PackageEditorState() [2/3]

PackageEditorState ( const PackageEditorState other)
delete

◆ PackageEditorState() [3/3]

PackageEditorState ( Context context)
explicitnoexcept

◆ ~PackageEditorState()

~PackageEditorState ( )
virtualnoexcept

Member Function Documentation

◆ entry()

◆ exit()

◆ getAvailableFeatures()

◆ processKeyPressed()

virtual bool processKeyPressed ( const QKeyEvent &  e)
inlinevirtualnoexcept

◆ processKeyReleased()

virtual bool processKeyReleased ( const QKeyEvent &  e)
inlinevirtualnoexcept

◆ processGraphicsSceneMouseMoved()

◆ processGraphicsSceneLeftMouseButtonPressed()

virtual bool processGraphicsSceneLeftMouseButtonPressed ( QGraphicsSceneMouseEvent &  e)
inlinevirtualnoexcept

◆ processGraphicsSceneLeftMouseButtonReleased()

virtual bool processGraphicsSceneLeftMouseButtonReleased ( QGraphicsSceneMouseEvent &  e)
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

◆ processGraphicsSceneLeftMouseButtonDoubleClicked()

virtual bool processGraphicsSceneLeftMouseButtonDoubleClicked ( QGraphicsSceneMouseEvent &  e)
inlinevirtualnoexcept

◆ processGraphicsSceneRightMouseButtonReleased()

virtual bool processGraphicsSceneRightMouseButtonReleased ( QGraphicsSceneMouseEvent &  e)
inlinevirtualnoexcept

Reimplemented in PackageEditorState_AddPads, PackageEditorState_DrawTextBase, and PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processSelectAll()

virtual bool processSelectAll ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processCut()

virtual bool processCut ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processCopy()

virtual bool processCopy ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Measure, and PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processPaste()

virtual bool processPaste ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processMove()

virtual bool processMove ( Qt::ArrowType  direction)
inlinevirtual

Reimplemented in PackageEditorState_Select.

◆ processRotate()

virtual bool processRotate ( const Angle rotation)
inlinevirtualnoexcept

◆ processMirror()

virtual bool processMirror ( Qt::Orientation  orientation)
inlinevirtualnoexcept

◆ processSnapToGrid()

virtual bool processSnapToGrid ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processFlip()

virtual bool processFlip ( Qt::Orientation  orientation)
inlinevirtualnoexcept

◆ processRemove()

virtual bool processRemove ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Measure, and PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processEditProperties()

virtual bool processEditProperties ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processGenerateOutline()

virtual bool processGenerateOutline ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processGenerateCourtyard()

virtual bool processGenerateCourtyard ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

+ Here is the caller graph for this function:

◆ processImportDxf()

virtual bool processImportDxf ( )
inlinevirtualnoexcept

Reimplemented in PackageEditorState_Select.

◆ processAbortCommand()

◆ operator=()

PackageEditorState & operator= ( const PackageEditorState rhs)
delete

◆ availableFeaturesChanged

void availableFeaturesChanged ( )
signal
+ Here is the caller graph for this function:

◆ statusBarMessageChanged

void statusBarMessageChanged ( const QString &  message,
int  timeoutMs = -1 
)
signal
+ Here is the caller graph for this function:

◆ getGridInterval()

const PositiveLength & getGridInterval ( ) const
protectednoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getLengthUnit()

const LengthUnit & getLengthUnit ( ) const
protectednoexcept
+ Here is the caller graph for this function:

◆ getAllowedTextLayers()

const QSet< const Layer * > & getAllowedTextLayers ( )
staticprotectednoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getAllowedCircleAndPolygonLayers()

const QSet< const Layer * > & getAllowedCircleAndPolygonLayers ( )
staticprotectednoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ mContext

Context& mContext
protected

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