[Libreoffice-commits] core.git: sc/AllLangResTarget_sc.mk sc/source sc/uiconfig sc/UIConfig_scalc.mk

Katarina Behrens bubli at bubli.org
Wed Nov 27 14:36:00 PST 2013


 sc/AllLangResTarget_sc.mk               |    1 
 sc/UIConfig_scalc.mk                    |    1 
 sc/source/ui/condformat/colorformat.cxx |  141 ++++------
 sc/source/ui/inc/colorformat.hrc        |   36 --
 sc/source/ui/inc/colorformat.hxx        |   35 --
 sc/source/ui/src/colorformat.src        |  160 ------------
 sc/uiconfig/scalc/ui/databaroptions.ui  |  417 ++++++++++++++++++++++++++++++++
 7 files changed, 493 insertions(+), 298 deletions(-)

New commits:
commit d933a10c744adde8566f1e5db24760be03979828
Author: Katarina Behrens <bubli at bubli.org>
Date:   Wed Nov 27 22:54:49 2013 +0100

    Converted data bar options dialog to .ui
    
    all right this time
    
    Change-Id: I9168df3cd83cfa910e4a189b5330a28ad85773ac

diff --git a/sc/AllLangResTarget_sc.mk b/sc/AllLangResTarget_sc.mk
index 274c08a..abeb023 100644
--- a/sc/AllLangResTarget_sc.mk
+++ b/sc/AllLangResTarget_sc.mk
@@ -53,7 +53,6 @@ $(eval $(call gb_SrsTarget_add_files,sc/res,\
     sc/source/ui/src/scstring.src \
     sc/source/ui/src/sortdlg.src \
     sc/source/ui/src/filter.src \
-    sc/source/ui/src/colorformat.src \
     sc/source/ui/src/condformatdlg.src \
     sc/source/ui/src/condformatmgr.src \
     sc/source/ui/src/xmlsourcedlg.src \
diff --git a/sc/UIConfig_scalc.mk b/sc/UIConfig_scalc.mk
index 23c4972..1d68b97 100644
--- a/sc/UIConfig_scalc.mk
+++ b/sc/UIConfig_scalc.mk
@@ -29,6 +29,7 @@ $(eval $(call gb_UIConfig_add_toolbarfiles,modules/scalc,\
 	sc/uiconfig/scalc/toolbar/basicshapes \
 	sc/uiconfig/scalc/toolbar/calloutshapes \
 	sc/uiconfig/scalc/toolbar/colorbar \
+	sc/uiconfig/scalc/toolbar/databaroptions \
 	sc/uiconfig/scalc/toolbar/datastreams \
 	sc/uiconfig/scalc/toolbar/drawbar \
 	sc/uiconfig/scalc/toolbar/drawobjectbar \
diff --git a/sc/source/ui/condformat/colorformat.cxx b/sc/source/ui/condformat/colorformat.cxx
index 9c8e57e..b126174 100644
--- a/sc/source/ui/condformat/colorformat.cxx
+++ b/sc/source/ui/condformat/colorformat.cxx
@@ -10,8 +10,8 @@
 #include "colorformat.hxx"
 #include "colorscale.hxx"
 
-#include "colorformat.hrc"
 #include "document.hxx"
+#include "sc.hrc"
 
 #include <svx/xtable.hxx>
 #include <svx/drawitem.hxx>
@@ -61,55 +61,47 @@ void SetValue( ScColorScaleEntry* pEntry, Edit& aEdit)
 }
 
 ScDataBarSettingsDlg::ScDataBarSettingsDlg(Window* pWindow, const ScDataBarFormatData& rData, ScDocument* pDoc, const ScAddress& rPos):
-    ModalDialog( pWindow, ScResId( RID_SCDLG_DATABAR ) ),
-    maBtnOk( this, ScResId( BTN_OK ) ),
-    maBtnCancel( this, ScResId( BTN_CANCEL ) ),
-    maFlBarColors( this, ScResId( FL_BAR_COLORS ) ),
-    maFlAxes( this, ScResId( FL_AXIS ) ),
-    maFlValues( this, ScResId( FL_VALUES ) ),
-    maFtMin( this, ScResId( FT_MINIMUM ) ),
-    maFtMax( this, ScResId( FT_MAXIMUM ) ),
-    maFtPositive( this, ScResId( FT_POSITIVE ) ),
-    maFtNegative( this, ScResId( FT_NEGATIVE ) ),
-    maFtPosition( this, ScResId( FT_POSITION ) ),
-    maFtAxisColor( this, ScResId( FT_COLOR_AXIS ) ),
-    maLbPos( this, ScResId( LB_POS ) ),
-    maLbNeg( this, ScResId( LB_NEG ) ),
-    maLbAxisCol( this, ScResId( LB_COL_AXIS ) ),
-    maLbTypeMin( this, ScResId( LB_TYPE ) ),
-    maLbTypeMax( this, ScResId( LB_TYPE ) ),
-    maLbAxisPos( this, ScResId( LB_AXIS_POSITION ) ),
-    maEdMin( this, ScResId( ED_MIN ) ),
-    maEdMax( this, ScResId( ED_MAX ) ),
-    maStrWarnSameValue( SC_RESSTR( STR_WARN_SAME_VALUE ) ),
+    ModalDialog( pWindow, "DataBarOptions", "modules/scalc/ui/databaroptions.ui" ),
     mpNumberFormatter( pDoc->GetFormatTable() ),
     mpDoc(pDoc),
     maPos(rPos)
 {
+    get( mpBtnOk, "ok");
+    get( mpBtnCancel, "cancel" );
+    get( mpLbPos, "positive_colour" );
+    get( mpLbNeg, "negative_colour" );
+    get( mpLbTypeMin, "min" );
+    get( mpLbTypeMax, "max" );
+    get( mpLbAxisPos, "axis_pos" );
+    get( mpLbAxisCol, "axis_colour" );
+    get( mpEdMin, "min_value" );
+    get( mpEdMax, "max_value" );
+
+    maStrWarnSameValue = get<FixedText>("str_same_value")->GetText();
+
     Init();
-    FreeResource();
 
-    maLbPos.SelectEntry( rData.maPositiveColor );
+    mpLbPos->SelectEntry( rData.maPositiveColor );
     if(rData.mpNegativeColor)
-        maLbNeg.SelectEntry( *rData.mpNegativeColor );
+        mpLbNeg->SelectEntry( *rData.mpNegativeColor );
 
     switch (rData.meAxisPosition)
     {
         case databar::NONE:
-            maLbAxisPos.SelectEntryPos(2);
+            mpLbAxisPos->SelectEntryPos(2);
             break;
         case databar::AUTOMATIC:
-            maLbAxisPos.SelectEntryPos(0);
+            mpLbAxisPos->SelectEntryPos(0);
             break;
         case databar::MIDDLE:
-            maLbAxisPos.SelectEntryPos(1);
+            mpLbAxisPos->SelectEntryPos(1);
             break;
     }
-    ::SetType(rData.mpLowerLimit.get(), maLbTypeMin);
-    ::SetType(rData.mpUpperLimit.get(), maLbTypeMax);
-    SetValue(rData.mpLowerLimit.get(), maEdMin);
-    SetValue(rData.mpUpperLimit.get(), maEdMax);
-    maLbAxisCol.SelectEntry(rData.maAxisColor);
+    ::SetType(rData.mpLowerLimit.get(), *mpLbTypeMin);
+    ::SetType(rData.mpUpperLimit.get(), *mpLbTypeMax);
+    SetValue(rData.mpLowerLimit.get(), *mpEdMin);
+    SetValue(rData.mpUpperLimit.get(), *mpEdMax);
+    mpLbAxisCol->SelectEntry(rData.maAxisColor);
 
     TypeSelectHdl(NULL);
 }
@@ -130,43 +122,40 @@ void ScDataBarSettingsDlg::Init()
     if ( pColorTable.is() )
     {
         // filling the line color box
-        maLbPos.SetUpdateMode( false );
-        maLbNeg.SetUpdateMode( false );
-        maLbAxisCol.SetUpdateMode( false );
+        mpLbPos->SetUpdateMode( false );
+        mpLbNeg->SetUpdateMode( false );
+        mpLbAxisCol->SetUpdateMode( false );
 
         for ( long i = 0; i < pColorTable->Count(); ++i )
         {
             XColorEntry* pEntry = pColorTable->GetColor(i);
-            maLbPos.InsertEntry( pEntry->GetColor(), pEntry->GetName() );
-            maLbNeg.InsertEntry( pEntry->GetColor(), pEntry->GetName() );
-            maLbAxisCol.InsertEntry( pEntry->GetColor(), pEntry->GetName() );
+            mpLbPos->InsertEntry( pEntry->GetColor(), pEntry->GetName() );
+            mpLbNeg->InsertEntry( pEntry->GetColor(), pEntry->GetName() );
+            mpLbAxisCol->InsertEntry( pEntry->GetColor(), pEntry->GetName() );
 
             if(pEntry->GetColor() == Color(COL_LIGHTRED))
-                maLbNeg.SelectEntryPos(i);
+                mpLbNeg->SelectEntryPos(i);
             if(pEntry->GetColor() == Color(COL_BLACK))
-                maLbAxisCol.SelectEntryPos(i);
+                mpLbAxisCol->SelectEntryPos(i);
             if(pEntry->GetColor() == Color(COL_LIGHTBLUE))
-                maLbPos.SelectEntryPos(i);
+                mpLbPos->SelectEntryPos(i);
         }
-        maLbPos.SetUpdateMode( sal_True );
-        maLbNeg.SetUpdateMode( sal_True );
-        maLbAxisCol.SetUpdateMode( sal_True );
+        mpLbPos->SetUpdateMode( sal_True );
+        mpLbNeg->SetUpdateMode( sal_True );
+        mpLbAxisCol->SetUpdateMode( sal_True );
     }
-    maBtnOk.SetClickHdl( LINK( this, ScDataBarSettingsDlg, OkBtnHdl ) );
-
-    Point aPoint(maLbTypeMax.GetPosPixel().X(), maFtMax.GetPosPixel().Y());
-    maLbTypeMax.SetPosPixel(aPoint);
+    mpBtnOk->SetClickHdl( LINK( this, ScDataBarSettingsDlg, OkBtnHdl ) );
 
-    maLbTypeMin.SetSelectHdl( LINK( this, ScDataBarSettingsDlg, TypeSelectHdl ) );
-    maLbTypeMax.SetSelectHdl( LINK( this, ScDataBarSettingsDlg, TypeSelectHdl ) );
+    mpLbTypeMin->SetSelectHdl( LINK( this, ScDataBarSettingsDlg, TypeSelectHdl ) );
+    mpLbTypeMax->SetSelectHdl( LINK( this, ScDataBarSettingsDlg, TypeSelectHdl ) );
 
 }
 
 namespace {
 
-void GetAxesPosition(ScDataBarFormatData* pData, const ListBox& rLbox)
+void GetAxesPosition(ScDataBarFormatData* pData, const ListBox* rLbox)
 {
-    switch(rLbox.GetSelectEntryPos())
+    switch(rLbox->GetSelectEntryPos())
     {
         case 0:
             pData->meAxisPosition = databar::AUTOMATIC;
@@ -185,16 +174,16 @@ void GetAxesPosition(ScDataBarFormatData* pData, const ListBox& rLbox)
 ScDataBarFormatData* ScDataBarSettingsDlg::GetData()
 {
     ScDataBarFormatData* pData = new ScDataBarFormatData();
-    pData->maPositiveColor = maLbPos.GetSelectEntryColor();
-    pData->mpNegativeColor.reset(new Color(maLbNeg.GetSelectEntryColor()));
+    pData->maPositiveColor = mpLbPos->GetSelectEntryColor();
+    pData->mpNegativeColor.reset(new Color(mpLbNeg->GetSelectEntryColor()));
     pData->mbGradient = true; //FIXME
     pData->mpUpperLimit.reset(new ScColorScaleEntry());
     pData->mpLowerLimit.reset(new ScColorScaleEntry());
-    pData->maAxisColor = maLbAxisCol.GetSelectEntryColor();
+    pData->maAxisColor = mpLbAxisCol->GetSelectEntryColor();
 
-    ::GetType(maLbTypeMin, maEdMin, pData->mpLowerLimit.get(), mpNumberFormatter, mpDoc, maPos);
-    ::GetType(maLbTypeMax, maEdMax, pData->mpUpperLimit.get(), mpNumberFormatter, mpDoc, maPos);
-    GetAxesPosition(pData, maLbAxisPos);
+    ::GetType(*mpLbTypeMin, *mpEdMin, pData->mpLowerLimit.get(), mpNumberFormatter, mpDoc, maPos);
+    ::GetType(*mpLbTypeMax, *mpEdMax, pData->mpUpperLimit.get(), mpNumberFormatter, mpDoc, maPos);
+    GetAxesPosition(pData, mpLbAxisPos);
 
     return pData;
 }
@@ -203,20 +192,20 @@ IMPL_LINK_NOARG( ScDataBarSettingsDlg, OkBtnHdl )
 {
     //check that min < max
     bool bWarn = false;
-    sal_Int32 nSelectMin = maLbTypeMin.GetSelectEntryPos();
+    sal_Int32 nSelectMin = mpLbTypeMin->GetSelectEntryPos();
     if( nSelectMin == COLORSCALE_MAX )
         bWarn = true;
-    sal_Int32 nSelectMax = maLbTypeMax.GetSelectEntryPos();
+    sal_Int32 nSelectMax = mpLbTypeMax->GetSelectEntryPos();
     if( nSelectMax == COLORSCALE_MIN )
         bWarn = true;
 
-    if(!bWarn && maLbTypeMin.GetSelectEntryPos() == maLbTypeMax.GetSelectEntryPos())
+    if(!bWarn && mpLbTypeMin->GetSelectEntryPos() == mpLbTypeMax->GetSelectEntryPos())
     {
 
         if(nSelectMax != COLORSCALE_FORMULA && nSelectMax != COLORSCALE_AUTO)
         {
-            OUString aMinString = maEdMin.GetText();
-            OUString aMaxString = maEdMax.GetText();
+            OUString aMinString = mpEdMin->GetText();
+            OUString aMaxString = mpEdMax->GetText();
             double nMinValue = 0;
             sal_uInt32 nIndex = 0;
             mpNumberFormatter->IsNumberFormat(aMinString, nIndex, nMinValue);
@@ -243,33 +232,33 @@ IMPL_LINK_NOARG( ScDataBarSettingsDlg, OkBtnHdl )
 
 IMPL_LINK_NOARG( ScDataBarSettingsDlg, TypeSelectHdl )
 {
-    sal_Int32 nSelectMin = maLbTypeMin.GetSelectEntryPos();
+    sal_Int32 nSelectMin = mpLbTypeMin->GetSelectEntryPos();
     if( nSelectMin <= COLORSCALE_MAX)
-        maEdMin.Disable();
+        mpEdMin->Disable();
     else
     {
-        maEdMin.Enable();
-        if(maEdMin.GetText().isEmpty())
+        mpEdMin->Enable();
+        if(mpEdMin->GetText().isEmpty())
         {
             if(nSelectMin == COLORSCALE_PERCENTILE || nSelectMin == COLORSCALE_PERCENT)
-                maEdMin.SetText(OUString::number(50));
+                mpEdMin->SetText(OUString::number(50));
             else
-                maEdMin.SetText(OUString::number(0));
+                mpEdMin->SetText(OUString::number(0));
         }
     }
 
-    sal_Int32 nSelectMax = maLbTypeMax.GetSelectEntryPos();
+    sal_Int32 nSelectMax = mpLbTypeMax->GetSelectEntryPos();
     if(nSelectMax <= COLORSCALE_MAX)
-        maEdMax.Disable();
+        mpEdMax->Disable();
     else
     {
-        maEdMax.Enable();
-        if(maEdMax.GetText().isEmpty())
+        mpEdMax->Enable();
+        if(mpEdMax->GetText().isEmpty())
         {
             if(nSelectMax == COLORSCALE_PERCENTILE || nSelectMax == COLORSCALE_PERCENT)
-                maEdMax.SetText(OUString::number(50));
+                mpEdMax->SetText(OUString::number(50));
             else
-                maEdMax.SetText(OUString::number(0));
+                mpEdMax->SetText(OUString::number(0));
         }
     }
     return 0;
diff --git a/sc/source/ui/inc/colorformat.hrc b/sc/source/ui/inc/colorformat.hrc
deleted file mode 100644
index 6ec0da5..0000000
--- a/sc/source/ui/inc/colorformat.hrc
+++ /dev/null
@@ -1,36 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include "sc.hrc"
-
-#define BTN_OK 1
-#define BTN_CANCEL 2
-
-#define FL_BAR_COLORS 10
-#define FL_AXIS 11
-#define FL_VALUES 12
-#define FT_MINIMUM 13
-#define FT_MAXIMUM 14
-#define FT_POSITIVE 15
-#define FT_NEGATIVE 16
-#define FT_POSITION 17
-#define FT_COLOR_AXIS 18
-#define LB_POS 19
-#define LB_NEG 20
-#define LB_COL_AXIS 21
-
-#define LB_TYPE 22
-#define LB_AXIS_POSITION 23
-
-#define ED_MIN 24
-#define ED_MAX 25
-
-#define STR_WARN_SAME_VALUE 26
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/inc/colorformat.hxx b/sc/source/ui/inc/colorformat.hxx
index cf094b5..f3d40dd 100644
--- a/sc/source/ui/inc/colorformat.hxx
+++ b/sc/source/ui/inc/colorformat.hxx
@@ -7,9 +7,6 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
  */
 
-#ifndef SC_COLORFORMAT_HXX
-#define SC_COLORFORMAT_HXX
-
 #include <vcl/button.hxx>
 #include <vcl/dialog.hxx>
 #include <vcl/fixed.hxx>
@@ -23,29 +20,19 @@ class ScDocument;
 class ScDataBarSettingsDlg : public ModalDialog
 {
 private:
-    OKButton maBtnOk;
-    CancelButton maBtnCancel;
-    FixedLine maFlBarColors;
-    FixedLine maFlAxes;
-    FixedLine maFlValues;
-
-    FixedText maFtMin;
-    FixedText maFtMax;
-    FixedText maFtPositive;
-    FixedText maFtNegative;
-    FixedText maFtPosition;
-    FixedText maFtAxisColor;
+    OKButton* mpBtnOk;
+    CancelButton* mpBtnCancel;
 
-    ColorListBox maLbPos;
-    ColorListBox maLbNeg;
-    ColorListBox maLbAxisCol;
+    ColorListBox* mpLbPos;
+    ColorListBox* mpLbNeg;
+    ColorListBox* mpLbAxisCol;
 
-    ListBox maLbTypeMin;
-    ListBox maLbTypeMax;
-    ListBox maLbAxisPos;
+    ListBox* mpLbTypeMin;
+    ListBox* mpLbTypeMax;
+    ListBox* mpLbAxisPos;
 
-    Edit maEdMin;
-    Edit maEdMax;
+    Edit* mpEdMin;
+    Edit* mpEdMax;
 
     OUString maStrWarnSameValue;
     SvNumberFormatter* mpNumberFormatter;
@@ -64,6 +51,4 @@ public:
     ScDataBarFormatData* GetData();
 };
 
-#endif
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/src/colorformat.src b/sc/source/ui/src/colorformat.src
deleted file mode 100644
index 439f4fb..0000000
--- a/sc/source/ui/src/colorformat.src
+++ /dev/null
@@ -1,160 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include "colorformat.hrc"
-
-ModalDialog RID_SCDLG_DATABAR
-{
-    OutputSize = TRUE;
-    Hide = TRUE;
-    Size = MAP_APPFONT ( 200, 200 );
-    Text [ en-US ] = "Data Bar";
-    Moveable = TRUE;
-    Closeable = TRUE;
-    OkButton BTN_OK
-    {
-        Pos = MAP_APPFONT ( 120, 180 );
-        Size = MAP_APPFONT ( 30, 14 );
-        TabStop = TRUE;
-    };
-    CancelButton BTN_CANCEL
-    {
-        Pos = MAP_APPFONT ( 160, 180 );
-        Size = MAP_APPFONT ( 30, 14 );
-        TabStop = TRUE;
-    };
-    FixedLine FL_VALUES
-    {
-        Pos = MAP_APPFONT( 5, 5 );
-        Size = MAP_APPFONT( 190, 10 );
-        Text [ en-US ] = "Entry Values";
-    };
-    FixedLine FL_BAR_COLORS
-    {
-        Pos = MAP_APPFONT( 5, 60 );
-        Size = MAP_APPFONT( 190, 10 );
-        Text [ en-US ] = "Bar Colors";
-    };
-    FixedLine FL_AXIS
-    {
-        Pos = MAP_APPFONT( 5, 120 );
-        Size = MAP_APPFONT( 190, 10 );
-        Text [ en-US ] = "Axis";
-    };
-    FixedText FT_MINIMUM
-    {
-        Pos = MAP_APPFONT( 10, 20 );
-        Size = MAP_APPFONT( 50, 14 );
-        Text [ en-US ] = "Minimum:";
-    };
-    FixedText FT_MAXIMUM
-    {
-        Pos = MAP_APPFONT( 10, 40 );
-        Size = MAP_APPFONT( 50, 14 );
-        Text [ en-US ] = "Maximum:";
-    };
-    FixedText FT_POSITIVE
-    {
-        Pos = MAP_APPFONT( 10, 75 );
-        Size = MAP_APPFONT( 50, 14 );
-        Text [ en-US ] = "Positive:";
-    };
-    FixedText FT_NEGATIVE
-    {
-        Pos = MAP_APPFONT( 10, 95 );
-        Size = MAP_APPFONT( 50, 14 );
-        Text [ en-US ] = "Negative:";
-    };
-    FixedText FT_POSITION
-    {
-        Pos = MAP_APPFONT( 10, 135 );
-        Size = MAP_APPFONT( 110, 14 );
-        Text [ en-US ] = "Position of vertical axis";
-    };
-    FixedText FT_COLOR_AXIS
-    {
-        Pos = MAP_APPFONT( 10, 155 );
-        Size = MAP_APPFONT( 110, 14 );
-        Text [ en-US ] = "Color of vertical axis";
-    };
-    ListBox LB_POS
-    {
-        Pos = MAP_APPFONT( 80, 75 );
-        Size = MAP_APPFONT( 60, 50 );
-        Border = TRUE;
-        DropDown = TRUE;
-        DDExtraWidth = TRUE;
-    };
-    ListBox LB_NEG
-    {
-        Pos = MAP_APPFONT( 80, 95 );
-        Size = MAP_APPFONT( 60, 50 );
-        Border = TRUE;
-        DropDown = TRUE;
-        DDExtraWidth = TRUE;
-    };
-    ListBox LB_COL_AXIS
-    {
-        Pos = MAP_APPFONT( 120, 155 );
-        Size = MAP_APPFONT( 60, 50 );
-        Border = TRUE;
-        DropDown = TRUE;
-        DDExtraWidth = TRUE;
-    };
-    ListBox LB_TYPE
-    {
-        Pos = MAP_APPFONT( 80, 20 );
-        Size = MAP_APPFONT( 50, 50 );
-        Border = TRUE;
-        DropDown = TRUE;
-        StringList [ en-US ] =
-        {
-            "Automatic";
-            "Minimum";
-            "Maximum";
-            "Percentile";
-            "Value";
-            "Percent";
-            "Formula";
-        };
-    };
-    ListBox LB_AXIS_POSITION
-    {
-        Pos = MAP_APPFONT( 120, 135 );
-        Size = MAP_APPFONT( 50, 50 );
-        Border = TRUE;
-        DropDown = TRUE;
-        StringList [ en-US ] =
-        {
-            "Automatic";
-            "Middle";
-            "None";
-        };
-    };
-    Edit ED_MIN
-    {
-        Pos = MAP_APPFONT( 140, 21 );
-        Size = MAP_APPFONT( 40, 12 );
-        TabStop = TRUE;
-        Border = TRUE;
-    };
-    Edit ED_MAX
-    {
-        Pos = MAP_APPFONT( 140, 41 );
-        Size = MAP_APPFONT( 40, 12 );
-        TabStop = TRUE;
-        Border = TRUE;
-    };
-    String STR_WARN_SAME_VALUE
-    {
-        Text [ en-US ] = "Min value must be smaller than max value!";
-    };
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/uiconfig/scalc/ui/databaroptions.ui b/sc/uiconfig/scalc/ui/databaroptions.ui
new file mode 100644
index 0000000..a4dac5c
--- /dev/null
+++ b/sc/uiconfig/scalc/ui/databaroptions.ui
@@ -0,0 +1,417 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkDialog" id="DataBarOptions">
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="type_hint">dialog</property>
+    <child internal-child="vbox">
+      <object class="GtkBox" id="dialog-vbox1">
+        <property name="can_focus">False</property>
+        <property name="orientation">vertical</property>
+        <property name="spacing">12</property>
+        <child internal-child="action_area">
+          <object class="GtkButtonBox" id="dialog-action_area1">
+            <property name="can_focus">False</property>
+            <property name="layout_style">end</property>
+            <child>
+              <object class="GtkButton" id="ok">
+                <property name="label">gtk-ok</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="cancel">
+                <property name="label">gtk-cancel</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="pack_type">end</property>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkBox" id="box1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="orientation">vertical</property>
+            <child>
+              <object class="GtkFrame" id="frame1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label_xalign">0</property>
+                <property name="shadow_type">none</property>
+                <child>
+                  <object class="GtkAlignment" id="alignment1">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="left_padding">12</property>
+                    <property name="top_padding">6</property>
+                    <child>
+                      <object class="GtkGrid" id="grid1">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="top_padding">6</property>
+                        <property name="row_spacing">12</property>
+                        <property name="column_spacing">6</property>
+                        <property name="hexpand">True</property>
+                        <property name="vexpand">True</property>
+                        <child>
+                          <object class="GtkLabel" id="label4">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">end</property>
+                            <property name="label" translatable="yes">Minimum:</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkLabel" id="label5">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">end</property>
+                            <property name="label" translatable="yes">Maximum:</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkComboBox" id="min">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                            <items>
+                              <item translatable="yes">Automatic</item>
+                              <item translatable="yes">Middle</item>
+                              <item translatable="yes">None</item>
+                            </items>
+                          </object>
+                          <packing>
+                            <property name="left_attach">1</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkComboBox" id="max">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                            <items>
+                              <item translatable="yes">Automatic</item>
+                              <item translatable="yes">Middle</item>
+                              <item translatable="yes">None</item>
+                            </items>
+                          </object>
+                          <packing>
+                            <property name="left_attach">1</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkEntry" id="min_value">
+                            <property name="visible">True</property>
+                            <property name="can_focus">True</property>
+                            <property name="invisible_char">●</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">2</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkEntry" id="max_value">
+                            <property name="visible">True</property>
+                            <property name="can_focus">True</property>
+                            <property name="invisible_char">●</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">2</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                      </object>
+                    </child>
+                  </object>
+                </child>
+                <child type="label">
+                  <object class="GtkLabel" id="label1">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="label" translatable="yes">Entry Values</property>
+                    <attributes>
+                      <attribute name="weight" value="bold"/>
+                    </attributes>
+                  </object>
+                </child>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkFrame" id="frame2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label_xalign">0</property>
+                <property name="shadow_type">none</property>
+                <child>
+                  <object class="GtkAlignment" id="alignment2">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="left_padding">12</property>
+                    <property name="top_padding">6</property>
+                    <child>
+                      <object class="GtkGrid" id="grid2">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="row_spacing">12</property>
+                        <property name="column_spacing">6</property>
+                        <property name="hexpand">True</property>
+                        <property name="vexpand">True</property>
+                        <child>
+                          <object class="GtkLabel" id="label6">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">end</property>
+                            <property name="">False</property>
+                            <property name="label" translatable="yes">Positive:</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkLabel" id="label7">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">end</property>
+                            <property name="label" translatable="yes">Negative:</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="svtlo-ColorListBox" id="positive_colour">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">1</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="svtlo-ColorListBox" id="negative_colour">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">1</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                      </object>
+                    </child>
+                  </object>
+                </child>
+                <child type="label">
+                  <object class="GtkLabel" id="label2">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="label" translatable="yes">Bar Colors</property>
+                    <attributes>
+                      <attribute name="weight" value="bold"/>
+                    </attributes>
+                  </object>
+                </child>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkFrame" id="frame3">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label_xalign">0</property>
+                <property name="shadow_type">none</property>
+                <child>
+                  <object class="GtkAlignment" id="alignment3">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="left_padding">12</property>
+                    <property name="top_padding">6</property>
+                    <child>
+                      <object class="GtkGrid" id="grid3">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="row_spacing">12</property>
+                        <property name="column_spacing">6</property>
+                        <property name="hexpand">True</property>
+                        <property name="vexpand">True</property>
+                        <child>
+                          <object class="GtkLabel" id="label8">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">end</property>
+                            <property name="label" translatable="yes">Position of vertical axis:</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkLabel" id="label9">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">end</property>
+                            <property name="label" translatable="yes">Color of vertical axis:</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkComboBox" id="axis_pos">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                            <items>
+                              <item translatable="yes">Automatic</item>
+                              <item translatable="yes">Minimum</item>
+                              <item translatable="yes">Maximum</item>
+                              <item translatable="yes">Percentile</item>
+                              <item translatable="yes">Value</item>
+                              <item translatable="yes">Percent</item>
+                              <item translatable="yes">Formula</item>
+                            </items>
+                          </object>
+                          <packing>
+                            <property name="left_attach">1</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="svtlo-ColorListBox" id="axis_colour">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="hexpand">True</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">1</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                      </object>
+                    </child>
+                  </object>
+                </child>
+                <child type="label">
+                  <object class="GtkLabel" id="label3">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="label" translatable="yes">Axis</property>
+                    <attributes>
+                      <attribute name="weight" value="bold"/>
+                    </attributes>
+                  </object>
+                </child>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">2</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkLabel" id="str_same_value">
+                <property name="can_focus">False</property>
+                <property name="no_show_all">False</property>
+                <property name="xalign">0</property>
+                <property name="label" translatable="yes">Min value must be smaller than max value!</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">3</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+    <action-widgets>
+      <action-widget response="0">ok</action-widget>
+      <action-widget response="0">cancel</action-widget>
+    </action-widgets>
+  </object>
+</interface>


More information about the Libreoffice-commits mailing list