diff --git a/eeschema/CMakeLists.txt b/eeschema/CMakeLists.txt index 070dd48273..0f48fa8508 100644 --- a/eeschema/CMakeLists.txt +++ b/eeschema/CMakeLists.txt @@ -37,6 +37,8 @@ set(EESCHEMA_SRCS database.cpp delete.cpp delsheet.cpp + dialogs/dialog_plot_schematic_HPGL.cpp + dialogs/dialog_plot_schematic_HPGL_base.cpp dialogs/dialog_plot_schematic_PS.cpp dialogs/dialog_plot_schematic_PS_base.cpp dialog_annotate_base.cpp @@ -118,7 +120,6 @@ set(EESCHEMA_SRCS operations_on_items_lists.cpp pinedit.cpp plot.cpp - plothpgl.cpp plotdxf.cpp read_from_file_schematic_items_descriptions.cpp save_schemas.cpp diff --git a/eeschema/dialogs/dialog_plot_schematic_HPGL.cpp b/eeschema/dialogs/dialog_plot_schematic_HPGL.cpp new file mode 100644 index 0000000000..bc94d6aeb4 --- /dev/null +++ b/eeschema/dialogs/dialog_plot_schematic_HPGL.cpp @@ -0,0 +1,404 @@ +/** @file dialog_plot_schematic_HPGL.cpp + */ + +/* + * This program source code file is part of KICAD, a free EDA CAD application. + * + * Copyright (C) 1992-2010 Jean-Pieere Charras SetSizeHints( this ); + Centre(); +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::initDlg() +{ + + SetFocus(); // Make ESC key working + + // Set validators + m_SizeOption->SetSelection( m_pageSizeSelect ); + AddUnitSymbol( *m_penWidthTitle, g_UserUnit ); + PutValueInLocalUnits( *m_penWidthCtrl, g_HPGL_Pen_Descr. m_Pen_Diam, EESCHEMA_INTERNAL_UNIT ); + m_penSpeedCtrl->SetValue( g_HPGL_Pen_Descr. m_Pen_Speed ); + m_penNumCtrl->SetValue( g_HPGL_Pen_Descr. m_Pen_Num ); + +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::OnPlotCurrent( wxCommandEvent& event ) +{ + HPGL_Plot( false ); +} + +void DIALOG_PLOT_SCHEMATIC_HPGL::OnPlotAll( wxCommandEvent& event ) +{ + HPGL_Plot( true ); +} + +void DIALOG_PLOT_SCHEMATIC_HPGL::OnCancelClick( wxCommandEvent& event ) +{ + EndModal( 0 ); +} + +void DIALOG_PLOT_SCHEMATIC_HPGL::SetPageOffsetValue() +{ + wxString msg; + + m_pageSizeSelect = (PageFormatReq) m_SizeOption->GetSelection(); + if( m_pageSizeSelect != PAGE_DEFAULT ) + { + msg = ReturnStringFromValue( g_UserUnit, + Plot_sheet_list[m_pageSizeSelect]->m_Offset.x, + EESCHEMA_INTERNAL_UNIT ); + m_PlotOrgPosition_X->SetValue( msg ); + msg = ReturnStringFromValue( g_UserUnit, + Plot_sheet_list[m_pageSizeSelect]-> m_Offset.y, + EESCHEMA_INTERNAL_UNIT ); + m_PlotOrgPosition_Y->SetValue( msg ); + + m_PlotOrgPosition_X->Enable( TRUE ); + m_PlotOrgPosition_Y->Enable( TRUE ); + } + else + { + m_PlotOrgPosition_X->Enable( FALSE ); + m_PlotOrgPosition_Y->Enable( FALSE ); + } +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::AcceptPlotOffset( wxCommandEvent& event ) +{ + m_pageSizeSelect = (PageFormatReq) m_SizeOption->GetSelection(); + + if( m_pageSizeSelect != PAGE_DEFAULT ) + { + wxString msg = m_PlotOrgPosition_X->GetValue(); + Plot_sheet_list[m_pageSizeSelect]->m_Offset.x = + ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); + msg = m_PlotOrgPosition_Y->GetValue(); + Plot_sheet_list[m_pageSizeSelect]->m_Offset.y = + ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); + } +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::SetPenWidth( ) +{ + g_HPGL_Pen_Descr.m_Pen_Diam = ReturnValueFromTextCtrl( *m_penWidthCtrl, + EESCHEMA_INTERNAL_UNIT); + if( g_HPGL_Pen_Descr.m_Pen_Diam > 100 ) + g_HPGL_Pen_Descr.m_Pen_Diam = 100; + if( g_HPGL_Pen_Descr.m_Pen_Diam < 1 ) + g_HPGL_Pen_Descr.m_Pen_Diam = 1; +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::SetPenSpeed( ) +{ + g_HPGL_Pen_Descr.m_Pen_Speed = m_penSpeedCtrl->GetValue(); + if( g_HPGL_Pen_Descr.m_Pen_Speed > 40 ) + g_HPGL_Pen_Descr.m_Pen_Speed = 40; + if( g_HPGL_Pen_Descr.m_Pen_Speed < 1 ) + g_HPGL_Pen_Descr.m_Pen_Speed = 1; +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::SetPenNum( ) +{ + g_HPGL_Pen_Descr.m_Pen_Num = m_penNumCtrl->GetValue(); + if( g_HPGL_Pen_Descr.m_Pen_Num > 8 ) + g_HPGL_Pen_Descr.m_Pen_Num = 8; + if( g_HPGL_Pen_Descr.m_Pen_Num < 1 ) + g_HPGL_Pen_Descr.m_Pen_Num = 1; +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::HPGL_Plot( bool aPlotAll ) +{ + SetPenWidth( ); + SetPenNum( ); + SetPenSpeed( ); + + if( m_pageSizeSelect != PAGE_DEFAULT ) + { + Ki_PageDescr* plot_sheet = Plot_sheet_list[m_pageSizeSelect]; + wxString msg = m_PlotOrgPosition_X->GetValue(); + plot_sheet->m_Offset.x = + ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); + msg = m_PlotOrgPosition_Y->GetValue(); + plot_sheet->m_Offset.y = + ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); + } + + Plot_Schematic_HPGL( aPlotAll, m_pageSizeSelect ); +} + + +/* Function calculates the offsets and dimensions of any trace of the + * selected sheet + */ +void DIALOG_PLOT_SCHEMATIC_HPGL::ReturnSheetDims( BASE_SCREEN* screen, + wxSize& SheetSize, + wxPoint& SheetOffset ) +{ + Ki_PageDescr* PlotSheet; + + if( screen == NULL ) + screen = m_Parent->GetBaseScreen(); + + PlotSheet = screen->m_CurrentSheetDesc; + + SheetSize = PlotSheet->m_Size; + SheetOffset = PlotSheet->m_Offset; +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::Plot_Schematic_HPGL( bool aPlotAll, int HPGL_SheetSize ) +{ + wxString PlotFileName; + SCH_SCREEN* screen = m_Parent->GetScreen(); + SCH_SCREEN* oldscreen = screen; + SCH_SHEET_PATH* sheetpath, * oldsheetpath = m_Parent->GetSheet(); + Ki_PageDescr* PlotSheet; + wxSize SheetSize; + wxPoint SheetOffset, PlotOffset; + + /* When printing all pages, the printed page is not the current page. + * In complex hierarchies, we must setup references and others parameters + * in the printed SCH_SCREEN + * because in complex hierarchies a SCH_SCREEN (a schematic drawings) + * is shared between many sheets + */ + SCH_SHEET_LIST SheetList( NULL ); + + sheetpath = SheetList.GetFirst(); + SCH_SHEET_PATH list; + + while( true ) + { + if( aPlotAll ) + { + if( sheetpath == NULL ) + break; + list.Clear(); + if( list.BuildSheetPathInfoFromSheetPathValue( sheetpath->Path() ) ) + { + m_Parent->m_CurrentSheet = &list; + m_Parent->m_CurrentSheet->UpdateAllScreenReferences(); + m_Parent->SetSheetNumberAndCount(); + screen = m_Parent->m_CurrentSheet->LastScreen(); + ActiveScreen = screen; + } + else // Should not happen + return; + sheetpath = SheetList.GetNext(); + } + ReturnSheetDims( screen, SheetSize, SheetOffset ); + /* Calculation of conversion scales. */ + if( HPGL_SheetSize ) + PlotSheet = Plot_sheet_list[HPGL_SheetSize]; + else + PlotSheet = screen->m_CurrentSheetDesc; + /* 10x because eeschema works in mils, not decimals */ + double plot_scale = 10 * (double) PlotSheet->m_Size.x / + (double) SheetSize.x; + + /* Calculate offsets */ + PlotOffset.x = -SheetOffset.x; + PlotOffset.y = -SheetOffset.y; + + PlotFileName = m_Parent->GetUniqueFilenameForCurrentSheet() + + wxT( ".plt" ); + + SetLocaleTo_C_standard(); + Plot_1_Page_HPGL( PlotFileName, screen, PlotSheet, PlotOffset, + plot_scale ); + SetLocaleTo_Default(); + + if( !aPlotAll ) + break; + } + + ActiveScreen = oldscreen; + m_Parent->m_CurrentSheet = oldsheetpath; + m_Parent->m_CurrentSheet->UpdateAllScreenReferences(); + m_Parent->SetSheetNumberAndCount(); +} + + +void DIALOG_PLOT_SCHEMATIC_HPGL::Plot_1_Page_HPGL( const wxString& FileName, + SCH_SCREEN* screen, + Ki_PageDescr* sheet, + wxPoint& offset, + double plot_scale ) +{ + wxString msg; + + FILE* output_file = wxFopen( FileName, wxT( "wt" ) ); + + if( output_file == NULL ) + { + msg = wxT( "\n** " ); + msg += _( "Unable to create " ) + FileName + wxT( " **\n" ); + m_MsgBox->AppendText( msg ); + wxBell(); + return; + } + + SetLocaleTo_C_standard(); + msg.Printf( _( "Plot: %s " ), FileName.GetData() ); + m_MsgBox->AppendText( msg ); + + HPGL_PLOTTER* plotter = new HPGL_PLOTTER(); + plotter->set_paper_size( sheet ); + plotter->set_viewport( offset, plot_scale, 0 ); + plotter->set_default_line_width( g_DrawDefaultLineThickness ); + /* Init : */ + plotter->set_creator( wxT( "EESchema-HPGL" ) ); + plotter->set_filename( FileName ); + plotter->set_pen_speed( g_HPGL_Pen_Descr.m_Pen_Speed ); + plotter->set_pen_number( g_HPGL_Pen_Descr.m_Pen_Num ); + plotter->set_pen_diameter( g_HPGL_Pen_Descr.m_Pen_Diam ); + plotter->set_pen_overlap( g_HPGL_Pen_Descr.m_Pen_Diam / 2 ); + plotter->start_plot( output_file ); + + plotter->set_color( BLACK ); + if( m_plot_Sheet_Ref ) + m_Parent->PlotWorkSheet( plotter, screen ); + + PlotDrawlist( plotter, screen->EEDrawList ); + + plotter->end_plot(); + delete plotter; + SetLocaleTo_Default(); + + m_MsgBox->AppendText( wxT( "Ok\n" ) ); +} + + +/* Event handler for page size option + */ +void DIALOG_PLOT_SCHEMATIC_HPGL::OnPageSelected( wxCommandEvent& event ) +{ + m_pageSizeSelect = (PageFormatReq) m_SizeOption->GetSelection(); + SetPageOffsetValue(); +} + + diff --git a/eeschema/dialogs/dialog_plot_schematic_HPGL_base.cpp b/eeschema/dialogs/dialog_plot_schematic_HPGL_base.cpp new file mode 100644 index 0000000000..bd0c492759 --- /dev/null +++ b/eeschema/dialogs/dialog_plot_schematic_HPGL_base.cpp @@ -0,0 +1,143 @@ +/////////////////////////////////////////////////////////////////////////// +// C++ code generated with wxFormBuilder (version Sep 8 2010) +// http://www.wxformbuilder.org/ +// +// PLEASE DO "NOT" EDIT THIS FILE! +/////////////////////////////////////////////////////////////////////////// + +#include "dialog_plot_schematic_HPGL_base.h" + +/////////////////////////////////////////////////////////////////////////// + +DIALOG_PLOT_SCHEMATIC_HPGL_BASE::DIALOG_PLOT_SCHEMATIC_HPGL_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style ) +{ + this->SetSizeHints( wxDefaultSize, wxDefaultSize ); + + wxBoxSizer* bmainSizer; + bmainSizer = new wxBoxSizer( wxVERTICAL ); + + wxBoxSizer* bupperSizer; + bupperSizer = new wxBoxSizer( wxHORIZONTAL ); + + wxBoxSizer* bleftSizer; + bleftSizer = new wxBoxSizer( wxVERTICAL ); + + wxString m_SizeOptionChoices[] = { _("Schematic size"), _("Page size A4"), _("Page size A3"), _("Page size A2"), _("Page size A1"), _("Page size A0"), _("Page size A"), _("Page size B"), _("Page size C"), _("Page size D"), _("Page size E") }; + int m_SizeOptionNChoices = sizeof( m_SizeOptionChoices ) / sizeof( wxString ); + m_SizeOption = new wxRadioBox( this, wxID_ANY, _("Plot Page Size:"), wxDefaultPosition, wxDefaultSize, m_SizeOptionNChoices, m_SizeOptionChoices, 1, wxRA_SPECIFY_COLS ); + m_SizeOption->SetSelection( 1 ); + bleftSizer->Add( m_SizeOption, 0, wxALL|wxEXPAND, 5 ); + + m_Plot_Sheet_Ref_Ctrl = new wxCheckBox( this, wxID_ANY, _("Print page references"), wxDefaultPosition, wxDefaultSize, 0 ); + m_Plot_Sheet_Ref_Ctrl->SetValue(true); + bleftSizer->Add( m_Plot_Sheet_Ref_Ctrl, 0, wxALL|wxEXPAND, 5 ); + + bupperSizer->Add( bleftSizer, 1, wxEXPAND, 5 ); + + wxBoxSizer* sbSizerMiddle; + sbSizerMiddle = new wxBoxSizer( wxVERTICAL ); + + wxStaticBoxSizer* sbSizer1; + sbSizer1 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Pen control:") ), wxVERTICAL ); + + m_penWidthTitle = new wxStaticText( this, wxID_ANY, _("Pen Width"), wxDefaultPosition, wxDefaultSize, 0 ); + m_penWidthTitle->Wrap( -1 ); + sbSizer1->Add( m_penWidthTitle, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); + + m_penWidthCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); + sbSizer1->Add( m_penWidthCtrl, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 ); + + m_penSpeedTitle = new wxStaticText( this, wxID_ANY, _("Pen Speed ( cm/s )"), wxDefaultPosition, wxDefaultSize, 0 ); + m_penSpeedTitle->Wrap( -1 ); + sbSizer1->Add( m_penSpeedTitle, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); + + m_penSpeedCtrl = new wxSpinCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS, 1, 50, 20 ); + sbSizer1->Add( m_penSpeedCtrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + + m_penNumTitle = new wxStaticText( this, wxID_ANY, _("Pen Number"), wxDefaultPosition, wxDefaultSize, 0 ); + m_penNumTitle->Wrap( -1 ); + sbSizer1->Add( m_penNumTitle, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); + + m_penNumCtrl = new wxSpinCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS, 1, 8, 1 ); + sbSizer1->Add( m_penNumCtrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + + sbSizerMiddle->Add( sbSizer1, 0, wxEXPAND|wxALL, 5 ); + + wxStaticBoxSizer* sbSizer2; + sbSizer2 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Page offset:") ), wxVERTICAL ); + + m_offsetXTitle = new wxStaticText( this, wxID_ANY, _("Plot Offset X"), wxDefaultPosition, wxDefaultSize, 0 ); + m_offsetXTitle->Wrap( -1 ); + sbSizer2->Add( m_offsetXTitle, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); + + m_PlotOrgPosition_X = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); + sbSizer2->Add( m_PlotOrgPosition_X, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 ); + + m_offsetYTitle = new wxStaticText( this, wxID_ANY, _("Plot Offset Y"), wxDefaultPosition, wxDefaultSize, 0 ); + m_offsetYTitle->Wrap( -1 ); + sbSizer2->Add( m_offsetYTitle, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); + + m_PlotOrgPosition_Y = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); + sbSizer2->Add( m_PlotOrgPosition_Y, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + + sbSizerMiddle->Add( sbSizer2, 1, wxEXPAND|wxALL, 5 ); + + bupperSizer->Add( sbSizerMiddle, 1, wxEXPAND, 5 ); + + + bupperSizer->Add( 10, 10, 0, 0, 5 ); + + wxBoxSizer* bbuttonsSizer; + bbuttonsSizer = new wxBoxSizer( wxVERTICAL ); + + m_buttonPlotPage = new wxButton( this, wxID_ANY, _("&Plot Page"), wxDefaultPosition, wxDefaultSize, 0 ); + bbuttonsSizer->Add( m_buttonPlotPage, 0, wxALL|wxEXPAND, 5 ); + + m_buttonPlotAll = new wxButton( this, wxID_ANY, _("Plot A&LL"), wxDefaultPosition, wxDefaultSize, 0 ); + bbuttonsSizer->Add( m_buttonPlotAll, 0, wxALL|wxEXPAND, 5 ); + + m_buttonClose = new wxButton( this, wxID_ANY, _("Close"), wxDefaultPosition, wxDefaultSize, 0 ); + bbuttonsSizer->Add( m_buttonClose, 0, wxALL|wxEXPAND, 5 ); + + + bbuttonsSizer->Add( 10, 10, 1, wxEXPAND, 5 ); + + m_buttonOffset = new wxButton( this, wxID_ANY, _("&Accept Offset"), wxDefaultPosition, wxDefaultSize, 0 ); + bbuttonsSizer->Add( m_buttonOffset, 0, wxALL, 5 ); + + bupperSizer->Add( bbuttonsSizer, 0, wxALIGN_CENTER_VERTICAL, 5 ); + + bmainSizer->Add( bupperSizer, 0, wxEXPAND, 5 ); + + m_staticText1 = new wxStaticText( this, wxID_ANY, _("Messages :"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticText1->Wrap( -1 ); + bmainSizer->Add( m_staticText1, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); + + m_MsgBox = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_READONLY ); + m_MsgBox->SetMinSize( wxSize( -1,150 ) ); + + bmainSizer->Add( m_MsgBox, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + + this->SetSizer( bmainSizer ); + this->Layout(); + + this->Centre( wxBOTH ); + + // Connect Events + m_SizeOption->Connect( wxEVT_COMMAND_RADIOBOX_SELECTED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnPageSelected ), NULL, this ); + m_buttonPlotPage->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnPlotCurrent ), NULL, this ); + m_buttonPlotAll->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnPlotAll ), NULL, this ); + m_buttonClose->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnCancelClick ), NULL, this ); + m_buttonOffset->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::AcceptPlotOffset ), NULL, this ); +} + +DIALOG_PLOT_SCHEMATIC_HPGL_BASE::~DIALOG_PLOT_SCHEMATIC_HPGL_BASE() +{ + // Disconnect Events + m_SizeOption->Disconnect( wxEVT_COMMAND_RADIOBOX_SELECTED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnPageSelected ), NULL, this ); + m_buttonPlotPage->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnPlotCurrent ), NULL, this ); + m_buttonPlotAll->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnPlotAll ), NULL, this ); + m_buttonClose->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::OnCancelClick ), NULL, this ); + m_buttonOffset->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_HPGL_BASE::AcceptPlotOffset ), NULL, this ); + +} diff --git a/eeschema/dialogs/dialog_plot_schematic_HPGL_base.fbp b/eeschema/dialogs/dialog_plot_schematic_HPGL_base.fbp new file mode 100644 index 0000000000..3617fae332 --- /dev/null +++ b/eeschema/dialogs/dialog_plot_schematic_HPGL_base.fbp @@ -0,0 +1,1222 @@ + + + + + + C++ + 1 + source_name + 0 + UTF-8 + connect + dialog_plot_schematic_HPGL_base + 1000 + none + 1 + dialog_plot_schematic_HPGL + + . + + 1 + 1 + 0 + 0 + + + wxBOTH + + 1 + 1 + impl_virtual + + + + 0 + wxID_ANY + + + DIALOG_PLOT_SCHEMATIC_HPGL_BASE + + 387,408 + wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER + + EESchema Plot HPGL + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + bmainSizer + wxVERTICAL + none + + 5 + wxEXPAND + 0 + + + bupperSizer + wxHORIZONTAL + none + + 5 + wxEXPAND + 1 + + + bleftSizer + wxVERTICAL + none + + 5 + wxALL|wxEXPAND + 0 + + + "Schematic size" "Page size A4" "Page size A3" "Page size A2" "Page size A1" "Page size A0" "Page size A" "Page size B" "Page size C" "Page size D" "Page size E" + + 1 + 1 + + + 0 + wxID_ANY + Plot Page Size: + 1 + + + m_SizeOption + protected + + 1 + + wxRA_SPECIFY_COLS + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + OnPageSelected + + + + + + + + + + 5 + wxALL|wxEXPAND + 0 + + + 1 + + 1 + 1 + + + 0 + wxID_ANY + Print page references + + + m_Plot_Sheet_Ref_Ctrl + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxEXPAND + 1 + + + sbSizerMiddle + wxVERTICAL + none + + 5 + wxEXPAND|wxALL + 0 + + wxID_ANY + Pen control: + + sbSizer1 + wxVERTICAL + none + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + Pen Width + + + m_penWidthTitle + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + + 0 + + m_penWidthCtrl + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + Pen Speed ( cm/s ) + + + m_penSpeedTitle + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + 20 + 50 + + 1 + + m_penSpeedCtrl + protected + + + wxSP_ARROW_KEYS + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + Pen Number + + + m_penNumTitle + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + 1 + 8 + + 1 + + m_penNumCtrl + protected + + + wxSP_ARROW_KEYS + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxEXPAND|wxALL + 1 + + wxID_ANY + Page offset: + + sbSizer2 + wxVERTICAL + none + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + Plot Offset X + + + m_offsetXTitle + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + + 0 + + m_PlotOrgPosition_X + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + Plot Offset Y + + + m_offsetYTitle + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + + 0 + + m_PlotOrgPosition_Y + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + + 0 + + 10 + protected + 10 + + + + 5 + wxALIGN_CENTER_VERTICAL + 0 + + + bbuttonsSizer + wxVERTICAL + none + + 5 + wxALL|wxEXPAND + 0 + + + + 1 + 0 + 1 + + + 0 + wxID_ANY + &Plot Page + + + m_buttonPlotPage + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + OnPlotCurrent + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxALL|wxEXPAND + 0 + + + + 1 + 0 + 1 + + + 0 + wxID_ANY + Plot A&LL + + + m_buttonPlotAll + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + OnPlotAll + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxALL|wxEXPAND + 0 + + + + 1 + 0 + 1 + + + 0 + wxID_ANY + Close + + + m_buttonClose + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + OnCancelClick + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxEXPAND + 1 + + 10 + protected + 10 + + + + 5 + wxALL + 0 + + + + 1 + 0 + 1 + + + 0 + wxID_ANY + &Accept Offset + + + m_buttonOffset + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + AcceptPlotOffset + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + + + 1 + 1 + + + 0 + wxID_ANY + Messages : + + + m_staticText1 + protected + + + + + + + wxFILTER_NONE + wxDefaultValidator + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 1 + + + + 1 + 1 + + + 0 + wxID_ANY + + 0 + -1,150 + m_MsgBox + protected + + + wxTE_MULTILINE|wxTE_READONLY + + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/eeschema/dialogs/dialog_plot_schematic_HPGL_base.h b/eeschema/dialogs/dialog_plot_schematic_HPGL_base.h new file mode 100644 index 0000000000..b7cb6a6770 --- /dev/null +++ b/eeschema/dialogs/dialog_plot_schematic_HPGL_base.h @@ -0,0 +1,75 @@ +/////////////////////////////////////////////////////////////////////////// +// C++ code generated with wxFormBuilder (version Sep 8 2010) +// http://www.wxformbuilder.org/ +// +// PLEASE DO "NOT" EDIT THIS FILE! +/////////////////////////////////////////////////////////////////////////// + +#ifndef __dialog_plot_schematic_HPGL_base__ +#define __dialog_plot_schematic_HPGL_base__ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/////////////////////////////////////////////////////////////////////////// + + +/////////////////////////////////////////////////////////////////////////////// +/// Class DIALOG_PLOT_SCHEMATIC_HPGL_BASE +/////////////////////////////////////////////////////////////////////////////// +class DIALOG_PLOT_SCHEMATIC_HPGL_BASE : public wxDialog +{ + private: + + protected: + wxRadioBox* m_SizeOption; + wxCheckBox* m_Plot_Sheet_Ref_Ctrl; + wxStaticText* m_penWidthTitle; + wxTextCtrl* m_penWidthCtrl; + wxStaticText* m_penSpeedTitle; + wxSpinCtrl* m_penSpeedCtrl; + wxStaticText* m_penNumTitle; + wxSpinCtrl* m_penNumCtrl; + wxStaticText* m_offsetXTitle; + wxTextCtrl* m_PlotOrgPosition_X; + wxStaticText* m_offsetYTitle; + wxTextCtrl* m_PlotOrgPosition_Y; + + wxButton* m_buttonPlotPage; + wxButton* m_buttonPlotAll; + wxButton* m_buttonClose; + + wxButton* m_buttonOffset; + wxStaticText* m_staticText1; + wxTextCtrl* m_MsgBox; + + // Virtual event handlers, overide them in your derived class + virtual void OnPageSelected( wxCommandEvent& event ) { event.Skip(); } + virtual void OnPlotCurrent( wxCommandEvent& event ) { event.Skip(); } + virtual void OnPlotAll( wxCommandEvent& event ) { event.Skip(); } + virtual void OnCancelClick( wxCommandEvent& event ) { event.Skip(); } + virtual void AcceptPlotOffset( wxCommandEvent& event ) { event.Skip(); } + + + public: + + DIALOG_PLOT_SCHEMATIC_HPGL_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("EESchema Plot HPGL"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 387,408 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); + ~DIALOG_PLOT_SCHEMATIC_HPGL_BASE(); + +}; + +#endif //__dialog_plot_schematic_HPGL_base__ diff --git a/eeschema/dialogs/dialog_plot_schematic_PS.cpp b/eeschema/dialogs/dialog_plot_schematic_PS.cpp index cf74745610..ad2da36101 100644 --- a/eeschema/dialogs/dialog_plot_schematic_PS.cpp +++ b/eeschema/dialogs/dialog_plot_schematic_PS.cpp @@ -1,4 +1,4 @@ -/** @file dialog_plot_schematic_ps.cpp +/** @file dialog_plot_schematic_PS.cpp */ /* @@ -60,8 +60,8 @@ private: static bool m_plot_Sheet_Ref; bool m_select_PlotAll; private: - void OnPlotPsCurrentExecuteClick( wxCommandEvent& event ); - void OnPlotPsAllExecuteClick( wxCommandEvent& event ); + void OnPlotCurrent( wxCommandEvent& event ); + void OnPlotAll( wxCommandEvent& event ); void OnCancelClick( wxCommandEvent& event ); void initDlg(); @@ -71,7 +71,7 @@ private: SCH_SCREEN* screen, Ki_PageDescr* sheet, wxPoint plot_offset, double scale ); }; -/* static variables (staic to remember last state: */ +/* static members (static to remember last state): */ bool DIALOG_PLOT_SCHEMATIC_PS::m_plotColorOpt = false; int DIALOG_PLOT_SCHEMATIC_PS:: m_pageSizeSelect = PAGE_SIZE_AUTO; bool DIALOG_PLOT_SCHEMATIC_PS::m_plot_Sheet_Ref = true; @@ -120,7 +120,7 @@ void DIALOG_PLOT_SCHEMATIC_PS::initDlg() * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON */ -void DIALOG_PLOT_SCHEMATIC_PS::OnPlotPsCurrentExecuteClick( wxCommandEvent& event ) +void DIALOG_PLOT_SCHEMATIC_PS::OnPlotCurrent( wxCommandEvent& event ) { m_select_PlotAll = false; @@ -134,7 +134,7 @@ void DIALOG_PLOT_SCHEMATIC_PS::OnPlotPsCurrentExecuteClick( wxCommandEvent& even * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON1 */ -void DIALOG_PLOT_SCHEMATIC_PS::OnPlotPsAllExecuteClick( wxCommandEvent& event ) +void DIALOG_PLOT_SCHEMATIC_PS::OnPlotAll( wxCommandEvent& event ) { m_select_PlotAll = TRUE; diff --git a/eeschema/dialogs/dialog_plot_schematic_PS_base.cpp b/eeschema/dialogs/dialog_plot_schematic_PS_base.cpp index cece212a97..0acabde520 100644 --- a/eeschema/dialogs/dialog_plot_schematic_PS_base.cpp +++ b/eeschema/dialogs/dialog_plot_schematic_PS_base.cpp @@ -19,9 +19,9 @@ DIALOG_PLOT_SCHEMATIC_PS_BASE::DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, wxBoxSizer* bupperSizer; bupperSizer = new wxBoxSizer( wxHORIZONTAL ); - wxString m_SizeOptionChoices[] = { wxT("Schematic size"), wxT("Force size A4"), wxT("Force size A") }; + wxString m_SizeOptionChoices[] = { _("Schematic size"), _("Force size A4"), _("Force size A") }; int m_SizeOptionNChoices = sizeof( m_SizeOptionChoices ) / sizeof( wxString ); - m_SizeOption = new wxRadioBox( this, wxID_ANY, wxT("Plot Page Size:"), wxDefaultPosition, wxDefaultSize, m_SizeOptionNChoices, m_SizeOptionChoices, 1, wxRA_SPECIFY_COLS ); + m_SizeOption = new wxRadioBox( this, wxID_ANY, _("Plot Page Size:"), wxDefaultPosition, wxDefaultSize, m_SizeOptionNChoices, m_SizeOptionChoices, 1, wxRA_SPECIFY_COLS ); m_SizeOption->SetSelection( 0 ); bupperSizer->Add( m_SizeOption, 1, wxALL, 5 ); @@ -31,13 +31,13 @@ DIALOG_PLOT_SCHEMATIC_PS_BASE::DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, wxBoxSizer* sbSizerMiddle; sbSizerMiddle = new wxBoxSizer( wxVERTICAL ); - wxString m_PlotPSColorOptionChoices[] = { wxT("B/W"), wxT("Color") }; + wxString m_PlotPSColorOptionChoices[] = { _("B/W"), _("Color") }; int m_PlotPSColorOptionNChoices = sizeof( m_PlotPSColorOptionChoices ) / sizeof( wxString ); - m_PlotPSColorOption = new wxRadioBox( this, wxID_ANY, wxT("Plot Mode:"), wxDefaultPosition, wxDefaultSize, m_PlotPSColorOptionNChoices, m_PlotPSColorOptionChoices, 1, wxRA_SPECIFY_COLS ); + m_PlotPSColorOption = new wxRadioBox( this, wxID_ANY, _("Plot Mode:"), wxDefaultPosition, wxDefaultSize, m_PlotPSColorOptionNChoices, m_PlotPSColorOptionChoices, 1, wxRA_SPECIFY_COLS ); m_PlotPSColorOption->SetSelection( 0 ); sbSizerMiddle->Add( m_PlotPSColorOption, 0, wxALL|wxEXPAND, 5 ); - m_Plot_Sheet_Ref_Ctrl = new wxCheckBox( this, wxID_ANY, wxT("Print page references"), wxDefaultPosition, wxDefaultSize, 0 ); + m_Plot_Sheet_Ref_Ctrl = new wxCheckBox( this, wxID_ANY, _("Print page references"), wxDefaultPosition, wxDefaultSize, 0 ); m_Plot_Sheet_Ref_Ctrl->SetValue(true); sbSizerMiddle->Add( m_Plot_Sheet_Ref_Ctrl, 0, wxALL|wxEXPAND, 5 ); @@ -49,13 +49,13 @@ DIALOG_PLOT_SCHEMATIC_PS_BASE::DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, wxBoxSizer* bbuttonsSizer; bbuttonsSizer = new wxBoxSizer( wxVERTICAL ); - m_buttonPlotPage = new wxButton( this, wxID_ANY, wxT("&Plot Page"), wxDefaultPosition, wxDefaultSize, 0 ); + m_buttonPlotPage = new wxButton( this, wxID_ANY, _("&Plot Page"), wxDefaultPosition, wxDefaultSize, 0 ); bbuttonsSizer->Add( m_buttonPlotPage, 0, wxALL|wxEXPAND, 5 ); - m_buttonPlotAll = new wxButton( this, wxID_ANY, wxT("Plot A&LL"), wxDefaultPosition, wxDefaultSize, 0 ); + m_buttonPlotAll = new wxButton( this, wxID_ANY, _("Plot A&LL"), wxDefaultPosition, wxDefaultSize, 0 ); bbuttonsSizer->Add( m_buttonPlotAll, 0, wxALL|wxEXPAND, 5 ); - m_buttonClose = new wxButton( this, wxID_ANY, wxT("Close"), wxDefaultPosition, wxDefaultSize, 0 ); + m_buttonClose = new wxButton( this, wxID_ANY, _("Close"), wxDefaultPosition, wxDefaultSize, 0 ); bbuttonsSizer->Add( m_buttonClose, 0, wxALL|wxEXPAND, 5 ); bupperSizer->Add( bbuttonsSizer, 0, wxALIGN_CENTER_VERTICAL, 5 ); @@ -65,7 +65,7 @@ DIALOG_PLOT_SCHEMATIC_PS_BASE::DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, wxBoxSizer* bSizerLineWidth; bSizerLineWidth = new wxBoxSizer( wxHORIZONTAL ); - m_defaultLineWidthTitle = new wxStaticText( this, wxID_ANY, wxT("Default line width:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_defaultLineWidthTitle = new wxStaticText( this, wxID_ANY, _("Default line width:"), wxDefaultPosition, wxDefaultSize, 0 ); m_defaultLineWidthTitle->Wrap( -1 ); bSizerLineWidth->Add( m_defaultLineWidthTitle, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 ); @@ -74,7 +74,7 @@ DIALOG_PLOT_SCHEMATIC_PS_BASE::DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, bmainSizer->Add( bSizerLineWidth, 0, wxEXPAND, 5 ); - m_staticText1 = new wxStaticText( this, wxID_ANY, wxT("Messages :"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticText1 = new wxStaticText( this, wxID_ANY, _("Messages :"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText1->Wrap( -1 ); bmainSizer->Add( m_staticText1, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); @@ -89,16 +89,16 @@ DIALOG_PLOT_SCHEMATIC_PS_BASE::DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, this->Centre( wxBOTH ); // Connect Events - m_buttonPlotPage->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotPsCurrentExecuteClick ), NULL, this ); - m_buttonPlotAll->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotPsAllExecuteClick ), NULL, this ); + m_buttonPlotPage->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotCurrent ), NULL, this ); + m_buttonPlotAll->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotAll ), NULL, this ); m_buttonClose->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnCancelClick ), NULL, this ); } DIALOG_PLOT_SCHEMATIC_PS_BASE::~DIALOG_PLOT_SCHEMATIC_PS_BASE() { // Disconnect Events - m_buttonPlotPage->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotPsCurrentExecuteClick ), NULL, this ); - m_buttonPlotAll->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotPsAllExecuteClick ), NULL, this ); + m_buttonPlotPage->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotCurrent ), NULL, this ); + m_buttonPlotAll->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnPlotAll ), NULL, this ); m_buttonClose->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PLOT_SCHEMATIC_PS_BASE::OnCancelClick ), NULL, this ); } diff --git a/eeschema/dialogs/dialog_plot_schematic_PS_base.fbp b/eeschema/dialogs/dialog_plot_schematic_PS_base.fbp index dce15fc4e7..032e0f3f0e 100644 --- a/eeschema/dialogs/dialog_plot_schematic_PS_base.fbp +++ b/eeschema/dialogs/dialog_plot_schematic_PS_base.fbp @@ -12,7 +12,7 @@ dialog_plot_schematic_PS_base 1000 none - 0 + 1 dialog_plot_schematic_PS . @@ -339,7 +339,7 @@ - OnPlotPsCurrentExecuteClick + OnPlotCurrent @@ -396,7 +396,7 @@ - OnPlotPsAllExecuteClick + OnPlotAll diff --git a/eeschema/dialogs/dialog_plot_schematic_PS_base.h b/eeschema/dialogs/dialog_plot_schematic_PS_base.h index 46596d73bf..ebc999b829 100644 --- a/eeschema/dialogs/dialog_plot_schematic_PS_base.h +++ b/eeschema/dialogs/dialog_plot_schematic_PS_base.h @@ -8,6 +8,8 @@ #ifndef __dialog_plot_schematic_PS_base__ #define __dialog_plot_schematic_PS_base__ +#include + #include #include #include @@ -46,14 +48,14 @@ class DIALOG_PLOT_SCHEMATIC_PS_BASE : public wxDialog wxTextCtrl* m_MsgBox; // Virtual event handlers, overide them in your derived class - virtual void OnPlotPsCurrentExecuteClick( wxCommandEvent& event ) { event.Skip(); } - virtual void OnPlotPsAllExecuteClick( wxCommandEvent& event ) { event.Skip(); } + virtual void OnPlotCurrent( wxCommandEvent& event ) { event.Skip(); } + virtual void OnPlotAll( wxCommandEvent& event ) { event.Skip(); } virtual void OnCancelClick( wxCommandEvent& event ) { event.Skip(); } public: - DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = wxT("EESchema Plot PS"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 387,365 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); + DIALOG_PLOT_SCHEMATIC_PS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("EESchema Plot PS"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 387,365 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); ~DIALOG_PLOT_SCHEMATIC_PS_BASE(); }; diff --git a/eeschema/plothpgl.cpp b/eeschema/plothpgl.cpp deleted file mode 100644 index c53599b7a5..0000000000 --- a/eeschema/plothpgl.cpp +++ /dev/null @@ -1,768 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: plothpgl.cpp -// Purpose: -// Author: jean-pierre Charras -// Modified by: -// Created: 04/02/2006 16:54:19 -// RCS-ID: -// Copyright: License GNU -// License: -///////////////////////////////////////////////////////////////////////////// - -// Generated by DialogBlocks (unregistered), 04/02/2006 16:54:19 - -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma implementation "plothpgl.h" -#endif - -////@begin includes -////@end includes - -#include "fctsys.h" -#include "gr_basic.h" -#include "common.h" -#include "confirm.h" -#include "plot_common.h" -#include "worksheet.h" - -#include "program.h" -#include "general.h" -#include "protos.h" -#include "plothpgl.h" - - -////@begin XPM images -////@end XPM images - -FILE* PlotOutput; -int HPGL_SizeSelect; - -enum PageFormatReq -{ - PAGE_DEFAULT = 0, - PAGE_SIZE_A4, - PAGE_SIZE_A3, - PAGE_SIZE_A2, - PAGE_SIZE_A1, - PAGE_SIZE_A0, - PAGE_SIZE_A, - PAGE_SIZE_B, - PAGE_SIZE_C, - PAGE_SIZE_D, - PAGE_SIZE_E -}; - -static Ki_PageDescr* Plot_sheet_list[] = -{ - NULL, - &g_Sheet_A4, - &g_Sheet_A3, - &g_Sheet_A2, - &g_Sheet_A1, - &g_Sheet_A0, - &g_Sheet_A, - &g_Sheet_B, - &g_Sheet_C, - &g_Sheet_D, - &g_Sheet_E, - &g_Sheet_GERBER, - &g_Sheet_user -}; - - -void WinEDA_SchematicFrame::ToPlot_HPGL( wxCommandEvent& event ) -{ - WinEDA_PlotHPGLFrame* HPGL_frame = new WinEDA_PlotHPGLFrame( this ); - - HPGL_frame->ShowModal(); - HPGL_frame->Destroy(); -} - - -/*! - * WinEDA_PlotHPGLFrame type definition - */ - -IMPLEMENT_DYNAMIC_CLASS( WinEDA_PlotHPGLFrame, wxDialog ) - -/*! - * WinEDA_PlotHPGLFrame event table definition - */ - -BEGIN_EVENT_TABLE( WinEDA_PlotHPGLFrame, wxDialog ) - -////@begin WinEDA_PlotHPGLFrame event table entries - EVT_RADIOBOX( ID_RADIOBOX, WinEDA_PlotHPGLFrame::OnRadioboxSelected ) - - EVT_SPINCTRL( ID_PEN_WIDTH_UPDATED, - WinEDA_PlotHPGLFrame::OnPenWidthUpdatedUpdated ) - - EVT_SPINCTRL( ID_PEN_SPEED_UPDATED, - WinEDA_PlotHPGLFrame::OnPenSpeedUpdatedUpdated ) - - EVT_SPINCTRL( ID_PEN_NUMBER_UPDATED, - WinEDA_PlotHPGLFrame::OnPenNumberUpdatedUpdated ) - - EVT_BUTTON( ID_PLOT_HPGL_CURRENT_EXECUTE, - WinEDA_PlotHPGLFrame::OnPlotHpglCurrentExecuteClick ) - - EVT_BUTTON( ID_PLOT_HPGL_ALL_EXECUTE, - WinEDA_PlotHPGLFrame::OnPlotHpglAllExecuteClick ) - - EVT_BUTTON( wxID_CANCEL, WinEDA_PlotHPGLFrame::OnCancelClick ) - - EVT_BUTTON( ID_PLOT_ACCEPT_OFFSET, - WinEDA_PlotHPGLFrame::OnPlotAcceptOffsetClick ) - -////@end WinEDA_PlotHPGLFrame event table entries - -END_EVENT_TABLE() -/*! - * WinEDA_PlotHPGLFrame constructors - */ - -WinEDA_PlotHPGLFrame::WinEDA_PlotHPGLFrame() -{ -} - - -WinEDA_PlotHPGLFrame::WinEDA_PlotHPGLFrame( WinEDA_DrawFrame* parent, - wxWindowID id, - const wxString& caption, - const wxPoint& pos, - const wxSize& size, - long style ) -{ - m_Parent = parent; - Create( parent, id, caption, pos, size, style ); - SetPageOffsetValue(); -} - - -/*! - * WinEDA_PlotHPGLFrame creator - */ - -bool WinEDA_PlotHPGLFrame::Create( wxWindow* parent, - wxWindowID id, - const wxString& caption, - const wxPoint& pos, - const wxSize& size, - long style ) -{ -////@begin WinEDA_PlotHPGLFrame member initialization - m_SizeOption = NULL; - m_ButtPenWidth = NULL; - m_ButtPenSpeed = NULL; - m_ButtPenNum = NULL; - m_PlotOrgPosition_X = NULL; - m_PlotOrgPosition_Y = NULL; - m_btClose = NULL; - m_MsgBox = NULL; - -////@end WinEDA_PlotHPGLFrame member initialization - -////@begin WinEDA_PlotHPGLFrame creation - SetExtraStyle( wxWS_EX_BLOCK_EVENTS ); - wxDialog::Create( parent, id, caption, pos, size, style ); - - CreateControls(); - if( GetSizer() ) - { - GetSizer()->SetSizeHints( this ); - } - Centre(); - -////@end WinEDA_PlotHPGLFrame creation - return true; -} - - -/*! - * Control creation for WinEDA_PlotHPGLFrame - */ - -void WinEDA_PlotHPGLFrame::CreateControls() -{ -////@begin WinEDA_PlotHPGLFrame content construction - // Generated by DialogBlocks, 24/04/2009 14:24:58 (unregistered) - - WinEDA_PlotHPGLFrame* itemDialog1 = this; - - wxBoxSizer* itemBoxSizer2 = new wxBoxSizer( wxVERTICAL ); - - itemDialog1->SetSizer( itemBoxSizer2 ); - - wxBoxSizer* itemBoxSizer3 = new wxBoxSizer( wxHORIZONTAL ); - itemBoxSizer2->Add( itemBoxSizer3, 0, wxALIGN_CENTER_HORIZONTAL | wxALL, 5 ); - - wxBoxSizer* itemBoxSizer4 = new wxBoxSizer( wxVERTICAL ); - itemBoxSizer3->Add( itemBoxSizer4, 0, wxGROW | wxALL, 5 ); - - wxArrayString m_SizeOptionStrings; - m_SizeOptionStrings.Add( _( "Sheet Size" ) ); - m_SizeOptionStrings.Add( _( "Page Size A4" ) ); - m_SizeOptionStrings.Add( _( "Page Size A3" ) ); - m_SizeOptionStrings.Add( _( "Page Size A2" ) ); - m_SizeOptionStrings.Add( _( "Page Size A1" ) ); - m_SizeOptionStrings.Add( _( "Page Size A0" ) ); - m_SizeOptionStrings.Add( _( "Page Size A" ) ); - m_SizeOptionStrings.Add( _( "Page Size B" ) ); - m_SizeOptionStrings.Add( _( "Page Size C" ) ); - m_SizeOptionStrings.Add( _( "Page Size D" ) ); - m_SizeOptionStrings.Add( _( "Page Size E" ) ); - m_SizeOption = - new wxRadioBox( itemDialog1, ID_RADIOBOX, _( "Plot page size:" ), - wxDefaultPosition, wxDefaultSize, m_SizeOptionStrings, - 1, wxRA_SPECIFY_COLS ); - m_SizeOption->SetSelection( 0 ); - itemBoxSizer4->Add( m_SizeOption, 0, wxALIGN_LEFT | wxALL, 5 ); - - wxBoxSizer* itemBoxSizer6 = new wxBoxSizer( wxVERTICAL ); - itemBoxSizer3->Add( itemBoxSizer6, 0, wxALIGN_TOP | wxALL, 5 ); - - wxStaticBox* itemStaticBoxSizer7Static = - new wxStaticBox( itemDialog1, wxID_ANY, _( "Pen control:" ) ); - wxStaticBoxSizer* itemStaticBoxSizer7 = - new wxStaticBoxSizer( itemStaticBoxSizer7Static, wxVERTICAL ); - itemBoxSizer6->Add( itemStaticBoxSizer7, - 0, - wxALIGN_CENTER_HORIZONTAL | wxALL, - 5 ); - - wxStaticText* itemStaticText8 = new wxStaticText( itemDialog1, - wxID_STATIC, - _( "Pen Width ( mils )" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemStaticBoxSizer7->Add( - itemStaticText8, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxTOP | - wxADJUST_MINSIZE, - 5 ); - - m_ButtPenWidth = - new wxSpinCtrl( itemDialog1, ID_PEN_WIDTH_UPDATED, _T( "1" ), - wxDefaultPosition, wxDefaultSize, - wxSP_ARROW_KEYS | wxSP_WRAP, 1, 100, 1 ); - itemStaticBoxSizer7->Add( m_ButtPenWidth, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxBOTTOM, - 5 ); - - wxStaticText* itemStaticText10 = new wxStaticText( itemDialog1, - wxID_STATIC, - _( "Pen Speed ( cm/s )" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemStaticBoxSizer7->Add( itemStaticText10, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxTOP | - wxADJUST_MINSIZE, - 5 ); - - m_ButtPenSpeed = - new wxSpinCtrl( itemDialog1, ID_PEN_SPEED_UPDATED, _T( "1" ), - wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS, - 1, 100, 1 ); - itemStaticBoxSizer7->Add( m_ButtPenSpeed, - 0, - wxALIGN_CENTER_HORIZONTAL | wxLEFT | wxRIGHT | - wxBOTTOM, - 5 ); - - wxStaticText* itemStaticText12 = new wxStaticText( itemDialog1, - wxID_STATIC, - _( "Pen Number" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemStaticBoxSizer7->Add( itemStaticText12, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxTOP | - wxADJUST_MINSIZE, - 5 ); - - m_ButtPenNum = new wxSpinCtrl( itemDialog1, ID_PEN_NUMBER_UPDATED, - _T( "1" ), wxDefaultPosition, wxDefaultSize, - wxSP_ARROW_KEYS, 1, 8, 1 ); - itemStaticBoxSizer7->Add( m_ButtPenNum, - 0, - wxALIGN_CENTER_HORIZONTAL | wxLEFT | wxRIGHT | - wxBOTTOM, - 5 ); - - wxStaticBox* itemStaticBoxSizer14Static = - new wxStaticBox( itemDialog1, wxID_ANY, _( "Page offset:" ) ); - wxStaticBoxSizer* itemStaticBoxSizer14 = - new wxStaticBoxSizer( itemStaticBoxSizer14Static, wxVERTICAL ); - itemBoxSizer6->Add( itemStaticBoxSizer14, 0, wxALIGN_LEFT | wxALL, 5 ); - - wxStaticText* itemStaticText15 = new wxStaticText( itemDialog1, - wxID_STATIC, - _( "Plot Offset X" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemStaticBoxSizer14->Add( itemStaticText15, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxTOP | - wxADJUST_MINSIZE, - 5 ); - - m_PlotOrgPosition_X = new wxTextCtrl( itemDialog1, ID_TEXTCTRL1, - _T( "" ), wxDefaultPosition, - wxDefaultSize, 0 ); - itemStaticBoxSizer14->Add( m_PlotOrgPosition_X, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxBOTTOM, - 5 ); - - wxStaticText* itemStaticText17 = new wxStaticText( itemDialog1, - wxID_STATIC, - _( "Plot Offset Y" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemStaticBoxSizer14->Add( itemStaticText17, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxTOP | - wxADJUST_MINSIZE, - 5 ); - - m_PlotOrgPosition_Y = new wxTextCtrl( itemDialog1, ID_TEXTCTRL2, _T( "" ), - wxDefaultPosition, wxDefaultSize, 0 ); - itemStaticBoxSizer14->Add( m_PlotOrgPosition_Y, - 0, - wxALIGN_LEFT | wxLEFT | wxRIGHT | wxBOTTOM, - 5 ); - - itemBoxSizer3->Add( 5, 5, 0, wxALIGN_CENTER_VERTICAL | wxALL, 5 ); - - wxBoxSizer* itemBoxSizer20 = new wxBoxSizer( wxVERTICAL ); - itemBoxSizer3->Add( itemBoxSizer20, - 0, - wxALIGN_TOP | wxLEFT | wxTOP | wxBOTTOM, - 5 ); - - wxButton* itemButton21 = new wxButton( itemDialog1, - ID_PLOT_HPGL_CURRENT_EXECUTE, - _( "&Plot Page" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemButton21->SetDefault(); - itemBoxSizer20->Add( itemButton21, 0, wxGROW | wxALL, 5 ); - - wxButton* itemButton22 = new wxButton( itemDialog1, - ID_PLOT_HPGL_ALL_EXECUTE, - _( "Plot A&LL" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemBoxSizer20->Add( itemButton22, 0, wxGROW | wxALL, 5 ); - - m_btClose = new wxButton( itemDialog1, wxID_CANCEL, _( "&Close" ), - wxDefaultPosition, wxDefaultSize, - 0 ); - itemBoxSizer20->Add( m_btClose, 0, wxGROW | wxALL, 5 ); - - itemBoxSizer20->Add( 5, 5, 0, wxALIGN_CENTER_HORIZONTAL | wxALL, 5 ); - - wxButton* itemButton25 = new wxButton( itemDialog1, - ID_PLOT_ACCEPT_OFFSET, - _( "&Accept Offset" ), - wxDefaultPosition, - wxDefaultSize, - 0 ); - itemBoxSizer20->Add( itemButton25, 0, wxGROW | wxALL, 5 ); - - m_MsgBox = new wxTextCtrl( itemDialog1, ID_TEXTCTRL, _T( "" ), - wxDefaultPosition, wxSize( -1, 110 ), - wxTE_MULTILINE ); - itemBoxSizer2->Add( m_MsgBox, 0, wxGROW | wxALL, 5 ); - - // Set validators - m_SizeOption->SetValidator( wxGenericValidator( &HPGL_SizeSelect ) ); - m_ButtPenWidth->SetValidator( wxGenericValidator( &g_HPGL_Pen_Descr. - m_Pen_Diam ) ); - m_ButtPenSpeed->SetValidator( wxGenericValidator( &g_HPGL_Pen_Descr. - m_Pen_Speed ) ); - m_ButtPenNum->SetValidator( wxGenericValidator( &g_HPGL_Pen_Descr. - m_Pen_Num ) ); - -////@end WinEDA_PlotHPGLFrame content construction - SetFocus(); // Make ESC key working -} - - -/*! - * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PLOT_HPGL_CURRENT_EXECUTE - */ - -void WinEDA_PlotHPGLFrame::OnPlotHpglCurrentExecuteClick( - wxCommandEvent& event ) -{ - HPGL_Plot( event ); -} - - -/*! - * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PLOT_HPGL_ALL_EXECUTE - */ - -void WinEDA_PlotHPGLFrame::OnPlotHpglAllExecuteClick( wxCommandEvent& event ) -{ - HPGL_Plot( event ); -} - - -/*! - * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL - */ - -void WinEDA_PlotHPGLFrame::OnCancelClick( wxCommandEvent& event ) -{ -////@begin wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL in -// WinEDA_PlotHPGLFrame. - // Before editing this code, remove the block markers. - event.Skip(); - -////@end wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL in -// WinEDA_PlotHPGLFrame. -} - - -/*! - * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PLOT_ACCEPT_OFFSET - */ - -void WinEDA_PlotHPGLFrame::OnPlotAcceptOffsetClick( wxCommandEvent& event ) -{ - AcceptPlotOffset( event ); -} - - -/*! - * Should we show tooltips? - */ - -bool WinEDA_PlotHPGLFrame::ShowToolTips() -{ - return true; -} - - -/*! - * Get bitmap resources - */ - -wxBitmap WinEDA_PlotHPGLFrame::GetBitmapResource( const wxString& name ) -{ - // Bitmap retrieval -////@begin WinEDA_PlotHPGLFrame bitmap retrieval - wxUnusedVar( name ); - return wxNullBitmap; - -////@end WinEDA_PlotHPGLFrame bitmap retrieval -} - - -/*! - * Get icon resources - */ - -wxIcon WinEDA_PlotHPGLFrame::GetIconResource( const wxString& name ) -{ - // Icon retrieval -////@begin WinEDA_PlotHPGLFrame icon retrieval - wxUnusedVar( name ); - return wxNullIcon; - -////@end WinEDA_PlotHPGLFrame icon retrieval -} - - -void WinEDA_PlotHPGLFrame::SetPageOffsetValue() -{ - wxString msg; - - if( HPGL_SizeSelect != PAGE_DEFAULT ) - { - msg = ReturnStringFromValue( g_UserUnit, - Plot_sheet_list[HPGL_SizeSelect]->m_Offset.x, - EESCHEMA_INTERNAL_UNIT ); - m_PlotOrgPosition_X->SetValue( msg ); - msg = ReturnStringFromValue( g_UserUnit, - Plot_sheet_list[HPGL_SizeSelect]-> m_Offset.y, - EESCHEMA_INTERNAL_UNIT ); - m_PlotOrgPosition_Y->SetValue( msg ); - - m_PlotOrgPosition_X->Enable( TRUE ); - m_PlotOrgPosition_Y->Enable( TRUE ); - } - else - { - m_PlotOrgPosition_X->Enable( FALSE ); - m_PlotOrgPosition_Y->Enable( FALSE ); - } -} - - -void WinEDA_PlotHPGLFrame::AcceptPlotOffset( wxCommandEvent& event ) -{ - int ii = m_SizeOption->GetSelection(); - - if( ii <= 0 ) - HPGL_SizeSelect = 0; - else - HPGL_SizeSelect = ii; - - if( HPGL_SizeSelect != PAGE_DEFAULT ) - { - wxString msg = m_PlotOrgPosition_X->GetValue(); - Plot_sheet_list[HPGL_SizeSelect]->m_Offset.x = - ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); - msg = m_PlotOrgPosition_Y->GetValue(); - Plot_sheet_list[HPGL_SizeSelect]->m_Offset.y = - ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); - } -} - - -void WinEDA_PlotHPGLFrame::SetPenWidth( wxSpinEvent& event ) -{ - g_HPGL_Pen_Descr.m_Pen_Diam = m_ButtPenWidth->GetValue(); - if( g_HPGL_Pen_Descr.m_Pen_Diam > 100 ) - g_HPGL_Pen_Descr.m_Pen_Diam = 100; - if( g_HPGL_Pen_Descr.m_Pen_Diam < 1 ) - g_HPGL_Pen_Descr.m_Pen_Diam = 1; -} - - -void WinEDA_PlotHPGLFrame::SetPenSpeed( wxSpinEvent& event ) -{ - g_HPGL_Pen_Descr.m_Pen_Speed = m_ButtPenSpeed->GetValue(); - if( g_HPGL_Pen_Descr.m_Pen_Speed > 40 ) - g_HPGL_Pen_Descr.m_Pen_Speed = 40; - if( g_HPGL_Pen_Descr.m_Pen_Speed < 1 ) - g_HPGL_Pen_Descr.m_Pen_Speed = 1; -} - - -void WinEDA_PlotHPGLFrame::SetPenNum( wxSpinEvent& event ) -{ - g_HPGL_Pen_Descr.m_Pen_Num = m_ButtPenNum->GetValue(); - if( g_HPGL_Pen_Descr.m_Pen_Num > 8 ) - g_HPGL_Pen_Descr.m_Pen_Num = 8; - if( g_HPGL_Pen_Descr.m_Pen_Num < 1 ) - g_HPGL_Pen_Descr.m_Pen_Num = 1; -} - - -void WinEDA_PlotHPGLFrame::HPGL_Plot( wxCommandEvent& event ) -{ - int Select_PlotAll = FALSE; - - if( event.GetId() == ID_PLOT_HPGL_ALL_EXECUTE ) - Select_PlotAll = TRUE; - - if( HPGL_SizeSelect ) - { - wxString msg = m_PlotOrgPosition_X->GetValue(); - Plot_sheet_list[HPGL_SizeSelect]->m_Offset.x = - ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); - msg = m_PlotOrgPosition_Y->GetValue(); - Plot_sheet_list[HPGL_SizeSelect]->m_Offset.y = - ReturnValueFromString( g_UserUnit, msg, EESCHEMA_INTERNAL_UNIT ); - } - - Plot_Schematic_HPGL( Select_PlotAll, HPGL_SizeSelect ); -} - - -/* Function calculates the offsets and dimensions of any trace of the - * selected sheet - */ -void WinEDA_PlotHPGLFrame::ReturnSheetDims( BASE_SCREEN* screen, - wxSize& SheetSize, - wxPoint& SheetOffset ) -{ - Ki_PageDescr* PlotSheet; - - if( screen == NULL ) - screen = m_Parent->GetBaseScreen(); - - PlotSheet = screen->m_CurrentSheetDesc; - - SheetSize = PlotSheet->m_Size; - SheetOffset = PlotSheet->m_Offset; -} - - -void WinEDA_PlotHPGLFrame::Plot_Schematic_HPGL( int Select_PlotAll, - int HPGL_SheetSize ) -{ - WinEDA_SchematicFrame* schframe = (WinEDA_SchematicFrame*) m_Parent; - wxString PlotFileName; - SCH_SCREEN* screen = schframe->GetScreen(); - SCH_SCREEN* oldscreen = screen; - SCH_SHEET_PATH* sheetpath, * oldsheetpath = schframe->GetSheet(); - Ki_PageDescr* PlotSheet; - wxSize SheetSize; - wxPoint SheetOffset, PlotOffset; - - /* When printing all pages, the printed page is not the current page. - * In complex hierarchies, we must setup references and others parameters - * in the printed SCH_SCREEN - * because in complex hierarchies a SCH_SCREEN (a schematic drawings) - * is shared between many sheets - */ - SCH_SHEET_LIST SheetList( NULL ); - - sheetpath = SheetList.GetFirst(); - SCH_SHEET_PATH list; - - while( true ) - { - if( Select_PlotAll ) - { - if( sheetpath == NULL ) - break; - list.Clear(); - if( list.BuildSheetPathInfoFromSheetPathValue( sheetpath->Path() ) ) - { - schframe->m_CurrentSheet = &list; - schframe->m_CurrentSheet->UpdateAllScreenReferences(); - schframe->SetSheetNumberAndCount(); - screen = schframe->m_CurrentSheet->LastScreen(); - ActiveScreen = screen; - } - else // Should not happen - return; - sheetpath = SheetList.GetNext(); - } - ReturnSheetDims( screen, SheetSize, SheetOffset ); - /* Calculation of conversion scales. */ - if( HPGL_SheetSize ) - PlotSheet = Plot_sheet_list[HPGL_SheetSize]; - else - PlotSheet = screen->m_CurrentSheetDesc; - /* 10x because eeschema works in mils, not decimals */ - double plot_scale = 10 * (double) PlotSheet->m_Size.x / - (double) SheetSize.x; - - /* Calculate offsets */ - PlotOffset.x = -SheetOffset.x; - PlotOffset.y = -SheetOffset.y; - - PlotFileName = schframe->GetUniqueFilenameForCurrentSheet() + - wxT( ".plt" ); - - SetLocaleTo_C_standard(); - Plot_1_Page_HPGL( PlotFileName, screen, PlotSheet, PlotOffset, - plot_scale ); - SetLocaleTo_Default(); - - if( !Select_PlotAll ) - break; - } - - ActiveScreen = oldscreen; - schframe->m_CurrentSheet = oldsheetpath; - schframe->m_CurrentSheet->UpdateAllScreenReferences(); - schframe->SetSheetNumberAndCount(); -} - - -void WinEDA_PlotHPGLFrame::Plot_1_Page_HPGL( const wxString& FileName, - SCH_SCREEN* screen, - Ki_PageDescr* sheet, - wxPoint& offset, - double plot_scale ) -{ - wxString msg; - - FILE* output_file = wxFopen( FileName, wxT( "wt" ) ); - - if( output_file == NULL ) - { - msg = wxT( "\n** " ); - msg += _( "Unable to create " ) + FileName + wxT( " **\n\n" ); - m_MsgBox->AppendText( msg ); - wxBell(); - return; - } - - SetLocaleTo_C_standard(); - msg.Printf( _( "Plot: %s\n" ), FileName.GetData() ); - m_MsgBox->AppendText( msg ); - - HPGL_PLOTTER* plotter = new HPGL_PLOTTER(); - plotter->set_paper_size( sheet ); - plotter->set_viewport( offset, plot_scale, 0 ); - plotter->set_default_line_width( g_DrawDefaultLineThickness ); - /* Init : */ - plotter->set_creator( wxT( "EESchema-HPGL" ) ); - plotter->set_filename( FileName ); - plotter->set_pen_speed( g_HPGL_Pen_Descr.m_Pen_Speed ); - plotter->set_pen_number( g_HPGL_Pen_Descr.m_Pen_Num ); - plotter->set_pen_diameter( g_HPGL_Pen_Descr.m_Pen_Diam ); - plotter->set_pen_overlap( g_HPGL_Pen_Descr.m_Pen_Diam / 2 ); - plotter->start_plot( output_file ); - - plotter->set_color( BLACK ); - m_Parent->PlotWorkSheet( plotter, screen ); - - PlotDrawlist( plotter, screen->EEDrawList ); - - plotter->end_plot(); - delete plotter; - SetLocaleTo_Default(); - - m_MsgBox->AppendText( wxT( "Ok\n" ) ); -} - - -/*! - * wxEVT_COMMAND_RADIOBOX_SELECTED event handler for ID_RADIOBOX - */ - -void WinEDA_PlotHPGLFrame::OnRadioboxSelected( wxCommandEvent& event ) -{ - HPGL_SizeSelect = m_SizeOption->GetSelection(); - SetPageOffsetValue(); -} - - -/*! - * wxEVT_COMMAND_SPINCTRL_UPDATED event handler for ID_PEN_WIDTH_UPDATED - */ - -void WinEDA_PlotHPGLFrame::OnPenWidthUpdatedUpdated( wxSpinEvent& event ) -{ - SetPenWidth( event ); -} - - -/*! - * wxEVT_COMMAND_SPINCTRL_UPDATED event handler for ID_PEN_SPEED_UPDATED - */ - -void WinEDA_PlotHPGLFrame::OnPenSpeedUpdatedUpdated( wxSpinEvent& event ) -{ - SetPenSpeed( event ); -} - - -/*! - * wxEVT_COMMAND_SPINCTRL_UPDATED event handler for ID_PEN_NUMBER_UPDATED - */ - -void WinEDA_PlotHPGLFrame::OnPenNumberUpdatedUpdated( wxSpinEvent& event ) -{ - SetPenNum( event ); -} diff --git a/eeschema/plothpgl.h b/eeschema/plothpgl.h deleted file mode 100644 index 0c51f31f07..0000000000 --- a/eeschema/plothpgl.h +++ /dev/null @@ -1,155 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// Name: plothpgl.h -// Purpose: -// Author: jean-pierre Charras -// Modified by: -// Created: 04/02/2006 16:54:19 -// RCS-ID: -// Copyright: License GNU -// Licence: -///////////////////////////////////////////////////////////////////////////// - -// Generated by DialogBlocks (unregistered), 04/02/2006 16:54:19 - -#ifndef _PLOTHPGL_H_ -#define _PLOTHPGL_H_ - -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma interface "plothpgl.h" -#endif - -/*! - * Includes - */ - -////@begin includes -#include "wx/valgen.h" -#include "wx/spinctrl.h" -////@end includes - -/*! - * Forward declarations - */ - -////@begin forward declarations -class wxSpinCtrl; -////@end forward declarations - -/*! - * Control identifiers - */ - -////@begin control identifiers -#define ID_DIALOG 10000 -#define ID_RADIOBOX 10001 -#define ID_PEN_WIDTH_UPDATED 10002 -#define ID_PEN_SPEED_UPDATED 10003 -#define ID_PEN_NUMBER_UPDATED 10004 -#define ID_TEXTCTRL1 10010 -#define ID_TEXTCTRL2 10009 -#define ID_PLOT_HPGL_CURRENT_EXECUTE 10005 -#define ID_PLOT_HPGL_ALL_EXECUTE 10006 -#define ID_PLOT_ACCEPT_OFFSET 10008 -#define ID_TEXTCTRL 10007 -#define SYMBOL_WINEDA_PLOTHPGLFRAME_STYLE wxDEFAULT_DIALOG_STYLE|wxCAPTION|wxSYSTEM_MENU|wxCLOSE_BOX|MAYBE_RESIZE_BORDER -#define SYMBOL_WINEDA_PLOTHPGLFRAME_TITLE _("EESchema Plot HPGL") -#define SYMBOL_WINEDA_PLOTHPGLFRAME_IDNAME ID_DIALOG -#define SYMBOL_WINEDA_PLOTHPGLFRAME_SIZE wxSize(400, 300) -#define SYMBOL_WINEDA_PLOTHPGLFRAME_POSITION wxDefaultPosition -////@end control identifiers - -/*! - * Compatibility - */ - -#ifndef wxCLOSE_BOX -#define wxCLOSE_BOX 0x1000 -#endif - -/*! - * WinEDA_PlotHPGLFrame class declaration - */ - -class WinEDA_PlotHPGLFrame: public wxDialog -{ - DECLARE_DYNAMIC_CLASS( WinEDA_PlotHPGLFrame ) - DECLARE_EVENT_TABLE() - -public: - /// Constructors - WinEDA_PlotHPGLFrame( ); - WinEDA_PlotHPGLFrame( WinEDA_DrawFrame* parent, wxWindowID id = SYMBOL_WINEDA_PLOTHPGLFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_PLOTHPGLFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_PLOTHPGLFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_PLOTHPGLFRAME_SIZE, long style = SYMBOL_WINEDA_PLOTHPGLFRAME_STYLE ); - - /// Creation - bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WINEDA_PLOTHPGLFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_PLOTHPGLFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_PLOTHPGLFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_PLOTHPGLFRAME_SIZE, long style = SYMBOL_WINEDA_PLOTHPGLFRAME_STYLE ); - - /// Creates the controls and sizers - void CreateControls(); - -////@begin WinEDA_PlotHPGLFrame event handler declarations - - /// wxEVT_COMMAND_RADIOBOX_SELECTED event handler for ID_RADIOBOX - void OnRadioboxSelected( wxCommandEvent& event ); - - /// wxEVT_COMMAND_SPINCTRL_UPDATED event handler for ID_PEN_WIDTH_UPDATED - void OnPenWidthUpdatedUpdated( wxSpinEvent& event ); - - /// wxEVT_COMMAND_SPINCTRL_UPDATED event handler for ID_PEN_SPEED_UPDATED - void OnPenSpeedUpdatedUpdated( wxSpinEvent& event ); - - /// wxEVT_COMMAND_SPINCTRL_UPDATED event handler for ID_PEN_NUMBER_UPDATED - void OnPenNumberUpdatedUpdated( wxSpinEvent& event ); - - /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PLOT_HPGL_CURRENT_EXECUTE - void OnPlotHpglCurrentExecuteClick( wxCommandEvent& event ); - - /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PLOT_HPGL_ALL_EXECUTE - void OnPlotHpglAllExecuteClick( wxCommandEvent& event ); - - /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL - void OnCancelClick( wxCommandEvent& event ); - - /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PLOT_ACCEPT_OFFSET - void OnPlotAcceptOffsetClick( wxCommandEvent& event ); - -////@end WinEDA_PlotHPGLFrame event handler declarations - -////@begin WinEDA_PlotHPGLFrame member function declarations - - /// Retrieves bitmap resources - wxBitmap GetBitmapResource( const wxString& name ); - - /// Retrieves icon resources - wxIcon GetIconResource( const wxString& name ); -////@end WinEDA_PlotHPGLFrame member function declarations - - /// Should we show tooltips? - static bool ShowToolTips(); - - void HPGL_Plot(wxCommandEvent& event); - void SetSizeOption(wxCommandEvent& event); - void AcceptPlotOffset(wxCommandEvent& event); - void SetPenWidth(wxSpinEvent& event); - void SetPenSpeed(wxSpinEvent& event); - void SetPenNum(wxSpinEvent& event); - void Plot_1_Page_HPGL(const wxString &FileName, SCH_SCREEN * screen, - Ki_PageDescr* paper, wxPoint& offset, double scale); - void Plot_Schematic_HPGL(int Select_PlotAll, int HPGL_SheetSize); - void ReturnSheetDims( BASE_SCREEN * screen, wxSize & SheetSize, wxPoint & SheetOffset); - void SetPageOffsetValue(); - -////@begin WinEDA_PlotHPGLFrame member variables - wxRadioBox* m_SizeOption; - wxSpinCtrl* m_ButtPenWidth; - wxSpinCtrl* m_ButtPenSpeed; - wxSpinCtrl* m_ButtPenNum; - wxTextCtrl* m_PlotOrgPosition_X; - wxTextCtrl* m_PlotOrgPosition_Y; - wxButton* m_btClose; - wxTextCtrl* m_MsgBox; -////@end WinEDA_PlotHPGLFrame member variables - WinEDA_DrawFrame * m_Parent; -}; - -#endif - // _PLOTHPGL_H_ diff --git a/eeschema/plothpgl.pjd b/eeschema/plothpgl.pjd deleted file mode 100644 index 5e32b1257a..0000000000 --- a/eeschema/plothpgl.pjd +++ /dev/null @@ -1,1710 +0,0 @@ - - -
- 0 - "" - "" - "" - "" - "" - 0 - 0 - 0 - 1 - 1 - 1 - 1 - 0 - "jean-pierre Charras" - "License GNU" - "" - 0 - 0 - 0 - "<All platforms>" - "<Any>" - "///////////////////////////////////////////////////////////////////////////// -// Name: %HEADER-FILENAME% -// Purpose: -// Author: %AUTHOR% -// Modified by: -// Created: %DATE% -// RCS-ID: -// Copyright: %COPYRIGHT% -// Licence: -///////////////////////////////////////////////////////////////////////////// - -" - "///////////////////////////////////////////////////////////////////////////// -// Name: %SOURCE-FILENAME% -// Purpose: -// Author: %AUTHOR% -// Modified by: -// Created: %DATE% -// RCS-ID: -// Copyright: %COPYRIGHT% -// Licence: -///////////////////////////////////////////////////////////////////////////// - -" - "///////////////////////////////////////////////////////////////////////////// -// Name: %SYMBOLS-FILENAME% -// Purpose: Symbols file -// Author: %AUTHOR% -// Modified by: -// Created: %DATE% -// RCS-ID: -// Copyright: %COPYRIGHT% -// Licence: -///////////////////////////////////////////////////////////////////////////// - -" - "#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma interface "%HEADER-FILENAME%" -#endif - -" - "#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma implementation "%HEADER-FILENAME%" -#endif - -// For compilers that support precompilation, includes "wx/wx.h". -#include "wx/wxprec.h" - -#ifdef __BORLANDC__ -#pragma hdrstop -#endif - -#ifndef WX_PRECOMP -#include "wx/wx.h" -#endif - -" - " /// %BODY% -" - " -/*! - * %BODY% - */ - -" - "app_resources.h" - "app_resources.cpp" - "AppResources" - "app.h" - "app.cpp" - "Application" - 0 - "" - "<None>" - "<System>" - "utf-8" - "<System>" - "" - 0 - 0 - 4 - " " - "" - 0 - 0 - 1 - 0 - 1 - 1 - 0 - 1 - 0 - 0 -
- - - "" - "data-document" - "" - "" - 0 - 1 - 0 - 0 - - "Configurations" - "config-data-document" - "" - "" - 0 - 1 - 0 - 0 - "" - 1 - -8519680 - "" - "Debug" - "ANSI" - "Static" - "Modular" - "GUI" - "wxMSW" - "Dynamic" - "Yes" - "No" - "No" - "%WXVERSION%" - "%EXECUTABLE%" - "" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - "%AUTO%" - 0 - 1 - "" - - - - - - - "Projects" - "root-document" - "" - "project" - 1 - 1 - 0 - 1 - - "Windows" - "html-document" - "" - "dialogsfolder" - 1 - 1 - 0 - 1 - - "EESchema Plot HPGL" - "dialog-document" - "" - "dialog" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbDialogProxy" - 10000 - 0 - "" - 0 - "" - 0 - 0 - "ID_DIALOG" - 10000 - "WinEDA_PlotHPGLFrame" - "wxDialog" - "wxDialog" - "plothpgl.cpp" - "plothpgl.h" - "" - "EESchema Plot HPGL" - 1 - "" - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "Tiled" - 1 - 1 - 0 - 1 - 0 - 0 - 1 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 1 - 0 - "MAYBE_RESIZE_BORDER" - 0 - 1 - -1 - -1 - 400 - 300 - 0 - "" - - "wxBoxSizer V" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbBoxSizerProxy" - "Vertical" - "" - 0 - 0 - 0 - "<Any platform>" - - "wxBoxSizer H" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbBoxSizerProxy" - "Horizontal" - "" - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - "wxBoxSizer V" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbBoxSizerProxy" - "Vertical" - "" - "Centre" - "Expand" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - "wxRadioBox: ID_RADIOBOX" - "dialog-control-document" - "" - "radiobox" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbRadioBoxProxy" - "wxEVT_COMMAND_RADIOBOX_SELECTED|OnRadioboxSelected" - "ID_RADIOBOX" - 10001 - "" - "wxRadioBox" - "wxRadioBox" - 1 - 0 - "" - "" - "m_SizeOption" - "Plot page size:" - 1 - "Sheet Size|Page Size A4|Page Size A3|Page Size A2|Page Size A1|Page Size A0|Page Size A|Page Size B|Page Size C|Page Size D|Page Size E" - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "HPGL_SizeSelect" - "wxGenericValidator(& %VARIABLE%)" - "" - "" - "" - "" - "" - 0 - 1 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "" - "" - - - - "wxBoxSizer V" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbBoxSizerProxy" - "Vertical" - "" - "Centre" - "Top" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - "wxStaticBoxSizer V" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbStaticBoxSizerProxy" - "wxID_ANY" - "-1" - "Pen control:" - "" - "" - "" - "" - 0 - 1 - "wxStaticBox" - "Vertical" - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - "wxStaticText: wxID_STATIC" - "dialog-control-document" - "" - "statictext" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbStaticTextProxy" - "wxID_STATIC" - 5105 - "" - "wxStaticText" - "wxStaticText" - 1 - 0 - "" - "" - "" - "Pen Width ( mils )" - -1 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 0 - 0 - 1 - 0 - "" - "" - - - "wxSpinCtrl: ID_PEN_WIDTH_UPDATED" - "dialog-control-document" - "" - "spinctrl" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbSpinCtrlProxy" - "wxEVT_COMMAND_SPINCTRL_UPDATED|OnPenWidthUpdatedUpdated" - "ID_PEN_WIDTH_UPDATED" - 10002 - "" - "wxSpinCtrl" - "wxSpinCtrl" - 1 - 0 - "" - "" - "m_ButtPenWidth" - 1 - 100 - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "g_HPGL_Pen_Descr.m_Pen_Diam" - "wxGenericValidator(& %VARIABLE%)" - "" - "" - "" - "" - "" - 1 - 1 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 0 - 1 - 0 - 0 - 0 - "" - "" - - - "wxStaticText: wxID_STATIC" - "dialog-control-document" - "" - "statictext" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbStaticTextProxy" - "wxID_STATIC" - 5105 - "" - "wxStaticText" - "wxStaticText" - 1 - 0 - "" - "" - "" - "Pen Speed ( cm/s )" - -1 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 0 - 0 - 1 - 0 - "" - "" - - - "wxSpinCtrl: ID_PEN_SPEED_UPDATED" - "dialog-control-document" - "" - "spinctrl" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbSpinCtrlProxy" - "wxEVT_COMMAND_SPINCTRL_UPDATED|OnPenSpeedUpdatedUpdated" - "ID_PEN_SPEED_UPDATED" - 10003 - "" - "wxSpinCtrl" - "wxSpinCtrl" - 1 - 0 - "" - "" - "m_ButtPenSpeed" - 1 - 100 - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "g_HPGL_Pen_Descr.m_Pen_Speed" - "wxGenericValidator(& %VARIABLE%)" - "" - "" - "" - "" - "" - 1 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 0 - 1 - 0 - 0 - 0 - "" - "" - - - "wxStaticText: wxID_STATIC" - "dialog-control-document" - "" - "statictext" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbStaticTextProxy" - "wxID_STATIC" - 5105 - "" - "wxStaticText" - "wxStaticText" - 1 - 0 - "" - "" - "" - "Pen Number" - -1 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 0 - 0 - 1 - 0 - "" - "" - - - "wxSpinCtrl: ID_PEN_NUMBER_UPDATED" - "dialog-control-document" - "" - "spinctrl" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbSpinCtrlProxy" - "wxEVT_COMMAND_SPINCTRL_UPDATED|OnPenNumberUpdatedUpdated" - "ID_PEN_NUMBER_UPDATED" - 10004 - "" - "wxSpinCtrl" - "wxSpinCtrl" - 1 - 0 - "" - "" - "m_ButtPenNum" - 1 - 8 - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "g_HPGL_Pen_Descr.m_Pen_Num" - "wxGenericValidator(& %VARIABLE%)" - "" - "" - "" - "" - "" - 1 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 0 - 1 - 0 - 0 - 0 - "" - "" - - - - "wxStaticBoxSizer V" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/9/2006" - "wbStaticBoxSizerProxy" - "wxID_ANY" - -1 - "Page offset:" - "" - "" - "" - "" - 0 - 1 - "wxStaticBox" - "Vertical" - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - "wxStaticText: wxID_STATIC" - "dialog-control-document" - "" - "statictext" - 0 - 1 - 0 - 0 - "4/9/2006" - "wbStaticTextProxy" - "wxID_STATIC" - 5105 - "" - "wxStaticText" - "wxStaticText" - 1 - 0 - "" - "" - "" - "Plot Offset X" - -1 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 0 - 0 - 1 - 0 - "" - "" - - - "wxTextCtrl: ID_TEXTCTRL1" - "dialog-control-document" - "" - "textctrl" - 0 - 1 - 0 - 0 - "4/9/2006" - "wbTextCtrlProxy" - "ID_TEXTCTRL1" - 10010 - "" - "wxTextCtrl" - "wxTextCtrl" - 1 - 0 - "" - "" - "m_PlotOrgPosition_X" - "" - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 0 - 1 - 0 - 0 - 0 - "" - "" - - - "wxStaticText: wxID_STATIC" - "dialog-control-document" - "" - "statictext" - 0 - 1 - 0 - 0 - "4/9/2006" - "wbStaticTextProxy" - "wxID_STATIC" - 5105 - "" - "wxStaticText" - "wxStaticText" - 1 - 0 - "" - "" - "" - "Plot Offset Y" - -1 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 1 - 0 - 0 - 1 - 0 - "" - "" - - - "wxTextCtrl: ID_TEXTCTRL2" - "dialog-control-document" - "" - "textctrl" - 0 - 1 - 0 - 0 - "4/9/2006" - "wbTextCtrlProxy" - "ID_TEXTCTRL2" - 10009 - "" - "wxTextCtrl" - "wxTextCtrl" - 1 - 0 - "" - "" - "m_PlotOrgPosition_Y" - "" - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Left" - "Centre" - 0 - 5 - 1 - 1 - 0 - 1 - 0 - 0 - 0 - "" - "" - - - - - "Spacer" - "dialog-control-document" - "" - "spacer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbSpacerProxy" - 5 - 5 - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - - "wxBoxSizer V" - "dialog-control-document" - "" - "sizer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbBoxSizerProxy" - "Vertical" - "" - "Centre" - "Top" - 0 - 5 - 1 - 0 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - "wxButton: ID_PLOT_HPGL_CURRENT_EXECUTE" - "dialog-control-document" - "" - "dialogcontrol" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbButtonProxy" - "wxEVT_COMMAND_BUTTON_CLICKED|OnPlotHpglCurrentExecuteClick" - "ID_PLOT_HPGL_CURRENT_EXECUTE" - 10005 - "" - "wxButton" - "wxButton" - 1 - 0 - "" - "" - "" - "&Plot Page" - 1 - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Expand" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "" - "" - - - "wxButton: ID_PLOT_HPGL_ALL_EXECUTE" - "dialog-control-document" - "" - "dialogcontrol" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbButtonProxy" - "wxEVT_COMMAND_BUTTON_CLICKED|OnPlotHpglAllExecuteClick" - "ID_PLOT_HPGL_ALL_EXECUTE" - 10006 - "" - "wxButton" - "wxButton" - 1 - 0 - "" - "" - "" - "Plot A&LL" - 0 - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Expand" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "" - "" - - - "wxButton: wxID_CANCEL" - "dialog-control-document" - "" - "dialogcontrol" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbButtonProxy" - "wxEVT_COMMAND_BUTTON_CLICKED|OnCancelClick|||WinEDA_PlotHPGLFrame" - "wxID_CANCEL" - 5101 - "" - "wxButton" - "wxButton" - 1 - 0 - "" - "" - "m_btClose" - "&Close" - 0 - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Expand" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "" - "" - - - "Spacer" - "dialog-control-document" - "" - "spacer" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbSpacerProxy" - 5 - 5 - "Centre" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "<Any platform>" - - - "wxButton: ID_PLOT_ACCEPT_OFFSET" - "dialog-control-document" - "" - "dialogcontrol" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbButtonProxy" - "wxEVT_COMMAND_BUTTON_CLICKED|OnPlotAcceptOffsetClick" - "ID_PLOT_ACCEPT_OFFSET" - 10008 - "" - "wxButton" - "wxButton" - 1 - 0 - "" - "" - "" - "&Accept Offset" - 0 - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - -1 - "Expand" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "" - "" - - - - - "wxTextCtrl: ID_TEXTCTRL" - "dialog-control-document" - "" - "textctrl" - 0 - 1 - 0 - 0 - "4/12/2006" - "wbTextCtrlProxy" - "ID_TEXTCTRL" - 10007 - "" - "wxTextCtrl" - "wxTextCtrl" - 1 - 0 - "" - "" - "m_MsgBox" - "" - 0 - "" - "" - "" - "" - "" - 0 - 1 - "<Any platform>" - "" - "" - "" - "" - "" - "" - "" - 1 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - "" - -1 - -1 - -1 - 110 - "Expand" - "Centre" - 0 - 5 - 1 - 1 - 1 - 1 - 0 - 0 - 0 - "" - "" - 0 - - - - - - "Sources" - "html-document" - "" - "sourcesfolder" - 1 - 1 - 0 - 1 - - "plothpgl.rc" - "source-editor-document" - "plothpgl.rc" - "source-editor" - 0 - 0 - 1 - 0 - "4/12/2006" - "" - - - - "Images" - "html-document" - "" - "bitmapsfolder" - 1 - 1 - 0 - 1 - - - - -
diff --git a/eeschema/plothpgl.rc b/eeschema/plothpgl.rc deleted file mode 100644 index b86c4e2265..0000000000 --- a/eeschema/plothpgl.rc +++ /dev/null @@ -1 +0,0 @@ -#include "wx/msw/wx.rc"