set paper orientation into wxPrintData when possible

This commit is contained in:
Dick Hollenbeck 2012-01-17 09:34:05 -06:00
parent 5cf2d4fabb
commit b142b9defe
3 changed files with 12 additions and 7 deletions

View File

@ -59,7 +59,7 @@ private:
void OnPageSetup( wxCommandEvent& event );
void OnPrintPreview( wxCommandEvent& event );
void OnPrintButtonClick( wxCommandEvent& event );
void OnScaleSelectionClick( wxCommandEvent& event );
void OnScaleSelectionClick( wxCommandEvent& event );
void OnButtonCancelClick( wxCommandEvent& event ) { Close(); }
void SetPrintParameters( );
@ -95,12 +95,14 @@ void GERBVIEW_FRAME::ToPrinter( wxCommandEvent& event )
DisplayError( this, _( "Error Init Printer info" ) );
}
g_PrintData->SetQuality( wxPRINT_QUALITY_HIGH ); // Default resolution = HIGHT;
g_PrintData->SetOrientation( DEFAULT_ORIENTATION_PAPER );
}
g_PrintData->SetOrientation( GetPageSettings().IsPortrait() ? wxPORTRAIT : wxLANDSCAPE );
DIALOG_PRINT_USING_PRINTER* frame = new DIALOG_PRINT_USING_PRINTER( this );
frame->ShowModal(); frame->Destroy();
frame->ShowModal();
frame->Destroy();
}

View File

@ -70,12 +70,14 @@ void FOOTPRINT_EDIT_FRAME::ToPrinter( wxCommandEvent& event )
DisplayError( this, _( "Error Init Printer info" ) );
}
s_PrintData->SetQuality( wxPRINT_QUALITY_HIGH ); // Default resolution = HIGHT;
s_PrintData->SetOrientation( DEFAULT_ORIENTATION_PAPER );
}
s_PrintData->SetOrientation( GetPageSettings().IsPortrait() ? wxPORTRAIT : wxLANDSCAPE );
DIALOG_PRINT_FOR_MODEDIT* frame = new DIALOG_PRINT_FOR_MODEDIT( this );
frame->ShowModal(); frame->Destroy();
frame->ShowModal();
frame->Destroy();
}
/*************************************************************************************/

View File

@ -64,7 +64,7 @@ private:
void OnPageSetup( wxCommandEvent& event );
void OnPrintPreview( wxCommandEvent& event );
void OnPrintButtonClick( wxCommandEvent& event );
void OnScaleSelectionClick( wxCommandEvent& event );
void OnScaleSelectionClick( wxCommandEvent& event );
void OnButtonCancelClick( wxCommandEvent& event ) { Close(); }
void SetPrintParameters( );
@ -105,9 +105,10 @@ void PCB_EDIT_FRAME::ToPrinter( wxCommandEvent& event )
DisplayError( this, _( "Error Init Printer info" ) );
}
s_PrintData->SetQuality( wxPRINT_QUALITY_HIGH ); // Default resolution = HIGHT;
s_PrintData->SetOrientation( DEFAULT_ORIENTATION_PAPER );
}
s_PrintData->SetOrientation( GetPageSettings().IsPortrait() ? wxPORTRAIT : wxLANDSCAPE );
DIALOG_PRINT_USING_PRINTER* frame = new DIALOG_PRINT_USING_PRINTER( this );
frame->ShowModal(); frame->Destroy();