comparison libgui/graphics/GLCanvas.h @ 19870:815db217f6f4

provide autoscale option for Qt plotting (bug #44307) * Canvas.h, Canvas.cc (Canvas::autoAxes): New pure virtual function. (Canvas::canvasAutoAxes): New function. (autoscale_axes): New static function. (Canvas::canvasMouseDoubleClickEvent, Canvas::canvasMousePressEvent): Use it. * Figure.h, Figure.cc (Figure::createFigureToolBarAndMenuBar): Add autoscale button to window. (Figure::autoAxes): New function. * GLCanvas.h, GLCanvas.cc (GLCanvas::autoAxes): New function.
author John W. Eaton <jwe@octave.org>
date Fri, 27 Feb 2015 11:24:12 -0500
parents dfea01b3425f
children f0e61a67ad9f
comparison
equal deleted inserted replaced
19869:60fe3ef12bb0 19870:815db217f6f4
37 ~GLCanvas (void); 37 ~GLCanvas (void);
38 38
39 void draw (const graphics_handle& handle); 39 void draw (const graphics_handle& handle);
40 void toggleAxes (const graphics_handle& handle); 40 void toggleAxes (const graphics_handle& handle);
41 void toggleGrid (const graphics_handle& handle); 41 void toggleGrid (const graphics_handle& handle);
42 void autoAxes (const graphics_handle& handle);
42 void drawZoomBox (const QPoint& p1, const QPoint& p2); 43 void drawZoomBox (const QPoint& p1, const QPoint& p2);
43 void resize (int /* x */, int /* y */, 44 void resize (int /* x */, int /* y */,
44 int /* width */, int /* height */) { } 45 int /* width */, int /* height */) { }
45 graphics_object selectFromAxes (const graphics_object& ax, 46 graphics_object selectFromAxes (const graphics_object& ax,
46 const QPoint& pt); 47 const QPoint& pt);