Commit 5c4c584b authored by charras's avatar charras

Cleaning code in print dialogs.

parent 098a5bfe
...@@ -5,6 +5,14 @@ Started 2007-June-11 ...@@ -5,6 +5,14 @@ Started 2007-June-11
Please add newer entries at the top, list the date and your name with Please add newer entries at the top, list the date and your name with
email address. email address.
2009-Jan-17 UPDATE Jean-Pierre Charras <jean-pierre.charras@inpg.fr>
================================================================================
++All:
Cleaned code in print dialogs.
They are now specific to eeschema and pcbnew.
Gerbview uses pcbnew dialog.
The code is now a lot more easy to understand.
2009-Jan-15 UPDATE Jean-Pierre Charras <jean-pierre.charras@inpg.fr> 2009-Jan-15 UPDATE Jean-Pierre Charras <jean-pierre.charras@inpg.fr>
================================================================================ ================================================================================
......
...@@ -50,6 +50,8 @@ set(EESCHEMA_SRCS ...@@ -50,6 +50,8 @@ set(EESCHEMA_SRCS
dialog_erc.cpp dialog_erc.cpp
# dialog_find.cpp # dialog_find.cpp
dialog_options.cpp dialog_options.cpp
dialog_print_using_printer_base.cpp
dialog_print_using_printer.cpp
dialog_SVG_print.cpp dialog_SVG_print.cpp
dialog_SVG_print_base.cpp dialog_SVG_print_base.cpp
edit_component_in_lib.cpp edit_component_in_lib.cpp
...@@ -110,8 +112,7 @@ set(EESCHEMA_SRCS ...@@ -110,8 +112,7 @@ set(EESCHEMA_SRCS
viewlibs.cpp) viewlibs.cpp)
set(EESCHEMA_EXTRA_SRCS set(EESCHEMA_EXTRA_SRCS
../share/setpage.cpp ../share/setpage.cpp)
../share/wxprint.cpp)
if(WIN32) if(WIN32)
if(MINGW) if(MINGW)
......
...@@ -50,7 +50,7 @@ DIALOG_SVG_PRINT_base::DIALOG_SVG_PRINT_base( wxWindow* parent, wxWindowID id, c ...@@ -50,7 +50,7 @@ DIALOG_SVG_PRINT_base::DIALOG_SVG_PRINT_base( wxWindow* parent, wxWindowID id, c
wxBoxSizer* bButtonsSizer; wxBoxSizer* bButtonsSizer;
bButtonsSizer = new wxBoxSizer( wxVERTICAL ); bButtonsSizer = new wxBoxSizer( wxVERTICAL );
m_buttonPlotCurrent = new wxButton( this, wxID_PRINT_CURRENT, _("PrintCurrent"), wxDefaultPosition, wxDefaultSize, 0 ); m_buttonPlotCurrent = new wxButton( this, wxID_PRINT_CURRENT, _("Print Current"), wxDefaultPosition, wxDefaultSize, 0 );
bButtonsSizer->Add( m_buttonPlotCurrent, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); bButtonsSizer->Add( m_buttonPlotCurrent, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonPlotAll = new wxButton( this, wxID_PRINT_ALL, _("Print All"), wxDefaultPosition, wxDefaultSize, 0 ); m_buttonPlotAll = new wxButton( this, wxID_PRINT_ALL, _("Print All"), wxDefaultPosition, wxDefaultSize, 0 );
......
This diff is collapsed.
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 16 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#include "dialog_print_using_printer_base.h"
///////////////////////////////////////////////////////////////////////////
DIALOG_PRINT_USING_PRINTER_base::DIALOG_PRINT_USING_PRINTER_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( wxSize( -1,-1 ), wxDefaultSize );
wxBoxSizer* bMainSizer;
bMainSizer = new wxBoxSizer( wxHORIZONTAL );
wxBoxSizer* bleftSizer;
bleftSizer = new wxBoxSizer( wxVERTICAL );
wxStaticBoxSizer* sbOptionsSizer;
sbOptionsSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Options:") ), wxVERTICAL );
m_TextPenWidth = new wxStaticText( this, wxID_ANY, _("Pen Width Mini"), wxDefaultPosition, wxDefaultSize, 0 );
m_TextPenWidth->Wrap( -1 );
sbOptionsSizer->Add( m_TextPenWidth, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_DialogPenWidth = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_DialogPenWidth->SetToolTip( _("Selection of the minimum pen thickness used to draw items.") );
m_DialogPenWidth->SetMinSize( wxSize( 200,-1 ) );
sbOptionsSizer->Add( m_DialogPenWidth, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 );
m_Print_Sheet_Ref = new wxCheckBox( this, wxID_FRAME_SEL, _("Print frame ref"), wxDefaultPosition, wxDefaultSize, 0 );
m_Print_Sheet_Ref->SetValue(true);
m_Print_Sheet_Ref->SetToolTip( _("Print (or not) the Frame references.") );
sbOptionsSizer->Add( m_Print_Sheet_Ref, 0, wxALL, 5 );
bleftSizer->Add( sbOptionsSizer, 1, wxEXPAND|wxALL, 5 );
wxString m_ModeColorOptionChoices[] = { _("Color"), _("Black and white") };
int m_ModeColorOptionNChoices = sizeof( m_ModeColorOptionChoices ) / sizeof( wxString );
m_ModeColorOption = new wxRadioBox( this, wxID_PRINT_MODE, _("Print Mode"), wxDefaultPosition, wxDefaultSize, m_ModeColorOptionNChoices, m_ModeColorOptionChoices, 1, wxRA_SPECIFY_COLS );
m_ModeColorOption->SetSelection( 1 );
m_ModeColorOption->SetToolTip( _("Choose if you wand to draw the sheet like it appears on screen,\nor in black and white mode, better to print it when using black and white printers") );
bleftSizer->Add( m_ModeColorOption, 0, wxALL|wxEXPAND, 5 );
wxString m_PagesOptionChoices[] = { _("Current"), _("All") };
int m_PagesOptionNChoices = sizeof( m_PagesOptionChoices ) / sizeof( wxString );
m_PagesOption = new wxRadioBox( this, wxID_PAGE_MODE, _("Page Print"), wxDefaultPosition, wxDefaultSize, m_PagesOptionNChoices, m_PagesOptionChoices, 1, wxRA_SPECIFY_COLS );
m_PagesOption->SetSelection( 0 );
bleftSizer->Add( m_PagesOption, 0, wxALL|wxEXPAND, 5 );
bMainSizer->Add( bleftSizer, 1, wxEXPAND, 5 );
wxBoxSizer* bbuttonsSizer;
bbuttonsSizer = new wxBoxSizer( wxVERTICAL );
m_buttonOption = new wxButton( this, wxID_PRINT_OPTIONS, _("Page Options"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonOption, 0, wxALL, 5 );
m_buttonPreview = new wxButton( this, wxID_PREVIEW, _("Preview"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonPreview, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonPrint = new wxButton( this, wxID_PRINT_ALL, _("Print"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonPrint, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonQuit = new wxButton( this, wxID_CANCEL, _("Close"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonQuit, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
bMainSizer->Add( bbuttonsSizer, 0, wxALIGN_CENTER_VERTICAL, 5 );
this->SetSizer( bMainSizer );
this->Layout();
// Connect Events
this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnCloseWindow ) );
this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnInitDialog ) );
m_buttonOption->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintSetup ), NULL, this );
m_buttonPreview->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintPreview ), NULL, this );
m_buttonPrint->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintButtonClick ), NULL, this );
m_buttonQuit->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnButtonCancelClick ), NULL, this );
}
DIALOG_PRINT_USING_PRINTER_base::~DIALOG_PRINT_USING_PRINTER_base()
{
// Disconnect Events
this->Disconnect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnCloseWindow ) );
this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnInitDialog ) );
m_buttonOption->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintSetup ), NULL, this );
m_buttonPreview->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintPreview ), NULL, this );
m_buttonPrint->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintButtonClick ), NULL, this );
m_buttonQuit->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnButtonCancelClick ), NULL, this );
}
This diff is collapsed.
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 16 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#ifndef __dialog_print_using_printer_base__
#define __dialog_print_using_printer_base__
#include <wx/intl.h>
#include <wx/string.h>
#include <wx/stattext.h>
#include <wx/gdicmn.h>
#include <wx/font.h>
#include <wx/colour.h>
#include <wx/settings.h>
#include <wx/textctrl.h>
#include <wx/checkbox.h>
#include <wx/sizer.h>
#include <wx/statbox.h>
#include <wx/radiobox.h>
#include <wx/button.h>
#include <wx/dialog.h>
///////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////
/// Class DIALOG_PRINT_USING_PRINTER_base
///////////////////////////////////////////////////////////////////////////////
class DIALOG_PRINT_USING_PRINTER_base : public wxDialog
{
private:
protected:
enum
{
wxID_FRAME_SEL = 1000,
wxID_PRINT_MODE,
wxID_PAGE_MODE,
wxID_PRINT_OPTIONS,
wxID_PRINT_ALL,
};
wxStaticText* m_TextPenWidth;
wxTextCtrl* m_DialogPenWidth;
wxCheckBox* m_Print_Sheet_Ref;
wxRadioBox* m_ModeColorOption;
wxRadioBox* m_PagesOption;
wxButton* m_buttonOption;
wxButton* m_buttonPreview;
wxButton* m_buttonPrint;
wxButton* m_buttonQuit;
// Virtual event handlers, overide them in your derived class
virtual void OnCloseWindow( wxCloseEvent& event ){ event.Skip(); }
virtual void OnInitDialog( wxInitDialogEvent& event ){ event.Skip(); }
virtual void OnPrintSetup( wxCommandEvent& event ){ event.Skip(); }
virtual void OnPrintPreview( wxCommandEvent& event ){ event.Skip(); }
virtual void OnPrintButtonClick( wxCommandEvent& event ){ event.Skip(); }
virtual void OnButtonCancelClick( wxCommandEvent& event ){ event.Skip(); }
public:
DIALOG_PRINT_USING_PRINTER_base( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Print"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 336,268 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_PRINT_USING_PRINTER_base();
};
#endif //__dialog_print_using_printer_base__
...@@ -41,7 +41,8 @@ OBJECTS = eeschema.o\ ...@@ -41,7 +41,8 @@ OBJECTS = eeschema.o\
tool_viewlib.o\ tool_viewlib.o\
schframe.o\ schframe.o\
viewlib_frame.o\ viewlib_frame.o\
wxprint.o\ dialog_print_using_printer_base.o\
dialog_print_using_printer.o\
lib_export.o \ lib_export.o \
busentry.o \ busentry.o \
bus-wire-junction.o \ bus-wire-junction.o \
......
...@@ -53,7 +53,8 @@ set(GERBVIEW_EXTRA_SRCS ...@@ -53,7 +53,8 @@ set(GERBVIEW_EXTRA_SRCS
../pcbnew/undelete.cpp ../pcbnew/undelete.cpp
../share/setpage.cpp ../share/setpage.cpp
../share/wxprint.cpp) ../pcbnew/dialog_print_using_printer_base.cpp
../pcbnew/dialog_print_using_printer.cpp)
if(WIN32) if(WIN32)
if(MINGW) if(MINGW)
......
...@@ -117,7 +117,6 @@ BEGIN_EVENT_TABLE( WinEDA_GerberFrame, WinEDA_BasePcbFrame ) ...@@ -117,7 +117,6 @@ BEGIN_EVENT_TABLE( WinEDA_GerberFrame, WinEDA_BasePcbFrame )
EVT_TOOL_RANGE( ID_TB_OPTIONS_START, ID_TB_OPTIONS_END, EVT_TOOL_RANGE( ID_TB_OPTIONS_START, ID_TB_OPTIONS_END,
WinEDA_GerberFrame::OnSelectOptionToolbar ) WinEDA_GerberFrame::OnSelectOptionToolbar )
// PopUp Menu trait�s dans drawpanel.cpp
END_EVENT_TABLE() END_EVENT_TABLE()
...@@ -150,7 +149,8 @@ WinEDA_GerberFrame::WinEDA_GerberFrame( wxWindow* father, ...@@ -150,7 +149,8 @@ WinEDA_GerberFrame::WinEDA_GerberFrame( wxWindow* father,
SetIcon( wxICON( icon_gerbview ) ); SetIcon( wxICON( icon_gerbview ) );
#endif #endif
SetBaseScreen( ActiveScreen = ScreenPcb ); SetBaseScreen( ScreenPcb );
ActiveScreen = ScreenPcb;
GetSettings(); GetSettings();
SetSize( m_FramePos.x, m_FramePos.y, m_FrameSize.x, m_FrameSize.y ); SetSize( m_FramePos.x, m_FramePos.y, m_FrameSize.x, m_FrameSize.y );
...@@ -173,6 +173,7 @@ void WinEDA_GerberFrame::OnCloseWindow( wxCloseEvent& Event ) ...@@ -173,6 +173,7 @@ void WinEDA_GerberFrame::OnCloseWindow( wxCloseEvent& Event )
{ {
PCB_SCREEN* screen = ScreenPcb; PCB_SCREEN* screen = ScreenPcb;
#if 0 // unused currently
while( screen ) while( screen )
{ {
if( screen->IsModify() ) if( screen->IsModify() )
...@@ -188,7 +189,7 @@ void WinEDA_GerberFrame::OnCloseWindow( wxCloseEvent& Event ) ...@@ -188,7 +189,7 @@ void WinEDA_GerberFrame::OnCloseWindow( wxCloseEvent& Event )
return; return;
} }
} }
#endif
while( screen ) // suppression flag modify pour eviter d'autres message while( screen ) // suppression flag modify pour eviter d'autres message
{ {
screen->ClrModify(); screen->ClrModify();
......
...@@ -115,8 +115,6 @@ bool Read_Config() ...@@ -115,8 +115,6 @@ bool Read_Config()
FALSE ); FALSE );
/* Inits autres variables */ /* Inits autres variables */
if( ScreenPcb )
ScreenPcb->SetGrid( TmpGrid );
if( g_PhotoFilenameExt.IsEmpty() ) if( g_PhotoFilenameExt.IsEmpty() )
g_PhotoFilenameExt = wxT( ".pho" ); g_PhotoFilenameExt = wxT( ".pho" );
if( g_DrillFilenameExt.IsEmpty() ) if( g_DrillFilenameExt.IsEmpty() )
......
...@@ -6,8 +6,6 @@ ...@@ -6,8 +6,6 @@
#define INSETUP TRUE #define INSETUP TRUE
static wxSize TmpGrid; /* memorisation temporaire */
/* Liste des parametres */ /* Liste des parametres */
static PARAM_CFG_WXSTRING PhotoExtBufCfg static PARAM_CFG_WXSTRING PhotoExtBufCfg
......
...@@ -15,7 +15,8 @@ OBJECTS= \ ...@@ -15,7 +15,8 @@ OBJECTS= \
select_layers_to_pcb.o\ select_layers_to_pcb.o\
sel_layer.o\ sel_layer.o\
lay2plot.o\ lay2plot.o\
wxprint.o \ dialog_print_using_printer_base.o \
dialog_print_using_printer.o \
edit.o \ edit.o \
setpage.o \ setpage.o \
tool_gerber.o \ tool_gerber.o \
...@@ -82,8 +83,11 @@ class_drc_item.o: ../pcbnew/class_drc_item.cpp ...@@ -82,8 +83,11 @@ class_drc_item.o: ../pcbnew/class_drc_item.cpp
sel_layer.o: ../pcbnew/sel_layer.cpp sel_layer.o: ../pcbnew/sel_layer.cpp
$(CXX) -c $(EDACPPFLAGS) -o $@ ../pcbnew/$*.cpp $(CXX) -c $(EDACPPFLAGS) -o $@ ../pcbnew/$*.cpp
wxprint.o: ../share/wxprint.cpp ../share/dialog_print.cpp ../share/dialog_print.h dialog_print_using_printer_base.o: ../pcbnew/dialog_print_using_printer_base.cpp ../pcbnew/dialog_print_using_printer_base.h
$(CXX) -c $(EDACPPFLAGS) -o $@ ../share/$*.cpp $(CXX) -c $(EDACPPFLAGS) -o $@ ../pcbnew/$*.cpp
dialog_print_using_printer.o: ../pcbnew/dialog_print_using_printer.cpp ../pcbnew/dialog_print_using_printer_base.h
$(CXX) -c $(EDACPPFLAGS) -o $@ ../pcbnew/$*.cpp
classpcb.o: ../pcbnew/classpcb.cpp classpcb.o: ../pcbnew/classpcb.cpp
$(CXX) -c $(EDACPPFLAGS) -o $@ ../pcbnew/$*.cpp $(CXX) -c $(EDACPPFLAGS) -o $@ ../pcbnew/$*.cpp
......
No preview for this file type
...@@ -2,8 +2,8 @@ msgid "" ...@@ -2,8 +2,8 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: kicad\n" "Project-Id-Version: kicad\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-01-15 21:48+0100\n" "POT-Creation-Date: 2009-01-17 16:54+0100\n"
"PO-Revision-Date: 2009-01-15 21:50+0100\n" "PO-Revision-Date: 2009-01-17 16:54+0100\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: kicad team <jean-pierre.charras@ujf-grenoble.fr>\n" "Language-Team: kicad team <jean-pierre.charras@ujf-grenoble.fr>\n"
"MIME-Version: 1.0\n" "MIME-Version: 1.0\n"
...@@ -4550,6 +4550,8 @@ msgid "" ...@@ -4550,6 +4550,8 @@ msgid ""
"Choose if you wand to draw the sheet like it appears on screen,\n" "Choose if you wand to draw the sheet like it appears on screen,\n"
"or in black and white mode, better to print it when using black and white printers" "or in black and white mode, better to print it when using black and white printers"
msgstr "" msgstr ""
"Choisir si vous voulez tracer la feuille telle qu'elle apparait à l'écran,\n"
"ou en noir et blanc, préférable pour l'imprimer lorsque l'on utilise des imprimantes monochromes"
#: pcbnew/dialog_SVG_print_base.cpp:55 #: pcbnew/dialog_SVG_print_base.cpp:55
msgid "Print Frame Ref" msgid "Print Frame Ref"
...@@ -4588,6 +4590,8 @@ msgid "" ...@@ -4588,6 +4590,8 @@ msgid ""
"Enter a filename if you do not want to use defaults files names\n" "Enter a filename if you do not want to use defaults files names\n"
"Can be used only when printing the current sheet" "Can be used only when printing the current sheet"
msgstr "" msgstr ""
"Entrez un nom de fichier si vous ne voulez pas utiliser les noms par défaut\n"
"Ne peut être utilisé que pour imprimer la feuille courante"
#: pcbnew/dialog_SVG_print_base.cpp:97 #: pcbnew/dialog_SVG_print_base.cpp:97
msgid "Messages:" msgid "Messages:"
...@@ -5271,6 +5275,107 @@ msgstr "Une piste ou via a une référence vers un pad \"%s\" manquant" ...@@ -5271,6 +5275,107 @@ msgstr "Une piste ou via a une référence vers un pad \"%s\" manquant"
msgid "TextPCB properties" msgid "TextPCB properties"
msgstr "Propriétés des textes PCB" msgstr "Propriétés des textes PCB"
#: pcbnew/dialog_print_using_printer_base.cpp:35
msgid "Exclude Edges_Pcb Layer"
msgstr "Exclure Couche Contours PCB"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "fit in page"
msgstr "Ajustage en page"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "Scale 0.5"
msgstr "Echelle 0,5"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "Scale 0.7"
msgstr "Echelle 0,7"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "Approx. Scale 1"
msgstr "Echelle Appprox. 1"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "Accurate Scale 1"
msgstr "Echelle Précise 1"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "Scale 1.4"
msgstr "Echelle 1,4"
#: pcbnew/dialog_print_using_printer_base.cpp:46
msgid "Scale 4"
msgstr "Echelle 4"
#: pcbnew/dialog_print_using_printer_base.cpp:48
msgid "Approx. Scale:"
msgstr "Echelle approx.:"
#: pcbnew/dialog_print_using_printer_base.cpp:52
msgid "X Scale Adjust"
msgstr "Ajustage Echelle X"
#: pcbnew/dialog_print_using_printer_base.cpp:61
msgid "Y Scale Adjust"
msgstr "Ajustage Echelle Y"
#: pcbnew/dialog_print_using_printer_base.cpp:78
msgid "Pen Width Mini"
msgstr "Epaiss Plume Mini"
#: pcbnew/dialog_print_using_printer_base.cpp:87
msgid "Print frame ref"
msgstr "Imprimer cartouche"
#: pcbnew/dialog_print_using_printer_base.cpp:100
msgid "Black and white"
msgstr "Noir et blanc"
#: pcbnew/dialog_print_using_printer_base.cpp:102
msgid "Print Mode"
msgstr "Mode d'impression"
#: pcbnew/dialog_print_using_printer_base.cpp:108
msgid "1 Page per Layer"
msgstr "1 Page par couche"
#: pcbnew/dialog_print_using_printer_base.cpp:108
msgid "Single page"
msgstr "Page unique"
#: pcbnew/dialog_print_using_printer_base.cpp:110
msgid "Page Print"
msgstr "Imprimer Page"
#: pcbnew/dialog_print_using_printer_base.cpp:119
msgid "Page Options"
msgstr "Options Pages"
#: pcbnew/dialog_print_using_printer_base.cpp:122
msgid "Preview"
msgstr "Previsualisation"
#: pcbnew/dialog_print_using_printer_base.cpp:125
msgid "Print"
msgstr "Imprimer"
#: pcbnew/dialog_print_using_printer.cpp:122
msgid "Error Init Printer info"
msgstr "Erreur Init info imprimante"
#: pcbnew/dialog_print_using_printer.cpp:361
msgid "Printer Problem!"
msgstr "Probleme d'imprimante"
#: pcbnew/dialog_print_using_printer.cpp:454
msgid "There was a problem printing"
msgstr "Il y a un problème d'impression"
#: pcbnew/dialog_print_using_printer.cpp:470
#, c-format
msgid "Print page %d"
msgstr "Print page %d"
#: eeschema/backanno.cpp:135 #: eeschema/backanno.cpp:135
msgid "Load Stuff File" msgid "Load Stuff File"
msgstr "Charger Fichier d'échange" msgstr "Charger Fichier d'échange"
...@@ -5385,6 +5490,7 @@ msgid "Sheet Size" ...@@ -5385,6 +5490,7 @@ msgid "Sheet Size"
msgstr "Dim. feuille" msgstr "Dim. feuille"
#: eeschema/plothpgl.cpp:225 #: eeschema/plothpgl.cpp:225
#: eeschema/plotps.cpp:193
msgid "Page Size A4" msgid "Page Size A4"
msgstr "Feuille A4" msgstr "Feuille A4"
...@@ -5405,6 +5511,7 @@ msgid "Page Size A0" ...@@ -5405,6 +5511,7 @@ msgid "Page Size A0"
msgstr "Feuille A0" msgstr "Feuille A0"
#: eeschema/plothpgl.cpp:230 #: eeschema/plothpgl.cpp:230
#: eeschema/plotps.cpp:194
msgid "Page Size A" msgid "Page Size A"
msgstr "Feuille A" msgstr "Feuille A"
...@@ -5425,6 +5532,7 @@ msgid "Page Size E" ...@@ -5425,6 +5532,7 @@ msgid "Page Size E"
msgstr "Feuille E" msgstr "Feuille E"
#: eeschema/plothpgl.cpp:236 #: eeschema/plothpgl.cpp:236
#: eeschema/plotps.cpp:196
msgid "Plot page size:" msgid "Plot page size:"
msgstr "Format de la feuille:" msgstr "Format de la feuille:"
...@@ -5453,10 +5561,12 @@ msgid "Plot Offset Y" ...@@ -5453,10 +5561,12 @@ msgid "Plot Offset Y"
msgstr "Offset de tracé Y" msgstr "Offset de tracé Y"
#: eeschema/plothpgl.cpp:339 #: eeschema/plothpgl.cpp:339
#: eeschema/plotps.cpp:233
msgid "&Plot page" msgid "&Plot page"
msgstr "&Tracer Page" msgstr "&Tracer Page"
#: eeschema/plothpgl.cpp:345 #: eeschema/plothpgl.cpp:345
#: eeschema/plotps.cpp:240
msgid "Plot a&ll" msgid "Plot a&ll"
msgstr "&Tout tracer" msgstr "&Tout tracer"
...@@ -5524,22 +5634,18 @@ msgid "Length" ...@@ -5524,22 +5634,18 @@ msgid "Length"
msgstr "Longueur" msgstr "Longueur"
#: eeschema/affiche.cpp:102 #: eeschema/affiche.cpp:102
#: eeschema/pinedit-dialog.cpp:225
msgid "Up" msgid "Up"
msgstr "Haut" msgstr "Haut"
#: eeschema/affiche.cpp:105 #: eeschema/affiche.cpp:105
#: eeschema/pinedit-dialog.cpp:226
msgid "Down" msgid "Down"
msgstr "Bas" msgstr "Bas"
#: eeschema/affiche.cpp:108 #: eeschema/affiche.cpp:108
#: eeschema/pinedit-dialog.cpp:224
msgid "Left" msgid "Left"
msgstr "Gauche" msgstr "Gauche"
#: eeschema/affiche.cpp:111 #: eeschema/affiche.cpp:111
#: eeschema/pinedit-dialog.cpp:223
msgid "Right" msgid "Right"
msgstr "Droite" msgstr "Droite"
...@@ -5947,37 +6053,30 @@ msgid "Plot: %s\n" ...@@ -5947,37 +6053,30 @@ msgid "Plot: %s\n"
msgstr "Trace: %s\n" msgstr "Trace: %s\n"
#: eeschema/pinedit.cpp:22 #: eeschema/pinedit.cpp:22
#: eeschema/pinedit-dialog.cpp:251
msgid "line" msgid "line"
msgstr "Ligne" msgstr "Ligne"
#: eeschema/pinedit.cpp:22 #: eeschema/pinedit.cpp:22
#: eeschema/pinedit-dialog.cpp:252
msgid "invert" msgid "invert"
msgstr "invert" msgstr "invert"
#: eeschema/pinedit.cpp:22 #: eeschema/pinedit.cpp:22
#: eeschema/pinedit-dialog.cpp:253
msgid "clock" msgid "clock"
msgstr "clock" msgstr "clock"
#: eeschema/pinedit.cpp:22 #: eeschema/pinedit.cpp:22
#: eeschema/pinedit-dialog.cpp:254
msgid "clock inv" msgid "clock inv"
msgstr "clock inv" msgstr "clock inv"
#: eeschema/pinedit.cpp:23 #: eeschema/pinedit.cpp:23
#: eeschema/pinedit-dialog.cpp:255
msgid "low in" msgid "low in"
msgstr "low in" msgstr "low in"
#: eeschema/pinedit.cpp:23 #: eeschema/pinedit.cpp:23
#: eeschema/pinedit-dialog.cpp:256
msgid "low clock" msgid "low clock"
msgstr "low clock" msgstr "low clock"
#: eeschema/pinedit.cpp:23 #: eeschema/pinedit.cpp:23
#: eeschema/pinedit-dialog.cpp:257
msgid "low out" msgid "low out"
msgstr "low out" msgstr "low out"
...@@ -6152,7 +6251,6 @@ msgid "Common to Units" ...@@ -6152,7 +6251,6 @@ msgid "Common to Units"
msgstr "Commun aux Unités" msgstr "Commun aux Unités"
#: eeschema/dialog_cmp_graphic_properties.cpp:160 #: eeschema/dialog_cmp_graphic_properties.cpp:160
#: eeschema/pinedit-dialog.cpp:197
msgid "Common to convert" msgid "Common to convert"
msgstr "Commun a converti" msgstr "Commun a converti"
...@@ -8429,7 +8527,7 @@ msgid "Datasheet" ...@@ -8429,7 +8527,7 @@ msgid "Datasheet"
msgstr "Documentation" msgstr "Documentation"
#: eeschema/dialog_SVG_print_base.cpp:53 #: eeschema/dialog_SVG_print_base.cpp:53
msgid "PrintCurrent" msgid "Print Current"
msgstr "Imprimer Page Courante" msgstr "Imprimer Page Courante"
#: eeschema/dialog_SVG_print_base.cpp:56 #: eeschema/dialog_SVG_print_base.cpp:56
...@@ -8472,6 +8570,10 @@ msgstr "Voir documents des composants" ...@@ -8472,6 +8570,10 @@ msgstr "Voir documents des composants"
msgid "Insert component in schematic" msgid "Insert component in schematic"
msgstr "Placer composant en schématique" msgstr "Placer composant en schématique"
#: eeschema/dialog_print_using_printer_base.cpp:52
msgid "Current"
msgstr "Courant"
#: eeschema/class_drawsheetpath.cpp:180 #: eeschema/class_drawsheetpath.cpp:180
#, c-format #, c-format
msgid "%8.8lX/" msgid "%8.8lX/"
...@@ -9131,7 +9233,6 @@ msgid "Create New Directory" ...@@ -9131,7 +9233,6 @@ msgid "Create New Directory"
msgstr "Créer un nouveau Répertoire" msgstr "Créer un nouveau Répertoire"
#: kicad/treeprj_frame.cpp:543 #: kicad/treeprj_frame.cpp:543
#: kicad/kicad.cpp:381
msgid "noname" msgid "noname"
msgstr "noname" msgstr "noname"
...@@ -9510,6 +9611,7 @@ msgid "%d errors while reading Gerber file [%s]" ...@@ -9510,6 +9611,7 @@ msgid "%d errors while reading Gerber file [%s]"
msgstr "%d erreurs pendant lecture fichier gerber [%s]" msgstr "%d erreurs pendant lecture fichier gerber [%s]"
#: gerbview/readgerb.cpp:273 #: gerbview/readgerb.cpp:273
#: gerbview/files.cpp:187
msgid "D codes files:" msgid "D codes files:"
msgstr "Fichiers D-Codes:" msgstr "Fichiers D-Codes:"
...@@ -10200,18 +10302,22 @@ msgid "Back View" ...@@ -10200,18 +10302,22 @@ msgid "Back View"
msgstr "Vue arrière" msgstr "Vue arrière"
#: 3d-viewer/3d_canvas.cpp:374 #: 3d-viewer/3d_canvas.cpp:374
#: 3d-viewer/3d_toolbar.cpp:77
msgid "Move left <-" msgid "Move left <-"
msgstr "Vers la gauche <-" msgstr "Vers la gauche <-"
#: 3d-viewer/3d_canvas.cpp:379 #: 3d-viewer/3d_canvas.cpp:379
#: 3d-viewer/3d_toolbar.cpp:80
msgid "Move right ->" msgid "Move right ->"
msgstr "Vers la droite ->" msgstr "Vers la droite ->"
#: 3d-viewer/3d_canvas.cpp:384 #: 3d-viewer/3d_canvas.cpp:384
#: 3d-viewer/3d_toolbar.cpp:83
msgid "Move Up ^" msgid "Move Up ^"
msgstr "Vers le haut ^" msgstr "Vers le haut ^"
#: 3d-viewer/3d_canvas.cpp:389 #: 3d-viewer/3d_canvas.cpp:389
#: 3d-viewer/3d_toolbar.cpp:86
msgid "Move Down" msgid "Move Down"
msgstr "Vers le bas" msgstr "Vers le bas"
...@@ -10299,58 +10405,10 @@ msgstr "Couche ECO1 On/Off" ...@@ -10299,58 +10405,10 @@ msgstr "Couche ECO1 On/Off"
msgid "Eco2 Layer On/Off" msgid "Eco2 Layer On/Off"
msgstr "Couche ECO2 On/Off" msgstr "Couche ECO2 On/Off"
#: share/dialog_print.cpp:146
msgid "Exclude Edges_Pcb Layer"
msgstr "Exclure Couche Contours PCB"
#: share/dialog_print.cpp:157
msgid "fit in page"
msgstr "Ajustage en page"
#: share/dialog_print.cpp:158
msgid "Scale 0.5"
msgstr "Echelle 0,5"
#: share/dialog_print.cpp:159
msgid "Scale 0.7"
msgstr "Echelle 0,7"
#: share/dialog_print.cpp:160
msgid "Approx. Scale 1"
msgstr "Echelle Appprox. 1"
#: share/dialog_print.cpp:161
msgid "Accurate Scale 1"
msgstr "Echelle Précise 1"
#: share/dialog_print.cpp:162
msgid "Scale 1.4"
msgstr "Echelle 1,4"
#: share/dialog_print.cpp:165
msgid "Scale 4"
msgstr "Echelle 4"
#: share/dialog_print.cpp:166
msgid "Approx. Scale:"
msgstr "Echelle approx.:"
#: share/dialog_print.cpp:170
msgid "X Scale Adjust"
msgstr "Ajustage Echelle X"
#: share/dialog_print.cpp:176
msgid "Y Scale Adjust"
msgstr "Ajustage Echelle Y"
#: share/dialog_print.cpp:205 #: share/dialog_print.cpp:205
msgid "Color Print:" msgid "Color Print:"
msgstr "Impression Couleurs:" msgstr "Impression Couleurs:"
#: share/dialog_print.cpp:210
msgid "1 Page per Layer"
msgstr "1 Page par couche"
#: share/dialog_print.cpp:211 #: share/dialog_print.cpp:211
msgid "Single Page" msgid "Single Page"
msgstr "Page unique" msgstr "Page unique"
...@@ -10360,10 +10418,6 @@ msgstr "Page unique" ...@@ -10360,10 +10418,6 @@ msgstr "Page unique"
msgid "Page Print:" msgid "Page Print:"
msgstr "Imprimer page" msgstr "Imprimer page"
#: share/dialog_print.cpp:217
msgid "Current"
msgstr "Courant"
#: share/dialog_print.cpp:230 #: share/dialog_print.cpp:230
msgid "Print S&etup" msgid "Print S&etup"
msgstr "Options Impr&ession" msgstr "Options Impr&ession"
...@@ -10476,27 +10530,10 @@ msgstr "Commentaire3:" ...@@ -10476,27 +10530,10 @@ msgstr "Commentaire3:"
msgid "Comment4:" msgid "Comment4:"
msgstr "Commentaire4:" msgstr "Commentaire4:"
#: share/wxprint.cpp:127
msgid "Error Init Printer info"
msgstr "Erreur Init info imprimante"
#: share/wxprint.cpp:372
msgid "Printer Problem!"
msgstr "Probleme d'imprimante"
#: share/wxprint.cpp:405 #: share/wxprint.cpp:405
msgid "There was a problem previewing" msgid "There was a problem previewing"
msgstr "Il y a un problème de prévisualisation" msgstr "Il y a un problème de prévisualisation"
#: share/wxprint.cpp:469
msgid "There was a problem printing"
msgstr "Il y a un problème d'impression"
#: share/wxprint.cpp:485
#, c-format
msgid "Print page %d"
msgstr "Print page %d"
#: pcbnew/gen_self.h:217 #: pcbnew/gen_self.h:217
msgid "Length(inch):" msgid "Length(inch):"
msgstr "Longueur (pouces):" msgstr "Longueur (pouces):"
...@@ -10965,10 +11002,6 @@ msgstr "DCodes id." ...@@ -10965,10 +11002,6 @@ msgstr "DCodes id."
msgid "Page Settings" msgid "Page Settings"
msgstr "Ajustage opt Page" msgstr "Ajustage opt Page"
#: share/dialog_print.h:52
msgid "Print"
msgstr "Imprimer"
#~ msgid "Tracks" #~ msgid "Tracks"
#~ msgstr "Pistes" #~ msgstr "Pistes"
#~ msgid "** Plot End **\n" #~ msgid "** Plot End **\n"
......
...@@ -65,6 +65,8 @@ set(PCBNEW_SRCS ...@@ -65,6 +65,8 @@ set(PCBNEW_SRCS
dialog_non_copper_zones_properties_base.cpp dialog_non_copper_zones_properties_base.cpp
dialog_pad_properties.cpp dialog_pad_properties.cpp
dialog_pad_properties_base.cpp dialog_pad_properties_base.cpp
dialog_print_using_printer.cpp
dialog_print_using_printer_base.cpp
dialog_setup_libs.cpp dialog_setup_libs.cpp
dialog_orient_footprints.cpp dialog_orient_footprints.cpp
# dialog_track_options.cpp # dialog_track_options.cpp
...@@ -159,8 +161,7 @@ set(PCBNEW_SRCS ...@@ -159,8 +161,7 @@ set(PCBNEW_SRCS
) )
set(PCBNEW_EXTRA_SRCS set(PCBNEW_EXTRA_SRCS
../share/setpage.cpp ../share/setpage.cpp )
../share/wxprint.cpp)
if(WIN32) if(WIN32)
if(MINGW) if(MINGW)
......
...@@ -312,9 +312,10 @@ void DIALOG_SVG_PRINT::OnButtonCancelClick( wxCommandEvent& event ) ...@@ -312,9 +312,10 @@ void DIALOG_SVG_PRINT::OnButtonCancelClick( wxCommandEvent& event )
void DIALOG_SVG_PRINT::OnCloseWindow( wxCloseEvent& event ) void DIALOG_SVG_PRINT::OnCloseWindow( wxCloseEvent& event )
/***********************************************************/ /***********************************************************/
{ {
SetPenWidth();
s_PlotBlackAndWhite = m_ModeColorOption->GetSelection();
if( m_Config ) if( m_Config )
{ {
s_PlotBlackAndWhite = m_ModeColorOption->GetSelection();
m_Config->Write( OPTKEY_PLOT_LINEWIDTH_VALUE, s_PrintPenMinWidth ); m_Config->Write( OPTKEY_PLOT_LINEWIDTH_VALUE, s_PrintPenMinWidth );
m_Config->Write( PLOTSVGMODECOLOR_KEY, s_PlotBlackAndWhite ); m_Config->Write( PLOTSVGMODECOLOR_KEY, s_PlotBlackAndWhite );
wxString layerKey; wxString layerKey;
......
...@@ -75,7 +75,7 @@ DIALOG_SVG_PRINT_base::DIALOG_SVG_PRINT_base( wxWindow* parent, wxWindowID id, c ...@@ -75,7 +75,7 @@ DIALOG_SVG_PRINT_base::DIALOG_SVG_PRINT_base( wxWindow* parent, wxWindowID id, c
bButtonsSizer->Add( m_buttonPrintSelected, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); bButtonsSizer->Add( m_buttonPrintSelected, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonBoard = new wxButton( this, wxID_PRINT_BOARD, _("Print Board"), wxDefaultPosition, wxDefaultSize, 0 ); m_buttonBoard = new wxButton( this, wxID_PRINT_BOARD, _("Print Board"), wxDefaultPosition, wxDefaultSize, 0 );
bButtonsSizer->Add( m_buttonBoard, 0, wxALL, 5 ); bButtonsSizer->Add( m_buttonBoard, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonQuit = new wxButton( this, wxID_CANCEL, _("Quit"), wxDefaultPosition, wxDefaultSize, 0 ); m_buttonQuit = new wxButton( this, wxID_CANCEL, _("Quit"), wxDefaultPosition, wxDefaultSize, 0 );
bButtonsSizer->Add( m_buttonQuit, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); bButtonsSizer->Add( m_buttonQuit, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
......
...@@ -467,7 +467,7 @@ ...@@ -467,7 +467,7 @@
</object> </object>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="1">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxALL</property> <property name="flag">wxALL|wxALIGN_CENTER_HORIZONTAL</property>
<property name="proportion">0</property> <property name="proportion">0</property>
<object class="wxButton" expanded="1"> <object class="wxButton" expanded="1">
<property name="bg"></property> <property name="bg"></property>
......
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 16 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#include "dialog_print_using_printer_base.h"
///////////////////////////////////////////////////////////////////////////
DIALOG_PRINT_USING_PRINTER_base::DIALOG_PRINT_USING_PRINTER_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( wxSize( -1,-1 ), wxDefaultSize );
wxBoxSizer* bMainSizer;
bMainSizer = new wxBoxSizer( wxHORIZONTAL );
wxStaticBoxSizer* sbLayersSizer;
sbLayersSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Layers:") ), wxVERTICAL );
wxBoxSizer* bleftSizer;
bleftSizer = new wxBoxSizer( wxHORIZONTAL );
m_CopperLayersBoxSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Copper Layers:") ), wxVERTICAL );
bleftSizer->Add( m_CopperLayersBoxSizer, 1, wxALL, 5 );
m_TechnicalLayersBoxSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Technical Layers:") ), wxVERTICAL );
bleftSizer->Add( m_TechnicalLayersBoxSizer, 1, wxALL, 5 );
sbLayersSizer->Add( bleftSizer, 1, wxEXPAND, 5 );
m_Exclude_Edges_Pcb = new wxCheckBox( this, wxID_ANY, _("Exclude Edges_Pcb Layer"), wxDefaultPosition, wxDefaultSize, 0 );
m_Exclude_Edges_Pcb->SetToolTip( _("Exclude contents of Edges_Pcb layer from all other layers") );
sbLayersSizer->Add( m_Exclude_Edges_Pcb, 0, wxALL|wxEXPAND, 5 );
bMainSizer->Add( sbLayersSizer, 1, wxEXPAND, 5 );
wxBoxSizer* bmiddleLeftSizer;
bmiddleLeftSizer = new wxBoxSizer( wxVERTICAL );
wxString m_ScaleOptionChoices[] = { _("fit in page"), _("Scale 0.5"), _("Scale 0.7"), _("Approx. Scale 1"), _("Accurate Scale 1"), _("Scale 1.4"), _("Scale 2"), _("Scale 3"), _("Scale 4") };
int m_ScaleOptionNChoices = sizeof( m_ScaleOptionChoices ) / sizeof( wxString );
m_ScaleOption = new wxRadioBox( this, wxID_ANY, _("Approx. Scale:"), wxDefaultPosition, wxDefaultSize, m_ScaleOptionNChoices, m_ScaleOptionChoices, 1, wxRA_SPECIFY_COLS );
m_ScaleOption->SetSelection( 3 );
bmiddleLeftSizer->Add( m_ScaleOption, 0, wxALL, 5 );
m_FineAdjustXscaleTitle = new wxStaticText( this, wxID_ANY, _("X Scale Adjust"), wxDefaultPosition, wxDefaultSize, 0 );
m_FineAdjustXscaleTitle->Wrap( -1 );
bmiddleLeftSizer->Add( m_FineAdjustXscaleTitle, 0, wxRIGHT|wxLEFT, 5 );
m_FineAdjustXscaleOpt = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_FineAdjustXscaleOpt->SetToolTip( _("Set X scale adjust for exact scale plotting") );
bmiddleLeftSizer->Add( m_FineAdjustXscaleOpt, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 );
m_FineAdjustYscaleTitle = new wxStaticText( this, wxID_ANY, _("Y Scale Adjust"), wxDefaultPosition, wxDefaultSize, 0 );
m_FineAdjustYscaleTitle->Wrap( -1 );
bmiddleLeftSizer->Add( m_FineAdjustYscaleTitle, 0, wxRIGHT|wxLEFT, 5 );
m_FineAdjustYscaleOpt = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_FineAdjustYscaleOpt->SetToolTip( _("Set Y scale adjust for exact scale plotting") );
bmiddleLeftSizer->Add( m_FineAdjustYscaleOpt, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 );
bMainSizer->Add( bmiddleLeftSizer, 0, wxEXPAND, 5 );
wxBoxSizer* bmiddleRightSizer;
bmiddleRightSizer = new wxBoxSizer( wxVERTICAL );
wxStaticBoxSizer* sbOptionsSizer;
sbOptionsSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Options:") ), wxVERTICAL );
m_TextPenWidth = new wxStaticText( this, wxID_ANY, _("Pen Width Mini"), wxDefaultPosition, wxDefaultSize, 0 );
m_TextPenWidth->Wrap( -1 );
sbOptionsSizer->Add( m_TextPenWidth, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_DialogPenWidth = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_DialogPenWidth->SetToolTip( _("Selection of the minimum pen thickness used to draw items.") );
sbOptionsSizer->Add( m_DialogPenWidth, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 );
m_Print_Sheet_Ref = new wxCheckBox( this, wxID_FRAME_SEL, _("Print frame ref"), wxDefaultPosition, wxDefaultSize, 0 );
m_Print_Sheet_Ref->SetValue(true);
m_Print_Sheet_Ref->SetToolTip( _("Print (or not) the Frame references.") );
sbOptionsSizer->Add( m_Print_Sheet_Ref, 0, wxALL, 5 );
m_Print_Mirror = new wxCheckBox( this, wxID_ANY, _("Mirror"), wxDefaultPosition, wxDefaultSize, 0 );
sbOptionsSizer->Add( m_Print_Mirror, 0, wxALL, 5 );
bmiddleRightSizer->Add( sbOptionsSizer, 0, wxEXPAND|wxALL, 5 );
wxString m_ModeColorOptionChoices[] = { _("Color"), _("Black and white") };
int m_ModeColorOptionNChoices = sizeof( m_ModeColorOptionChoices ) / sizeof( wxString );
m_ModeColorOption = new wxRadioBox( this, wxID_PRINT_MODE, _("Print Mode"), wxDefaultPosition, wxDefaultSize, m_ModeColorOptionNChoices, m_ModeColorOptionChoices, 1, wxRA_SPECIFY_COLS );
m_ModeColorOption->SetSelection( 1 );
m_ModeColorOption->SetToolTip( _("Choose if you wand to draw the sheet like it appears on screen,\nor in black and white mode, better to print it when using black and white printers") );
bmiddleRightSizer->Add( m_ModeColorOption, 0, wxALL|wxEXPAND, 5 );
wxString m_PagesOptionChoices[] = { _("1 Page per Layer"), _("Single page") };
int m_PagesOptionNChoices = sizeof( m_PagesOptionChoices ) / sizeof( wxString );
m_PagesOption = new wxRadioBox( this, wxID_PAGE_MODE, _("Page Print"), wxDefaultPosition, wxDefaultSize, m_PagesOptionNChoices, m_PagesOptionChoices, 1, wxRA_SPECIFY_COLS );
m_PagesOption->SetSelection( 0 );
bmiddleRightSizer->Add( m_PagesOption, 0, wxALL|wxEXPAND, 5 );
bMainSizer->Add( bmiddleRightSizer, 0, wxEXPAND, 5 );
wxBoxSizer* bbuttonsSizer;
bbuttonsSizer = new wxBoxSizer( wxVERTICAL );
m_buttonOption = new wxButton( this, wxID_PRINT_OPTIONS, _("Page Options"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonOption, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonPreview = new wxButton( this, wxID_PREVIEW, _("Preview"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonPreview, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonPrint = new wxButton( this, wxID_PRINT_ALL, _("Print"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonPrint, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_buttonQuit = new wxButton( this, wxID_CANCEL, _("Close"), wxDefaultPosition, wxDefaultSize, 0 );
bbuttonsSizer->Add( m_buttonQuit, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
bMainSizer->Add( bbuttonsSizer, 0, wxALIGN_CENTER_VERTICAL, 5 );
this->SetSizer( bMainSizer );
this->Layout();
// Connect Events
this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnCloseWindow ) );
this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnInitDialog ) );
m_ScaleOption->Connect( wxEVT_COMMAND_RADIOBOX_SELECTED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::SetScale ), NULL, this );
m_buttonOption->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintSetup ), NULL, this );
m_buttonPreview->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintPreview ), NULL, this );
m_buttonPrint->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintButtonClick ), NULL, this );
m_buttonQuit->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnButtonCancelClick ), NULL, this );
}
DIALOG_PRINT_USING_PRINTER_base::~DIALOG_PRINT_USING_PRINTER_base()
{
// Disconnect Events
this->Disconnect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnCloseWindow ) );
this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnInitDialog ) );
m_ScaleOption->Disconnect( wxEVT_COMMAND_RADIOBOX_SELECTED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::SetScale ), NULL, this );
m_buttonOption->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintSetup ), NULL, this );
m_buttonPreview->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintPreview ), NULL, this );
m_buttonPrint->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnPrintButtonClick ), NULL, this );
m_buttonQuit->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PRINT_USING_PRINTER_base::OnButtonCancelClick ), NULL, this );
}
This diff is collapsed.
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 16 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#ifndef __dialog_print_using_printer_base__
#define __dialog_print_using_printer_base__
#include <wx/intl.h>
#include <wx/string.h>
#include <wx/sizer.h>
#include <wx/statbox.h>
#include <wx/gdicmn.h>
#include <wx/checkbox.h>
#include <wx/font.h>
#include <wx/colour.h>
#include <wx/settings.h>
#include <wx/radiobox.h>
#include <wx/stattext.h>
#include <wx/textctrl.h>
#include <wx/button.h>
#include <wx/dialog.h>
///////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////
/// Class DIALOG_PRINT_USING_PRINTER_base
///////////////////////////////////////////////////////////////////////////////
class DIALOG_PRINT_USING_PRINTER_base : public wxDialog
{
private:
protected:
enum
{
wxID_FRAME_SEL = 1000,
wxID_PRINT_MODE,
wxID_PAGE_MODE,
wxID_PRINT_OPTIONS,
wxID_PRINT_ALL,
};
wxStaticBoxSizer* m_CopperLayersBoxSizer;
wxStaticBoxSizer* m_TechnicalLayersBoxSizer;
wxCheckBox* m_Exclude_Edges_Pcb;
wxRadioBox* m_ScaleOption;
wxStaticText* m_FineAdjustXscaleTitle;
wxTextCtrl* m_FineAdjustXscaleOpt;
wxStaticText* m_FineAdjustYscaleTitle;
wxTextCtrl* m_FineAdjustYscaleOpt;
wxStaticText* m_TextPenWidth;
wxTextCtrl* m_DialogPenWidth;
wxCheckBox* m_Print_Sheet_Ref;
wxCheckBox* m_Print_Mirror;
wxRadioBox* m_ModeColorOption;
wxRadioBox* m_PagesOption;
wxButton* m_buttonOption;
wxButton* m_buttonPreview;
wxButton* m_buttonPrint;
wxButton* m_buttonQuit;
// Virtual event handlers, overide them in your derived class
virtual void OnCloseWindow( wxCloseEvent& event ){ event.Skip(); }
virtual void OnInitDialog( wxInitDialogEvent& event ){ event.Skip(); }
virtual void SetScale( wxCommandEvent& event ){ event.Skip(); }
virtual void OnPrintSetup( wxCommandEvent& event ){ event.Skip(); }
virtual void OnPrintPreview( wxCommandEvent& event ){ event.Skip(); }
virtual void OnPrintButtonClick( wxCommandEvent& event ){ event.Skip(); }
virtual void OnButtonCancelClick( wxCommandEvent& event ){ event.Skip(); }
public:
DIALOG_PRINT_USING_PRINTER_base( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Print"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 551,314 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_PRINT_USING_PRINTER_base();
};
#endif //__dialog_print_using_printer_base__
...@@ -35,12 +35,13 @@ OBJECTS= $(TARGET).o classpcb.o\ ...@@ -35,12 +35,13 @@ OBJECTS= $(TARGET).o classpcb.o\
dialog_pcb_text_properties.o\ dialog_pcb_text_properties.o\
dialog_SVG_print.o\ dialog_SVG_print.o\
dialog_SVG_print_base.o\ dialog_SVG_print_base.o\
dialog_print_using_printer.o\
dialog_print_using_printer_base.o\
onrightclick.o\ onrightclick.o\
onleftclick.o\ onleftclick.o\
modedit_onclick.o\ modedit_onclick.o\
cross-probing.o\ cross-probing.o\
via_edit.o\ via_edit.o\
wxprint.o \
class_marker.o\ class_marker.o\
menubarpcb.o \ menubarpcb.o \
menubarmodedit.o \ menubarmodedit.o \
...@@ -162,9 +163,6 @@ files.o: files.cpp ...@@ -162,9 +163,6 @@ files.o: files.cpp
export_gencad.o: export_gencad.cpp export_gencad.o: export_gencad.cpp
wxprint.o: ../share/wxprint.cpp ../share/dialog_print.cpp ../share/dialog_print.h
$(CXX) -c $(EDACPPFLAGS) -o $@ ../share/$*.cpp
print_board_functions.o: print_board_functions.cpp print_board_functions.o: print_board_functions.cpp
classpcb.o: classpcb.cpp classpcb.o: classpcb.cpp
......
...@@ -296,7 +296,7 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb ) ...@@ -296,7 +296,7 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb )
} }
// Now we remove all unused thermal stubs. // Now we remove all unused thermal stubs.
#define REMOVE_UNUSED_THERMAL_STUBS // Can be commented to skip unused thermal stubs calculations //#define REMOVE_UNUSED_THERMAL_STUBS // Can be commented to skip unused thermal stubs calculations
#ifdef REMOVE_UNUSED_THERMAL_STUBS #ifdef REMOVE_UNUSED_THERMAL_STUBS
// first compute endindex for TestPointInsidePolygon // first compute endindex for TestPointInsidePolygon
unsigned int indexstart = 0, indexend; unsigned int indexstart = 0, indexend;
...@@ -338,8 +338,8 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb ) ...@@ -338,8 +338,8 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb )
continue; continue;
// test point // test point
int dx = (pad->m_Size.x / 2) + m_ThermalReliefGapValue; int dx = (pad->m_Size.x / 2) + m_ThermalReliefGapValue + 3;
int dy = (pad->m_Size.y / 2) + m_ThermalReliefGapValue; int dy = (pad->m_Size.y / 2) + m_ThermalReliefGapValue + 3;
// compute north, south, west and east points for zone connection. // compute north, south, west and east points for zone connection.
wxPoint ptTest[4]; wxPoint ptTest[4];
...@@ -349,14 +349,18 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb ) ...@@ -349,14 +349,18 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb )
ptTest[3] = wxPoint(-(dx+m_ZoneMinThickness/2), 0); ptTest[3] = wxPoint(-(dx+m_ZoneMinThickness/2), 0);
// This is CIRCLE pad tweak (for circle pads the thermal stubs are at 45 deg) // This is CIRCLE pad tweak (for circle pads the thermal stubs are at 45 deg)
float fAngle = 0.0; int fAngle = pad->m_Orient;
if ( pad->m_PadShape == PAD_CIRCLE) if ( pad->m_PadShape == PAD_CIRCLE)
fAngle = 450.0; {
dx = (int) (dx * s_Correction);
dy = dx;
fAngle = 450;
}
// Test all sides // Test all sides
for (int i=0; i<4; i++) { for (int i=0; i<4; i++) {
// rotate point // rotate point
RotatePoint( &ptTest[i], pad->m_Orient + fAngle ); RotatePoint( &ptTest[i], fAngle );
// translate point // translate point
ptTest[i] += pad->ReturnShapePos(); ptTest[i] += pad->ReturnShapePos();
if ( TestPointInsidePolygon( m_FilledPolysList, indexstart, if ( TestPointInsidePolygon( m_FilledPolysList, indexstart,
...@@ -398,7 +402,7 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb ) ...@@ -398,7 +402,7 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb )
for( unsigned ic = 0; ic < corners_buffer.size(); ic++ ) for( unsigned ic = 0; ic < corners_buffer.size(); ic++ )
{ {
wxPoint cpos = corners_buffer[ic]; wxPoint cpos = corners_buffer[ic];
RotatePoint( &cpos, pad->m_Orient + fAngle ); // Rotate according to module orientation RotatePoint( &cpos, fAngle ); // Rotate according to module orientation
cpos += pad->ReturnShapePos(); // Shift origin to position cpos += pad->ReturnShapePos(); // Shift origin to position
booleng->AddPoint( cpos.x, cpos.y ); booleng->AddPoint( cpos.x, cpos.y );
} }
......
This diff is collapsed.
/////////////////////////////////////////////////////////////////////////////
// Name: dialog_print.h
// Purpose:
// Author: jean-pierre Charras
// Modified by:
// Created: 28/02/2006 18:30:16
// RCS-ID:
// Copyright: License GNU
// Licence:
/////////////////////////////////////////////////////////////////////////////
// Generated by DialogBlocks (unregistered), 28/02/2006 18:30:16
#ifndef _DIALOG_PRINT_H_
#define _DIALOG_PRINT_H_
/*!
* Includes
*/
////@begin includes
#include "wx/valgen.h"
////@end includes
/*!
* Forward declarations
*/
////@begin forward declarations
class wxBoxSizer;
////@end forward declarations
/*!
* Control identifiers
*/
////@begin control identifiers
#define ID_DIALOG 10000
#define ID_EXCLUDE_EDGES_PCB 10005
#define ID_SET_PRINT_SCALE 10004
#define ID_TEXTCTRL 10009
#define ID_TEXTCTRL1 10010
#define ID_PRINT_REF 10006
#define ID_CHECK_PRINT_MIROR 10011
#define ID_SET_BW 10007
#define ID_PRINT_ALL_IN_ONE 10008
#define ID_PRINT_ALL 10008
#define ID_PRINT_SETUP 10001
#define ID_PRINT_PREVIEW 10002
#define ID_PRINT_EXECUTE 10003
#define SYMBOL_WINEDA_PRINTFRAME_STYLE wxCAPTION|wxSYSTEM_MENU|wxCLOSE_BOX|MAYBE_RESIZE_BORDER
#define SYMBOL_WINEDA_PRINTFRAME_TITLE _("Print")
#define SYMBOL_WINEDA_PRINTFRAME_IDNAME ID_DIALOG
#define SYMBOL_WINEDA_PRINTFRAME_SIZE wxSize(400, 300)
#define SYMBOL_WINEDA_PRINTFRAME_POSITION wxDefaultPosition
////@end control identifiers
/*!
* Compatibility
*/
#ifndef wxCLOSE_BOX
#define wxCLOSE_BOX 0x1000
#endif
/*!
* WinEDA_PrintFrame class declaration
*/
class WinEDA_PrintFrame: public wxDialog
{
DECLARE_DYNAMIC_CLASS( WinEDA_PrintFrame )
DECLARE_EVENT_TABLE()
public:
/// Constructors
WinEDA_PrintFrame( );
WinEDA_PrintFrame( WinEDA_DrawFrame* parent, wxWindowID id = SYMBOL_WINEDA_PRINTFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_PRINTFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_PRINTFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_PRINTFRAME_SIZE, long style = SYMBOL_WINEDA_PRINTFRAME_STYLE );
/// Creation
bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WINEDA_PRINTFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_PRINTFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_PRINTFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_PRINTFRAME_SIZE, long style = SYMBOL_WINEDA_PRINTFRAME_STYLE );
/// Creates the controls and sizers
void CreateControls();
////@begin WinEDA_PrintFrame event handler declarations
/// wxEVT_COMMAND_RADIOBOX_SELECTED event handler for ID_SET_PRINT_SCALE
void OnSetPrintScaleSelected( wxCommandEvent& event );
/// wxEVT_COMMAND_RADIOBOX_SELECTED event handler for ID_SET_BW
void OnSetBwSelected( wxCommandEvent& event );
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PRINT_SETUP
void OnPrintSetupClick( wxCommandEvent& event );
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PRINT_PREVIEW
void OnPrintPreviewClick( wxCommandEvent& event );
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_PRINT_EXECUTE
void OnPrintExecuteClick( wxCommandEvent& event );
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL
void OnCancelClick( wxCommandEvent& event );
////@end WinEDA_PrintFrame event handler declarations
////@begin WinEDA_PrintFrame member function declarations
/// Retrieves bitmap resources
wxBitmap GetBitmapResource( const wxString& name );
/// Retrieves icon resources
wxIcon GetIconResource( const wxString& name );
////@end WinEDA_PrintFrame member function declarations
/// Should we show tooltips?
static bool ShowToolTips();
void OnClosePrintDialog();
void OnPrintSetup(wxCommandEvent& event);
void OnPrintPreview(wxCommandEvent& event);
void EDA_PrintPage(wxCommandEvent& event);
void SetColorOrBlack(wxCommandEvent& event);
void SetScale(wxCommandEvent& event);
int SetLayerMaskFromListSelection();
wxString BuildPrintTitle();
void SetOthersDatas();
void SetPenWidth();
////@begin WinEDA_PrintFrame member variables
wxBoxSizer* m_FullDialogBowSizer;
wxBoxSizer* m_LeftBoxSizer;
wxBoxSizer* m_LayersSelectionsBoxSizer;
wxBoxSizer* m_CopperLayersBoxSizer;
wxBoxSizer* m_TechLayersBoxSizer;
wxCheckBox* m_Exclude_Edges_Pcb;
wxBoxSizer* m_ScaleBoxSizer;
wxRadioBox* m_ScaleOption;
wxStaticText* m_FineAdjustXscaleTitle;
wxTextCtrl* m_FineAdjustXscaleOpt;
wxStaticText* m_FineAdjustYscaleTitle;
wxTextCtrl* m_FineAdjustYscaleOpt;
wxStaticBox* m_OptionsBoxSizer;
wxBoxSizer* m_DialogPenWidthSizer;
wxCheckBox* m_Print_Sheet_Ref;
wxCheckBox* m_Print_Mirror;
wxRadioBox* m_ColorOption;
wxRadioBox* m_PagesOptionPcb;
wxRadioBox* m_PagesOptionEeschema;
wxBoxSizer* m_ButtonsBoxSizer;
wxButton* m_CloseButton;
////@end WinEDA_PrintFrame member variables
WinEDA_DrawFrame * m_Parent;
wxRadioBox* m_PagesOption;
WinEDA_ValueCtrl * m_DialogPenWidth;
wxCheckBox * m_BoxSelecLayer[32];
double m_XScaleAdjust, m_YScaleAdjust;
wxConfig * m_Config;
};
#endif
// _DIALOG_PRINT_H_
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment