Make plotting of PDF property popups optional.
This commit is contained in:
parent
f708c7d962
commit
f50de028fb
|
@ -110,6 +110,8 @@ void DIALOG_PLOT_SCHEMATIC::initDlg()
|
|||
|
||||
setOpenFileAfterPlot( cfg->m_PlotPanel.open_file_after_plot );
|
||||
|
||||
m_plotPDFPropertyPopups->SetValue( cfg->m_PlotPanel.pdf_property_popups );
|
||||
|
||||
// HPGL plot origin and unit system configuration
|
||||
m_plotOriginOpt->SetSelection( cfg->m_PlotPanel.hpgl_origin );
|
||||
|
||||
|
@ -304,6 +306,7 @@ void DIALOG_PLOT_SCHEMATIC::getPlotOptions( RENDER_SETTINGS* aSettings )
|
|||
cfg->m_PlotPanel.format = static_cast<int>( GetPlotFileFormat() );
|
||||
cfg->m_PlotPanel.hpgl_origin = m_plotOriginOpt->GetSelection();
|
||||
cfg->m_PlotPanel.hpgl_paper_size = static_cast<int>( m_HPGLPaperSizeSelect );
|
||||
cfg->m_PlotPanel.pdf_property_popups = m_plotPDFPropertyPopups->GetValue();
|
||||
cfg->m_PlotPanel.open_file_after_plot = getOpenFileAfterPlot();
|
||||
|
||||
// HPGL Pen Size is stored in mm in config
|
||||
|
@ -377,10 +380,11 @@ void DIALOG_PLOT_SCHEMATIC::plotSchematic( bool aPlotAll )
|
|||
plotSettings.m_blackAndWhite = !getModeColor();
|
||||
plotSettings.m_useBackgroundColor = m_plotBackgroundColor->GetValue();
|
||||
plotSettings.m_theme = colors->GetFilename();
|
||||
plotSettings.m_HPGLPenSize = m_HPGLPenSize;
|
||||
plotSettings.m_PDFPropertyPopups = m_plotPDFPropertyPopups->GetValue();
|
||||
plotSettings.m_HPGLPaperSizeSelect = static_cast<HPGL_PAGE_SIZE>( m_HPGLPaperSizeSelect );
|
||||
plotSettings.m_HPGLPlotOrigin =
|
||||
static_cast<HPGL_PLOT_ORIGIN_AND_UNITS>( m_plotOriginOpt->GetSelection() );
|
||||
plotSettings.m_HPGLPenSize = m_HPGLPenSize;
|
||||
plotSettings.m_outputDirectory = getOutputPath();
|
||||
plotSettings.m_pageSizeSelect = m_pageSizeSelect;
|
||||
|
||||
|
|
|
@ -49,73 +49,74 @@ DIALOG_PLOT_SCHEMATIC_BASE::DIALOG_PLOT_SCHEMATIC_BASE( wxWindow* parent, wxWind
|
|||
sbOptions = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Options") ), wxVERTICAL );
|
||||
|
||||
wxGridBagSizer* gbSizer1;
|
||||
gbSizer1 = new wxGridBagSizer( 0, 0 );
|
||||
gbSizer1 = new wxGridBagSizer( 5, 3 );
|
||||
gbSizer1->SetFlexibleDirection( wxBOTH );
|
||||
gbSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
||||
gbSizer1->SetEmptyCellSize( wxSize( -1,10 ) );
|
||||
|
||||
m_staticText4 = new wxStaticText( sbOptions->GetStaticBox(), wxID_ANY, _("Page size:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText4->Wrap( -1 );
|
||||
gbSizer1->Add( m_staticText4, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT, 5 );
|
||||
gbSizer1->Add( m_staticText4, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
wxString m_paperSizeOptionChoices[] = { _("Schematic size"), _("A4"), _("A") };
|
||||
int m_paperSizeOptionNChoices = sizeof( m_paperSizeOptionChoices ) / sizeof( wxString );
|
||||
m_paperSizeOption = new wxChoice( sbOptions->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_paperSizeOptionNChoices, m_paperSizeOptionChoices, 0 );
|
||||
m_paperSizeOption->SetSelection( 0 );
|
||||
gbSizer1->Add( m_paperSizeOption, wxGBPosition( 0, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
gbSizer1->Add( m_paperSizeOption, wxGBPosition( 0, 1 ), wxGBSpan( 1, 2 ), wxEXPAND|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_plotDrawingSheet = new wxCheckBox( sbOptions->GetStaticBox(), wxID_ANY, _("Plot drawing sheet"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_plotDrawingSheet->SetValue(true);
|
||||
m_plotDrawingSheet->SetToolTip( _("Plot the drawing sheet border and title block") );
|
||||
|
||||
gbSizer1->Add( m_plotDrawingSheet, wxGBPosition( 1, 0 ), wxGBSpan( 1, 2 ), wxALL, 5 );
|
||||
gbSizer1->Add( m_plotDrawingSheet, wxGBPosition( 1, 0 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
wxStaticText* bOutputModeLabel;
|
||||
bOutputModeLabel = new wxStaticText( sbOptions->GetStaticBox(), wxID_ANY, _("Output mode:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
bOutputModeLabel->Wrap( -1 );
|
||||
gbSizer1->Add( bOutputModeLabel, wxGBPosition( 2, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
||||
gbSizer1->Add( bOutputModeLabel, wxGBPosition( 3, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
wxString m_ModeColorOptionChoices[] = { _("Color"), _("Black and White") };
|
||||
int m_ModeColorOptionNChoices = sizeof( m_ModeColorOptionChoices ) / sizeof( wxString );
|
||||
m_ModeColorOption = new wxChoice( sbOptions->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_ModeColorOptionNChoices, m_ModeColorOptionChoices, 0 );
|
||||
m_ModeColorOption->SetSelection( 0 );
|
||||
gbSizer1->Add( m_ModeColorOption, wxGBPosition( 2, 1 ), wxGBSpan( 1, 1 ), wxALL, 5 );
|
||||
|
||||
m_plotBackgroundColor = new wxCheckBox( sbOptions->GetStaticBox(), wxID_ANY, _("Plot background color"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_plotBackgroundColor->SetToolTip( _("Plot the background color if the output format supports it") );
|
||||
|
||||
gbSizer1->Add( m_plotBackgroundColor, wxGBPosition( 3, 0 ), wxGBSpan( 1, 3 ), wxALIGN_CENTER_VERTICAL|wxALL|wxEXPAND, 5 );
|
||||
gbSizer1->Add( m_ModeColorOption, wxGBPosition( 3, 1 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
|
||||
|
||||
m_staticText9 = new wxStaticText( sbOptions->GetStaticBox(), wxID_ANY, _("Color theme:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText9->Wrap( -1 );
|
||||
gbSizer1->Add( m_staticText9, wxGBPosition( 4, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxALL, 5 );
|
||||
gbSizer1->Add( m_staticText9, wxGBPosition( 4, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
wxArrayString m_colorThemeChoices;
|
||||
m_colorTheme = new wxChoice( sbOptions->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_colorThemeChoices, 0 );
|
||||
m_colorTheme->SetSelection( 0 );
|
||||
m_colorTheme->SetToolTip( _("Select the color theme to use for plotting") );
|
||||
|
||||
gbSizer1->Add( m_colorTheme, wxGBPosition( 4, 1 ), wxGBSpan( 1, 1 ), wxALL|wxEXPAND, 5 );
|
||||
gbSizer1->Add( m_colorTheme, wxGBPosition( 4, 1 ), wxGBSpan( 1, 2 ), wxEXPAND|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_plotBackgroundColor = new wxCheckBox( sbOptions->GetStaticBox(), wxID_ANY, _("Plot background color"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_plotBackgroundColor->SetToolTip( _("Plot the background color if the output format supports it") );
|
||||
|
||||
gbSizer1->Add( m_plotBackgroundColor, wxGBPosition( 5, 0 ), wxGBSpan( 1, 3 ), wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
|
||||
|
||||
m_lineWidthLabel = new wxStaticText( sbOptions->GetStaticBox(), wxID_ANY, _("Minimum line width:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_lineWidthLabel->Wrap( -1 );
|
||||
gbSizer1->Add( m_lineWidthLabel, wxGBPosition( 5, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
||||
gbSizer1->Add( m_lineWidthLabel, wxGBPosition( 7, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_lineWidthCtrl = new wxTextCtrl( sbOptions->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_lineWidthCtrl->SetToolTip( _("Selection of the default pen thickness used to draw items, when their thickness is set to 0.") );
|
||||
|
||||
gbSizer1->Add( m_lineWidthCtrl, wxGBPosition( 5, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxALL, 5 );
|
||||
gbSizer1->Add( m_lineWidthCtrl, wxGBPosition( 7, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_lineWidthUnits = new wxStaticText( sbOptions->GetStaticBox(), wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_lineWidthUnits->Wrap( -1 );
|
||||
gbSizer1->Add( m_lineWidthUnits, wxGBPosition( 5, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT|wxTOP, 5 );
|
||||
gbSizer1->Add( m_lineWidthUnits, wxGBPosition( 7, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
|
||||
gbSizer1->AddGrowableCol( 1 );
|
||||
|
||||
sbOptions->Add( gbSizer1, 1, wxEXPAND, 5 );
|
||||
sbOptions->Add( gbSizer1, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
|
||||
m_optionsSizer->Add( sbOptions, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
m_optionsSizer->Add( sbOptions, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
wxBoxSizer* bOptionsRight;
|
||||
bOptionsRight = new wxBoxSizer( wxVERTICAL );
|
||||
|
@ -123,49 +124,59 @@ DIALOG_PLOT_SCHEMATIC_BASE::DIALOG_PLOT_SCHEMATIC_BASE( wxWindow* parent, wxWind
|
|||
m_HPGLOptionsSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("HPGL Options") ), wxVERTICAL );
|
||||
|
||||
wxGridBagSizer* gbSizer2;
|
||||
gbSizer2 = new wxGridBagSizer( 0, 0 );
|
||||
gbSizer2 = new wxGridBagSizer( 3, 3 );
|
||||
gbSizer2->SetFlexibleDirection( wxBOTH );
|
||||
gbSizer2->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
||||
|
||||
m_plotOriginTitle = new wxStaticText( m_HPGLOptionsSizer->GetStaticBox(), wxID_ANY, _("Position and units:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_plotOriginTitle->Wrap( -1 );
|
||||
gbSizer2->Add( m_plotOriginTitle, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT, 5 );
|
||||
gbSizer2->Add( m_plotOriginTitle, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
wxString m_plotOriginOptChoices[] = { _("Bottom left, plotter units"), _("Centered, plotter units"), _("Page fit, user units"), _("Content fit, user units") };
|
||||
int m_plotOriginOptNChoices = sizeof( m_plotOriginOptChoices ) / sizeof( wxString );
|
||||
m_plotOriginOpt = new wxChoice( m_HPGLOptionsSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_plotOriginOptNChoices, m_plotOriginOptChoices, 0 );
|
||||
m_plotOriginOpt->SetSelection( 0 );
|
||||
gbSizer2->Add( m_plotOriginOpt, wxGBPosition( 0, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||
gbSizer2->Add( m_plotOriginOpt, wxGBPosition( 0, 1 ), wxGBSpan( 1, 2 ), wxEXPAND, 5 );
|
||||
|
||||
m_penWidthLabel = new wxStaticText( m_HPGLOptionsSizer->GetStaticBox(), wxID_ANY, _("Pen width:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_penWidthLabel->Wrap( -1 );
|
||||
gbSizer2->Add( m_penWidthLabel, wxGBPosition( 1, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 );
|
||||
gbSizer2->Add( m_penWidthLabel, wxGBPosition( 1, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_penWidthCtrl = new wxTextCtrl( m_HPGLOptionsSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
gbSizer2->Add( m_penWidthCtrl, wxGBPosition( 1, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxALL, 5 );
|
||||
gbSizer2->Add( m_penWidthCtrl, wxGBPosition( 1, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
|
||||
|
||||
m_penWidthUnits = new wxStaticText( m_HPGLOptionsSizer->GetStaticBox(), wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_penWidthUnits->Wrap( -1 );
|
||||
gbSizer2->Add( m_penWidthUnits, wxGBPosition( 1, 2 ), wxGBSpan( 1, 1 ), wxTOP|wxBOTTOM|wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
gbSizer2->Add( m_penWidthUnits, wxGBPosition( 1, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
|
||||
gbSizer2->AddGrowableCol( 1 );
|
||||
|
||||
m_HPGLOptionsSizer->Add( gbSizer2, 1, wxEXPAND, 5 );
|
||||
m_HPGLOptionsSizer->Add( gbSizer2, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
|
||||
bOptionsRight->Add( m_HPGLOptionsSizer, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
wxStaticBoxSizer* sbSizer4;
|
||||
sbSizer4 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("PDF Options") ), wxVERTICAL );
|
||||
|
||||
m_plotPDFPropertyPopups = new wxCheckBox( sbSizer4->GetStaticBox(), wxID_ANY, _("Generate property popups"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_plotPDFPropertyPopups->SetValue(true);
|
||||
sbSizer4->Add( m_plotPDFPropertyPopups, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
|
||||
bOptionsRight->Add( sbSizer4, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
m_otherOptions = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Other options") ), wxVERTICAL );
|
||||
|
||||
m_openFileAfterPlot = new wxCheckBox( m_otherOptions->GetStaticBox(), wxID_ANY, _("Open file after plot"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_openFileAfterPlot->Enable( false );
|
||||
m_openFileAfterPlot->SetToolTip( _("Open output file with associated application after successful plot") );
|
||||
|
||||
m_otherOptions->Add( m_openFileAfterPlot, 0, wxALL, 5 );
|
||||
m_otherOptions->Add( m_openFileAfterPlot, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
|
||||
bOptionsRight->Add( m_otherOptions, 1, wxEXPAND|wxLEFT|wxRIGHT, 5 );
|
||||
bOptionsRight->Add( m_otherOptions, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
|
||||
m_optionsSizer->Add( bOptionsRight, 1, wxEXPAND, 5 );
|
||||
|
|
|
@ -352,7 +352,7 @@
|
|||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxStaticBoxSizer" expanded="1">
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Options</property>
|
||||
|
@ -363,24 +363,24 @@
|
|||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="flag">wxEXPAND|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxGridBagSizer" expanded="1">
|
||||
<property name="empty_cell_size"></property>
|
||||
<property name="empty_cell_size">-1,10</property>
|
||||
<property name="flexible_direction">wxBOTH</property>
|
||||
<property name="growablecols">1</property>
|
||||
<property name="growablerows"></property>
|
||||
<property name="hgap">0</property>
|
||||
<property name="hgap">3</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">gbSizer1</property>
|
||||
<property name="non_flexible_grow_mode">wxFLEX_GROWMODE_SPECIFIED</property>
|
||||
<property name="permission">none</property>
|
||||
<property name="vgap">0</property>
|
||||
<property name="vgap">5</property>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">0</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
|
@ -442,9 +442,9 @@
|
|||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxEXPAND|wxRIGHT|wxLEFT</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">0</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxChoice" expanded="0">
|
||||
|
@ -512,7 +512,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">1</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="0">
|
||||
|
@ -579,8 +579,8 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxLEFT</property>
|
||||
<property name="row">2</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">3</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -641,10 +641,10 @@
|
|||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="row">2</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxEXPAND</property>
|
||||
<property name="row">3</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxChoice" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -706,78 +706,11 @@
|
|||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">3</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALL|wxEXPAND</property>
|
||||
<property name="row">3</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Plot background color</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_plotBackgroundColor</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">Plot the background color if the output format supports it</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALL</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">4</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
|
@ -839,9 +772,9 @@
|
|||
</object>
|
||||
<object class="gbsizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">4</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxChoice" expanded="1">
|
||||
|
@ -904,12 +837,79 @@
|
|||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">3</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxEXPAND</property>
|
||||
<property name="row">5</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Plot background color</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_plotBackgroundColor</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">Plot the background color if the output format supports it</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxLEFT</property>
|
||||
<property name="row">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">7</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -972,8 +972,8 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxEXPAND|wxALL</property>
|
||||
<property name="row">5</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">7</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxTextCtrl" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1039,8 +1039,8 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">2</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT|wxTOP</property>
|
||||
<property name="row">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">7</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1126,24 +1126,24 @@
|
|||
<property name="permission">protected</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="flag">wxEXPAND|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxGridBagSizer" expanded="1">
|
||||
<property name="empty_cell_size"></property>
|
||||
<property name="flexible_direction">wxBOTH</property>
|
||||
<property name="growablecols">1</property>
|
||||
<property name="growablerows"></property>
|
||||
<property name="hgap">0</property>
|
||||
<property name="hgap">3</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">gbSizer2</property>
|
||||
<property name="non_flexible_grow_mode">wxFLEX_GROWMODE_SPECIFIED</property>
|
||||
<property name="permission">none</property>
|
||||
<property name="vgap">0</property>
|
||||
<property name="vgap">3</property>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">0</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
|
@ -1205,9 +1205,9 @@
|
|||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="row">0</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxChoice" expanded="0">
|
||||
|
@ -1274,7 +1274,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">1</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
|
@ -1338,7 +1338,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxEXPAND|wxALL</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxEXPAND</property>
|
||||
<property name="row">1</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxTextCtrl" expanded="0">
|
||||
|
@ -1405,7 +1405,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">2</property>
|
||||
<property name="flag">wxTOP|wxBOTTOM|wxRIGHT|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">1</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
|
@ -1471,7 +1471,85 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxLEFT|wxRIGHT</property>
|
||||
<property name="flag">wxEXPAND|wxTOP|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxStaticBoxSizer" expanded="1">
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">PDF Options</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">sbSizer4</property>
|
||||
<property name="orient">wxVERTICAL</property>
|
||||
<property name="parent">1</property>
|
||||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">1</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Generate property popups</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_plotPDFPropertyPopups</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxTOP|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxStaticBoxSizer" expanded="1">
|
||||
<property name="id">wxID_ANY</property>
|
||||
|
@ -1483,7 +1561,7 @@
|
|||
<property name="permission">protected</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="flag">wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
|
|
@ -54,9 +54,9 @@ class DIALOG_PLOT_SCHEMATIC_BASE : public DIALOG_SHIM
|
|||
wxChoice* m_paperSizeOption;
|
||||
wxCheckBox* m_plotDrawingSheet;
|
||||
wxChoice* m_ModeColorOption;
|
||||
wxCheckBox* m_plotBackgroundColor;
|
||||
wxStaticText* m_staticText9;
|
||||
wxChoice* m_colorTheme;
|
||||
wxCheckBox* m_plotBackgroundColor;
|
||||
wxStaticText* m_lineWidthLabel;
|
||||
wxTextCtrl* m_lineWidthCtrl;
|
||||
wxStaticText* m_lineWidthUnits;
|
||||
|
@ -66,6 +66,7 @@ class DIALOG_PLOT_SCHEMATIC_BASE : public DIALOG_SHIM
|
|||
wxStaticText* m_penWidthLabel;
|
||||
wxTextCtrl* m_penWidthCtrl;
|
||||
wxStaticText* m_penWidthUnits;
|
||||
wxCheckBox* m_plotPDFPropertyPopups;
|
||||
wxStaticBoxSizer* m_otherOptions;
|
||||
wxCheckBox* m_openFileAfterPlot;
|
||||
WX_HTML_REPORT_PANEL* m_MessagesBox;
|
||||
|
|
|
@ -480,6 +480,9 @@ EESCHEMA_SETTINGS::EESCHEMA_SETTINGS() :
|
|||
m_params.emplace_back( new PARAM<bool>( "plot.frame_reference",
|
||||
&m_PlotPanel.frame_reference, true ) );
|
||||
|
||||
m_params.emplace_back( new PARAM<bool>( "plot.pdf_property_popups",
|
||||
&m_PlotPanel.pdf_property_popups, true ) );
|
||||
|
||||
m_params.emplace_back( new PARAM<int>( "plot.hpgl_paper_size",
|
||||
&m_PlotPanel.hpgl_paper_size, 0 ) );
|
||||
|
||||
|
|
|
@ -249,6 +249,7 @@ public:
|
|||
int hpgl_paper_size;
|
||||
double hpgl_pen_size;
|
||||
int hpgl_origin;
|
||||
bool pdf_property_popups;
|
||||
bool open_file_after_plot;
|
||||
};
|
||||
|
||||
|
|
|
@ -203,13 +203,14 @@ bool SCH_BITMAP::HitTest( const BOX2I& aRect, bool aContained, int aAccuracy ) c
|
|||
}
|
||||
|
||||
|
||||
void SCH_BITMAP::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_BITMAP::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
{
|
||||
m_bitmapBase->PlotImage( aPlotter, m_pos,
|
||||
aPlotter->RenderSettings()->GetLayerColor( GetLayer() ),
|
||||
aPlotter->RenderSettings()->GetDefaultPenWidth() );
|
||||
aPlotter->RenderSettings()->GetLayerColor( GetLayer() ),
|
||||
aPlotter->RenderSettings()->GetDefaultPenWidth() );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -150,7 +150,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override;
|
||||
|
||||
|
|
|
@ -468,7 +468,8 @@ bool SCH_BUS_ENTRY_BASE::HitTest( const BOX2I& aRect, bool aContained, int aAccu
|
|||
}
|
||||
|
||||
|
||||
void SCH_BUS_ENTRY_BASE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_BUS_ENTRY_BASE::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
return;
|
||||
|
|
|
@ -122,7 +122,8 @@ public:
|
|||
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
void GetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vector<MSG_PANEL_ITEM>& aList ) override;
|
||||
|
||||
|
|
|
@ -1125,7 +1125,8 @@ bool SCH_FIELD::HitTest( const BOX2I& aRect, bool aContained, int aAccuracy ) co
|
|||
}
|
||||
|
||||
|
||||
void SCH_FIELD::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_FIELD::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( GetShownText( true ).IsEmpty() || aBackground )
|
||||
return;
|
||||
|
|
|
@ -269,7 +269,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override;
|
||||
|
||||
|
|
|
@ -349,7 +349,8 @@ bool SCH_ITEM::RenderAsBitmap( double aWorldScale ) const
|
|||
}
|
||||
|
||||
|
||||
void SCH_ITEM::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_ITEM::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
wxFAIL_MSG( wxT( "Plot() method not implemented for class " ) + GetClass() );
|
||||
}
|
||||
|
|
|
@ -43,6 +43,7 @@ class SCHEMATIC;
|
|||
class LINE_READER;
|
||||
class SCH_EDIT_FRAME;
|
||||
class PLOTTER;
|
||||
struct SCH_PLOT_SETTINGS;
|
||||
class NETLIST_OBJECT_LIST;
|
||||
class PLOTTER;
|
||||
|
||||
|
@ -493,7 +494,8 @@ public:
|
|||
* @param aBackground a poor-man's Z-order. The routine will get called twice, first with
|
||||
* aBackground true and then with aBackground false.
|
||||
*/
|
||||
virtual void Plot( PLOTTER* aPlotter, bool aBackground ) const;
|
||||
virtual void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const;
|
||||
|
||||
virtual bool operator <( const SCH_ITEM& aItem ) const;
|
||||
|
||||
|
|
|
@ -237,7 +237,8 @@ bool SCH_JUNCTION::doIsConnected( const VECTOR2I& aPosition ) const
|
|||
}
|
||||
|
||||
|
||||
void SCH_JUNCTION::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_JUNCTION::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
return;
|
||||
|
|
|
@ -121,7 +121,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override;
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#include <base_units.h>
|
||||
#include <pgm_base.h>
|
||||
#include <sch_edit_frame.h>
|
||||
#include <plotters/plotter.h>
|
||||
#include <sch_plotter.h>
|
||||
#include <widgets/msgpanel.h>
|
||||
#include <bitmaps.h>
|
||||
#include <string_utils.h>
|
||||
|
@ -1240,7 +1240,8 @@ void SCH_LABEL_BASE::GetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vector<MSG_PA
|
|||
}
|
||||
|
||||
|
||||
void SCH_LABEL_BASE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_LABEL_BASE::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
static std::vector<VECTOR2I> s_poly;
|
||||
|
||||
|
@ -1301,26 +1302,29 @@ void SCH_LABEL_BASE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
|||
}
|
||||
|
||||
// Plot attributes to a hypertext menu
|
||||
std::vector<wxString> properties;
|
||||
|
||||
if( connection )
|
||||
if( aPlotSettings.m_PDFPropertyPopups )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ), _( "Net" ),
|
||||
connection->Name() ) );
|
||||
std::vector<wxString> properties;
|
||||
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ), _( "Resolved netclass" ),
|
||||
GetEffectiveNetClass()->GetName() ) );
|
||||
if( connection )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ), _( "Net" ),
|
||||
connection->Name() ) );
|
||||
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ), _( "Resolved netclass" ),
|
||||
GetEffectiveNetClass()->GetName() ) );
|
||||
}
|
||||
|
||||
for( const SCH_FIELD& field : GetFields() )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ), field.GetName(),
|
||||
field.GetShownText( false ) ) );
|
||||
}
|
||||
|
||||
if( !properties.empty() )
|
||||
aPlotter->HyperlinkMenu( GetBodyBoundingBox(), properties );
|
||||
}
|
||||
|
||||
for( const SCH_FIELD& field : GetFields() )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ), field.GetName(),
|
||||
field.GetShownText( false ) ) );
|
||||
}
|
||||
|
||||
if( !properties.empty() )
|
||||
aPlotter->HyperlinkMenu( GetBodyBoundingBox(), properties );
|
||||
|
||||
if( Type() == SCH_HIER_LABEL_T )
|
||||
{
|
||||
aPlotter->Bookmark( GetBodyBoundingBox(), GetShownText( false ),
|
||||
|
@ -1329,7 +1333,7 @@ void SCH_LABEL_BASE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
|||
}
|
||||
|
||||
for( const SCH_FIELD& field : m_fields )
|
||||
field.Plot( aPlotter, aBackground );
|
||||
field.Plot( aPlotter, aBackground, aPlotSettings );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -287,7 +287,8 @@ public:
|
|||
|
||||
void GetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vector<MSG_PANEL_ITEM>& aList ) override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
void Print( const RENDER_SETTINGS* aSettings, const VECTOR2I& offset ) override;
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
#include <string_utils.h>
|
||||
#include <core/mirror.h>
|
||||
#include <sch_painter.h>
|
||||
#include <plotters/plotter.h>
|
||||
#include <sch_plotter.h>
|
||||
#include <geometry/shape_segment.h>
|
||||
#include <sch_line.h>
|
||||
#include <sch_edit_frame.h>
|
||||
|
@ -860,7 +860,8 @@ bool SCH_LINE::doIsConnected( const VECTOR2I& aPosition ) const
|
|||
}
|
||||
|
||||
|
||||
void SCH_LINE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_LINE::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
return;
|
||||
|
@ -887,31 +888,34 @@ void SCH_LINE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
|||
BOX2I bbox = GetBoundingBox();
|
||||
bbox.Inflate( GetPenWidth() * 3 );
|
||||
|
||||
if( GetLayer() == LAYER_WIRE )
|
||||
if( aPlotSettings.m_PDFPropertyPopups )
|
||||
{
|
||||
if( SCH_CONNECTION* connection = Connection() )
|
||||
if( GetLayer() == LAYER_WIRE )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
_( "Net" ),
|
||||
connection->Name() ) );
|
||||
if( SCH_CONNECTION* connection = Connection() )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
_( "Net" ),
|
||||
connection->Name() ) );
|
||||
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
_( "Resolved netclass" ),
|
||||
GetEffectiveNetClass()->GetName() ) );
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
_( "Resolved netclass" ),
|
||||
GetEffectiveNetClass()->GetName() ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
else if( GetLayer() == LAYER_BUS )
|
||||
{
|
||||
if( SCH_CONNECTION* connection = Connection() )
|
||||
else if( GetLayer() == LAYER_BUS )
|
||||
{
|
||||
for( const std::shared_ptr<SCH_CONNECTION>& member : connection->Members() )
|
||||
properties.emplace_back( wxT( "!" ) + member->Name() );
|
||||
if( SCH_CONNECTION* connection = Connection() )
|
||||
{
|
||||
for( const std::shared_ptr<SCH_CONNECTION>& member : connection->Members() )
|
||||
properties.emplace_back( wxT( "!" ) + member->Name() );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if( !properties.empty() )
|
||||
aPlotter->HyperlinkMenu( bbox, properties );
|
||||
}
|
||||
|
||||
if( !properties.empty() )
|
||||
aPlotter->HyperlinkMenu( bbox, properties );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -290,7 +290,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override;
|
||||
|
||||
|
|
|
@ -64,7 +64,8 @@ public:
|
|||
|
||||
void Print( const RENDER_SETTINGS* aSettings, const VECTOR2I& aOffset ) override;
|
||||
|
||||
void Plot( PLOTTER* /* aPlotter */, bool /* aBackground */ ) const override
|
||||
void Plot( PLOTTER* /* aPlotter */, bool /* aBackground */,
|
||||
const SCH_PLOT_SETTINGS& /* aPlotSettings */ ) const override
|
||||
{
|
||||
// SCH_MARKERs should not be plotted. However, SCH_ITEM will fail an assertion if we
|
||||
// do not confirm this by locally implementing a no-op Plot().
|
||||
|
|
|
@ -172,7 +172,8 @@ bool SCH_NO_CONNECT::HitTest( const BOX2I& aRect, bool aContained, int aAccuracy
|
|||
}
|
||||
|
||||
|
||||
void SCH_NO_CONNECT::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_NO_CONNECT::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
return;
|
||||
|
|
|
@ -105,7 +105,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override;
|
||||
|
||||
|
|
|
@ -250,7 +250,7 @@ void SCH_PLOTTER::plotOneSheetPDF( PLOTTER* aPlotter, SCH_SCREEN* aScreen,
|
|||
aScreen->GetFileName(), color, aScreen->GetVirtualPageNumber() == 1 );
|
||||
}
|
||||
|
||||
aScreen->Plot( aPlotter );
|
||||
aScreen->Plot( aPlotter, aPlotSettings );
|
||||
}
|
||||
|
||||
|
||||
|
@ -455,7 +455,7 @@ bool SCH_PLOTTER::plotOneSheetPS( const wxString& aFileName, SCH_SCREEN* aScreen
|
|||
aScreen->GetVirtualPageNumber() == 1 );
|
||||
}
|
||||
|
||||
aScreen->Plot( plotter );
|
||||
aScreen->Plot( plotter, aPlotSettings );
|
||||
|
||||
plotter->EndPlot();
|
||||
delete plotter;
|
||||
|
@ -630,7 +630,7 @@ bool SCH_PLOTTER::plotOneSheetSVG( const wxString& aFileName, SCH_SCREEN* aScree
|
|||
aScreen->GetVirtualPageNumber() == 1 );
|
||||
}
|
||||
|
||||
aScreen->Plot( plotter );
|
||||
aScreen->Plot( plotter, aPlotSettings );
|
||||
|
||||
plotter->EndPlot();
|
||||
delete plotter;
|
||||
|
@ -819,7 +819,7 @@ bool SCH_PLOTTER::plotOneSheetHpgl( const wxString& aFileName,
|
|||
COLOR4D::BLACK, aScreen->GetVirtualPageNumber() == 1 );
|
||||
}
|
||||
|
||||
aScreen->Plot( plotter );
|
||||
aScreen->Plot( plotter, aPlotSettings );
|
||||
|
||||
plotter->EndPlot();
|
||||
|
||||
|
@ -970,7 +970,7 @@ bool SCH_PLOTTER::plotOneSheetDXF( const wxString& aFileName, SCH_SCREEN* aScree
|
|||
aScreen->GetVirtualPageNumber() == 1 );
|
||||
}
|
||||
|
||||
aScreen->Plot( plotter );
|
||||
aScreen->Plot( plotter, aPlotSettings );
|
||||
|
||||
// finish
|
||||
plotter->EndPlot();
|
||||
|
|
|
@ -82,15 +82,16 @@ struct SCH_PLOT_SETTINGS
|
|||
bool m_plotDrawingSheet;
|
||||
std::vector<wxString> m_plotPages;
|
||||
|
||||
bool m_blackAndWhite;
|
||||
int m_pageSizeSelect;
|
||||
bool m_useBackgroundColor;
|
||||
double m_HPGLPenSize; // for HPGL format only: pen size
|
||||
bool m_blackAndWhite;
|
||||
int m_pageSizeSelect;
|
||||
bool m_useBackgroundColor;
|
||||
double m_HPGLPenSize; // for HPGL format only: pen size
|
||||
HPGL_PAGE_SIZE m_HPGLPaperSizeSelect;
|
||||
wxString m_theme;
|
||||
bool m_PDFPropertyPopups;
|
||||
wxString m_theme;
|
||||
|
||||
wxString m_outputDirectory;
|
||||
wxString m_outputFile;
|
||||
wxString m_outputDirectory;
|
||||
wxString m_outputFile;
|
||||
|
||||
HPGL_PLOT_ORIGIN_AND_UNITS m_HPGLPlotOrigin;
|
||||
|
||||
|
|
|
@ -32,17 +32,16 @@
|
|||
#include <string_utils.h>
|
||||
#include <kiway.h>
|
||||
#include <plotters/plotter.h>
|
||||
#include <sch_plotter.h>
|
||||
#include <project.h>
|
||||
#include <project_sch.h>
|
||||
#include <reporter.h>
|
||||
#include <sch_draw_panel.h>
|
||||
#include <sch_edit_frame.h>
|
||||
#include <sch_item.h>
|
||||
|
||||
#include <symbol_library.h>
|
||||
#include <connection_graph.h>
|
||||
#include <lib_pin.h>
|
||||
#include <lib_shape.h>
|
||||
#include <sch_symbol.h>
|
||||
#include <sch_junction.h>
|
||||
#include <sch_line.h>
|
||||
|
@ -54,7 +53,6 @@
|
|||
#include <symbol_lib_table.h>
|
||||
#include <tool/common_tools.h>
|
||||
#include <sim/sim_model.h> // For V6 to V7 simulation model migration.
|
||||
#include <sim/sim_value.h> //
|
||||
#include <locale_io.h>
|
||||
|
||||
#include <algorithm>
|
||||
|
@ -62,7 +60,6 @@
|
|||
// TODO(JE) Debugging only
|
||||
#include <core/profile.h>
|
||||
#include "sch_bus_entry.h"
|
||||
#include "sim/sim_model_ideal.h"
|
||||
|
||||
/*
|
||||
* Flag to enable profiling of the TestDanglingEnds() function.
|
||||
|
@ -1110,7 +1107,7 @@ void SCH_SCREEN::Print( const RENDER_SETTINGS* aSettings )
|
|||
}
|
||||
|
||||
|
||||
void SCH_SCREEN::Plot( PLOTTER* aPlotter ) const
|
||||
void SCH_SCREEN::Plot( PLOTTER* aPlotter, const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
// Ensure links are up to date, even if a library was reloaded for some reason:
|
||||
std::vector<SCH_ITEM*> junctions;
|
||||
|
@ -1165,21 +1162,21 @@ void SCH_SCREEN::Plot( PLOTTER* aPlotter ) const
|
|||
for( const SCH_ITEM* item : bitmaps )
|
||||
{
|
||||
aPlotter->SetCurrentLineWidth( std::max( item->GetPenWidth(), defaultPenWidth ) );
|
||||
item->Plot( aPlotter, background );
|
||||
item->Plot( aPlotter, background, aPlotSettings );
|
||||
}
|
||||
|
||||
// Plot the background items
|
||||
for( const SCH_ITEM* item : other )
|
||||
{
|
||||
aPlotter->SetCurrentLineWidth( std::max( item->GetPenWidth(), defaultPenWidth ) );
|
||||
item->Plot( aPlotter, background );
|
||||
item->Plot( aPlotter, background, aPlotSettings );
|
||||
}
|
||||
|
||||
// Plot the foreground items
|
||||
for( const SCH_ITEM* item : other )
|
||||
{
|
||||
aPlotter->SetCurrentLineWidth( std::max( item->GetPenWidth(), defaultPenWidth ) );
|
||||
item->Plot( aPlotter, !background );
|
||||
item->Plot( aPlotter, !background, aPlotSettings );
|
||||
}
|
||||
|
||||
// After plotting the symbols as a group above (in `other`), we need to overplot the pins
|
||||
|
@ -1191,7 +1188,7 @@ void SCH_SCREEN::Plot( PLOTTER* aPlotter ) const
|
|||
for( SCH_FIELD field : sym->GetFields() )
|
||||
{
|
||||
field.ClearRenderCache();
|
||||
field.Plot( aPlotter, false );
|
||||
field.Plot( aPlotter, false, aPlotSettings );
|
||||
}
|
||||
|
||||
sym->PlotPins( aPlotter );
|
||||
|
@ -1203,7 +1200,7 @@ void SCH_SCREEN::Plot( PLOTTER* aPlotter ) const
|
|||
for( const SCH_ITEM* item : junctions )
|
||||
{
|
||||
aPlotter->SetCurrentLineWidth( std::max( item->GetPenWidth(), defaultPenWidth ) );
|
||||
item->Plot( aPlotter, !background );
|
||||
item->Plot( aPlotter, !background, aPlotSettings );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -256,7 +256,7 @@ public:
|
|||
*
|
||||
* @param[in] aPlotter The plotter object to plot to.
|
||||
*/
|
||||
void Plot( PLOTTER* aPlotter ) const;
|
||||
void Plot( PLOTTER* aPlotter, const SCH_PLOT_SETTINGS& aPlotSettings ) const;
|
||||
|
||||
/**
|
||||
* Remove \a aItem from the schematic associated with this screen.
|
||||
|
|
|
@ -111,7 +111,8 @@ void SCH_SHAPE::Rotate( const VECTOR2I& aCenter )
|
|||
}
|
||||
|
||||
|
||||
void SCH_SHAPE::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_SHAPE::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
int pen_size = GetPenWidth();
|
||||
|
||||
|
|
|
@ -95,7 +95,8 @@ public:
|
|||
|
||||
void AddPoint( const VECTOR2I& aPosition );
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
void GetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vector<MSG_PANEL_ITEM>& aList ) override;
|
||||
|
||||
|
|
|
@ -1102,7 +1102,8 @@ bool SCH_SHEET::HitTest( const BOX2I& aRect, bool aContained, int aAccuracy ) co
|
|||
}
|
||||
|
||||
|
||||
void SCH_SHEET::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_SHEET::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground && !aPlotter->GetColorMode() )
|
||||
return;
|
||||
|
@ -1147,11 +1148,11 @@ void SCH_SHEET::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
|||
|
||||
// Plot sheet pins
|
||||
for( SCH_SHEET_PIN* sheetPin : m_pins )
|
||||
sheetPin->Plot( aPlotter, aBackground );
|
||||
sheetPin->Plot( aPlotter, aBackground, aPlotSettings );
|
||||
|
||||
// Plot the fields
|
||||
for( const SCH_FIELD& field : m_fields )
|
||||
field.Plot( aPlotter, aBackground );
|
||||
field.Plot( aPlotter, aBackground, aPlotSettings );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -381,7 +381,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override;
|
||||
|
||||
|
|
|
@ -38,10 +38,10 @@
|
|||
#include <refdes_utils.h>
|
||||
#include <wx/log.h>
|
||||
#include <settings/settings_manager.h>
|
||||
#include <sch_plotter.h>
|
||||
#include <string_utils.h>
|
||||
|
||||
#include <utility>
|
||||
#include "plotters/plotter.h"
|
||||
|
||||
|
||||
std::unordered_map<TRANSFORM, int> SCH_SYMBOL::s_transformToOrientationCache;
|
||||
|
@ -2313,7 +2313,8 @@ bool SCH_SYMBOL::IsInNetlist() const
|
|||
}
|
||||
|
||||
|
||||
void SCH_SYMBOL::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_SYMBOL::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
return;
|
||||
|
@ -2364,39 +2365,41 @@ void SCH_SYMBOL::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
|||
for( SCH_FIELD field : m_fields )
|
||||
{
|
||||
field.ClearRenderCache();
|
||||
field.Plot( aPlotter, local_background );
|
||||
field.Plot( aPlotter, local_background, aPlotSettings );
|
||||
}
|
||||
}
|
||||
|
||||
if( m_DNP )
|
||||
PlotDNP( aPlotter );
|
||||
|
||||
SCH_SHEET_PATH* sheet = &Schematic()->CurrentSheet();
|
||||
|
||||
// Plot attributes to a hypertext menu
|
||||
std::vector<wxString> properties;
|
||||
SCH_SHEET_PATH* sheet = &Schematic()->CurrentSheet();
|
||||
|
||||
for( const SCH_FIELD& field : GetFields() )
|
||||
if( aPlotSettings.m_PDFPropertyPopups )
|
||||
{
|
||||
wxString text_field = field.GetShownText( sheet, false);
|
||||
std::vector<wxString> properties;
|
||||
|
||||
if( text_field.IsEmpty() )
|
||||
continue;
|
||||
for( const SCH_FIELD& field : GetFields() )
|
||||
{
|
||||
wxString text_field = field.GetShownText( sheet, false);
|
||||
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
field.GetName(), text_field ) );
|
||||
if( text_field.IsEmpty() )
|
||||
continue;
|
||||
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
field.GetName(), text_field ) );
|
||||
}
|
||||
|
||||
if( !m_part->GetKeyWords().IsEmpty() )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
_( "Keywords" ),
|
||||
m_part->GetKeyWords() ) );
|
||||
}
|
||||
|
||||
aPlotter->HyperlinkMenu( GetBoundingBox(), properties );
|
||||
}
|
||||
|
||||
if( !m_part->GetKeyWords().IsEmpty() )
|
||||
{
|
||||
properties.emplace_back( wxString::Format( wxT( "!%s = %s" ),
|
||||
_( "Keywords" ),
|
||||
m_part->GetKeyWords() ) );
|
||||
}
|
||||
|
||||
aPlotter->HyperlinkMenu( GetBoundingBox(), properties );
|
||||
|
||||
|
||||
|
||||
aPlotter->EndBlock( nullptr );
|
||||
|
||||
if( !m_part->IsPower() )
|
||||
|
|
|
@ -706,7 +706,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
/**
|
||||
* Plot just the symbol pins. This is separated to match the GAL display order. The pins
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#include <base_units.h>
|
||||
#include <pgm_base.h>
|
||||
#include <sch_edit_frame.h>
|
||||
#include <plotters/plotter.h>
|
||||
#include <sch_plotter.h>
|
||||
#include <widgets/msgpanel.h>
|
||||
#include <bitmaps.h>
|
||||
#include <string_utils.h>
|
||||
|
@ -351,7 +351,8 @@ void SCH_TEXT::ViewGetLayers( int aLayers[], int& aCount ) const
|
|||
}
|
||||
|
||||
|
||||
void SCH_TEXT::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_TEXT::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
return;
|
||||
|
|
|
@ -129,7 +129,8 @@ public:
|
|||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override
|
||||
{
|
||||
|
|
|
@ -375,11 +375,12 @@ BITMAPS SCH_TEXTBOX::GetMenuImage() const
|
|||
}
|
||||
|
||||
|
||||
void SCH_TEXTBOX::Plot( PLOTTER* aPlotter, bool aBackground ) const
|
||||
void SCH_TEXTBOX::Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const
|
||||
{
|
||||
if( aBackground )
|
||||
{
|
||||
SCH_SHAPE::Plot( aPlotter, aBackground );
|
||||
SCH_SHAPE::Plot( aPlotter, aBackground, aPlotSettings );
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -111,7 +111,8 @@ public:
|
|||
|
||||
BITMAPS GetMenuImage() const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground ) const override;
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground,
|
||||
const SCH_PLOT_SETTINGS& aPlotSettings ) const override;
|
||||
|
||||
EDA_ITEM* Clone() const override
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue