summaryrefslogtreecommitdiff
path: root/src/drivers/OpenGL
diff options
context:
space:
mode:
authorMatthias Melcher <github@matthiasm.com>2022-12-30 19:14:36 +0100
committerGitHub <noreply@github.com>2022-12-30 19:14:36 +0100
commit44c874b731f9f58c2f50c3c6076371058cbe26e3 (patch)
tree2386dfcc700c41a1109fc78b96875c11056abcc9 /src/drivers/OpenGL
parentf58a93a159105336136ce6e54ab7fc161e4fa15a (diff)
Use `FL_OVERRIDE` for all overridden virtual methods (#611)
FL_OVERRIDE is defined as `override` for C++11 and higher FL_OVERRIDE is defined as `override` for VisualC 2015 and newer Don't interfere with Fl_Widget::override()
Diffstat (limited to 'src/drivers/OpenGL')
-rw-r--r--src/drivers/OpenGL/Fl_OpenGL_Graphics_Driver.H110
1 files changed, 55 insertions, 55 deletions
diff --git a/src/drivers/OpenGL/Fl_OpenGL_Graphics_Driver.H b/src/drivers/OpenGL/Fl_OpenGL_Graphics_Driver.H
index a2dcf099b..bd3173aad 100644
--- a/src/drivers/OpenGL/Fl_OpenGL_Graphics_Driver.H
+++ b/src/drivers/OpenGL/Fl_OpenGL_Graphics_Driver.H
@@ -39,64 +39,64 @@ public:
line_width_(1.0f),
line_stipple_(FL_SOLID) { }
// --- line and polygon drawing with integer coordinates
- void point(int x, int y);
- void rect(int x, int y, int w, int h);
- void rectf(int x, int y, int w, int h);
- void line(int x, int y, int x1, int y1);
- void line(int x, int y, int x1, int y1, int x2, int y2);
- void xyline(int x, int y, int x1);
- void xyline(int x, int y, int x1, int y2);
- void xyline(int x, int y, int x1, int y2, int x3);
- void yxline(int x, int y, int y1);
- void yxline(int x, int y, int y1, int x2);
- void yxline(int x, int y, int y1, int x2, int y3);
- void loop(int x0, int y0, int x1, int y1, int x2, int y2);
- void loop(int x0, int y0, int x1, int y1, int x2, int y2, int x3, int y3);
- void polygon(int x0, int y0, int x1, int y1, int x2, int y2);
- void polygon(int x0, int y0, int x1, int y1, int x2, int y2, int x3, int y3);
- void focus_rect(int x, int y, int w, int h);
+ void point(int x, int y) FL_OVERRIDE;
+ void rect(int x, int y, int w, int h) FL_OVERRIDE;
+ void rectf(int x, int y, int w, int h) FL_OVERRIDE;
+ void line(int x, int y, int x1, int y1) FL_OVERRIDE;
+ void line(int x, int y, int x1, int y1, int x2, int y2) FL_OVERRIDE;
+ void xyline(int x, int y, int x1) FL_OVERRIDE;
+ void xyline(int x, int y, int x1, int y2) FL_OVERRIDE;
+ void xyline(int x, int y, int x1, int y2, int x3) FL_OVERRIDE;
+ void yxline(int x, int y, int y1) FL_OVERRIDE;
+ void yxline(int x, int y, int y1, int x2) FL_OVERRIDE;
+ void yxline(int x, int y, int y1, int x2, int y3) FL_OVERRIDE;
+ void loop(int x0, int y0, int x1, int y1, int x2, int y2) FL_OVERRIDE;
+ void loop(int x0, int y0, int x1, int y1, int x2, int y2, int x3, int y3) FL_OVERRIDE;
+ void polygon(int x0, int y0, int x1, int y1, int x2, int y2) FL_OVERRIDE;
+ void polygon(int x0, int y0, int x1, int y1, int x2, int y2, int x3, int y3) FL_OVERRIDE;
+ void focus_rect(int x, int y, int w, int h) FL_OVERRIDE;
// ---- clipping
- void push_clip(int x, int y, int w, int h);
- void pop_clip();
- void push_no_clip();
- Fl_Region clip_region();
- void clip_region(Fl_Region r);
- void restore_clip();
- int not_clipped(int x, int y, int w, int h);
- int clip_box(int x, int y, int w, int h, int &X, int &Y, int &W, int &H);
+ void push_clip(int x, int y, int w, int h) FL_OVERRIDE;
+ void pop_clip() FL_OVERRIDE;
+ void push_no_clip() FL_OVERRIDE;
+ Fl_Region clip_region() FL_OVERRIDE;
+ void clip_region(Fl_Region r) FL_OVERRIDE;
+ void restore_clip() FL_OVERRIDE;
+ int not_clipped(int x, int y, int w, int h) FL_OVERRIDE;
+ int clip_box(int x, int y, int w, int h, int &X, int &Y, int &W, int &H) FL_OVERRIDE;
// ---- matrix transformed drawing
- void transformed_vertex(double xf, double yf);
- void begin_points();
- void end_points();
- void begin_line();
- void end_line();
- void begin_loop();
- void end_loop();
- void begin_polygon();
- void end_polygon();
- void begin_complex_polygon();
- void gap();
- void end_complex_polygon();
- void fixloop();
- void circle(double x, double y, double r);
- void arc(int x, int y, int w, int h, double a1, double a2);
- void arc(double x, double y, double r, double start, double end);
- void pie(int x, int y, int w, int h, double a1, double a2);
- void line_style(int style, int width=0, char* dashes=0);
- void color(Fl_Color c);
- Fl_Color color() { return color_; }
- void color(uchar r, uchar g, uchar b);
+ void transformed_vertex(double xf, double yf) FL_OVERRIDE;
+ void begin_points() FL_OVERRIDE;
+ void end_points() FL_OVERRIDE;
+ void begin_line() FL_OVERRIDE;
+ void end_line() FL_OVERRIDE;
+ void begin_loop() FL_OVERRIDE;
+ void end_loop() FL_OVERRIDE;
+ void begin_polygon() FL_OVERRIDE;
+ void end_polygon() FL_OVERRIDE;
+ void begin_complex_polygon() FL_OVERRIDE;
+ void gap() FL_OVERRIDE;
+ void end_complex_polygon() FL_OVERRIDE;
+ void fixloop() FL_OVERRIDE;
+ void circle(double x, double y, double r) FL_OVERRIDE;
+ void arc(int x, int y, int w, int h, double a1, double a2) FL_OVERRIDE;
+ void arc(double x, double y, double r, double start, double end) FL_OVERRIDE;
+ void pie(int x, int y, int w, int h, double a1, double a2) FL_OVERRIDE;
+ void line_style(int style, int width=0, char* dashes=0) FL_OVERRIDE;
+ void color(Fl_Color c) FL_OVERRIDE;
+ Fl_Color color() FL_OVERRIDE { return color_; }
+ void color(uchar r, uchar g, uchar b) FL_OVERRIDE;
// --- implementation is in Fl_OpenGL_Graphics_Driver_font.cxx
- void font(Fl_Font face, Fl_Fontsize fsize);
- Fl_Font font();
- void draw(const char *str, int n, int x, int y);
- void draw(const char *str, int n, float x, float y);
- void draw(int angle, const char *str, int n, int x, int y);
- double width(const char *str, int n);
- double width(unsigned int c);
- void text_extents(const char*, int n, int& dx, int& dy, int& w, int& h);
- int height();
- int descent();
+ void font(Fl_Font face, Fl_Fontsize fsize) FL_OVERRIDE;
+ Fl_Font font() FL_OVERRIDE;
+ void draw(const char *str, int n, int x, int y) FL_OVERRIDE;
+ void draw(const char *str, int n, float x, float y) FL_OVERRIDE;
+ void draw(int angle, const char *str, int n, int x, int y) FL_OVERRIDE;
+ double width(const char *str, int n) FL_OVERRIDE;
+ double width(unsigned int c) FL_OVERRIDE;
+ void text_extents(const char*, int n, int& dx, int& dy, int& w, int& h) FL_OVERRIDE;
+ int height() FL_OVERRIDE;
+ int descent() FL_OVERRIDE;
};
#endif // FL_OPENGL_GRAPHICS_DRIVER_H