2007-06-05 12:10:51 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// 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
|
2008-04-30 11:52:34 +00:00
|
|
|
#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
|
2007-06-05 12:10:51 +00:00
|
|
|
////@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
|
2008-04-30 11:52:34 +00:00
|
|
|
|
2007-06-05 12:10:51 +00:00
|
|
|
/// 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
|
2008-04-30 11:52:34 +00:00
|
|
|
|
2007-06-05 12:10:51 +00:00
|
|
|
/// 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);
|
2009-06-28 16:50:42 +00:00
|
|
|
void Plot_1_Page_HPGL(const wxString &FileName, SCH_SCREEN * screen,
|
|
|
|
Ki_PageDescr* paper, wxPoint& offset, double scale);
|
2007-06-05 12:10:51 +00:00
|
|
|
void Plot_Schematic_HPGL(int Select_PlotAll, int HPGL_SheetSize);
|
|
|
|
void ReturnSheetDims( BASE_SCREEN * screen, wxSize & SheetSize, wxPoint & SheetOffset);
|
2007-09-13 11:55:46 +00:00
|
|
|
void SetPageOffsetValue();
|
2007-06-05 12:10:51 +00:00
|
|
|
|
|
|
|
////@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;
|
2008-04-30 11:52:34 +00:00
|
|
|
wxButton* m_btClose;
|
2007-06-05 12:10:51 +00:00
|
|
|
wxTextCtrl* m_MsgBox;
|
|
|
|
////@end WinEDA_PlotHPGLFrame member variables
|
2007-05-06 16:03:28 +00:00
|
|
|
WinEDA_DrawFrame * m_Parent;
|
2007-06-05 12:10:51 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|
|
|
|
// _PLOTHPGL_H_
|