diff options
author | Tametomo <irarice@gmail.com> | 2009-04-11 09:36:44 -0600 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-04-15 19:59:41 +0200 |
commit | dcca13ea04fd7aa9b1539c1325cd0e465f9b545a (patch) | |
tree | e6426e8151dbfd7f2a41f840dd34549029b54f95 /src/gui | |
parent | 682738690e3293a8f28cb179a2903f8078311689 (diff) | |
download | mana-dcca13ea04fd7aa9b1539c1325cd0e465f9b545a.tar.gz mana-dcca13ea04fd7aa9b1539c1325cd0e465f9b545a.tar.bz2 mana-dcca13ea04fd7aa9b1539c1325cd0e465f9b545a.tar.xz mana-dcca13ea04fd7aa9b1539c1325cd0e465f9b545a.zip |
Fixed the width of the gradient type label for the Setup Color tab, as well
as moving the delay slider down.
Signed-off-by: Tametomo <irarice@gmail.com>
Signed-off-by: Bjørn Lindeijer <bjorn@lindeijer.nl>
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/setup_colors.cpp | 51 |
1 files changed, 32 insertions, 19 deletions
diff --git a/src/gui/setup_colors.cpp b/src/gui/setup_colors.cpp index 80c425e5..f68c6afe 100644 --- a/src/gui/setup_colors.cpp +++ b/src/gui/setup_colors.cpp @@ -79,6 +79,17 @@ Setup_Colors::Setup_Colors() : mGradTypeText = new Label; + std::string longText = _("Static"); + + if (getFont()->getWidth(_("Pulse")) > getFont()->getWidth(longText)) + longText = _("Pulse"); + if (getFont()->getWidth(_("Rainbow")) > getFont()->getWidth(longText)) + longText = _("Rainbow"); + if (getFont()->getWidth(_("Spectrum")) > getFont()->getWidth(longText)) + longText = _("Spectrum"); + + mGradTypeText->setCaption(longText); + mGradDelayLabel = new Label(_("Delay: ")); mGradDelayText = new TextField(); @@ -89,7 +100,7 @@ Setup_Colors::Setup_Colors() : mGradDelayText->setEnabled(false); mGradDelaySlider = new Slider(20, 400); - mGradDelaySlider->setWidth(200); + mGradDelaySlider->setWidth(180); mGradDelaySlider->setValue(mGradDelayText->getValue()); mGradDelaySlider->setActionEventId("slider_graddelay"); mGradDelaySlider->addActionListener(this); @@ -105,7 +116,7 @@ Setup_Colors::Setup_Colors() : mRedText->setEnabled(false); mRedSlider = new Slider(0, 255); - mRedSlider->setWidth(200); + mRedSlider->setWidth(180); mRedSlider->setValue(mRedText->getValue()); mRedSlider->setActionEventId("slider_red"); mRedSlider->addActionListener(this); @@ -121,7 +132,7 @@ Setup_Colors::Setup_Colors() : mGreenText->setEnabled(false); mGreenSlider = new Slider(0, 255); - mGreenSlider->setWidth(200); + mGreenSlider->setWidth(180); mGreenSlider->setValue(mGreenText->getValue()); mGreenSlider->setActionEventId("slider_green"); mGreenSlider->addActionListener(this); @@ -137,7 +148,7 @@ Setup_Colors::Setup_Colors() : mBlueText->setEnabled(false); mBlueSlider = new Slider(0, 255); - mBlueSlider->setWidth(200); + mBlueSlider->setWidth(180); mBlueSlider->setValue(mBlueText->getValue()); mBlueSlider->setActionEventId("slider_blue"); mBlueSlider->addActionListener(this); @@ -149,23 +160,25 @@ Setup_Colors::Setup_Colors() : LayoutHelper h(this); ContainerPlacer place = h.getPlacer(0, 0); - place(0, 0, mScroll, 4, 6).setPadding(2); - place(0, 6, mPreviewBox, 4).setPadding(2); + place(0, 0, mScroll, 5, 6).setPadding(2); + place(0, 6, mPreviewBox, 5).setPadding(2); place(0, 7, mGradTypeLabel, 2); place(2, 7, mGradTypeSlider); - place(3, 7, mGradTypeText); - place(0, 8, mGradDelayLabel, 2); - place(2, 8, mGradDelaySlider); - place(3, 8, mGradDelayText); - place(0, 9, mRedLabel, 2); - place(2, 9, mRedSlider); - place(3, 9, mRedText).setPadding(1); - place(0, 10, mGreenLabel, 2); - place(2, 10, mGreenSlider); - place(3, 10, mGreenText).setPadding(1); - place(0, 11, mBlueLabel, 2); - place(2, 11, mBlueSlider); - place(3, 11, mBlueText).setPadding(1); + place(3, 7, mGradTypeText, 2).setPadding(1); + place(0, 8, mRedLabel, 2); + place(2, 8, mRedSlider); + place(3, 8, mRedText).setPadding(1); + place(0, 9, mGreenLabel, 2); + place(2, 9, mGreenSlider); + place(3, 9, mGreenText).setPadding(1); + place(0, 10, mBlueLabel, 2); + place(2, 10, mBlueSlider); + place(3, 10, mBlueText).setPadding(1); + place(0, 11, mGradDelayLabel, 2); + place(2, 11, mGradDelaySlider); + place(3, 11, mGradDelayText).setPadding(1); + + mGradTypeText->setCaption(""); setDimension(gcn::Rectangle(0, 0, 325, 280)); } |