X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/3bad22d5566624804a73b3791980bab2d84c8266..54bd4123728628a6f77bad2584b70d1353a91666:/lib/gdi/grc.h diff --git a/lib/gdi/grc.h b/lib/gdi/grc.h index 47931792..5eb81314 100644 --- a/lib/gdi/grc.h +++ b/lib/gdi/grc.h @@ -11,7 +11,7 @@ #include #include -#include +#include #include #include #include @@ -29,7 +29,7 @@ struct gOpcode renderPara, setFont, - fill, clear, + fill, fillRegion, clear, blit, setPalette, @@ -55,10 +55,15 @@ struct gOpcode eRect area; } *fill; + struct pfillRegion + { + gRegion region; + } *fillRegion; + struct prenderText { eRect area; - eString text; + std::string text; int flags; } *renderText; @@ -117,7 +122,7 @@ struct gOpcode }; /* gRC is the singleton which controls the fifo and dispatches commands */ -class gRC: public virtual iObject +class gRC: public iObject { DECLARE_REF; private: @@ -169,10 +174,21 @@ public: void setForegroundColor(const gColor &color); void setFont(gFont *font); + /* flags only THESE: */ + enum + { + // todo, make mask. you cannot align both right AND center AND block ;) + RT_HALIGN_RIGHT = 1, + RT_HALIGN_CENTER = 2, + RT_HALIGN_BLOCK = 4, + RT_VALIGN_CENTER = 8 + }; void renderText(const eRect &position, const std::string &string, int flags=0); + void renderPara(eTextPara *para, ePoint offset=ePoint(0, 0)); void fill(const eRect &area); + void fill(const gRegion &area); void clear();