bWidgets
Core widget toolkit designed for Blender
bwPaintEngine.h
Go to the documentation of this file.
1#pragma once
2
3#include <string>
4
5#include "bwRectangle.h"
6
7namespace bWidgets {
8
9enum class TextAlignment;
10
32 public:
33 virtual ~bwPaintEngine() = default;
34
45 virtual void setupViewport(const bwRectanglePixel& rect, const class bwColor& clear_color) = 0;
46
47 virtual void enableMask(const bwRectanglePixel& rect) = 0;
48
55 virtual void drawPolygon(const class bwPainter& painter, const class bwPolygon& polygon) = 0;
62 virtual void drawText(const class bwPainter& painter,
63 const std::string& text,
64 const bwRectanglePixel& rect,
65 const TextAlignment alignment) = 0;
72 virtual void drawIcon(const class bwPainter& painter,
73 const class bwIconInterface& icon_interface,
74 const bwRectanglePixel& rect) = 0;
75};
76
77} // namespace bWidgets
Definition: bwColor.h:5
Interface to reference icons from within bWidgets.
Definition: bwIconInterface.h:22
Main interface to implement any drawing of geometry or text.
Definition: bwPaintEngine.h:31
virtual void setupViewport(const bwRectanglePixel &rect, const class bwColor &clear_color)=0
virtual void drawText(const class bwPainter &painter, const std::string &text, const bwRectanglePixel &rect, const TextAlignment alignment)=0
virtual ~bwPaintEngine()=default
virtual void drawPolygon(const class bwPainter &painter, const class bwPolygon &polygon)=0
virtual void enableMask(const bwRectanglePixel &rect)=0
virtual void drawIcon(const class bwPainter &painter, const class bwIconInterface &icon_interface, const bwRectanglePixel &rect)=0
Definition: bwPainter.h:40
Definition: bwPolygon.h:11
Definition: bwContext.h:3
TextAlignment
Definition: bwPainter.h:27