diff options
author | lordjaxom <lordjaxom> | 2004-07-14 16:49:10 +0000 |
---|---|---|
committer | lordjaxom <lordjaxom> | 2004-07-14 16:49:10 +0000 |
commit | 5071a1754f3db0adcf477ecf8e5b2a818d1935bd (patch) | |
tree | 210c39c7871d0192ec5aad51096ea39fa47ccd9e /scroller.h | |
parent | f2a4ea2dc8c0d915e0f2af6f4ec1a228e1e94453 (diff) | |
download | vdr-plugin-text2skin-5071a1754f3db0adcf477ecf8e5b2a818d1935bd.tar.gz vdr-plugin-text2skin-5071a1754f3db0adcf477ecf8e5b2a818d1935bd.tar.bz2 |
- fixed display of scrollbar if there is no text presentv0.0.8
- fixed animation delay if update takes longer than the delay
- using backgrounds also in 8-bit fullscreen mode to improve performance
- implemented screen layer to improve performance
- corrected offsets and tab widths in main menu
- implemented parameters "current", "mark" and "selected" to choose mark colors
in replay display (defaults to the old values)
- implemented color value "None" to be able to unset a color
Diffstat (limited to 'scroller.h')
-rw-r--r-- | scroller.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/scroller.h b/scroller.h new file mode 100644 index 0000000..9b338d9 --- /dev/null +++ b/scroller.h @@ -0,0 +1,47 @@ +/* + * $Id: scroller.h,v 1.1 2004/07/05 17:55:34 lordjaxom Exp $ + */ + +#ifndef VDR_TEXT2SKIN_SCROLLER_H +#define VDR_TEXT2SKIN_SCROLLER_H + +#include "common.h" +#include <vdr/font.h> + +class cText2SkinScreen; + +class cText2SkinScroller { +private: + cText2SkinScreen *mScreen; + const cFont *mFont; + int mLeft; + int mTop; + int mWidth; + int mHeight; + int mOffset; + int mShown; + tColor mColorFg; + tColor mColorBg; + cTextWrapper mWrapper; + +public: + cText2SkinScroller(void); + cText2SkinScroller(cText2SkinScreen *Screen, int Left, int Top, int Width, int Height, const char *Text, const cFont *Font, tColor ColorFg, tColor ColorBg); + + void Set(cText2SkinScreen *Screen, int Left, int Top, int Width, int Height, const char *Text, const cFont *Font, tColor ColorFg, tColor ColorBg); + void DrawText(void); + void Reset(void); + int Left(void) { return mLeft; } + int Top(void) { return mTop; } + int Width(void) { return mWidth; } + int Height(void) { return mHeight; } + int Total(void) { return mWrapper.Lines(); } + int Offset(void) { return mOffset; } + int Shown(void) { return mShown; } + bool CanScroll(void) { return CanScrollUp() || CanScrollDown(); } + bool CanScrollUp(void) { return mOffset > 0; } + bool CanScrollDown(void) { return mOffset + mShown < Total(); } + void Scroll(bool Up, bool Page); +}; + +#endif // VDR_TEXT2SKIN_SCROLLER_H |