cui/source/dialogs/colorpicker.cxx           |   23 ++------
 cui/source/dialogs/zoom.cxx                  |    4 -
 include/vcl/weld.hxx                         |    9 +--
 starmath/inc/dialog.hxx                      |   21 +++----
 starmath/source/dialog.cxx                   |   66 +++++++++---------------
 starmath/source/document.cxx                 |    8 +-
 starmath/uiconfig/smath/ui/fontsizedialog.ui |   74 +++++++++++++++++++--------
 sw/source/ui/misc/linenum.cxx                |    2 
 sw/source/ui/table/colwd.cxx                 |    2 
 sw/source/ui/table/rowht.cxx                 |    2 
 10 files changed, 109 insertions(+), 102 deletions(-)

New commits:
commit ccbaaa04417eac83f9f521e034a3e62821e4b7f3
Author: Caolán McNamara <caol...@redhat.com>
Date:   Mon Apr 9 15:04:02 2018 +0100

    weld SmFontSizeDialog
    
    and give it a parent via SfxRequest::GetFrameWeld
    
    Change-Id: I126c300ce4b3f477fd927efbcc83b1a6d315f594
    Reviewed-on: https://gerrit.libreoffice.org/52637
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Caolán McNamara <caol...@redhat.com>
    Tested-by: Caolán McNamara <caol...@redhat.com>

diff --git a/cui/source/dialogs/colorpicker.cxx 
b/cui/source/dialogs/colorpicker.cxx
index 864281ae3ad1..7c64bb23a136 100644
--- a/cui/source/dialogs/colorpicker.cxx
+++ b/cui/source/dialogs/colorpicker.cxx
@@ -802,25 +802,16 @@ ColorPickerDialog::ColorPickerDialog(weld::Window* 
pParent, Color nColor, sal_In
     , m_xMFGreen(m_xBuilder->weld_spin_button("greenSpinbutton"))
     , m_xMFBlue(m_xBuilder->weld_spin_button("blueSpinbutton"))
     , m_xEDHex(new weld::HexColorControl(m_xBuilder->weld_entry("hexEntry")))
-    , m_xMFHue(m_xBuilder->weld_metric_spin_button("hueSpinbutton"))
-    , m_xMFSaturation(m_xBuilder->weld_metric_spin_button("satSpinbutton"))
-    , m_xMFBrightness(m_xBuilder->weld_metric_spin_button("brightSpinbutton"))
-    , m_xMFCyan(m_xBuilder->weld_metric_spin_button("cyanSpinbutton"))
-    , m_xMFMagenta(m_xBuilder->weld_metric_spin_button("magSpinbutton"))
-    , m_xMFYellow(m_xBuilder->weld_metric_spin_button("yellowSpinbutton"))
-    , m_xMFKey(m_xBuilder->weld_metric_spin_button("keySpinbutton"))
+    , m_xMFHue(m_xBuilder->weld_metric_spin_button("hueSpinbutton", 
FUNIT_DEGREE))
+    , m_xMFSaturation(m_xBuilder->weld_metric_spin_button("satSpinbutton", 
FUNIT_PERCENT))
+    , m_xMFBrightness(m_xBuilder->weld_metric_spin_button("brightSpinbutton", 
FUNIT_PERCENT))
+    , m_xMFCyan(m_xBuilder->weld_metric_spin_button("cyanSpinbutton", 
FUNIT_PERCENT))
+    , m_xMFMagenta(m_xBuilder->weld_metric_spin_button("magSpinbutton", 
FUNIT_PERCENT))
+    , m_xMFYellow(m_xBuilder->weld_metric_spin_button("yellowSpinbutton", 
FUNIT_PERCENT))
+    , m_xMFKey(m_xBuilder->weld_metric_spin_button("keySpinbutton", 
FUNIT_PERCENT))
     , mnDialogMode( nMode )
     , meMode( DefaultMode )
 {
-    m_xMFHue->set_unit(FUNIT_DEGREE);
-    m_xMFSaturation->set_unit(FUNIT_PERCENT);
-    m_xMFBrightness->set_unit(FUNIT_PERCENT);
-
-    m_xMFCyan->set_unit(FUNIT_PERCENT);
-    m_xMFMagenta->set_unit(FUNIT_PERCENT);
-    m_xMFYellow->set_unit(FUNIT_PERCENT);
-    m_xMFKey->set_unit(FUNIT_PERCENT);
-
     m_xColorField->SetModifyHdl( LINK( this, ColorPickerDialog, 
ColorFieldControlModifydl ) );
     m_xColorSlider->SetModifyHdl( LINK( this, ColorPickerDialog, 
ColorSliderControlModifyHdl ) );
 
diff --git a/cui/source/dialogs/zoom.cxx b/cui/source/dialogs/zoom.cxx
index d7f91462f971..9ff5d03f9ace 100644
--- a/cui/source/dialogs/zoom.cxx
+++ b/cui/source/dialogs/zoom.cxx
@@ -132,7 +132,7 @@ SvxZoomDialog::SvxZoomDialog(weld::Window* pParent, const 
SfxItemSet& rCoreSet)
     , m_xPageWidthBtn(m_xBuilder->weld_radio_button("fitw"))
     , m_x100Btn(m_xBuilder->weld_radio_button("100pc"))
     , m_xUserBtn(m_xBuilder->weld_radio_button("variable"))
-    , m_xUserEdit(m_xBuilder->weld_metric_spin_button("zoomsb"))
+    , m_xUserEdit(m_xBuilder->weld_metric_spin_button("zoomsb", FUNIT_PERCENT))
     , m_xViewFrame(m_xBuilder->weld_widget("viewframe"))
     , m_xAutomaticBtn(m_xBuilder->weld_radio_button("automatic"))
     , m_xSingleBtn(m_xBuilder->weld_radio_button("singlepage"))
@@ -141,8 +141,6 @@ SvxZoomDialog::SvxZoomDialog(weld::Window* pParent, const 
SfxItemSet& rCoreSet)
     , m_xBookModeChk(m_xBuilder->weld_check_button("bookmode"))
     , m_xOKBtn(m_xBuilder->weld_button("ok"))
 {
-    m_xUserEdit->set_unit(FUNIT_PERCENT);
-
     Link<weld::ToggleButton&,void> aLink = LINK(this, SvxZoomDialog, UserHdl);
     m_x100Btn->connect_toggled(aLink);
     m_xOptimalBtn->connect_toggled(aLink);
diff --git a/include/vcl/weld.hxx b/include/vcl/weld.hxx
index 6bb4d6541c1f..ebbd505736d4 100644
--- a/include/vcl/weld.hxx
+++ b/include/vcl/weld.hxx
@@ -465,8 +465,8 @@ protected:
     void update_width_chars();
 
 public:
-    MetricSpinButton(SpinButton* pSpinButton)
-        : m_eSrcUnit(FUNIT_CM)
+    MetricSpinButton(SpinButton* pSpinButton, FieldUnit eSrcUnit)
+        : m_eSrcUnit(eSrcUnit)
         , m_xSpinButton(pSpinButton)
     {
         update_width_chars();
@@ -670,9 +670,10 @@ public:
     virtual RadioButton* weld_radio_button(const OString& id, bool 
bTakeOwnership = false) = 0;
     virtual CheckButton* weld_check_button(const OString& id, bool 
bTakeOwnership = false) = 0;
     virtual SpinButton* weld_spin_button(const OString& id, bool 
bTakeOwnership = false) = 0;
-    MetricSpinButton* weld_metric_spin_button(const OString& id, bool 
bTakeOwnership = false)
+    MetricSpinButton* weld_metric_spin_button(const OString& id, FieldUnit 
eUnit,
+                                              bool bTakeOwnership = false)
     {
-        return new MetricSpinButton(weld_spin_button(id, bTakeOwnership));
+        return new MetricSpinButton(weld_spin_button(id, bTakeOwnership), 
eUnit);
     }
     virtual ComboBoxText* weld_combo_box_text(const OString& id, bool 
bTakeOwnership = false) = 0;
     virtual TreeView* weld_tree_view(const OString& id, bool bTakeOwnership = 
false) = 0;
diff --git a/starmath/inc/dialog.hxx b/starmath/inc/dialog.hxx
index d4452b86a427..bc0701421d43 100644
--- a/starmath/inc/dialog.hxx
+++ b/starmath/inc/dialog.hxx
@@ -123,22 +123,21 @@ public:
 
 /**************************************************************************/
 
-class SmFontSizeDialog : public ModalDialog
+class SmFontSizeDialog : public weld::GenericDialogController
 {
-    VclPtr<MetricField> m_pBaseSize;
-    VclPtr<MetricField> m_pTextSize;
-    VclPtr<MetricField> m_pIndexSize;
-    VclPtr<MetricField> m_pFunctionSize;
-    VclPtr<MetricField> m_pOperatorSize;
-    VclPtr<MetricField> m_pBorderSize;
-    VclPtr<PushButton> m_pDefaultButton;
+    std::unique_ptr<weld::MetricSpinButton> m_xBaseSize;
+    std::unique_ptr<weld::MetricSpinButton> m_xTextSize;
+    std::unique_ptr<weld::MetricSpinButton> m_xIndexSize;
+    std::unique_ptr<weld::MetricSpinButton> m_xFunctionSize;
+    std::unique_ptr<weld::MetricSpinButton> m_xOperatorSize;
+    std::unique_ptr<weld::MetricSpinButton> m_xBorderSize;
+    std::unique_ptr<weld::Button> m_xDefaultButton;
 
-    DECL_LINK(DefaultButtonClickHdl, Button *, void);
+    DECL_LINK(DefaultButtonClickHdl, weld::Button&, void);
 
 public:
-    SmFontSizeDialog(vcl::Window *pParent);
+    SmFontSizeDialog(weld::Window *pParent);
     virtual ~SmFontSizeDialog() override;
-    virtual void dispose() override;
 
     void ReadFrom(const SmFormat &rFormat);
     void WriteTo (SmFormat &rFormat) const;
diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx
index ad70b04e3402..e8afccc2586d 100644
--- a/starmath/source/dialog.cxx
+++ b/starmath/source/dialog.cxx
@@ -404,9 +404,9 @@ public:
     }
 };
 
-IMPL_LINK_NOARG( SmFontSizeDialog, DefaultButtonClickHdl, Button *, void )
+IMPL_LINK_NOARG( SmFontSizeDialog, DefaultButtonClickHdl, weld::Button&, void )
 {
-    SaveDefaultsQuery aQuery(GetFrameWeld());
+    SaveDefaultsQuery aQuery(m_xDialog.get());
     if (aQuery.run() == RET_YES)
     {
         SmModule *pp = SM_MOD();
@@ -416,61 +416,45 @@ IMPL_LINK_NOARG( SmFontSizeDialog, DefaultButtonClickHdl, 
Button *, void )
     }
 }
 
-SmFontSizeDialog::SmFontSizeDialog(vcl::Window * pParent)
-    : ModalDialog(pParent, "FontSizeDialog", 
"modules/smath/ui/fontsizedialog.ui")
+SmFontSizeDialog::SmFontSizeDialog(weld::Window* pParent)
+    : GenericDialogController(pParent, "modules/smath/ui/fontsizedialog.ui", 
"FontSizeDialog")
+    , m_xBaseSize(m_xBuilder->weld_metric_spin_button("spinB_baseSize", 
FUNIT_POINT))
+    , m_xTextSize(m_xBuilder->weld_metric_spin_button("spinB_text", 
FUNIT_PERCENT))
+    , m_xIndexSize(m_xBuilder->weld_metric_spin_button("spinB_index", 
FUNIT_PERCENT))
+    , m_xFunctionSize(m_xBuilder->weld_metric_spin_button("spinB_function", 
FUNIT_PERCENT))
+    , m_xOperatorSize(m_xBuilder->weld_metric_spin_button("spinB_operator", 
FUNIT_PERCENT))
+    , m_xBorderSize(m_xBuilder->weld_metric_spin_button("spinB_limit", 
FUNIT_PERCENT))
+    , m_xDefaultButton(m_xBuilder->weld_button("default"))
 {
-    get(m_pTextSize, "spinB_text");
-    get(m_pIndexSize, "spinB_index");
-    get(m_pFunctionSize, "spinB_function");
-    get(m_pOperatorSize, "spinB_operator");
-    get(m_pBorderSize, "spinB_limit");
-    get(m_pBaseSize, "spinB_baseSize");
-    get(m_pDefaultButton, "default");
-
-    m_pDefaultButton->SetClickHdl(LINK(this, SmFontSizeDialog, 
DefaultButtonClickHdl));
+    m_xDefaultButton->connect_clicked(LINK(this, SmFontSizeDialog, 
DefaultButtonClickHdl));
 }
 
 SmFontSizeDialog::~SmFontSizeDialog()
 {
-    disposeOnce();
 }
 
-void SmFontSizeDialog::dispose()
-{
-    m_pBaseSize.clear();
-    m_pTextSize.clear();
-    m_pIndexSize.clear();
-    m_pFunctionSize.clear();
-    m_pOperatorSize.clear();
-    m_pBorderSize.clear();
-    m_pDefaultButton.clear();
-    ModalDialog::dispose();
-}
-
-
 void SmFontSizeDialog::ReadFrom(const SmFormat &rFormat)
 {
     //! watch out: round properly!
-    m_pBaseSize->SetValue( SmRoundFraction(
-        Sm100th_mmToPts( rFormat.GetBaseSize().Height() ) ) );
+    m_xBaseSize->set_value( SmRoundFraction(
+        Sm100th_mmToPts( rFormat.GetBaseSize().Height() ) ), FUNIT_NONE );
 
-    m_pTextSize->SetValue( rFormat.GetRelSize(SIZ_TEXT) );
-    m_pIndexSize->SetValue( rFormat.GetRelSize(SIZ_INDEX) );
-    m_pFunctionSize->SetValue( rFormat.GetRelSize(SIZ_FUNCTION) );
-    m_pOperatorSize->SetValue( rFormat.GetRelSize(SIZ_OPERATOR) );
-    m_pBorderSize->SetValue( rFormat.GetRelSize(SIZ_LIMITS) );
+    m_xTextSize->set_value( rFormat.GetRelSize(SIZ_TEXT), FUNIT_NONE );
+    m_xIndexSize->set_value( rFormat.GetRelSize(SIZ_INDEX), FUNIT_NONE );
+    m_xFunctionSize->set_value( rFormat.GetRelSize(SIZ_FUNCTION), FUNIT_NONE );
+    m_xOperatorSize->set_value( rFormat.GetRelSize(SIZ_OPERATOR), FUNIT_NONE );
+    m_xBorderSize->set_value( rFormat.GetRelSize(SIZ_LIMITS), FUNIT_NONE );
 }
 
-
 void SmFontSizeDialog::WriteTo(SmFormat &rFormat) const
 {
-    rFormat.SetBaseSize( Size(0, SmPtsTo100th_mm( static_cast< long 
>(m_pBaseSize->GetValue()))) );
+    rFormat.SetBaseSize( Size(0, SmPtsTo100th_mm( static_cast< long 
>(m_xBaseSize->get_value(FUNIT_NONE)))) );
 
-    rFormat.SetRelSize(SIZ_TEXT,     
sal::static_int_cast<sal_uInt16>(m_pTextSize->GetValue()));
-    rFormat.SetRelSize(SIZ_INDEX,    
sal::static_int_cast<sal_uInt16>(m_pIndexSize->GetValue()));
-    rFormat.SetRelSize(SIZ_FUNCTION, 
sal::static_int_cast<sal_uInt16>(m_pFunctionSize->GetValue()));
-    rFormat.SetRelSize(SIZ_OPERATOR, 
sal::static_int_cast<sal_uInt16>(m_pOperatorSize->GetValue()));
-    rFormat.SetRelSize(SIZ_LIMITS,   
sal::static_int_cast<sal_uInt16>(m_pBorderSize->GetValue()));
+    rFormat.SetRelSize(SIZ_TEXT,     
sal::static_int_cast<sal_uInt16>(m_xTextSize->get_value(FUNIT_NONE)));
+    rFormat.SetRelSize(SIZ_INDEX,    
sal::static_int_cast<sal_uInt16>(m_xIndexSize->get_value(FUNIT_NONE)));
+    rFormat.SetRelSize(SIZ_FUNCTION, 
sal::static_int_cast<sal_uInt16>(m_xFunctionSize->get_value(FUNIT_NONE)));
+    rFormat.SetRelSize(SIZ_OPERATOR, 
sal::static_int_cast<sal_uInt16>(m_xOperatorSize->get_value(FUNIT_NONE)));
+    rFormat.SetRelSize(SIZ_LIMITS,   
sal::static_int_cast<sal_uInt16>(m_xBorderSize->get_value(FUNIT_NONE)));
 
     const Size aTmp (rFormat.GetBaseSize());
     for (sal_uInt16  i = FNT_BEGIN;  i <= FNT_END;  i++)
diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx
index c4a312888d0b..9eac89d5f474 100644
--- a/starmath/source/document.cxx
+++ b/starmath/source/document.cxx
@@ -950,15 +950,15 @@ void SmDocShell::Execute(SfxRequest& rReq)
 
         case SID_FONTSIZE:
         {
-            VclPtrInstance< SmFontSizeDialog > xFontSizeDialog(nullptr);
+            SmFontSizeDialog aFontSizeDialog(rReq.GetFrameWeld());
 
             SmFormat aOldFormat  = GetFormat();
-            xFontSizeDialog->ReadFrom( aOldFormat );
-            if (xFontSizeDialog->Execute() == RET_OK)
+            aFontSizeDialog.ReadFrom( aOldFormat );
+            if (aFontSizeDialog.run() == RET_OK)
             {
                 SmFormat aNewFormat( aOldFormat );
 
-                xFontSizeDialog->WriteTo(aNewFormat);
+                aFontSizeDialog.WriteTo(aNewFormat);
 
                 ::svl::IUndoManager *pTmpUndoMgr = GetUndoManager();
                 if (pTmpUndoMgr)
diff --git a/starmath/uiconfig/smath/ui/fontsizedialog.ui 
b/starmath/uiconfig/smath/ui/fontsizedialog.ui
index 3eaa2236f5c5..68c90e15d8fb 100644
--- a/starmath/uiconfig/smath/ui/fontsizedialog.ui
+++ b/starmath/uiconfig/smath/ui/fontsizedialog.ui
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!-- Generated with glade 3.20.0 -->
+<!-- Generated with glade 3.20.4 -->
 <interface domain="sm">
   <requires lib="gtk+" version="3.18"/>
   <object class="GtkAdjustment" id="adjustmentBaseSize">
@@ -8,7 +8,31 @@
     <property name="step_increment">1</property>
     <property name="page_increment">10</property>
   </object>
-  <object class="GtkAdjustment" id="adjustmentRelativeSizes">
+  <object class="GtkAdjustment" id="adjustmentRelativeSizes1">
+    <property name="lower">5</property>
+    <property name="upper">200</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkAdjustment" id="adjustmentRelativeSizes2">
+    <property name="lower">5</property>
+    <property name="upper">200</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkAdjustment" id="adjustmentRelativeSizes3">
+    <property name="lower">5</property>
+    <property name="upper">200</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkAdjustment" id="adjustmentRelativeSizes4">
+    <property name="lower">5</property>
+    <property name="upper">200</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkAdjustment" id="adjustmentRelativeSizes5">
     <property name="lower">5</property>
     <property name="upper">200</property>
     <property name="step_increment">1</property>
@@ -20,6 +44,8 @@
     <property name="title" translatable="yes" 
context="fontsizedialog|FontSizeDialog">Font Sizes</property>
     <property name="resizable">False</property>
     <property name="modal">True</property>
+    <property name="default_width">0</property>
+    <property name="default_height">0</property>
     <property name="type_hint">dialog</property>
     <child internal-child="vbox">
       <object class="GtkBox" id="dialog-vbox4">
@@ -121,7 +147,7 @@
                         <property name="can_focus">False</property>
                         <property name="label" translatable="yes" 
context="fontsizedialog|label4">Base _size:</property>
                         <property name="use_underline">True</property>
-                        <property 
name="mnemonic_widget">spinB_baseSize:0pt</property>
+                        <property 
name="mnemonic_widget">spinB_baseSize</property>
                         <property name="xalign">0</property>
                       </object>
                       <packing>
@@ -131,10 +157,11 @@
                       </packing>
                     </child>
                     <child>
-                      <object class="GtkSpinButton" id="spinB_baseSize:0pt">
+                      <object class="GtkSpinButton" id="spinB_baseSize">
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="hexpand">True</property>
+                        <property name="activates_default">True</property>
                         <property 
name="adjustment">adjustmentBaseSize</property>
                       </object>
                       <packing>
@@ -174,11 +201,12 @@
                         <property name="row_spacing">6</property>
                         <property name="column_spacing">12</property>
                         <child>
-                          <object class="GtkSpinButton" id="spinB_function:0%">
+                          <object class="GtkSpinButton" id="spinB_function">
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="hexpand">True</property>
-                            <property 
name="adjustment">adjustmentRelativeSizes</property>
+                            <property name="activates_default">True</property>
+                            <property 
name="adjustment">adjustmentRelativeSizes1</property>
                           </object>
                           <packing>
                             <property name="left_attach">1</property>
@@ -191,7 +219,7 @@
                             <property name="can_focus">False</property>
                             <property name="label" translatable="yes" 
context="fontsizedialog|label2">_Operators:</property>
                             <property name="use_underline">True</property>
-                            <property 
name="mnemonic_widget">spinB_function:0%</property>
+                            <property 
name="mnemonic_widget">spinB_function</property>
                             <property name="xalign">0</property>
                           </object>
                           <packing>
@@ -205,7 +233,7 @@
                             <property name="can_focus">False</property>
                             <property name="label" translatable="yes" 
context="fontsizedialog|label3">_Limits:</property>
                             <property name="use_underline">True</property>
-                            <property 
name="mnemonic_widget">spinB_limit:0%</property>
+                            <property 
name="mnemonic_widget">spinB_limit</property>
                             <property name="xalign">0</property>
                           </object>
                           <packing>
@@ -214,11 +242,12 @@
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkSpinButton" id="spinB_operator:0%">
+                          <object class="GtkSpinButton" id="spinB_operator">
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="hexpand">True</property>
-                            <property 
name="adjustment">adjustmentRelativeSizes</property>
+                            <property name="activates_default">True</property>
+                            <property 
name="adjustment">adjustmentRelativeSizes2</property>
                           </object>
                           <packing>
                             <property name="left_attach">1</property>
@@ -226,11 +255,12 @@
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkSpinButton" id="spinB_limit:0%">
+                          <object class="GtkSpinButton" id="spinB_limit">
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="hexpand">True</property>
-                            <property 
name="adjustment">adjustmentRelativeSizes</property>
+                            <property name="activates_default">True</property>
+                            <property 
name="adjustment">adjustmentRelativeSizes3</property>
                           </object>
                           <packing>
                             <property name="left_attach">1</property>
@@ -243,7 +273,7 @@
                             <property name="can_focus">False</property>
                             <property name="label" translatable="yes" 
context="fontsizedialog|label5">_Text:</property>
                             <property name="use_underline">True</property>
-                            <property 
name="mnemonic_widget">spinB_text:0%</property>
+                            <property 
name="mnemonic_widget">spinB_text</property>
                             <property name="xalign">0</property>
                           </object>
                           <packing>
@@ -257,7 +287,7 @@
                             <property name="can_focus">False</property>
                             <property name="label" translatable="yes" 
context="fontsizedialog|label7">_Functions:</property>
                             <property name="use_underline">True</property>
-                            <property 
name="mnemonic_widget">spinB_function:0%</property>
+                            <property 
name="mnemonic_widget">spinB_function</property>
                             <property name="xalign">0</property>
                           </object>
                           <packing>
@@ -271,7 +301,7 @@
                             <property name="can_focus">False</property>
                             <property name="label" translatable="yes" 
context="fontsizedialog|label6">_Indexes:</property>
                             <property name="use_underline">True</property>
-                            <property 
name="mnemonic_widget">spinB_index:0%</property>
+                            <property 
name="mnemonic_widget">spinB_index</property>
                             <property name="xalign">0</property>
                           </object>
                           <packing>
@@ -280,11 +310,12 @@
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkSpinButton" id="spinB_text:0%">
+                          <object class="GtkSpinButton" id="spinB_text">
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="hexpand">True</property>
-                            <property 
name="adjustment">adjustmentRelativeSizes</property>
+                            <property name="activates_default">True</property>
+                            <property 
name="adjustment">adjustmentRelativeSizes4</property>
                           </object>
                           <packing>
                             <property name="left_attach">1</property>
@@ -292,11 +323,12 @@
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkSpinButton" id="spinB_index:0%">
+                          <object class="GtkSpinButton" id="spinB_index">
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="hexpand">True</property>
-                            <property 
name="adjustment">adjustmentRelativeSizes</property>
+                            <property name="activates_default">True</property>
+                            <property 
name="adjustment">adjustmentRelativeSizes5</property>
                           </object>
                           <packing>
                             <property name="left_attach">1</property>
@@ -334,7 +366,9 @@
       </object>
     </child>
     <action-widgets>
-      <action-widget response="0">default</action-widget>
+      <action-widget response="-5">ok</action-widget>
+      <action-widget response="-6">cancel</action-widget>
+      <action-widget response="-11">help</action-widget>
     </action-widgets>
     <child>
       <placeholder/>
diff --git a/sw/source/ui/misc/linenum.cxx b/sw/source/ui/misc/linenum.cxx
index 40604b299f1e..537cc428e59a 100644
--- a/sw/source/ui/misc/linenum.cxx
+++ b/sw/source/ui/misc/linenum.cxx
@@ -74,7 +74,7 @@ SwLineNumberingDlg::SwLineNumberingDlg(const SwView& rVw)
     , m_xCharStyleLB(m_xBuilder->weld_combo_box_text("styledropdown"))
     , m_xFormatLB(new 
NumberingTypeListBox(m_xBuilder->weld_combo_box_text("formatdropdown")))
     , m_xPosLB(m_xBuilder->weld_combo_box_text("positiondropdown"))
-    , m_xOffsetMF(m_xBuilder->weld_metric_spin_button("spacingspin"))
+    , m_xOffsetMF(m_xBuilder->weld_metric_spin_button("spacingspin", FUNIT_CM))
     , m_xDivisorED(m_xBuilder->weld_entry("textentry"))
     , m_xCountEmptyLinesCB(m_xBuilder->weld_check_button("blanklines"))
     , m_xCountFrameLinesCB(m_xBuilder->weld_check_button("linesintextframes"))
diff --git a/sw/source/ui/table/colwd.cxx b/sw/source/ui/table/colwd.cxx
index deb4fb03e35a..d572563cbe4a 100644
--- a/sw/source/ui/table/colwd.cxx
+++ b/sw/source/ui/table/colwd.cxx
@@ -42,7 +42,7 @@ SwTableWidthDlg::SwTableWidthDlg(weld::Window *pParent, 
SwTableFUNC &rTableFnc)
     : GenericDialogController(pParent, "modules/swriter/ui/columnwidth.ui", 
"ColumnWidthDialog")
     , m_rFnc(rTableFnc)
     , m_xColNF(m_xBuilder->weld_spin_button("column"))
-    , m_xWidthMF(m_xBuilder->weld_metric_spin_button("width"))
+    , m_xWidthMF(m_xBuilder->weld_metric_spin_button("width", FUNIT_CM))
 {
     bool bIsWeb = rTableFnc.GetShell()
                   && (dynamic_cast< const SwWebDocShell* >(
diff --git a/sw/source/ui/table/rowht.cxx b/sw/source/ui/table/rowht.cxx
index 29c84b7fd242..e8b725b806cd 100644
--- a/sw/source/ui/table/rowht.cxx
+++ b/sw/source/ui/table/rowht.cxx
@@ -50,7 +50,7 @@ void SwTableHeightDlg::Apply()
 SwTableHeightDlg::SwTableHeightDlg(weld::Window *pParent, SwWrtShell &rS)
     : GenericDialogController(pParent, "modules/swriter/ui/rowheight.ui", 
"RowHeightDialog")
     , m_rSh(rS)
-    , m_xHeightEdit(m_xBuilder->weld_metric_spin_button("heightmf"))
+    , m_xHeightEdit(m_xBuilder->weld_metric_spin_button("heightmf", FUNIT_CM))
     , m_xAutoHeightCB(m_xBuilder->weld_check_button("fit"))
 {
     FieldUnit eFieldUnit = SW_MOD()->GetUsrPref( dynamic_cast< const 
SwWebDocShell*>(
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to