vdr 2.6.7
|
Public Member Functions | |
cCursesOsd (int Left, int Top) | |
virtual | ~cCursesOsd () |
virtual void | SaveRegion (int x1, int y1, int x2, int y2) |
virtual void | RestoreRegion (void) |
virtual void | DrawText (int x, int y, const char *s, tColor ColorFg, tColor ColorBg, const cFont *Font, int Width=0, int Height=0, int Alignment=taDefault) |
virtual void | DrawRectangle (int x1, int y1, int x2, int y2, tColor Color) |
virtual void | Flush (void) |
![]() | |
virtual | ~cOsd () |
bool | IsTrueColor (void) const |
int | Left (void) |
int | Top (void) |
int | Width (void) |
int | Height (void) |
void | SetAntiAliasGranularity (uint FixedColors, uint BlendColors) |
virtual const cSize & | MaxPixmapSize (void) const |
virtual cPixmap * | CreatePixmap (int Layer, const cRect &ViewPort, const cRect &DrawPort=cRect::Null) |
virtual void | DestroyPixmap (cPixmap *Pixmap) |
virtual void | DrawImage (const cPoint &Point, const cImage &Image) |
virtual void | DrawImage (const cPoint &Point, int ImageHandle) |
virtual void | DrawScaledImage (const cPoint &Point, const cImage &Image, double FactorX, double FactorY, bool AntiAlias=false) |
virtual void | DrawScaledImage (const cPoint &Point, int ImageHandle, double FactorX, double FactorY, bool AntiAlias=false) |
virtual eOsdError | CanHandleAreas (const tArea *Areas, int NumAreas) |
virtual eOsdError | SetAreas (const tArea *Areas, int NumAreas) |
virtual eOsdError | SetPalette (const cPalette &Palette, int Area) |
virtual void | DrawPixel (int x, int y, tColor Color) |
virtual void | DrawBitmap (int x, int y, const cBitmap &Bitmap, tColor ColorFg=0, tColor ColorBg=0, bool ReplacePalette=false, bool Overlay=false) |
virtual void | DrawScaledBitmap (int x, int y, const cBitmap &Bitmap, double FactorX, double FactorY, bool AntiAlias=false) |
virtual void | DrawEllipse (int x1, int y1, int x2, int y2, tColor Color, int Quadrants=0) |
virtual void | DrawSlope (int x1, int y1, int x2, int y2, tColor Color, int Type) |
Private Member Functions | |
void | SetColor (int colorFg, int colorBg=clrBackground) |
Private Attributes | |
WINDOW * | savedRegion |
cVector< int > | colorPairs |
Additional Inherited Members | |
![]() | |
static int | OsdLeft (void) |
static int | OsdTop (void) |
static int | OsdWidth (void) |
static int | OsdHeight (void) |
static void | SetOsdPosition (int Left, int Top, int Width, int Height) |
static int | IsOpen (void) |
![]() | |
cOsd (int Left, int Top, uint Level) | |
bool | Active (void) |
virtual void | SetActive (bool On) |
cPixmap * | AddPixmap (cPixmap *Pixmap) |
cPixmap * | RenderPixmaps (void) |
cBitmap * | GetBitmap (int Area) |
Definition at line 60 of file skincurses.c.
cCursesOsd::cCursesOsd | ( | int | Left, |
int | Top ) |
Definition at line 75 of file skincurses.c.
References savedRegion, ScOsdHeight, and ScOsdWidth.
|
virtual |
Definition at line 92 of file skincurses.c.
References Flush().
|
virtual |
Draws a filled rectangle defined by the upper left (x1, y1) and lower right (x2, y2) corners with the given Color.
Reimplemented from cOsd.
Definition at line 167 of file skincurses.c.
References SetColor().
Referenced by DrawText().
|
virtual |
Draws the given string at coordinates (x, y) with the given foreground and background color and font.
If Width and Height are given, the text will be drawn into a rectangle with the given size and the given Alignment (default is top-left). If ColorBg is clrTransparent, no background pixels will be drawn, which allows drawing "transparent" text.
Reimplemented from cOsd.
Definition at line 130 of file skincurses.c.
References DrawRectangle(), Font, cOsd::Height(), cCursesFont::Height(), ScOsdWidth, SetColor(), taBottom, taLeft, taRight, taTop, cOsd::Width(), and cCursesFont::Width().
|
virtual |
Actually commits all data to the OSD hardware.
Flush() should return as soon as possible. For a true color OSD using the default implementation with in memory pixmaps, the Flush() function should basically do something like this:
LOCK_PIXMAPS; while (cPixmapMemory *pm = dynamic_cast<cPixmapMemory *>(RenderPixmaps())) { int w = pm->ViewPort().Width(); int h = pm->ViewPort().Height(); int d = w * sizeof(tColor); MyOsdDrawPixmap(Left() + pm->ViewPort().X(), Top() + pm->ViewPort().Y(), pm->Data(), w, h, h * d); DestroyPixmap(pm); }
If a plugin uses a derived cPixmap implementation, it needs to use that type instead of cPixmapMemory.
Reimplemented from cOsd.
Definition at line 182 of file skincurses.c.
Referenced by ~cCursesOsd().
|
virtual |
Restores the region previously saved by a call to SaveRegion().
If SaveRegion() has not been called before, nothing will happen.
Reimplemented from cOsd.
Definition at line 121 of file skincurses.c.
References savedRegion.
|
virtual |
Saves the region defined by the given coordinates for later restoration through RestoreRegion().
Only one saved region can be active at any given time.
Reimplemented from cOsd.
Definition at line 110 of file skincurses.c.
References savedRegion.
|
private |
Definition at line 98 of file skincurses.c.
References cVector< T >::Append(), colorPairs, cVector< T >::IndexOf(), and cVector< T >::Size().
Referenced by DrawRectangle(), and DrawText().
|
private |
Definition at line 63 of file skincurses.c.
Referenced by SetColor().
|
private |
Definition at line 62 of file skincurses.c.
Referenced by cCursesOsd(), RestoreRegion(), and SaveRegion().