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

PCB specific render settings. More...

#include <pcb_painter.h>

Inheritance diagram for KIGFX::PCB_RENDER_SETTINGS:
KIGFX::RENDER_SETTINGS

Public Member Functions

 PCB_RENDER_SETTINGS ()
 
void LoadDisplayOptions (const PCB_DISPLAY_OPTIONS &aOptions)
 Load settings related to display options (high-contrast mode, full or outline modes for vias/pads/tracks and so on).
 
void LoadColors (const COLOR_SETTINGS *aSettings) override
 
COLOR4D GetColor (const VIEW_ITEM *aItem, int aLayer) const override
 Returns the color that should be used to draw the specific VIEW_ITEM on the specific layer using currently used render settings.
 
COLOR4D GetColor (const BOARD_ITEM *aItem, int aLayer) const
 nullptr version
 
COLOR4D GetColor (std::nullptr_t, int aLayer) const
 
bool GetShowPageLimits () const override
 
bool IsBackgroundDark () const override
 
const COLOR4DGetBackgroundColor () const override
 Return current background color settings.
 
void SetBackgroundColor (const COLOR4D &aColor) override
 Set the background color.
 
const COLOR4DGetGridColor () override
 Return current grid color settings.
 
const COLOR4DGetCursorColor () override
 Return current cursor color settings.
 
NET_COLOR_MODE GetNetColorMode () const
 
void SetNetColorMode (NET_COLOR_MODE aMode)
 
std::map< int, KIGFX::COLOR4D > & GetNetColorMap ()
 
std::set< int > & GetHiddenNets ()
 
const std::set< int > & GetHiddenNets () const
 
void SetLayerIsHighContrast (int aLayerId, bool aEnabled=true)
 Set the specified layer as high-contrast.
 
bool GetLayerIsHighContrast (int aLayerId) const
 Return information whether the queried layer is marked as high-contrast.
 
const std::set< int > GetHighContrastLayers () const
 Returns the set of currently high-contrast layers.
 
PCB_LAYER_ID GetPrimaryHighContrastLayer () const
 Return the board layer which is in high-contrast mode.
 
PCB_LAYER_ID GetActiveLayer () const
 
void SetActiveLayer (PCB_LAYER_ID aLayer)
 
const wxString & GetLayerName () const
 
void SetLayerName (const wxString &aLayerName)
 
LSET GetPrintLayers () const
 
void SetPrintLayers (LSET aLayerSet)
 
void ClearHighContrastLayers ()
 Clear the list of active layers.
 
bool IsHighlightEnabled () const
 Return current highlight setting.
 
const std::set< int > & GetHighlightNetCodes () const
 Return the netcode of currently highlighted net.
 
void SetHighlight (bool aEnabled, int aNetcode=-1, bool aMulti=false)
 Turns on/off highlighting.
 
void SetHighlight (std::set< int > &aHighlight, bool aEnabled=true)
 Turns on highlighting and highlights multiple nets.
 
void SetHighContrast (bool aEnabled)
 Turns on/off high contrast display mode.
 
bool GetHighContrast () const
 
void SetDrawBoundingBoxes (bool aEnabled)
 
bool GetDrawBoundingBoxes () const
 
float GetDrawingSheetLineWidth () const
 
int GetDefaultPenWidth () const
 
void SetDefaultPenWidth (int aWidth)
 
int GetMinPenWidth () const
 
void SetMinPenWidth (int aWidth)
 
double GetDashLengthRatio () const
 
void SetDashLengthRatio (double aRatio)
 
double GetDashLength (int aLineWidth) const
 
double GetDotLength (int aLineWidth) const
 
double GetGapLengthRatio () const
 
void SetGapLengthRatio (double aRatio)
 
double GetGapLength (int aLineWidth) const
 
bool IsPrinting () const
 
void SetIsPrinting (bool isPrinting)
 
bool IsPrintBlackAndWhite () const
 
void SetPrintBlackAndWhite (bool aPrintBlackAndWhite)
 
bool PrintBlackAndWhiteReq () const
 
const COLOR4DGetLayerColor (int aLayer) const
 Return the color used to draw a layer.
 
void SetLayerColor (int aLayer, const COLOR4D &aColor)
 Change the color used to draw a layer.
 
void SetOutlineWidth (float aWidth)
 Set line width used for drawing outlines.
 
float GetOutlineWidth () const
 
void SetHighlightFactor (float aFactor)
 
void SetSelectFactor (float aFactor)
 
void SetDefaultFont (const wxString &aFont)
 
const wxString & GetDefaultFont () const
 
wxDC * GetPrintDC () const
 
void SetPrintDC (wxDC *aDC)
 

Public Attributes

bool m_ForcePadSketchModeOn
 
bool m_ForceShowFieldsWhenFPSelected
 
ZONE_DISPLAY_MODE m_ZoneDisplayMode
 
HIGH_CONTRAST_MODE m_ContrastModeDisplay
 
PADm_PadEditModePad
 

Protected Member Functions

virtual void update ()
 Precalculates extra colors for layers (e.g.
 

Protected Attributes

NET_COLOR_MODE m_netColorMode
 Overrides for specific netclass colors.
 
std::map< wxString, KIGFX::COLOR4Dm_netclassColors
 Overrides for specific net colors, stored as netcodes for the ratsnest to access easily.
 
std::map< int, KIGFX::COLOR4Dm_netColors
 Set of net codes that should not have their ratsnest displayed.
 
std::set< int > m_hiddenNets
 
double m_trackOpacity
 Opacity override for all tracks.
 
double m_viaOpacity
 Opacity override for all types of via.
 
double m_padOpacity
 Opacity override for SMD pads and PTHs.
 
double m_zoneOpacity
 Opacity override for filled zones.
 
double m_imageOpacity
 Opacity override for user images.
 
double m_filledShapeOpacity
 Opacity override for graphic shapes.
 
PCB_LAYER_ID m_activeLayer
 
wxString m_layerName
 
std::set< int > m_highContrastLayers
 
COLOR4D m_layerColors [LAYER_ID_COUNT]
 
COLOR4D m_layerColorsHi [LAYER_ID_COUNT]
 
COLOR4D m_layerColorsSel [LAYER_ID_COUNT]
 
COLOR4D m_hiContrastColor [LAYER_ID_COUNT]
 
COLOR4D m_layerColorsDark [LAYER_ID_COUNT]
 
COLOR4D m_backgroundColor
 
bool m_hiContrastEnabled
 Parameters for display modes.
 
float m_hiContrastFactor
 
bool m_highlightEnabled
 
std::set< int > m_highlightNetcodes
 
float m_highlightFactor
 
bool m_drawBoundingBoxes
 
float m_selectFactor
 
float m_outlineWidth
 
float m_drawingSheetLineWidth
 
int m_defaultPenWidth
 
int m_minPenWidth
 
double m_dashLengthRatio
 
double m_gapLengthRatio
 
wxString m_defaultFont
 
bool m_isPrinting
 
bool m_printBlackAndWite
 
LSET m_printLayers
 
wxDC * m_printDC
 

Static Protected Attributes

static const double MAX_FONT_SIZE = pcbIUScale.mmToIU( 10.0 )
 < Maximum font size for netnames (and other dynamically shown strings)
 

Friends

class PCB_PAINTER
 

Detailed Description

PCB specific render settings.

Definition at line 77 of file pcb_painter.h.

Constructor & Destructor Documentation

◆ PCB_RENDER_SETTINGS()

Member Function Documentation

◆ ClearHighContrastLayers()

void KIGFX::RENDER_SETTINGS::ClearHighContrastLayers ( )
inlineinherited

◆ GetActiveLayer()

PCB_LAYER_ID KIGFX::RENDER_SETTINGS::GetActiveLayer ( ) const
inlineinherited

Definition at line 113 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_activeLayer.

Referenced by KIGFX::PCB_PAINTER::draw(), and GetColor().

◆ GetBackgroundColor()

const COLOR4D & KIGFX::PCB_RENDER_SETTINGS::GetBackgroundColor ( ) const
inlineoverridevirtual

Return current background color settings.

Implements KIGFX::RENDER_SETTINGS.

Definition at line 115 of file pcb_painter.h.

References LAYER_PCB_BACKGROUND, and KIGFX::RENDER_SETTINGS::m_layerColors.

Referenced by FOOTPRINT_PREVIEW_PANEL::GetBackgroundColor().

◆ GetColor() [1/3]

COLOR4D PCB_RENDER_SETTINGS::GetColor ( const BOARD_ITEM aItem,
int  aLayer 
) const

nullptr version

Definition at line 198 of file pcb_painter.cpp.

References LSET::AllCuMask(), B_Cu, B_Mask, KIGFX::COLOR4D::Brighten(), KIGFX::COLOR4D::CLEAR, color, KIGFX::COLOR4D::Darken(), Edge_Cuts, F_Cu, F_Mask, KIGFX::RENDER_SETTINGS::GetActiveLayer(), BOARD_ITEM::GetBoard(), BOARD_CONNECTED_ITEM::GetEffectiveNetClass(), BOARD::GetEnabledLayers(), KIGFX::VIEW_ITEM::GetForcedTransparency(), BOARD_ITEM::GetLayerSet(), BOARD_CONNECTED_ITEM::GetNetCode(), GetNetnameLayer(), NETCLASS::GetPcbColor(), KIGFX::RENDER_SETTINGS::GetPrimaryHighContrastLayer(), BOARD::GetVisibleLayers(), NETCLASS::HasPcbColor(), EDA_ITEM::IsBrightened(), BOARD_ITEM::IsConnected(), IsCopperLayer(), IsHoleLayer(), IsNetnameLayer(), BOARD_ITEM::IsOnCopperLayer(), EDA_ITEM::IsSelected(), IsZoneFillLayer(), LAYER_DRC_ERROR, LAYER_DRC_EXCLUSION, LAYER_DRC_WARNING, LAYER_MARKER_SHADOWS, LAYER_NON_PLATEDHOLES, LAYER_PAD_BK_NETNAMES, LAYER_PAD_FR_NETNAMES, LAYER_PAD_HOLEWALLS, LAYER_PAD_PLATEDHOLES, LAYER_PADS, LAYER_PCB_BACKGROUND, LAYER_VIA_BBLIND, LAYER_VIA_HOLES, LAYER_VIA_HOLEWALLS, LAYER_VIA_MICROVIA, LAYER_VIA_THROUGH, LAYER_ZONE_START, KIGFX::RENDER_SETTINGS::m_backgroundColor, m_ContrastModeDisplay, m_filledShapeOpacity, KIGFX::RENDER_SETTINGS::m_hiContrastEnabled, KIGFX::RENDER_SETTINGS::m_hiContrastFactor, KIGFX::RENDER_SETTINGS::m_highContrastLayers, KIGFX::RENDER_SETTINGS::m_highlightEnabled, KIGFX::RENDER_SETTINGS::m_highlightFactor, KIGFX::RENDER_SETTINGS::m_highlightNetcodes, m_imageOpacity, KIGFX::RENDER_SETTINGS::m_isPrinting, KIGFX::RENDER_SETTINGS::m_layerColors, KIGFX::RENDER_SETTINGS::m_layerColorsDark, KIGFX::RENDER_SETTINGS::m_layerColorsHi, KIGFX::RENDER_SETTINGS::m_layerColorsSel, m_netColorMode, m_netColors, m_PadEditModePad, m_padOpacity, KIGFX::RENDER_SETTINGS::m_selectFactor, m_trackOpacity, m_viaOpacity, m_zoneOpacity, pad, PCB_ARC_T, PCB_PAD_T, PCB_REFERENCE_IMAGE_T, PCB_SHAPE_T, PCB_TRACE_T, PCB_VIA_T, PCB_ZONE_T, LSET::PhysicalLayersMask(), LSET::Seq(), EDA_ITEM::Type(), UNDEFINED_LAYER, KIGFX::COLOR4D::UNSPECIFIED, via, and KIGFX::COLOR4D::WithAlpha().

◆ GetColor() [2/3]

COLOR4D PCB_RENDER_SETTINGS::GetColor ( const VIEW_ITEM aItem,
int  aLayer 
) const
overridevirtual

Returns the color that should be used to draw the specific VIEW_ITEM on the specific layer using currently used render settings.

Parameters
aItemis the VIEW_ITEM.
aLayeris the layer.
Returns
The color. Board-specific version

Implements KIGFX::RENDER_SETTINGS.

Definition at line 192 of file pcb_painter.cpp.

References GetColor().

Referenced by PNS_KICAD_IFACE::DisplayRatline(), KIGFX::PCB_PAINTER::draw(), and GetColor().

◆ GetColor() [3/3]

COLOR4D KIGFX::PCB_RENDER_SETTINGS::GetColor ( std::nullptr_t  ,
int  aLayer 
) const
inline

Definition at line 101 of file pcb_painter.h.

References GetColor().

◆ GetCursorColor()

const COLOR4D & KIGFX::PCB_RENDER_SETTINGS::GetCursorColor ( )
inlineoverridevirtual

Return current cursor color settings.

Implements KIGFX::RENDER_SETTINGS.

Definition at line 124 of file pcb_painter.h.

References LAYER_CURSOR, and KIGFX::RENDER_SETTINGS::m_layerColors.

◆ GetDashLength()

double RENDER_SETTINGS::GetDashLength ( int  aLineWidth) const
inherited

◆ GetDashLengthRatio()

double KIGFX::RENDER_SETTINGS::GetDashLengthRatio ( ) const
inlineinherited

Definition at line 216 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_dashLengthRatio.

◆ GetDefaultFont()

◆ GetDefaultPenWidth()

◆ GetDotLength()

double RENDER_SETTINGS::GetDotLength ( int  aLineWidth) const
inherited

Definition at line 73 of file render_settings.cpp.

References correction.

Referenced by PLOTTER::GetDotMarkLenIU(), and STROKE_PARAMS::Stroke().

◆ GetDrawBoundingBoxes()

bool KIGFX::RENDER_SETTINGS::GetDrawBoundingBoxes ( ) const
inlineinherited

◆ GetDrawingSheetLineWidth()

float KIGFX::RENDER_SETTINGS::GetDrawingSheetLineWidth ( ) const
inlineinherited

◆ GetGapLength()

double RENDER_SETTINGS::GetGapLength ( int  aLineWidth) const
inherited

◆ GetGapLengthRatio()

double KIGFX::RENDER_SETTINGS::GetGapLengthRatio ( ) const
inlineinherited

Definition at line 221 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_gapLengthRatio.

◆ GetGridColor()

const COLOR4D & KIGFX::PCB_RENDER_SETTINGS::GetGridColor ( )
inlineoverridevirtual

Return current grid color settings.

Implements KIGFX::RENDER_SETTINGS.

Definition at line 122 of file pcb_painter.h.

References LAYER_GRID, and KIGFX::RENDER_SETTINGS::m_layerColors.

◆ GetHiddenNets() [1/2]

std::set< int > & KIGFX::PCB_RENDER_SETTINGS::GetHiddenNets ( )
inline

◆ GetHiddenNets() [2/2]

const std::set< int > & KIGFX::PCB_RENDER_SETTINGS::GetHiddenNets ( ) const
inline

Definition at line 132 of file pcb_painter.h.

References m_hiddenNets.

◆ GetHighContrast()

◆ GetHighContrastLayers()

const std::set< int > KIGFX::RENDER_SETTINGS::GetHighContrastLayers ( ) const
inlineinherited

◆ GetHighlightNetCodes()

const std::set< int > & KIGFX::RENDER_SETTINGS::GetHighlightNetCodes ( ) const
inlineinherited

◆ GetLayerColor()

const COLOR4D & KIGFX::RENDER_SETTINGS::GetLayerColor ( int  aLayer) const
inlineinherited

Return the color used to draw a layer.

Parameters
aLayeris the layer number.

Definition at line 266 of file render_settings.h.

References LAYER_GLOBLABEL, LAYER_INTERSHEET_REFS, and KIGFX::RENDER_SETTINGS::m_layerColors.

Referenced by DIALOG_PIN_PROPERTIES::DIALOG_PIN_PROPERTIES(), KIGFX::PCB_PAINTER::draw(), KIGFX::PREVIEW::DRAW_CONTEXT::DrawCircle(), KIGFX::PREVIEW::DRAW_CONTEXT::DrawCircleDashed(), SCH_EDIT_FRAME::DrawCurrentSheetToClipboard(), KIGFX::PREVIEW::DRAW_CONTEXT::DrawLine(), KIGFX::PREVIEW::DRAW_CONTEXT::DrawLineDashed(), KIGFX::PREVIEW::DRAW_CONTEXT::DrawLineWithAngleHighlight(), BOARD_PRINTOUT::DrawPage(), KIGFX::PREVIEW::POLYGON_ITEM::drawPreviewShape(), KIGFX::PREVIEW::DrawTextNextToCursor(), FOOTPRINT_PREVIEW_PANEL::GetForegroundColor(), KIGFX::SCH_PAINTER::getRenderColor(), GRID_HELPER::GRID_HELPER(), DIALOG_SHAPE_PROPERTIES::onBorderSwatch(), DIALOG_SHAPE_PROPERTIES::onFillRadioButton(), RULE_AREA_CREATE_HELPER::OnFirstPoint(), PCB_GRID_HELPER::PCB_GRID_HELPER(), LIB_SYMBOL::Plot(), SCH_BITMAP::Plot(), SCH_BUS_ENTRY_BASE::Plot(), SCH_FIELD::Plot(), SCH_JUNCTION::Plot(), SCH_LABEL_BASE::Plot(), SCH_LINE::Plot(), SCH_NO_CONNECT::Plot(), SCH_RULE_AREA::Plot(), SCH_SHAPE::Plot(), SCH_SHEET::Plot(), SCH_TABLE::Plot(), SCH_TEXT::Plot(), SCH_TEXTBOX::Plot(), LIB_SYMBOL::PlotFields(), SCH_PLOTTER::plotOneSheetDXF(), SCH_PLOTTER::plotOneSheetPDF(), SCH_PLOTTER::plotOneSheetPS(), SCH_PLOTTER::plotOneSheetSVG(), SCH_PIN::PlotPinTexts(), SCH_PIN::PlotPinType(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), SCH_BUS_ENTRY_BASE::Print(), SCH_FIELD::Print(), SCH_JUNCTION::Print(), SCH_LINE::Print(), SCH_NO_CONNECT::Print(), SCH_PIN::Print(), SCH_SHAPE::Print(), SCH_SHEET::Print(), SCH_SYMBOL::Print(), SCH_LABEL_BASE::Print(), SCH_TABLE::Print(), SCH_TEXT::Print(), SCH_TEXTBOX::Print(), SCH_SHAPE::PrintBackground(), SCH_PRINTOUT::PrintPage(), SCH_PIN::printPinElectricalTypeName(), SCH_PIN::printPinSymbol(), SCH_PIN::printPinTexts(), DS_DRAW_ITEM_LINE::PrintWsItem(), DS_DRAW_ITEM_POLYPOLYGONS::PrintWsItem(), DS_DRAW_ITEM_RECT::PrintWsItem(), DS_DRAW_ITEM_TEXT::PrintWsItem(), StartPlotBoard(), DIALOG_SHAPE_PROPERTIES::TransferDataToWindow(), DIALOG_PAGES_SETTINGS::UpdateDrawingSheetExample(), DS_PROXY_VIEW_ITEM::ViewDraw(), EDIT_POINTS::ViewDraw(), KIGFX::PREVIEW::RULER_ITEM::ViewDraw(), and KIGFX::ANCHOR_DEBUG::ViewDraw().

◆ GetLayerIsHighContrast()

bool KIGFX::RENDER_SETTINGS::GetLayerIsHighContrast ( int  aLayerId) const
inlineinherited

Return information whether the queried layer is marked as high-contrast.

Returns
True if the queried layer is marked as active.

Definition at line 83 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_highContrastLayers.

Referenced by PCB_REFERENCE_IMAGE::ViewGetLOD().

◆ GetLayerName()

const wxString & KIGFX::RENDER_SETTINGS::GetLayerName ( ) const
inlineinherited

◆ GetMinPenWidth()

◆ GetNetColorMap()

std::map< int, KIGFX::COLOR4D > & KIGFX::PCB_RENDER_SETTINGS::GetNetColorMap ( )
inline

◆ GetNetColorMode()

NET_COLOR_MODE KIGFX::PCB_RENDER_SETTINGS::GetNetColorMode ( ) const
inline

Definition at line 126 of file pcb_painter.h.

References m_netColorMode.

Referenced by PNS_KICAD_IFACE::DisplayRatline().

◆ GetOutlineWidth()

float KIGFX::RENDER_SETTINGS::GetOutlineWidth ( ) const
inlineinherited

Definition at line 299 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_outlineWidth.

◆ GetPrimaryHighContrastLayer()

PCB_LAYER_ID KIGFX::RENDER_SETTINGS::GetPrimaryHighContrastLayer ( ) const
inlineinherited

Return the board layer which is in high-contrast mode.

There should only be one board layer which is high-contrast at any given time, although there might be many high-contrast synthetic (GAL) layers.

Definition at line 102 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_highContrastLayers, PCB_LAYER_ID_COUNT, PCBNEW_LAYER_ID_START, and UNDEFINED_LAYER.

Referenced by GetColor(), BOARD_INSPECTION_TOOL::highlightNet(), PNS_KICAD_IFACE::IsItemVisible(), PAD::ViewGetLOD(), PCB_SHAPE::ViewGetLOD(), PCB_TEXT::ViewGetLOD(), PCB_TEXTBOX::ViewGetLOD(), PCB_TRACK::ViewGetLOD(), and PCB_VIA::ViewGetLOD().

◆ GetPrintDC()

◆ GetPrintLayers()

LSET KIGFX::RENDER_SETTINGS::GetPrintLayers ( ) const
inlineinherited

Definition at line 119 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_printLayers.

Referenced by KIGFX::PCB_PAINTER::draw().

◆ GetShowPageLimits()

bool PCB_RENDER_SETTINGS::GetShowPageLimits ( ) const
overridevirtual

Reimplemented from KIGFX::RENDER_SETTINGS.

Definition at line 508 of file pcb_painter.cpp.

References PCBNEW_SETTINGS::m_ShowPageLimits, and pcbconfig().

◆ IsBackgroundDark()

bool KIGFX::PCB_RENDER_SETTINGS::IsBackgroundDark ( ) const
inlineoverridevirtual

◆ IsHighlightEnabled()

bool KIGFX::RENDER_SETTINGS::IsHighlightEnabled ( ) const
inlineinherited

Return current highlight setting.

Returns
True if highlight is enabled, false otherwise.

Definition at line 135 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_highlightEnabled.

Referenced by PCB_EDIT_FRAME::ExecuteRemoteCommand(), and PNS::TOOL_BASE::highlightNets().

◆ IsPrintBlackAndWhite()

bool KIGFX::RENDER_SETTINGS::IsPrintBlackAndWhite ( ) const
inlineinherited

Definition at line 230 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_printBlackAndWite.

◆ IsPrinting()

bool KIGFX::RENDER_SETTINGS::IsPrinting ( ) const
inlineinherited

◆ LoadColors()

◆ LoadDisplayOptions()

◆ PrintBlackAndWhiteReq()

bool KIGFX::RENDER_SETTINGS::PrintBlackAndWhiteReq ( ) const
inlineinherited

◆ SetActiveLayer()

void KIGFX::RENDER_SETTINGS::SetActiveLayer ( PCB_LAYER_ID  aLayer)
inlineinherited

◆ SetBackgroundColor()

void KIGFX::PCB_RENDER_SETTINGS::SetBackgroundColor ( const COLOR4D aColor)
inlineoverridevirtual

Set the background color.

Implements KIGFX::RENDER_SETTINGS.

Definition at line 117 of file pcb_painter.h.

References LAYER_PCB_BACKGROUND, and KIGFX::RENDER_SETTINGS::m_layerColors.

Referenced by LoadColors().

◆ SetDashLengthRatio()

◆ SetDefaultFont()

◆ SetDefaultPenWidth()

◆ SetDrawBoundingBoxes()

void KIGFX::RENDER_SETTINGS::SetDrawBoundingBoxes ( bool  aEnabled)
inlineinherited

◆ SetGapLengthRatio()

◆ SetHighContrast()

void KIGFX::RENDER_SETTINGS::SetHighContrast ( bool  aEnabled)
inlineinherited

Turns on/off high contrast display mode.

Definition at line 192 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_hiContrastEnabled.

Referenced by GERBVIEW_FRAME::ApplyDisplaySettingsToGAL().

◆ SetHighlight() [1/2]

void KIGFX::RENDER_SETTINGS::SetHighlight ( bool  aEnabled,
int  aNetcode = -1,
bool  aMulti = false 
)
inlineinherited

◆ SetHighlight() [2/2]

void KIGFX::RENDER_SETTINGS::SetHighlight ( std::set< int > &  aHighlight,
bool  aEnabled = true 
)
inlineinherited

Turns on highlighting and highlights multiple nets.

Parameters
aHighlightis a set of netcodes to highlight
aEnabledtells if highlighting should be enabled.

Definition at line 179 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_highlightEnabled, and KIGFX::RENDER_SETTINGS::m_highlightNetcodes.

◆ SetHighlightFactor()

void KIGFX::RENDER_SETTINGS::SetHighlightFactor ( float  aFactor)
inlineinherited

◆ SetIsPrinting()

void KIGFX::RENDER_SETTINGS::SetIsPrinting ( bool  isPrinting)
inlineinherited

◆ SetLayerColor()

void KIGFX::RENDER_SETTINGS::SetLayerColor ( int  aLayer,
const COLOR4D aColor 
)
inlineinherited

◆ SetLayerIsHighContrast()

void KIGFX::RENDER_SETTINGS::SetLayerIsHighContrast ( int  aLayerId,
bool  aEnabled = true 
)
inlineinherited

Set the specified layer as high-contrast.

Parameters
aLayerIdis a layer number that should be displayed in a specific mode.
aEnabledis the new layer state ( true = active or false = not active).

Definition at line 70 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_highContrastLayers.

Referenced by EDA_DRAW_PANEL_GAL::SetHighContrastLayer(), GERBVIEW_DRAW_PANEL_GAL::SetHighContrastLayer(), and PCB_DRAW_PANEL_GAL::SetHighContrastLayer().

◆ SetLayerName()

void KIGFX::RENDER_SETTINGS::SetLayerName ( const wxString &  aLayerName)
inlineinherited

Definition at line 117 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_layerName.

Referenced by BOARD_PRINTOUT::DrawPage(), and StartPlotBoard().

◆ SetMinPenWidth()

void KIGFX::RENDER_SETTINGS::SetMinPenWidth ( int  aWidth)
inlineinherited

◆ SetNetColorMode()

void KIGFX::PCB_RENDER_SETTINGS::SetNetColorMode ( NET_COLOR_MODE  aMode)
inline

Definition at line 127 of file pcb_painter.h.

References m_netColorMode.

◆ SetOutlineWidth()

void KIGFX::RENDER_SETTINGS::SetOutlineWidth ( float  aWidth)
inlineinherited

Set line width used for drawing outlines.

Parameters
aWidthis the new width.

Definition at line 298 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_outlineWidth.

◆ SetPrintBlackAndWhite()

void KIGFX::RENDER_SETTINGS::SetPrintBlackAndWhite ( bool  aPrintBlackAndWhite)
inlineinherited

Definition at line 231 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_printBlackAndWite.

Referenced by SCH_PRINTOUT::PrintPage().

◆ SetPrintDC()

◆ SetPrintLayers()

void KIGFX::RENDER_SETTINGS::SetPrintLayers ( LSET  aLayerSet)
inlineinherited

Definition at line 120 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_printLayers.

Referenced by BOARD_PRINTOUT::DrawPage().

◆ SetSelectFactor()

void KIGFX::RENDER_SETTINGS::SetSelectFactor ( float  aFactor)
inlineinherited

Definition at line 302 of file render_settings.h.

References KIGFX::RENDER_SETTINGS::m_selectFactor.

Referenced by PCB_BASE_FRAME::LoadSettings().

◆ update()

Friends And Related Function Documentation

◆ PCB_PAINTER

friend class PCB_PAINTER
friend

Definition at line 80 of file pcb_painter.h.

Member Data Documentation

◆ m_activeLayer

PCB_LAYER_ID KIGFX::RENDER_SETTINGS::m_activeLayer
protectedinherited

◆ m_backgroundColor

◆ m_ContrastModeDisplay

HIGH_CONTRAST_MODE KIGFX::PCB_RENDER_SETTINGS::m_ContrastModeDisplay

◆ m_dashLengthRatio

double KIGFX::RENDER_SETTINGS::m_dashLengthRatio
protectedinherited

◆ m_defaultFont

wxString KIGFX::RENDER_SETTINGS::m_defaultFont
protectedinherited

◆ m_defaultPenWidth

◆ m_drawBoundingBoxes

bool KIGFX::RENDER_SETTINGS::m_drawBoundingBoxes
protectedinherited

◆ m_drawingSheetLineWidth

float KIGFX::RENDER_SETTINGS::m_drawingSheetLineWidth
protectedinherited

◆ m_filledShapeOpacity

double KIGFX::PCB_RENDER_SETTINGS::m_filledShapeOpacity
protected

Opacity override for graphic shapes.

Definition at line 165 of file pcb_painter.h.

Referenced by GetColor(), LoadDisplayOptions(), and PCB_RENDER_SETTINGS().

◆ m_ForcePadSketchModeOn

bool KIGFX::PCB_RENDER_SETTINGS::m_ForcePadSketchModeOn

◆ m_ForceShowFieldsWhenFPSelected

bool KIGFX::PCB_RENDER_SETTINGS::m_ForceShowFieldsWhenFPSelected

◆ m_gapLengthRatio

double KIGFX::RENDER_SETTINGS::m_gapLengthRatio
protectedinherited

◆ m_hiContrastColor

COLOR4D KIGFX::RENDER_SETTINGS::m_hiContrastColor[LAYER_ID_COUNT]
protectedinherited

◆ m_hiContrastEnabled

bool KIGFX::RENDER_SETTINGS::m_hiContrastEnabled
protectedinherited

◆ m_hiContrastFactor

float KIGFX::RENDER_SETTINGS::m_hiContrastFactor
protectedinherited

◆ m_hiddenNets

std::set<int> KIGFX::PCB_RENDER_SETTINGS::m_hiddenNets
protected

Definition at line 157 of file pcb_painter.h.

Referenced by GetHiddenNets().

◆ m_highContrastLayers

◆ m_highlightEnabled

◆ m_highlightFactor

float KIGFX::RENDER_SETTINGS::m_highlightFactor
protectedinherited

◆ m_highlightNetcodes

std::set<int> KIGFX::RENDER_SETTINGS::m_highlightNetcodes
protectedinherited

◆ m_imageOpacity

double KIGFX::PCB_RENDER_SETTINGS::m_imageOpacity
protected

Opacity override for user images.

Definition at line 164 of file pcb_painter.h.

Referenced by GetColor(), LoadDisplayOptions(), and PCB_RENDER_SETTINGS().

◆ m_isPrinting

◆ m_layerColors

◆ m_layerColorsDark

COLOR4D KIGFX::RENDER_SETTINGS::m_layerColorsDark[LAYER_ID_COUNT]
protectedinherited

◆ m_layerColorsHi

COLOR4D KIGFX::RENDER_SETTINGS::m_layerColorsHi[LAYER_ID_COUNT]
protectedinherited

◆ m_layerColorsSel

COLOR4D KIGFX::RENDER_SETTINGS::m_layerColorsSel[LAYER_ID_COUNT]
protectedinherited

◆ m_layerName

wxString KIGFX::RENDER_SETTINGS::m_layerName
protectedinherited

◆ m_minPenWidth

◆ m_netclassColors

std::map<wxString, KIGFX::COLOR4D> KIGFX::PCB_RENDER_SETTINGS::m_netclassColors
protected

Overrides for specific net colors, stored as netcodes for the ratsnest to access easily.

Definition at line 151 of file pcb_painter.h.

◆ m_netColorMode

NET_COLOR_MODE KIGFX::PCB_RENDER_SETTINGS::m_netColorMode
protected

Overrides for specific netclass colors.

Definition at line 148 of file pcb_painter.h.

Referenced by GetColor(), GetNetColorMode(), LoadDisplayOptions(), PCB_RENDER_SETTINGS(), and SetNetColorMode().

◆ m_netColors

std::map<int, KIGFX::COLOR4D> KIGFX::PCB_RENDER_SETTINGS::m_netColors
protected

Set of net codes that should not have their ratsnest displayed.

Definition at line 154 of file pcb_painter.h.

Referenced by GetColor(), and GetNetColorMap().

◆ m_outlineWidth

◆ m_PadEditModePad

PAD* KIGFX::PCB_RENDER_SETTINGS::m_PadEditModePad

◆ m_padOpacity

double KIGFX::PCB_RENDER_SETTINGS::m_padOpacity
protected

Opacity override for SMD pads and PTHs.

Definition at line 162 of file pcb_painter.h.

Referenced by GetColor(), LoadDisplayOptions(), and PCB_RENDER_SETTINGS().

◆ m_printBlackAndWite

◆ m_printDC

wxDC* KIGFX::RENDER_SETTINGS::m_printDC
protectedinherited

◆ m_printLayers

LSET KIGFX::RENDER_SETTINGS::m_printLayers
protectedinherited

◆ m_selectFactor

float KIGFX::RENDER_SETTINGS::m_selectFactor
protectedinherited

◆ m_trackOpacity

double KIGFX::PCB_RENDER_SETTINGS::m_trackOpacity
protected

Opacity override for all tracks.

Definition at line 160 of file pcb_painter.h.

Referenced by GetColor(), LoadDisplayOptions(), and PCB_RENDER_SETTINGS().

◆ m_viaOpacity

double KIGFX::PCB_RENDER_SETTINGS::m_viaOpacity
protected

Opacity override for all types of via.

Definition at line 161 of file pcb_painter.h.

Referenced by GetColor(), LoadDisplayOptions(), and PCB_RENDER_SETTINGS().

◆ m_ZoneDisplayMode

ZONE_DISPLAY_MODE KIGFX::PCB_RENDER_SETTINGS::m_ZoneDisplayMode

◆ m_zoneOpacity

double KIGFX::PCB_RENDER_SETTINGS::m_zoneOpacity
protected

Opacity override for filled zones.

Definition at line 163 of file pcb_painter.h.

Referenced by GetColor(), LoadDisplayOptions(), and PCB_RENDER_SETTINGS().

◆ MAX_FONT_SIZE

const double PCB_RENDER_SETTINGS::MAX_FONT_SIZE = pcbIUScale.mmToIU( 10.0 )
staticprotected

< Maximum font size for netnames (and other dynamically shown strings)

How to display nets and netclasses with color overrides

Definition at line 145 of file pcb_painter.h.

Referenced by KIGFX::PCB_PAINTER::draw().


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