LibrePCB Developers Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FootprintGraphicsItem Class Referencefinal

The FootprintGraphicsItem class. More...

#include <footprintgraphicsitem.h>

Inherits QGraphicsItem.

+ Collaboration diagram for FootprintGraphicsItem:

Public Member Functions

 FootprintGraphicsItem ()=delete
 
 FootprintGraphicsItem (const FootprintGraphicsItem &other)=delete
 
 FootprintGraphicsItem (Footprint &fpt, const IF_GraphicsLayerProvider &lp) noexcept
 
 ~FootprintGraphicsItem () noexcept
 
FootprintgetFootprint () noexcept
 
FootprintPadGraphicsItemgetPadGraphicsItem (const FootprintPad &pin) noexcept
 
CircleGraphicsItemgetCircleGraphicsItem (const Circle &circle) noexcept
 
PolygonGraphicsItemgetPolygonGraphicsItem (const Polygon &polygon) noexcept
 
StrokeTextGraphicsItemgetTextGraphicsItem (const StrokeText &text) noexcept
 
HoleGraphicsItemgetHoleGraphicsItem (const Hole &hole) noexcept
 
int getItemsAtPosition (const Point &pos, QList< QSharedPointer< FootprintPadGraphicsItem >> *pads, QList< QSharedPointer< CircleGraphicsItem >> *circles, QList< QSharedPointer< PolygonGraphicsItem >> *polygons, QList< QSharedPointer< StrokeTextGraphicsItem >> *texts, QList< QSharedPointer< HoleGraphicsItem >> *holes) noexcept
 
QList< QSharedPointer
< FootprintPadGraphicsItem > > 
getSelectedPads () noexcept
 
QList< QSharedPointer
< CircleGraphicsItem > > 
getSelectedCircles () noexcept
 
QList< QSharedPointer
< PolygonGraphicsItem > > 
getSelectedPolygons () noexcept
 
QList< QSharedPointer
< StrokeTextGraphicsItem > > 
getSelectedStrokeTexts () noexcept
 
QList< QSharedPointer
< HoleGraphicsItem > > 
getSelectedHoles () noexcept
 
void setPosition (const Point &pos) noexcept
 
void setRotation (const Angle &rot) noexcept
 
void addPad (FootprintPad &pad) noexcept
 
void removePad (FootprintPad &pad) noexcept
 
void addCircle (Circle &circle) noexcept
 
void removeCircle (Circle &circle) noexcept
 
void addPolygon (Polygon &polygon) noexcept
 
void removePolygon (Polygon &polygon) noexcept
 
void addStrokeText (StrokeText &text) noexcept
 
void removeStrokeText (StrokeText &text) noexcept
 
void addHole (Hole &hole) noexcept
 
void removeHole (Hole &hole) noexcept
 
void setSelectionRect (const QRectF rect) noexcept
 
QRectF boundingRect () const noexceptoverride
 
QPainterPath shape () const noexceptoverride
 
void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0) noexceptoverride
 
FootprintGraphicsItemoperator= (const FootprintGraphicsItem &rhs)=delete
 

Private Attributes

FootprintmFootprint
 
const IF_GraphicsLayerProvidermLayerProvider
 
QHash< const FootprintPad
*, QSharedPointer
< FootprintPadGraphicsItem > > 
mPadGraphicsItems
 
QHash< const Circle
*, QSharedPointer
< CircleGraphicsItem > > 
mCircleGraphicsItems
 
QHash< const Polygon
*, QSharedPointer
< PolygonGraphicsItem > > 
mPolygonGraphicsItems
 
QHash< const StrokeText
*, QSharedPointer
< StrokeTextGraphicsItem > > 
mStrokeTextGraphicsItems
 
QHash< const Hole
*, QSharedPointer
< HoleGraphicsItem > > 
mHoleGraphicsItems
 

Detailed Description

The FootprintGraphicsItem class.

Author
ubruhin
Date
2017-05-28

Constructor & Destructor Documentation

FootprintGraphicsItem ( const FootprintGraphicsItem other)
delete
FootprintGraphicsItem ( Footprint fpt,
const IF_GraphicsLayerProvider lp 
)
noexcept
~FootprintGraphicsItem ( )
noexcept

+ Here is the call graph for this function:

Member Function Documentation

Footprint& getFootprint ( )
inlinenoexcept
FootprintPadGraphicsItem * getPadGraphicsItem ( const FootprintPad pin)
noexcept
CircleGraphicsItem * getCircleGraphicsItem ( const Circle circle)
noexcept
PolygonGraphicsItem * getPolygonGraphicsItem ( const Polygon polygon)
noexcept
StrokeTextGraphicsItem * getTextGraphicsItem ( const StrokeText text)
noexcept
HoleGraphicsItem * getHoleGraphicsItem ( const Hole hole)
noexcept
int getItemsAtPosition ( const Point pos,
QList< QSharedPointer< FootprintPadGraphicsItem >> *  pads,
QList< QSharedPointer< CircleGraphicsItem >> *  circles,
QList< QSharedPointer< PolygonGraphicsItem >> *  polygons,
QList< QSharedPointer< StrokeTextGraphicsItem >> *  texts,
QList< QSharedPointer< HoleGraphicsItem >> *  holes 
)
noexcept

+ Here is the call graph for this function:

QList< QSharedPointer< FootprintPadGraphicsItem > > getSelectedPads ( )
noexcept
QList< QSharedPointer< CircleGraphicsItem > > getSelectedCircles ( )
noexcept
QList< QSharedPointer< PolygonGraphicsItem > > getSelectedPolygons ( )
noexcept
QList< QSharedPointer< StrokeTextGraphicsItem > > getSelectedStrokeTexts ( )
noexcept
QList< QSharedPointer< HoleGraphicsItem > > getSelectedHoles ( )
noexcept
void setPosition ( const Point pos)
noexcept
void setRotation ( const Angle rot)
noexcept
void addPad ( FootprintPad pad)
noexcept
void removePad ( FootprintPad pad)
noexcept
void addCircle ( Circle circle)
noexcept
void removeCircle ( Circle circle)
noexcept
void addPolygon ( Polygon polygon)
noexcept
void removePolygon ( Polygon polygon)
noexcept
void addStrokeText ( StrokeText text)
noexcept
void removeStrokeText ( StrokeText text)
noexcept
void addHole ( Hole hole)
noexcept
void removeHole ( Hole hole)
noexcept
void setSelectionRect ( const QRectF  rect)
noexcept
QRectF boundingRect ( ) const
inlineoverridenoexcept
QPainterPath shape ( ) const
inlineoverridenoexcept
void paint ( QPainter *  painter,
const QStyleOptionGraphicsItem *  option,
QWidget *  widget = 0 
)
overridenoexcept
FootprintGraphicsItem& operator= ( const FootprintGraphicsItem rhs)
delete

Member Data Documentation

Footprint& mFootprint
private
const IF_GraphicsLayerProvider& mLayerProvider
private
QHash<const FootprintPad*, QSharedPointer<FootprintPadGraphicsItem> > mPadGraphicsItems
private
QHash<const Circle*, QSharedPointer<CircleGraphicsItem> > mCircleGraphicsItems
private
QHash<const Polygon*, QSharedPointer<PolygonGraphicsItem> > mPolygonGraphicsItems
private
QHash<const StrokeText*, QSharedPointer<StrokeTextGraphicsItem> > mStrokeTextGraphicsItems
private
QHash<const Hole*, QSharedPointer<HoleGraphicsItem> > mHoleGraphicsItems
private

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