X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=src%2Fdlgezplot.h;fp=src%2Fdlgezplot.h;h=0ab8806cd0743c9e3a7af3dcc4c43d8bf7d5ade1;hp=efba49a38ab1a2b7a4b5e17433a5a4cda709e74d;hb=ed576a069b0ba9de2e9153707012eba620ac606e;hpb=7f8f356151b0c8db0dbbf1c1896cc22630d6c774 diff --git a/src/dlgezplot.h b/src/dlgezplot.h index efba49a..0ab8806 100644 --- a/src/dlgezplot.h +++ b/src/dlgezplot.h @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2001 Kevin Rosenberg ** -** $Id: dlgezplot.h,v 1.1 2001/01/12 16:41:56 kevin Exp $ +** $Id: dlgezplot.h,v 1.2 2001/01/12 21:53:27 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -37,20 +37,17 @@ #include "wx/dcmemory.h" class wxButton; -class wxStaticText; -class Projections; class SGP; class SGPDriver; class EZPlot; -class EZPlotDialog : public wxDialog -{ -private: - DECLARE_DYNAMIC_CLASS(EZPlotDialog) - DECLARE_EVENT_TABLE() - EZPlot* m_pEZPlot; - wxWindow *m_parentTop; // parent top level window (may be NULL) +class EZPlotControl : public wxPanel +{ +private: + DECLARE_DYNAMIC_CLASS (EZPlotControl) + DECLARE_EVENT_TABLE () + EZPlot* m_pEZPlot; int m_iClientX; // size of client window int m_iClientY; @@ -58,19 +55,38 @@ private: SGP* m_pSGP; wxDC* m_pDC; +public: + EZPlotControl (wxWindow *parent, wxWindowID id = -1, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = wxSTATIC_BORDER, + const wxValidator& validator = wxDefaultValidator, + const wxString& name = "EZPlotCtrl"); + + virtual ~EZPlotControl(); + + virtual wxSize GetBestSize() const; + + EZPlot* getEZPlot() + { return m_pEZPlot; } + + void OnPaint(wxPaintEvent& event); +}; + + +class EZPlotDialog : public wxDialog +{ +private: + wxWindow *m_parentTop; // parent top level window (may be NULL) + EZPlotControl* m_pEZPlotCtrl; + public: EZPlotDialog (wxWindow *parent = NULL); ~EZPlotDialog(); - /* Perform projection on view number - return true if ABORT button has not been pressed - */ EZPlot* getEZPlot () - { return m_pEZPlot; } - - void OnClose(wxCloseEvent& event); - void OnPaint(wxPaintEvent& event); + { if (m_pEZPlotCtrl) return m_pEZPlotCtrl->getEZPlot(); else return NULL; } }; #endif