KiCad PCB EDA Suite
Loading...
Searching...
No Matches
KIGFX::DS_PAINTER Class Reference

Methods for painting drawing sheet items. More...

#include <ds_painter.h>

Inheritance diagram for KIGFX::DS_PAINTER:
KIGFX::PAINTER

Public Member Functions

 DS_PAINTER (GAL *aGal)
 
virtual bool Draw (const VIEW_ITEM *, int) override
 Takes an instance of VIEW_ITEM and passes it to a function that knows how to draw the item.
 
void DrawBorder (const PAGE_INFO *aPageInfo, int aScaleFactor) const
 
virtual RENDER_SETTINGSGetSettings () override
 Return a pointer to current settings that are going to be used when drawing items.
 
void SetGAL (GAL *aGal)
 Changes Graphics Abstraction Layer used for drawing items for a new one.
 

Protected Attributes

GALm_gal
 Instance of graphic abstraction layer that gives an interface to call commands used to draw (eg.
 

Private Member Functions

void draw (const DS_DRAW_ITEM_LINE *aItem, int aLayer) const
 
void draw (const DS_DRAW_ITEM_RECT *aItem, int aLayer) const
 
void draw (const DS_DRAW_ITEM_POLYPOLYGONS *aItem, int aLayer) const
 
void draw (const DS_DRAW_ITEM_TEXT *aItem, int aLayer) const
 
void draw (const DS_DRAW_ITEM_BITMAP *aItem, int aLayer) const
 
void draw (const DS_DRAW_ITEM_PAGE *aItem, int aLayer) const
 

Private Attributes

DS_RENDER_SETTINGS m_renderSettings
 

Detailed Description

Methods for painting drawing sheet items.

Definition at line 93 of file ds_painter.h.

Constructor & Destructor Documentation

◆ DS_PAINTER()

KIGFX::DS_PAINTER::DS_PAINTER ( GAL * aGal)
inline

Definition at line 96 of file ds_painter.h.

References KIGFX::PAINTER::PAINTER().

Member Function Documentation

◆ Draw()

bool KIGFX::DS_PAINTER::Draw ( const VIEW_ITEM * aItem,
int aLayer )
overridevirtual

Takes an instance of VIEW_ITEM and passes it to a function that knows how to draw the item.

Parameters
aItemis an item to be drawn.
aLayertells which layer is currently rendered so that draw functions may know what to draw (eg. for pads there are separate layers for holes, because they have other dimensions then the pad itself.

Implements KIGFX::PAINTER.

Definition at line 229 of file ds_painter.cpp.

References draw(), WSG_BITMAP_T, WSG_LINE_T, WSG_PAGE_T, WSG_POLY_T, WSG_RECT_T, and WSG_TEXT_T.

Referenced by DS_PROXY_VIEW_ITEM::ViewDraw().

◆ draw() [1/6]

◆ draw() [2/6]

void KIGFX::DS_PAINTER::draw ( const DS_DRAW_ITEM_LINE * aItem,
int aLayer ) const
private

◆ draw() [3/6]

void KIGFX::DS_PAINTER::draw ( const DS_DRAW_ITEM_PAGE * aItem,
int aLayer ) const
private

◆ draw() [4/6]

void KIGFX::DS_PAINTER::draw ( const DS_DRAW_ITEM_POLYPOLYGONS * aItem,
int aLayer ) const
private

◆ draw() [5/6]

void KIGFX::DS_PAINTER::draw ( const DS_DRAW_ITEM_RECT * aItem,
int aLayer ) const
private

◆ draw() [6/6]

◆ DrawBorder()

void KIGFX::DS_PAINTER::DrawBorder ( const PAGE_INFO * aPageInfo,
int aScaleFactor ) const

◆ GetSettings()

virtual RENDER_SETTINGS * KIGFX::DS_PAINTER::GetSettings ( )
inlineoverridevirtual

Return a pointer to current settings that are going to be used when drawing items.

Returns
Current rendering settings.

Implements KIGFX::PAINTER.

Definition at line 106 of file ds_painter.h.

References m_renderSettings.

Referenced by DS_PROXY_VIEW_ITEM::ViewDraw().

◆ SetGAL()

void KIGFX::PAINTER::SetGAL ( GAL * aGal)
inlineinherited

Changes Graphics Abstraction Layer used for drawing items for a new one.

Parameters
aGalis the new GAL instance.

Definition at line 72 of file painter.h.

References m_gal.

Member Data Documentation

◆ m_gal

GAL* KIGFX::PAINTER::m_gal
protectedinherited

Instance of graphic abstraction layer that gives an interface to call commands used to draw (eg.

DrawLine, DrawCircle, etc.)

Definition at line 98 of file painter.h.

Referenced by KIGFX::PCB_PAINTER::Draw(), ZONE_PAINTER::Draw(), KIGFX::DS_PAINTER::draw(), KIGFX::DS_PAINTER::draw(), KIGFX::DS_PAINTER::draw(), KIGFX::DS_PAINTER::draw(), KIGFX::DS_PAINTER::draw(), KIGFX::DS_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::SCH_PAINTER::drawAnchor(), KIGFX::GERBVIEW_PAINTER::drawApertureMacro(), KIGFX::PCB_PAINTER::drawBackdrillIndicator(), KIGFX::DS_PAINTER::DrawBorder(), KIGFX::SCH_PAINTER::drawDanglingIndicator(), KIGFX::GERBVIEW_PAINTER::drawFlashedShape(), KIGFX::SCH_PAINTER::drawItemBoundingBox(), KIGFX::SCH_PAINTER::drawLine(), KIGFX::SCH_PAINTER::drawLocalPowerIcon(), KIGFX::SCH_PAINTER::drawPinDanglingIndicator(), KIGFX::GERBVIEW_PAINTER::drawPolygon(), KIGFX::PCB_PAINTER::drawPostMachiningIndicator(), KIGFX::SCH_PAINTER::getOperatingPointTextSize(), KIGFX::SCH_PAINTER::getShadowWidth(), PAINTER(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), SetGAL(), KIGFX::PCB_PAINTER::strokeText(), and KIGFX::SCH_PAINTER::triLine().

◆ m_renderSettings

DS_RENDER_SETTINGS KIGFX::DS_PAINTER::m_renderSettings
private

Definition at line 117 of file ds_painter.h.

Referenced by draw(), draw(), draw(), draw(), draw(), DrawBorder(), and GetSettings().


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