source: git/src/mainfrm.h @ 3d43425

RELEASE/1.0RELEASE/1.2debug-cidebug-ci-sanitisersfaster-cavernloglog-selectstereostereo-2025walls-datawalls-data-hanging-as-warningwarn-only-for-hanging-survey
Last change on this file since 3d43425 was 6120efa, checked in by Olly Betts <olly@…>, 22 years ago

Fixes for compiling with MSVC.

git-svn-id: file:///home/survex-svn/survex/trunk@2468 4b37db11-9a0c-4f06-9ece-9ab7cdaee568

  • Property mode set to 100644
File size: 17.5 KB
Line 
1//
2//  mainfrm.h
3//
4//  Main frame handling for Aven.
5//
6//  Copyright (C) 2000-2001, Mark R. Shinwell.
7//  Copyright (C) 2001-2003 Olly Betts
8//
9//  This program is free software; you can redistribute it and/or modify
10//  it under the terms of the GNU General Public License as published by
11//  the Free Software Foundation; either version 2 of the License, or
12//  (at your option) any later version.
13//
14//  This program is distributed in the hope that it will be useful,
15//  but WITHOUT ANY WARRANTY; without even the implied warranty of
16//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17//  GNU General Public License for more details.
18//
19//  You should have received a copy of the GNU General Public License
20//  along with this program; if not, write to the Free Software
21//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
22//
23
24#ifndef mainfrm_h
25#define mainfrm_h
26
27#include "wx.h"
28#include "wx/docview.h"
29#include "gfxcore.h"
30#include "message.h"
31#include "aventreectrl.h"
32#include "img.h"
33
34#include <list>
35#if 0 // if you turn this back on, reenable the check in configure.in too
36#ifdef HAVE_EXT_HASH_MAP
37#include <ext/hash_map>
38#elif defined HAVE_HASH_MAP
39#include <hash_map>
40#else
41#include <map>
42#define hash_map map
43#endif
44#endif
45
46using namespace std;
47
48#include <math.h>
49
50// This is for mingw32/Visual C++:
51#ifndef M_PI
52#define M_PI 3.14159265358979323846
53#endif
54
55extern const int NUM_DEPTH_COLOURS;
56
57enum {
58    menu_FILE_OPEN = 1000,
59    menu_FILE_OPEN_PRES,
60    menu_FILE_QUIT,
61    menu_ROTATION_START,
62    menu_ROTATION_STOP,
63    menu_ROTATION_TOGGLE,
64    menu_ROTATION_SPEED_UP,
65    menu_ROTATION_SLOW_DOWN,
66    menu_ROTATION_REVERSE,
67    menu_ROTATION_STEP_CCW,
68    menu_ROTATION_STEP_CW,
69    menu_ORIENT_MOVE_NORTH,
70    menu_ORIENT_MOVE_EAST,
71    menu_ORIENT_MOVE_SOUTH,
72    menu_ORIENT_MOVE_WEST,
73    menu_ORIENT_SHIFT_LEFT,
74    menu_ORIENT_SHIFT_RIGHT,
75    menu_ORIENT_SHIFT_UP,
76    menu_ORIENT_SHIFT_DOWN,
77    menu_ORIENT_PLAN,
78    menu_ORIENT_ELEVATION,
79    menu_ORIENT_HIGHER_VP,
80    menu_ORIENT_LOWER_VP,
81    menu_ORIENT_ZOOM_IN,
82    menu_ORIENT_ZOOM_OUT,
83    menu_ORIENT_DEFAULTS,
84    menu_VIEW_SHOW_LEGS,
85    menu_VIEW_SHOW_CROSSES,
86    menu_VIEW_SHOW_NAMES,
87    menu_VIEW_SHOW_SURFACE,
88    menu_VIEW_SURFACE_DEPTH,
89    menu_VIEW_SURFACE_DASHED,
90    menu_VIEW_SHOW_OVERLAPPING_NAMES,
91    menu_VIEW_SHOW_ENTRANCES,
92    menu_VIEW_SHOW_FIXED_PTS,
93    menu_VIEW_SHOW_EXPORTED_PTS,
94    menu_VIEW_INDICATORS,
95    menu_VIEW_COMPASS,
96    menu_VIEW_CLINO,
97    menu_VIEW_DEPTH_BAR,
98    menu_VIEW_SCALE_BAR,
99    menu_VIEW_STATUS_BAR,
100    menu_VIEW_GRID,
101    menu_VIEW_SIDE_PANEL,
102    menu_VIEW_METRIC,
103    menu_VIEW_DEGREES,
104    menu_PRES_CREATE,
105    menu_PRES_GO,
106    menu_PRES_GO_BACK,
107    menu_PRES_RESTART,
108    menu_PRES_RECORD,
109    menu_PRES_FINISH,
110    menu_PRES_ERASE,
111    menu_PRES_ERASE_ALL,
112    menu_CTL_REVERSE,
113    menu_CTL_CANCEL_DIST_LINE,
114    menu_HELP_ABOUT,
115    button_FIND,
116    button_HIDE
117};
118
119class PointInfo {
120    friend class MainFrm;
121    Double x, y, z;
122    bool isLine; // false => move, true => draw line
123    bool isSurface;
124
125public:
126    Double GetX() const { return x; }
127    Double GetY() const { return y; }
128    Double GetZ() const { return z; }
129    bool IsLine() const { return isLine; }
130    bool IsSurface() const { return isSurface; }
131};
132
133#define LFLAG_SURFACE           img_SFLAG_SURFACE
134#define LFLAG_UNDERGROUND       img_SFLAG_UNDERGROUND
135#define LFLAG_EXPORTED          img_SFLAG_EXPORTED
136#define LFLAG_FIXED             img_SFLAG_FIXED
137#define LFLAG_ENTRANCE          0x100
138#define LFLAG_HIGHLIGHTED       0x200
139
140class LabelPlotCmp;
141
142class LabelInfo {
143    friend class MainFrm;
144    friend class GfxCore;
145    friend class LabelPlotCmp;
146    Double x, y, z;
147    wxString text;
148    int flags;
149    wxTreeItemId tree_id;
150
151public:
152    Double GetX() const { return x; }
153    Double GetY() const { return y; }
154    Double GetZ() const { return z; }
155
156    wxString GetText() const { return text; }
157
158    bool IsEntrance() const { return (flags & LFLAG_ENTRANCE != 0); }
159    bool IsFixedPt() const { return (flags & LFLAG_FIXED != 0); }
160    bool IsExportedPt() const { return (flags & LFLAG_EXPORTED != 0); }
161    bool IsUnderground() const { return (flags & LFLAG_UNDERGROUND != 0); }
162    bool IsSurface() const { return (flags & LFLAG_SURFACE != 0); }
163    bool IsHighLighted() const { return (flags & LFLAG_HIGHLIGHTED != 0); }
164};
165
166class MainFrm : public wxFrame {
167    wxFileHistory m_history;
168public: // FIXME: just public for workaround bodge in
169        // wxSplitterWindow::OnSplitterDClick
170    int m_SashPosition;
171private:
172    list<PointInfo*>* m_Points;
173    list<LabelInfo*> m_Labels;
174    Double m_XExt;
175    Double m_YExt;
176    Double m_ZExt;
177    Double m_XMin;
178    Double m_YMin;
179    Double m_ZMin;
180    int m_NumLegs;
181    int m_NumPoints;
182    int m_NumCrosses;
183    int m_NumExtraLegs;
184    GfxCore* m_Gfx;
185    wxPen* m_Pens;
186    wxBrush* m_Brushes;
187    int m_NumEntrances;
188    int m_NumFixedPts;
189    int m_NumExportedPts;
190    wxSplitterWindow* m_Splitter;
191    wxPanel* m_Panel;
192    AvenTreeCtrl* m_Tree;
193    wxTreeItemId m_TreeRoot;
194    wxTextCtrl* m_FindBox;
195    wxStaticText* m_MousePtr;
196    wxStaticText* m_Coords;
197    wxStaticText* m_StnCoords;
198    wxStaticText* m_StnName;
199    wxStaticText* m_StnAlt;
200    wxStaticText* m_Dist1;
201    wxStaticText* m_Dist2;
202    wxStaticText* m_Dist3;
203    wxStaticText* m_Found;
204    wxCheckBox* m_RegexpCheckBox;
205    wxString m_File;
206    int separator; // character separating survey levels (often '.')
207
208    struct {
209        Double x, y, z;
210    } m_Offsets;
211
212    void SetTreeItemColour(LabelInfo* label);
213    void FillTree();
214    void ClearPointLists();
215    bool LoadData(const wxString& file, wxString prefix = "");
216    void SortIntoDepthBands(list<PointInfo*>& points);
217    void IntersectLineWithPlane(Double x0, Double y0, Double z0,
218                                Double x1, Double y1, Double z1,
219                                Double z, Double& x, Double& y);
220    Double GetDepthBoundaryBetweenBands(int a, int b);
221    int GetDepthColour(Double z);
222    void CentreDataset(Double xmin, Double ymin, Double zmin);
223
224    wxString GetTabMsg(int key) {
225        wxString x(msg(key)); x.Replace("##", "\t"); x.Replace("@", "&"); return x;
226    }
227
228    void InitialisePensAndBrushes();
229    void CreateMenuBar();
230    void CreateToolBar();
231    void CreateSidePanel();
232
233public:
234    MainFrm(const wxString& title, const wxPoint& pos, const wxSize& size);
235    ~MainFrm();
236
237    void OnMRUFile(wxCommandEvent& event);
238    void OpenFile(const wxString& file, wxString survey = "", bool delay = false);
239    void OnFileOpenTerrainUpdate(wxUpdateUIEvent& event);
240
241    void OnFind(wxCommandEvent& event);
242    void OnHide(wxCommandEvent& event);
243
244    void OnOpen(wxCommandEvent& event);
245    void OnFileOpenTerrain(wxCommandEvent& event);
246    void OnQuit(wxCommandEvent& event);
247
248    void OnAbout(wxCommandEvent& event);
249    void OnClose(wxCloseEvent&);
250
251    void OnSetFocus(wxFocusEvent &) { if (m_Gfx) m_Gfx->SetFocus(); }
252
253    // temporary bodges until event handling problem is sorted out:
254    void OnDefaultsUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnDefaultsUpdate(event); }
255    void OnPlanUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnPlanUpdate(event); }
256    void OnElevationUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnElevationUpdate(event); }
257    void OnDisplayOverlappingNamesUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnDisplayOverlappingNamesUpdate(event); }
258    void OnShowCrossesUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowCrossesUpdate(event); }
259    void OnShowEntrancesUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowEntrancesUpdate(event); }
260    void OnShowFixedPtsUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowFixedPtsUpdate(event); }
261    void OnShowExportedPtsUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowExportedPtsUpdate(event); }
262    void OnShowStationNamesUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowStationNamesUpdate(event); }
263    void OnShowSurveyLegsUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowSurveyLegsUpdate(event); }
264    void OnShowSurfaceUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowSurfaceUpdate(event); }
265    void OnShowSurfaceDepthUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowSurfaceDepthUpdate(event); }
266    void OnShowSurfaceDashedUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShowSurfaceDashedUpdate(event); }
267    void OnMoveEastUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnMoveEastUpdate(event); }
268    void OnMoveNorthUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnMoveNorthUpdate(event); }
269    void OnMoveSouthUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnMoveSouthUpdate(event); }
270    void OnMoveWestUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnMoveWestUpdate(event); }
271    void OnStartRotationUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnStartRotationUpdate(event); }
272    void OnToggleRotationUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnToggleRotationUpdate(event); }
273    void OnStopRotationUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnStopRotationUpdate(event); }
274    void OnReverseControlsUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnReverseControlsUpdate(event); }
275    void OnSlowDownUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnSlowDownUpdate(event); }
276    void OnSpeedUpUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnSpeedUpUpdate(event); }
277    void OnStepOnceAnticlockwiseUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnStepOnceAnticlockwiseUpdate(event); }
278    void OnStepOnceClockwiseUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnStepOnceClockwiseUpdate(event); }
279    void OnHigherViewpointUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnHigherViewpointUpdate(event); }
280    void OnLowerViewpointUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnLowerViewpointUpdate(event); }
281    void OnShiftDisplayDownUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShiftDisplayDownUpdate(event); }
282    void OnShiftDisplayLeftUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShiftDisplayLeftUpdate(event); }
283    void OnShiftDisplayRightUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShiftDisplayRightUpdate(event); }
284    void OnShiftDisplayUpUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnShiftDisplayUpUpdate(event); }
285    void OnZoomInUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnZoomInUpdate(event); }
286    void OnZoomOutUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnZoomOutUpdate(event); }
287    void OnToggleScalebarUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnToggleScalebarUpdate(event); }
288    void OnToggleDepthbarUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnToggleDepthbarUpdate(event); }
289    void OnViewCompassUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnViewCompassUpdate(event); }
290    void OnViewGridUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnViewGridUpdate(event); }
291    void OnViewClinoUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnViewClinoUpdate(event); }
292    void OnReverseDirectionOfRotationUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnReverseDirectionOfRotationUpdate(event); }
293    void OnCancelDistLineUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnCancelDistLineUpdate(event); }
294    void OnIndicatorsUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnIndicatorsUpdate(event); }
295
296    void OnDefaults(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnDefaults(); }
297    void OnPlan(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnPlan(); }
298    void OnElevation(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnElevation(); }
299    void OnDisplayOverlappingNames(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnDisplayOverlappingNames(); }
300    void OnShowCrosses(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowCrosses(); }
301    void OnShowEntrances(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowEntrances(); }
302    void OnShowFixedPts(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowFixedPts(); }
303    void OnShowExportedPts(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowExportedPts(); }
304    void OnShowStationNames(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowStationNames(); }
305    void OnShowSurveyLegs(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowSurveyLegs(); }
306    void OnShowSurface(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowSurface(); }
307    void OnShowSurfaceDepth(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowSurfaceDepth(); }
308    void OnShowSurfaceDashed(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShowSurfaceDashed(); }
309    void OnMoveEast(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnMoveEast(); }
310    void OnMoveNorth(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnMoveNorth(); }
311    void OnMoveSouth(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnMoveSouth(); }
312    void OnMoveWest(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnMoveWest(); }
313    void OnStartRotation(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnStartRotation(); }
314    void OnToggleRotation(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnToggleRotation(); }
315    void OnStopRotation(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnStopRotation(); }
316    void OnReverseControls(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnReverseControls(); }
317    void OnSlowDown(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnSlowDown(); }
318    void OnSpeedUp(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnSpeedUp(); }
319    void OnStepOnceAnticlockwise(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnStepOnceAnticlockwise(); }
320    void OnStepOnceClockwise(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnStepOnceClockwise(); }
321    void OnHigherViewpoint(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnHigherViewpoint(); }
322    void OnLowerViewpoint(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnLowerViewpoint(); }
323    void OnShiftDisplayDown(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShiftDisplayDown(); }
324    void OnShiftDisplayLeft(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShiftDisplayLeft(); }
325    void OnShiftDisplayRight(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShiftDisplayRight(); }
326    void OnShiftDisplayUp(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnShiftDisplayUp(); }
327    void OnZoomIn(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnZoomIn(); }
328    void OnZoomOut(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnZoomOut(); }
329    void OnToggleScalebar(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnToggleScalebar(); }
330    void OnToggleDepthbar(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnToggleDepthbar(); }
331    void OnViewCompass(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnViewCompass(); }
332    void OnViewClino(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnViewClino(); }
333    void OnViewGrid(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnViewGrid(); }
334    void OnReverseDirectionOfRotation(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnReverseDirectionOfRotation(); }
335    void OnCancelDistLine(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnCancelDistLine(); }
336    // end of horrible bodges
337
338    void OnToggleMetric(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnToggleMetric(); }
339    void OnToggleDegrees(wxCommandEvent&) { if (m_Gfx) m_Gfx->OnToggleDegrees(); }
340
341    void OnToggleMetricUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnToggleMetricUpdate(event); }
342    void OnToggleDegreesUpdate(wxUpdateUIEvent& event) { if (m_Gfx) m_Gfx->OnToggleDegreesUpdate(event); }
343
344    void OnViewSidePanelUpdate(wxUpdateUIEvent& event);
345    void OnViewSidePanel(wxCommandEvent& event);
346    void ToggleSidePanel();
347
348    Double GetXExtent() const { return m_XExt; }
349    Double GetYExtent() const { return m_YExt; }
350    Double GetZExtent() const { return m_ZExt; }
351    Double GetXMin() const { return m_XMin; }
352    Double GetYMin() const { return m_YMin; }
353    Double GetYMax() const { return m_YMin + m_YExt; }
354    Double GetZMin() const { return m_ZMin; }
355    Double GetZMax() const { return m_ZMin + m_ZExt; }
356
357    int GetNumLegs() const { return m_NumLegs; }
358    int GetNumPoints() const { return m_NumPoints; }
359    int GetNumCrosses() const { return m_NumCrosses; }
360
361    int GetNumDepthBands() const { return NUM_DEPTH_COLOURS; }
362
363    wxPen GetPen(int band) const {
364        assert(band >= 0 && band < NUM_DEPTH_COLOURS);
365        return m_Pens[band];
366    }
367
368    wxBrush GetBrush(int band) const {
369        assert(band >= 0 && band < NUM_DEPTH_COLOURS);
370        return m_Brushes[band];
371    }
372
373    void GetColour(int band, Double& r, Double& g, Double& b) const;
374
375    wxPen GetSurfacePen() const { return m_Pens[NUM_DEPTH_COLOURS]; }
376
377    void SelectTreeItem(LabelInfo* label);
378    void ClearTreeSelection();
379
380    int GetNumFixedPts() const { return m_NumFixedPts; }
381    int GetNumExportedPts() const { return m_NumExportedPts; }
382    int GetNumEntrances() const { return m_NumEntrances; }
383
384    void ClearCoords();
385    void SetCoords(Double x, Double y);
386    void SetAltitude(Double z);
387
388    Double GetXOffset() const { return m_Offsets.x; }
389    Double GetYOffset() const { return m_Offsets.y; }
390    Double GetZOffset() const { return m_Offsets.z; }
391
392    void SetMouseOverStation(LabelInfo* label);
393
394    list<PointInfo*>::iterator GetPointsNC(int band) const {
395        assert(band >= 0 && band < NUM_DEPTH_COLOURS);
396        return m_Points[band].begin();
397    }
398
399    list<PointInfo*>::iterator GetPointsEndNC(int band) const {
400        assert(band >= 0 && band < NUM_DEPTH_COLOURS);
401        return m_Points[band].end();
402    }
403
404    list<PointInfo*>::const_iterator GetPoints(int band) const {
405        assert(band >= 0 && band < NUM_DEPTH_COLOURS);
406        return m_Points[band].begin();
407    }
408
409    list<PointInfo*>::const_iterator GetPointsEnd(int band) const {
410        assert(band >= 0 && band < NUM_DEPTH_COLOURS);
411        return m_Points[band].end();
412    }
413
414    list<LabelInfo*>::const_iterator GetLabels() const {
415        return m_Labels.begin();
416    }
417
418    list<LabelInfo*>::const_iterator GetLabelsEnd() const {
419        return m_Labels.end();
420    }
421
422    list<LabelInfo*>::const_reverse_iterator GetRevLabels() const {
423        return m_Labels.rbegin();
424    }
425
426    list<LabelInfo*>::const_reverse_iterator GetRevLabelsEnd() const {
427        return m_Labels.rend();
428    }
429
430    void ShowInfo(const LabelInfo *label);
431    void DisplayTreeInfo(const wxTreeItemData* data);
432    void TreeItemSelected(wxTreeItemData* data);
433
434private:
435    DECLARE_EVENT_TABLE()
436};
437
438#endif
Note: See TracBrowser for help on using the repository browser.