aboutsummaryrefslogtreecommitdiff
path: root/test/dw_image_background.cc
diff options
context:
space:
mode:
authorSebastian Geerken <devnull@localhost>2013-10-04 16:00:53 +0200
committerSebastian Geerken <devnull@localhost>2013-10-04 16:00:53 +0200
commit8ef6e194f3c77f6f21ffbe9fea5a5961b502541e (patch)
tree119c7f156eeaabbb62e181ad76fa77c7ef5dcbc5 /test/dw_image_background.cc
parente8f04035f76c6a31f42ec3465902854569905c1d (diff)
Background image for view(port)s; no updates yet.
Diffstat (limited to 'test/dw_image_background.cc')
-rw-r--r--test/dw_image_background.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/test/dw_image_background.cc b/test/dw_image_background.cc
index 3b692901..391d6fe1 100644
--- a/test/dw_image_background.cc
+++ b/test/dw_image_background.cc
@@ -115,6 +115,12 @@ int main(int argc, char **argv)
FltkViewport *viewport = new FltkViewport (0, 0, 200, 300);
layout->attachView (viewport);
+ image1 = StyleImage::create ();
+ image1->connectDeletion (&isdr);
+ layout->setBgImage (image1, BACKGROUND_REPEAT_Y,
+ BACKGROUND_ATTACHMENT_SCROLL, createPerLength (0.5),
+ createAbsLength (30));
+
StyleAttrs styleAttrs;
styleAttrs.initValues ();
styleAttrs.margin.setVal (5);
@@ -129,13 +135,7 @@ int main(int argc, char **argv)
styleAttrs.font = style::Font::create (layout, &fontAttrs);
styleAttrs.color = Color::create (layout, 0x000000);
- styleAttrs.backgroundColor = Color::create (layout, 0xffffff);
-
- image1 = styleAttrs.backgroundImage = StyleImage::create ();
- image1->connectDeletion (&isdr);
- styleAttrs.backgroundRepeat = BACKGROUND_REPEAT_Y;
- styleAttrs.backgroundPositionX = createPerLength (0.5);
- styleAttrs.backgroundPositionY = createAbsLength (30);
+ //styleAttrs.backgroundColor = Color::create (layout, 0xffffff);
Style *widgetStyle = Style::create (&styleAttrs);