From ab864ba3666b39586c54467137a2b26d246ba430 Mon Sep 17 00:00:00 2001 From: Willem Jan Palenstijn Date: Sun, 20 Mar 2016 16:53:58 +0100 Subject: SCI32: Implement kScrollWindow These should be all the actually used subfunctions. Co-authored-by: Colin Snover --- engines/sci/graphics/text32.h | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'engines/sci/graphics/text32.h') diff --git a/engines/sci/graphics/text32.h b/engines/sci/graphics/text32.h index c28629871f..88cf149da7 100644 --- a/engines/sci/graphics/text32.h +++ b/engines/sci/graphics/text32.h @@ -30,9 +30,15 @@ namespace Sci { enum TextAlign { - kTextAlignLeft = 0, - kTextAlignCenter = 1, - kTextAlignRight = 2 + kTextAlignDefault = -1, + kTextAlignLeft = 0, + kTextAlignCenter = 1, + kTextAlignRight = 2 +}; + +enum ScrollDirection { + kScrollUp, + kScrollDown }; enum BitmapFlags { @@ -457,6 +463,13 @@ public: * `textRect` using the given font. */ int16 getTextCount(const Common::String &text, const uint index, const GuiResourceId fontId, const Common::Rect &textRect, const bool doScaling); + + /** + * Scroll up/down one line. `numLines` is the number of the lines in the + * textarea, and `textLine` contains the text to draw as the newly + * visible line. Originally FontMgr::DrawOneLine and FontMgr::UpOneLine. + */ + void scrollLine(const Common::String &textLine, int numLines, uint8 color, TextAlign align, GuiResourceId fontId, ScrollDirection dir); }; } // End of namespace Sci -- cgit v1.2.3