From d0fca301c35ddd1e0091b31e36547143ecbf7076 Mon Sep 17 00:00:00 2001 From: Bjørn Lindeijer Date: Thu, 30 Dec 2004 14:58:43 +0000 Subject: Marker area of vertical scrollbar now skinned. Graphics seem lacking for other parts. --- src/gui/scrollarea.cpp | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ src/gui/scrollarea.h | 10 ++++++++++ 2 files changed, 60 insertions(+) (limited to 'src') diff --git a/src/gui/scrollarea.cpp b/src/gui/scrollarea.cpp index 30460efb..f994ea52 100644 --- a/src/gui/scrollarea.cpp +++ b/src/gui/scrollarea.cpp @@ -106,3 +106,53 @@ void ScrollArea::drawBorder(gcn::Graphics *graphics) draw_skinned_rect(gui_bitmap, &gui_skin.textbox.bg, x, y, w, h); } + +void ScrollArea::drawUpButton(gcn::Graphics *graphics) +{ + gcn::ScrollArea::drawUpButton(graphics); +} + +void ScrollArea::drawDownButton(gcn::Graphics *graphics) +{ + gcn::ScrollArea::drawDownButton(graphics); +} + +void ScrollArea::drawLeftButton(gcn::Graphics *graphics) +{ + gcn::ScrollArea::drawLeftButton(graphics); +} + +void ScrollArea::drawRightButton(gcn::Graphics *graphics) +{ + gcn::ScrollArea::drawRightButton(graphics); +} + +void ScrollArea::drawVBar(gcn::Graphics *graphics) +{ + int x, y; + gcn::Rectangle dim = getVerticalBarDimension(); + getAbsolutePosition(x, y); + + draw_skinned_rect(gui_bitmap, &gui_skin.listbox.bg, + x + dim.x, y + dim.y, dim.width, dim.height); +} + +void ScrollArea::drawHBar(gcn::Graphics *graphics) +{ + gcn::ScrollArea::drawHBar(graphics); +} + +void ScrollArea::drawVMarker(gcn::Graphics *graphics) +{ + int x, y; + gcn::Rectangle dim = getVerticalMarkerDimension(); + getAbsolutePosition(x, y); + + draw_skinned_rect(gui_bitmap, &gui_skin.listbox.vscroll, + x + dim.x, y + dim.y, dim.width, dim.height); +} + +void ScrollArea::drawHMarker(gcn::Graphics *graphics) +{ + gcn::ScrollArea::drawHMarker(graphics); +} diff --git a/src/gui/scrollarea.h b/src/gui/scrollarea.h index 63c8a122..c5b8c94d 100644 --- a/src/gui/scrollarea.h +++ b/src/gui/scrollarea.h @@ -53,6 +53,16 @@ class ScrollArea : public gcn::ScrollArea { * Draws the background and border of the scroll area. */ void drawBorder(gcn::Graphics *graphics); + + protected: + void drawUpButton(gcn::Graphics *graphics); + void drawDownButton(gcn::Graphics *graphics); + void drawLeftButton(gcn::Graphics *graphics); + void drawRightButton(gcn::Graphics *graphics); + void drawVBar(gcn::Graphics *graphics); + void drawHBar(gcn::Graphics *graphics); + void drawVMarker(gcn::Graphics *graphics); + void drawHMarker(gcn::Graphics *graphics); }; #endif -- cgit v1.2.3-70-g09d2