From 406af09ade55553e2b064506c3ba3c89bd965d73 Mon Sep 17 00:00:00 2001 From: Benji Dial Date: Thu, 4 Mar 2021 19:11:42 -0500 Subject: start of a c++ widget toolkit, c++ runtime --- src/user/include/cxx/raleigh/widget.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 src/user/include/cxx/raleigh/widget.h (limited to 'src/user/include/cxx/raleigh/widget.h') diff --git a/src/user/include/cxx/raleigh/widget.h b/src/user/include/cxx/raleigh/widget.h new file mode 100644 index 0000000..1839333 --- /dev/null +++ b/src/user/include/cxx/raleigh/widget.h @@ -0,0 +1,27 @@ +#ifndef RALEIGH_WIDGET_H +#define RALEIGH_WIDGET_H + +namespace raleigh { + class widget; +} + +#include +#include +#include + +namespace raleigh { + class widget { + public: + coord size; + + //set by window class (or parent widget) + window *w; + coord window_offset; + + //called by window class (or parent widget) + virtual void notify_window_change() = 0; + virtual void paint(_pixel_t *pixbuf, uint32_t pitch) = 0; + }; +} + +#endif \ No newline at end of file -- cgit v1.2.3