kicad-patches/cmdline-common.patch |
1 | 1 | diff -ru kicad.orig/include/appl_wxstruct.h kicad/include/appl_wxstruct.h |
2 | | +++ kicad/include/appl_wxstruct.h 2012-01-04 00:58:00.447684901 +0100 |
| 2 | --- kicad.orig/include/appl_wxstruct.h 2012-01-11 12:02:53.707180000 +0100 |
3 | 3 | @@ -52,6 +52,7 @@ |
4 | 4 | class wxSingleInstanceChecker; |
5 | 5 | class wxHtmlHelpController; |
... | ... | |
19 | 19 | * Function SetLanguage |
20 | 20 | * sets the dictionary file name for internationalization. |
21 | 21 | diff -ru kicad.orig/include/wxBasePcbFrame.h kicad/include/wxBasePcbFrame.h |
22 | | +++ kicad/include/wxBasePcbFrame.h 2012-01-11 11:06:46.974797876 +0100 |
23 | | @@ -520,6 +520,7 @@ |
| 22 | --- kicad.orig/include/wxBasePcbFrame.h 2012-01-11 12:02:53.707180000 +0100 |
| 23 | @@ -517,6 +517,7 @@ |
24 | 24 | |
25 | 25 | bool ExportToDxfFile( const wxString& aFullFileName, |
26 | 26 | int aLayer, |
27 | | + bool aPlotOriginIsAuxAxis, |
28 | | GRTraceMode aTraceMode ); |
| 27 | + bool aPlotOriginIsAuxAxis, |
| 28 | EDA_DRAW_MODE_T aTraceMode ); |
29 | 29 | |
30 | | void Plot_Layer( PLOTTER* plotter, |
| 30 | void Plot_Layer( PLOTTER* plotter, |
31 | 31 | diff -ru kicad.orig/include/wxEeschemaStruct.h kicad/include/wxEeschemaStruct.h |
32 | | +++ kicad/include/wxEeschemaStruct.h 2012-01-04 02:04:17.560214904 +0100 |
33 | | @@ -585,6 +585,8 @@ |
| 32 | --- kicad.orig/include/wxEeschemaStruct.h 2012-01-11 12:02:53.707180000 +0100 |
| 33 | @@ -593,6 +593,8 @@ |
34 | 34 | void SVG_Print( wxCommandEvent& event ); |
35 | 35 | |
36 | 36 | // Plot functions: |
... | ... | |
42 | 42 | void ToPlot_HPGL( wxCommandEvent& event ); |
43 | 43 | void ToPlot_DXF( wxCommandEvent& event ); |
44 | 44 | diff -ru kicad.orig/include/wxPcbStruct.h kicad/include/wxPcbStruct.h |
45 | | +++ kicad/include/wxPcbStruct.h 2012-01-10 17:49:51.848114042 +0100 |
| 45 | --- kicad.orig/include/wxPcbStruct.h 2012-01-11 12:02:53.707180000 +0100 |
46 | 46 | @@ -75,6 +75,7 @@ |
47 | 47 | class PCB_EDIT_FRAME : public PCB_BASE_FRAME |
48 | 48 | { |
... | ... | |
53 | 53 | void updateTraceWidthSelectBox(); |
54 | 54 | void updateViaSizeSelectBox(); |
55 | 55 | diff -ru kicad.orig/common/confirm.cpp kicad/common/confirm.cpp |
56 | | +++ kicad/common/confirm.cpp 2012-01-04 00:59:04.412020890 +0100 |
| 56 | --- kicad.orig/common/confirm.cpp 2012-01-11 12:02:53.707180000 +0100 |
57 | 57 | @@ -9,11 +9,18 @@ |
58 | 58 | #include "wx/html/htmlwin.h" |
59 | 59 | #include "html_messagebox.h" |
... | ... | |
101 | 101 | dlg->AddHTML_Text( text ); |
102 | 102 | dlg->ShowModal(); |
103 | 103 | diff -ru kicad.orig/common/edaappl.cpp kicad/common/edaappl.cpp |
104 | | +++ kicad/common/edaappl.cpp 2012-01-04 00:58:45.466217466 +0100 |
| 104 | --- kicad.orig/common/edaappl.cpp 2012-01-11 12:02:53.707180000 +0100 |
105 | 105 | @@ -306,6 +306,7 @@ |
106 | 106 | wxString EnvLang; |
107 | 107 | |
kicad-patches/cmdline-eeschema.patch |
1 | 1 | diff -ru kicad.orig/eeschema/CMakeLists.txt kicad/eeschema/CMakeLists.txt |
2 | | +++ kicad/eeschema/CMakeLists.txt 2012-01-04 00:55:02.169540766 +0100 |
| 2 | --- kicad.orig/eeschema/CMakeLists.txt 2012-01-11 12:02:53.707180000 +0100 |
3 | 3 | @@ -78,6 +78,7 @@ |
4 | 4 | eeredraw.cpp |
5 | 5 | eeschema.cpp |
... | ... | |
10 | 10 | events_called_functions_for_edit.cpp |
11 | 11 | files-io.cpp |
12 | 12 | diff -ru kicad.orig/eeschema/dialogs/dialog_build_BOM.h kicad/eeschema/dialogs/dialog_build_BOM.h |
13 | | +++ kicad/eeschema/dialogs/dialog_build_BOM.h 2012-01-04 01:04:19.481832883 +0100 |
| 13 | --- kicad.orig/eeschema/dialogs/dialog_build_BOM.h 2012-01-11 12:02:53.707180000 +0100 |
14 | 14 | @@ -17,6 +17,7 @@ |
15 | 15 | |
16 | 16 | class DIALOG_BUILD_BOM : public DIALOG_BUILD_BOM_BASE |
... | ... | |
21 | 21 | EDA_DRAW_FRAME* m_Parent; |
22 | 22 | wxConfig* m_Config; |
23 | 23 | diff -ru kicad.orig/eeschema/dialogs/dialog_erc.cpp kicad/eeschema/dialogs/dialog_erc.cpp |
24 | | +++ kicad/eeschema/dialogs/dialog_erc.cpp 2012-01-10 23:17:59.518338725 +0100 |
| 24 | --- kicad.orig/eeschema/dialogs/dialog_erc.cpp 2012-01-11 12:02:53.707180000 +0100 |
25 | 25 | @@ -574,10 +574,10 @@ |
26 | 26 | _( "Electronic rule check file (.erc)|*.erc" ), |
27 | 27 | wxFD_SAVE | wxFD_OVERWRITE_PROMPT ); |
... | ... | |
37 | 37 | Close( true ); |
38 | 38 | ExecuteFile( this, wxGetApp().GetEditorName(), QuoteFullPath( fn ) ); |
39 | 39 | diff -ru kicad.orig/eeschema/dialogs/dialog_erc.h kicad/eeschema/dialogs/dialog_erc.h |
40 | | +++ kicad/eeschema/dialogs/dialog_erc.h 2012-01-04 01:03:05.419550431 +0100 |
| 40 | --- kicad.orig/eeschema/dialogs/dialog_erc.h 2012-01-11 12:02:53.707180000 +0100 |
41 | 41 | @@ -29,6 +29,7 @@ |
42 | 42 | |
43 | 43 | class DIALOG_ERC : public DIALOG_ERC_BASE |
... | ... | |
48 | 48 | |
49 | 49 | private: |
50 | 50 | diff -ru kicad.orig/eeschema/dialogs/dialog_plot_schematic_DXF.cpp kicad/eeschema/dialogs/dialog_plot_schematic_DXF.cpp |
51 | | +++ kicad/eeschema/dialogs/dialog_plot_schematic_DXF.cpp 2012-01-04 02:05:43.305394193 +0100 |
| 51 | --- kicad.orig/eeschema/dialogs/dialog_plot_schematic_DXF.cpp 2012-01-11 12:02:53.707180000 +0100 |
52 | 52 | @@ -42,6 +42,7 @@ |
53 | 53 | |
54 | 54 | class DIALOG_PLOT_SCHEMATIC_DXF : public DIALOG_PLOT_SCHEMATIC_DXF_BASE |
... | ... | |
75 | 75 | { |
76 | 76 | DIALOG_PLOT_SCHEMATIC_DXF DXF_frame( this ); |
77 | 77 | diff -ru kicad.orig/eeschema/dialogs/dialog_plot_schematic_PS.cpp kicad/eeschema/dialogs/dialog_plot_schematic_PS.cpp |
78 | | +++ kicad/eeschema/dialogs/dialog_plot_schematic_PS.cpp 2012-01-04 01:20:57.415188192 +0100 |
| 78 | --- kicad.orig/eeschema/dialogs/dialog_plot_schematic_PS.cpp 2012-01-11 12:02:53.707180000 +0100 |
79 | 79 | @@ -48,6 +48,7 @@ |
80 | 80 | |
81 | 81 | class DIALOG_PLOT_SCHEMATIC_PS : public DIALOG_PLOT_SCHEMATIC_PS_BASE |
... | ... | |
85 | 85 | private: |
86 | 86 | SCH_EDIT_FRAME* m_Parent; |
87 | 87 | |
88 | | @@ -79,6 +80,15 @@ |
| 88 | @@ -80,6 +81,15 @@ |
89 | 89 | bool DIALOG_PLOT_SCHEMATIC_PS::m_plot_Sheet_Ref = true; |
90 | 90 | |
91 | 91 | |
... | ... | |
102 | 102 | { |
103 | 103 | DIALOG_PLOT_SCHEMATIC_PS dlg( this ); |
104 | 104 | diff -ru kicad.orig/eeschema/dialogs/dialog_SVG_print.cpp kicad/eeschema/dialogs/dialog_SVG_print.cpp |
105 | | +++ kicad/eeschema/dialogs/dialog_SVG_print.cpp 2012-01-10 23:20:13.888411068 +0100 |
| 105 | --- kicad.orig/eeschema/dialogs/dialog_SVG_print.cpp 2012-01-11 12:02:53.707180000 +0100 |
106 | 106 | @@ -53,6 +53,13 @@ |
107 | 107 | static bool s_Print_Frame_Ref = true; |
108 | 108 | static int s_PlotBlackAndWhite = 0; |
... | ... | |
119 | 119 | /*! |
120 | 120 | * DIALOG_SVG_PRINT functions |
121 | 121 | diff -ru kicad.orig/eeschema/dialogs/dialog_SVG_print.h kicad/eeschema/dialogs/dialog_SVG_print.h |
122 | | +++ kicad/eeschema/dialogs/dialog_SVG_print.h 2012-01-04 01:03:17.627432139 +0100 |
123 | | @@ -12,6 +12,7 @@ |
124 | | |
125 | | class DIALOG_SVG_PRINT : public DIALOG_SVG_PRINT_base |
126 | | { |
127 | | +friend void CmdLinePrintSVGDoc( EDA_DRAW_FRAME* frame, bool aPrintAll, bool aPrint_Sheet_Ref, bool aPrintBlackAndWhite ); |
128 | | private: |
129 | | EDA_DRAW_FRAME* m_Parent; |
130 | | wxConfig* m_Config; |
| 122 | --- kicad.orig/eeschema/dialogs/dialog_SVG_print.h 2012-01-11 12:02:53.707180000 +0100 |
| 123 | @@ -11,6 +11,8 @@ |
| 124 | |
| 125 | class DIALOG_SVG_PRINT : public DIALOG_SVG_PRINT_base |
| 126 | { |
| 127 | +friend void CmdLinePrintSVGDoc( EDA_DRAW_FRAME* frame, bool aPrintAll, bool aPrint_Sheet_Ref, bool aPrintBlackAndWhite ); |
| 128 | + private: |
| 129 | private: |
| 130 | EDA_DRAW_FRAME* m_Parent; |
| 131 | wxConfig* m_Config; |
131 | 132 | diff -ru kicad.orig/eeschema/eeschema.cpp kicad/eeschema/eeschema.cpp |
132 | | +++ kicad/eeschema/eeschema.cpp 2012-01-04 01:05:55.083907033 +0100 |
| 133 | --- kicad.orig/eeschema/eeschema.cpp 2012-01-11 12:02:53.707180000 +0100 |
133 | 134 | @@ -41,6 +41,7 @@ |
134 | 135 | #include "hotkeys.h" |
135 | 136 | #include "dialogs/dialog_color_config.h" |
kicad-patches/cmdline-new.patch |
1 | 1 | --- /dev/null 2012-01-06 01:10:09.493787641 +0100 |
2 | | +++ kicad/eeschema/eeschema_cmdline.h 2012-01-04 00:55:43.066114352 +0100 |
3 | 2 | @@ -0,0 +1,14 @@ |
4 | 3 | +///////////////////////////////////////////////////////////////////////////// |
5 | 4 | +// Name: eeschema_cmdline.h |
... | ... | |
16 | 16 | + |
17 | 17 | +extern EESCHEMA_CMDLINE g_EESchemaCmdLine; |
18 | 18 | --- /dev/null 2012-01-06 01:10:09.493787641 +0100 |
19 | | +++ kicad/eeschema/eeschema_cmdline.cpp 2012-01-10 16:33:11.565978324 +0100 |
20 | 19 | @@ -0,0 +1,233 @@ |
21 | 20 | +///////////////////////////////////////////////////////////////////////////// |
22 | 21 | +// Name: eeschema_cmdline.cpp |
... | ... | |
252 | 252 | + return true; |
253 | 253 | +} |
254 | 254 | --- /dev/null 2012-01-06 01:10:09.493787641 +0100 |
255 | | +++ kicad/pcbnew/pcbnew_cmdline.h 2012-01-04 00:59:32.003734758 +0100 |
256 | 255 | @@ -0,0 +1,7 @@ |
257 | 256 | +///////////////////////////////////////////////////////////////////////////// |
258 | 257 | +// Name: pcbnew_cmdline.h |
... | ... | |
262 | 262 | + |
263 | 263 | +bool Pcbnew_CmdLine(); |
264 | 264 | --- /dev/null 2012-01-06 01:10:09.493787641 +0100 |
265 | | +++ kicad/pcbnew/pcbnew_cmdline.cpp 2012-01-11 11:18:27.603953821 +0100 |
266 | 265 | @@ -0,0 +1,526 @@ |
267 | 266 | +///////////////////////////////////////////////////////////////////////////// |
268 | 267 | +// Name: pcbnew_cmdline.cpp |
kicad-patches/cmdline-pcbnew.patch |
1 | 1 | diff -ru kicad.orig/pcbnew/build_BOM_from_board.cpp kicad/pcbnew/build_BOM_from_board.cpp |
2 | | +++ kicad/pcbnew/build_BOM_from_board.cpp 2012-01-10 23:23:32.338040998 +0100 |
| 2 | --- kicad.orig/pcbnew/build_BOM_from_board.cpp 2012-01-11 12:02:53.707180000 +0100 |
3 | 3 | @@ -67,6 +67,7 @@ |
4 | 4 | fn = GetScreen()->GetFileName(); |
5 | 5 | fn.SetExt( CsvFileExtension ); |
... | ... | |
18 | 18 | FichBom = wxFopen( fn.GetFullPath(), wxT( "wt" ) ); |
19 | 19 | |
20 | 20 | diff -ru kicad.orig/pcbnew/CMakeLists.txt kicad/pcbnew/CMakeLists.txt |
21 | | +++ kicad/pcbnew/CMakeLists.txt 2012-01-05 01:53:42.424887775 +0100 |
| 21 | --- kicad.orig/pcbnew/CMakeLists.txt 2012-01-11 12:02:53.707180000 +0100 |
22 | 22 | @@ -150,6 +150,7 @@ |
23 | 23 | onrightclick.cpp |
24 | 24 | pcb_plot_params.cpp |
... | ... | |
29 | 29 | pcbplot.cpp |
30 | 30 | plotgerb.cpp |
31 | 31 | diff -ru kicad.orig/pcbnew/dialogs/dialog_gendrill.h kicad/pcbnew/dialogs/dialog_gendrill.h |
32 | | +++ kicad/pcbnew/dialogs/dialog_gendrill.h 2012-01-05 18:07:15.289119747 +0100 |
| 32 | --- kicad.orig/pcbnew/dialogs/dialog_gendrill.h 2012-01-11 12:02:53.707180000 +0100 |
33 | 33 | @@ -33,6 +33,7 @@ |
34 | 34 | |
35 | 35 | class DIALOG_GENDRILL : public DIALOG_GENDRILL_BASE |
... | ... | |
40 | 40 | static int m_UnitDrillIsInch; |
41 | 41 | static int m_ZerosFormat; |
42 | 42 | diff -ru kicad.orig/pcbnew/dialogs/dialog_SVG_print.h kicad/pcbnew/dialogs/dialog_SVG_print.h |
43 | | +++ kicad/pcbnew/dialogs/dialog_SVG_print.h 2012-01-10 19:40:48.754648647 +0100 |
| 43 | --- kicad.orig/pcbnew/dialogs/dialog_SVG_print.h 2012-01-11 12:02:53.707180000 +0100 |
44 | 44 | @@ -13,6 +13,7 @@ |
45 | 45 | |
46 | 46 | class DIALOG_SVG_PRINT : public DIALOG_SVG_PRINT_base |
... | ... | |
51 | 51 | PCB_BASE_FRAME* m_Parent; |
52 | 52 | wxConfig* m_Config; |
53 | 53 | diff -ru kicad.orig/pcbnew/drc_stuff.h kicad/pcbnew/drc_stuff.h |
54 | | +++ kicad/pcbnew/drc_stuff.h 2012-01-05 18:08:06.047781508 +0100 |
| 54 | --- kicad.orig/pcbnew/drc_stuff.h 2012-01-11 12:02:53.707180000 +0100 |
55 | 55 | @@ -146,6 +146,7 @@ |
56 | 56 | */ |
57 | 57 | class DRC |
... | ... | |
62 | 62 | |
63 | 63 | private: |
64 | 64 | diff -ru kicad.orig/pcbnew/gendrill.cpp kicad/pcbnew/gendrill.cpp |
65 | | +++ kicad/pcbnew/gendrill.cpp 2012-01-08 17:26:28.429837548 +0100 |
| 65 | --- kicad.orig/pcbnew/gendrill.cpp 2012-01-11 12:02:53.707180000 +0100 |
66 | 66 | @@ -159,8 +159,13 @@ |
67 | 67 | fn.GetFullName(), wxGetTranslation( DrillFileWildcard ), |
68 | 68 | wxFD_SAVE | wxFD_CHANGE_DIR ); |
... | ... | |
107 | 107 | FILE* report_dest = wxFopen( dlg.GetPath(), wxT( "w" ) ); |
108 | 108 | |
109 | 109 | diff -ru kicad.orig/pcbnew/gen_modules_placefile.cpp kicad/pcbnew/gen_modules_placefile.cpp |
110 | | +++ kicad/pcbnew/gen_modules_placefile.cpp 2012-01-08 18:32:33.547634589 +0100 |
| 110 | --- kicad.orig/pcbnew/gen_modules_placefile.cpp 2012-01-11 12:02:53.707180000 +0100 |
111 | 111 | @@ -138,10 +138,10 @@ |
112 | 112 | return; |
113 | 113 | } |
... | ... | |
131 | 131 | |
132 | 132 | exit: // the only safe way out of here, no returns please. |
133 | 133 | diff -ru kicad.orig/pcbnew/pcbnew.cpp kicad/pcbnew/pcbnew.cpp |
134 | | +++ kicad/pcbnew/pcbnew.cpp 2012-01-05 21:49:03.036099308 +0100 |
| 134 | --- kicad.orig/pcbnew/pcbnew.cpp 2012-01-11 12:02:53.707180000 +0100 |
135 | 135 | @@ -44,6 +44,7 @@ |
136 | 136 | #include "pcbnew.h" |
137 | 137 | #include "protos.h" |
... | ... | |
152 | 152 | |
153 | 153 | if( m_Checker && m_Checker->IsAnotherRunning() ) |
154 | 154 | diff -ru kicad.orig/pcbnew/pcbnew.h kicad/pcbnew/pcbnew.h |
155 | | +++ kicad/pcbnew/pcbnew.h 2012-01-05 21:47:10.422652798 +0100 |
| 155 | --- kicad.orig/pcbnew/pcbnew.h 2012-01-11 12:02:53.707180000 +0100 |
156 | 156 | @@ -41,6 +41,7 @@ |
157 | 157 | #define FORCE_SKETCH ( IS_DRAGGED | IN_EDIT ) |
158 | 158 | |
... | ... | |
163 | 163 | extern bool g_AutoDeleteOldTrack; |
164 | 164 | extern bool g_Drag_Pistes_On; |
165 | 165 | diff -ru kicad.orig/pcbnew/pcbplot.cpp kicad/pcbnew/pcbplot.cpp |
166 | | +++ kicad/pcbnew/pcbplot.cpp 2012-01-11 11:10:58.453057344 +0100 |
167 | | @@ -774,6 +774,7 @@ |
| 166 | --- kicad.orig/pcbnew/pcbplot.cpp 2012-01-11 12:02:53.707180000 +0100 |
| 167 | @@ -820,6 +820,7 @@ |
168 | 168 | |
169 | 169 | case PLOT_FORMAT_DXF: |
170 | 170 | success = m_Parent->ExportToDxfFile( fn.GetFullPath(), layer, |
... | ... | |
174 | 174 | break; |
175 | 175 | } |
176 | 176 | diff -ru kicad.orig/pcbnew/plotdxf.cpp kicad/pcbnew/plotdxf.cpp |
177 | | +++ kicad/pcbnew/plotdxf.cpp 2012-01-11 11:07:41.473420495 +0100 |
| 177 | --- kicad.orig/pcbnew/plotdxf.cpp 2012-01-11 12:02:53.707180000 +0100 |
178 | 178 | @@ -16,7 +16,7 @@ |
179 | 179 | |
180 | 180 | |
181 | 181 | bool PCB_BASE_FRAME::ExportToDxfFile( const wxString& aFullFileName, int aLayer, |
182 | | - GRTraceMode aTraceMode ) |
183 | | + bool aPlotOriginIsAuxAxis, GRTraceMode aTraceMode ) |
| 182 | - EDA_DRAW_MODE_T aTraceMode ) |
| 183 | + bool aPlotOriginIsAuxAxis, EDA_DRAW_MODE_T aTraceMode ) |
184 | 184 | { |
185 | | Ki_PageDescr* currentsheet = GetScreen()->m_CurrentSheetDesc; |
| 185 | LOCALE_IO toggle; |
186 | 186 | |
187 | | @@ -27,11 +27,23 @@ |
| 187 | @@ -27,9 +27,21 @@ |
188 | 188 | return false; |
189 | 189 | } |
190 | 190 | |
... | ... | |
193 | 193 | + |
194 | 194 | + if( aPlotOriginIsAuxAxis ) |
195 | 195 | + { |
196 | | + offset = m_originAxisPosition; |
| 196 | + offset = GetOriginAxisPosition(); |
197 | 197 | + } |
198 | 198 | + else |
199 | 199 | + { |
... | ... | |
201 | 201 | + offset.y = 0; |
202 | 202 | + } |
203 | 203 | + |
204 | | SetLocaleTo_C_standard(); |
205 | | |
206 | 204 | DXF_PLOTTER* plotter = new DXF_PLOTTER(); |
207 | | plotter->set_paper_size( currentsheet ); |
| 205 | plotter->SetPageSettings( GetPageSettings() ); |
208 | 206 | - plotter->set_viewport( wxPoint( 0, 0 ), 1, 0 ); |
209 | 207 | + plotter->set_viewport( offset, 1, 0 ); |
210 | 208 | plotter->set_creator( wxT( "PCBNEW-DXF" ) ); |
211 | 209 | plotter->set_filename( aFullFileName ); |
212 | 210 | plotter->start_plot( output_file ); |
213 | 211 | diff -ru kicad.orig/pcbnew/xchgmod.cpp kicad/pcbnew/xchgmod.cpp |
214 | | +++ kicad/pcbnew/xchgmod.cpp 2012-01-05 21:47:50.531456715 +0100 |
215 | | @@ -599,6 +599,7 @@ |
| 212 | --- kicad.orig/pcbnew/xchgmod.cpp 2012-01-11 12:02:53.707180000 +0100 |
| 213 | @@ -601,6 +601,7 @@ |
216 | 214 | fn.SetExt( NetCmpExtBuffer ); |
217 | 215 | wildcard = _( "Component files (." ) + NetCmpExtBuffer + wxT( ")|*." ) + NetCmpExtBuffer; |
218 | 216 | |
... | ... | |
221 | 219 | wxFileDialog dlg( this, _( "Save Component Files" ), wxGetCwd(), |
222 | 220 | fn.GetFullName(), wildcard, |
223 | 221 | wxFD_SAVE | wxFD_OVERWRITE_PROMPT ); |
224 | | @@ -607,6 +608,7 @@ |
| 222 | @@ -609,6 +610,7 @@ |
225 | 223 | return; |
226 | 224 | |
227 | 225 | fn = dlg.GetPath(); |