** This is part of the CTSim program
** Copyright (c) 1983-2001 Kevin Rosenberg
**
-** $Id: graph3dview.cpp,v 1.24 2001/09/24 11:34:06 kevin Exp $
+** $Id: graph3dview.cpp,v 1.25 2002/06/02 19:01:58 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
{
m_pFrame = CreateChildFrame(doc, this);
- int width, height;
- m_pFrame->GetClientSize (&width, &height);
m_pFrame->SetTitle("Graph3dFileView");
m_pCanvas = CreateCanvas (m_pFrame);
InitGL();
- int x, y; // X requires a forced resize
- m_pFrame->GetSize(&x, &y);
- m_pFrame->SetSize(-1, -1, x, y);
m_pFrame->SetFocus();
m_pFrame->Show(true);
Activate(true);
int width, height;
parent->GetClientSize (&width, &height);
- pCanvas = new Graph3dFileCanvas (this, parent, wxPoint(0, 0), wxSize(200, 200), 0);
+ pCanvas = new Graph3dFileCanvas (this, parent, wxPoint(0, 0), wxSize(width,height), 0);
pCanvas->SetBackgroundColour(*wxWHITE);
pCanvas->Clear();
m_pView->OnDraw(& dc);
}
+
+wxSize
+Graph3dFileCanvas::GetBestSize() const
+{
+ return wxSize (400,400);
+}
+
void
Graph3dFileCanvas::OnSize (wxSizeEvent& event)
{