1 // File: GLViewer_Selector2d.h
2 // Created: November, 2004
4 // Copyright (C) CEA 2004
6 /****************************************************************************
7 ** Class: GLViewer_Selector2d
8 ** Descr: OpenGL Selector 2D
10 ** Created: UI team, 20.09.02
11 *****************************************************************************/
12 #ifndef GLVIEWER_SELECTOR2D_H
13 #define GLVIEWER_SELECTOR2D_H
20 #include "GLViewer_Selector.h"
22 #include <Quantity_NameOfColor.hxx>
24 class GLViewer_Viewer2d;
25 class GLViewer_Context;
27 class GLVIEWER_EXPORT GLViewer_Selector2d : public GLViewer_Selector
32 GLViewer_Selector2d( GLViewer_Viewer2d*, GLViewer_Context* );
33 ~GLViewer_Selector2d();
36 void setContext( GLViewer_Context* glc ) { myGLContext = glc; }
37 GLViewer_Context* getContext() const { return myGLContext; }
39 void setHilightColor( Quantity_NameOfColor );
40 void setSelectColor( Quantity_NameOfColor );
42 void detect( int, int );
43 void select( bool append = false );
44 void select( const QRect&, bool append = false );
46 int numSelected() const;
48 void checkSelection( int, bool, int );
51 GLViewer_Context* myGLContext;