[Libreoffice-commits] core.git: 4 commits - cui/AllLangResTarget_cui.mk cui/source cui/uiconfig cui/UIConfig_cui.mk dbaccess/AllLangResTarget_dbu.mk dbaccess/inc dbaccess/source dbaccess/uiconfig dbaccess/UIConfig_dbaccess.mk helpcontent2 include/svx svx/source

Caolán McNamara caolanm at redhat.com
Thu Dec 26 01:59:49 PST 2013


 cui/AllLangResTarget_cui.mk             |    1 
 cui/UIConfig_cui.mk                     |    2 
 cui/source/dialogs/fmsearch.hrc         |    1 
 cui/source/dialogs/showcols.cxx         |   31 +---
 cui/source/dialogs/showcols.src         |   68 ---------
 cui/source/dialogs/srchxtra.cxx         |  112 +++++++--------
 cui/source/dialogs/srchxtra.src         |   62 --------
 cui/source/factory/dlgfact.cxx          |   20 --
 cui/source/factory/dlgfact.hxx          |    5 
 cui/source/inc/showcols.hxx             |    9 -
 cui/source/inc/srchxtra.hxx             |   10 -
 cui/uiconfig/ui/searchformatdialog.ui   |  233 ++++++++++++++++++++++++++++++++
 cui/uiconfig/ui/showcoldialog.ui        |  112 +++++++++++++++
 dbaccess/AllLangResTarget_dbu.mk        |    1 
 dbaccess/UIConfig_dbaccess.mk           |    4 
 dbaccess/inc/dbaccess_helpid.hrc        |    4 
 dbaccess/source/ui/dlg/dlgsize.cxx      |   51 ++-----
 dbaccess/source/ui/dlg/dlgsize.hrc      |   32 ----
 dbaccess/source/ui/dlg/dlgsize.src      |  139 -------------------
 dbaccess/source/ui/inc/dbu_resource.hrc |    3 
 dbaccess/source/ui/inc/dlgsize.hxx      |   10 -
 dbaccess/uiconfig/ui/colwidthdialog.ui  |  153 +++++++++++++++++++++
 dbaccess/uiconfig/ui/rowheightdialog.ui |  153 +++++++++++++++++++++
 helpcontent2                            |    2 
 include/svx/dialogs.hrc                 |    1 
 include/svx/svxdlg.hxx                  |    5 
 svx/source/dialog/srchdlg.cxx           |    2 
 27 files changed, 760 insertions(+), 466 deletions(-)

New commits:
commit fdc1b1fc174da27e3016370fdb603d6bbe49af4d
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Dec 26 09:55:18 2013 +0000

    convert search format dialog to .ui
    
    Change-Id: I29db27f8adf2afda7e47b69c43b032758c1e7b24

diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index b508acc..95fdba3 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -128,6 +128,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/recordnumberdialog \
 	cui/uiconfig/ui/rotationtabpage \
 	cui/uiconfig/ui/scriptorganizer \
+	cui/uiconfig/ui/searchformatdialog \
 	cui/uiconfig/ui/securityoptionsdialog \
 	cui/uiconfig/ui/select_persona_dialog \
 	cui/uiconfig/ui/shadowtabpage \
diff --git a/cui/source/dialogs/srchxtra.cxx b/cui/source/dialogs/srchxtra.cxx
index 87857a9..7000d95 100644
--- a/cui/source/dialogs/srchxtra.cxx
+++ b/cui/source/dialogs/srchxtra.cxx
@@ -37,87 +37,77 @@
 #include <rtl/strbuf.hxx>
 #include "svtools/treelistentry.hxx"
 
-// class SvxSearchFormatDialog -------------------------------------------
-
-SvxSearchFormatDialog::SvxSearchFormatDialog( Window* pParent, const SfxItemSet& rSet ) :
-
-    SfxTabDialog( pParent, CUI_RES( RID_SVXDLG_SEARCHFORMAT ), &rSet ),
-
-    pFontList( NULL )
-
+SvxSearchFormatDialog::SvxSearchFormatDialog(Window* pParent, const SfxItemSet& rSet)
+    : SfxTabDialog(pParent, "SearchFormatDialog", "cui/ui/searchformatdialog.ui", &rSet)
+    , m_pFontList(NULL)
+    , m_nNamePageId(0)
+    , m_nParaStdPageId(0)
+    , m_nParaAlignPageId(0)
+    , m_nBackPageId(0)
 {
-    FreeResource();
-
-    AddTabPage( RID_SVXPAGE_CHAR_NAME, SvxCharNamePage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_CHAR_EFFECTS, SvxCharEffectsPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_CHAR_POSITION, SvxCharPositionPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_CHAR_TWOLINES, SvxCharTwoLinesPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_STD_PARAGRAPH, SvxStdParagraphTabPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_ALIGN_PARAGRAPH, SvxParaAlignTabPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_EXT_PARAGRAPH, SvxExtParagraphTabPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_PARA_ASIAN, SvxAsianTabPage::Create, 0 );
-    AddTabPage( RID_SVXPAGE_BACKGROUND, SvxBackgroundTabPage::Create, 0 );
+    m_nNamePageId = AddTabPage("font", SvxCharNamePage::Create, 0);
+    AddTabPage("fonteffects", SvxCharEffectsPage::Create, 0);
+    AddTabPage("position", SvxCharPositionPage::Create, 0);
+    AddTabPage("asianlayout", SvxCharTwoLinesPage::Create, 0);
+    m_nParaStdPageId = AddTabPage("labelTP_PARA_STD", SvxStdParagraphTabPage::Create, 0);
+    m_nParaAlignPageId = AddTabPage("labelTP_PARA_ALIGN", SvxParaAlignTabPage::Create, 0);
+    AddTabPage("labelTP_PARA_EXT", SvxExtParagraphTabPage::Create, 0);
+    AddTabPage("labelTP_PARA_ASIAN", SvxAsianTabPage::Create, 0 );
+    m_nBackPageId = AddTabPage("background", SvxBackgroundTabPage::Create, 0);
 
     // remove asian tabpages if necessary
     SvtCJKOptions aCJKOptions;
     if ( !aCJKOptions.IsDoubleLinesEnabled() )
-        RemoveTabPage( RID_SVXPAGE_CHAR_TWOLINES );
+        RemoveTabPage("asianlayout");
     if ( !aCJKOptions.IsAsianTypographyEnabled() )
-        RemoveTabPage( RID_SVXPAGE_PARA_ASIAN );
+        RemoveTabPage("labelTP_PARA_ASIAN");
 }
 
-// -----------------------------------------------------------------------
-
 SvxSearchFormatDialog::~SvxSearchFormatDialog()
 {
-    delete pFontList;
+    delete m_pFontList;
 }
 
-// -----------------------------------------------------------------------
-
 void SvxSearchFormatDialog::PageCreated( sal_uInt16 nId, SfxTabPage& rPage )
 {
-    switch ( nId )
+    if (nId == m_nNamePageId)
     {
-        case RID_SVXPAGE_CHAR_NAME:
-        {
-            const FontList* pAppFontList = 0;
-            SfxObjectShell* pSh = SfxObjectShell::Current();
+        const FontList* pApm_pFontList = 0;
+        SfxObjectShell* pSh = SfxObjectShell::Current();
 
-            if ( pSh )
-            {
-                const SvxFontListItem* pFLItem = (const SvxFontListItem*)
-                    pSh->GetItem( SID_ATTR_CHAR_FONTLIST );
-                if ( pFLItem )
-                    pAppFontList = pFLItem->GetFontList();
-            }
+        if ( pSh )
+        {
+            const SvxFontListItem* pFLItem = (const SvxFontListItem*)
+                pSh->GetItem( SID_ATTR_CHAR_FONTLIST );
+            if ( pFLItem )
+                pApm_pFontList = pFLItem->GetFontList();
+        }
 
-            const FontList* pList = pAppFontList;
+        const FontList* pList = pApm_pFontList;
 
-            if ( !pList )
-            {
-                if ( !pFontList )
-                    pFontList = new FontList( this );
-                pList = pFontList;
-            }
-
-            if ( pList )
-                ( (SvxCharNamePage&)rPage ).
-                    SetFontList( SvxFontListItem( pList, SID_ATTR_CHAR_FONTLIST ) );
-            ( (SvxCharNamePage&)rPage ).EnableSearchMode();
-            break;
+        if ( !pList )
+        {
+            if ( !m_pFontList )
+                m_pFontList = new FontList( this );
+            pList = m_pFontList;
         }
 
-        case RID_SVXPAGE_STD_PARAGRAPH:
-            ( (SvxStdParagraphTabPage&)rPage ).EnableAutoFirstLine();
-            break;
-
-        case RID_SVXPAGE_ALIGN_PARAGRAPH:
-            ( (SvxParaAlignTabPage&)rPage ).EnableJustifyExt();
-            break;
-        case RID_SVXPAGE_BACKGROUND :
-            ( (SvxBackgroundTabPage&)rPage ).ShowParaControl(sal_True);
-            break;
+        if ( pList )
+            ( (SvxCharNamePage&)rPage ).
+                SetFontList( SvxFontListItem( pList, SID_ATTR_CHAR_FONTLIST ) );
+        ( (SvxCharNamePage&)rPage ).EnableSearchMode();
+    }
+    else if (nId == m_nParaStdPageId)
+    {
+        ( (SvxStdParagraphTabPage&)rPage ).EnableAutoFirstLine();
+    }
+    else if (nId == m_nParaAlignPageId)
+    {
+        ( (SvxParaAlignTabPage&)rPage ).EnableJustifyExt();
+    }
+    else if (nId == m_nBackPageId)
+    {
+        ( (SvxBackgroundTabPage&)rPage ).ShowParaControl(sal_True);
     }
 }
 
diff --git a/cui/source/dialogs/srchxtra.src b/cui/source/dialogs/srchxtra.src
index ec032f7..d8b2b5a 100644
--- a/cui/source/dialogs/srchxtra.src
+++ b/cui/source/dialogs/srchxtra.src
@@ -22,67 +22,7 @@
 #include "srchxtra.hrc"
 #include <svx/dialogs.hrc>
 
- // RID_SVXDLG_SEARCHFORMAT -----------------------------------------------
-TabDialog RID_SVXDLG_SEARCHFORMAT
-{
-    OutputSize = TRUE ;
-    SvLook = TRUE ;
-    Text [ en-US ] = "Text Format" ;
-    Moveable = TRUE ;
-    TabControl 1
-    {
-        OutputSize = TRUE ;
-        PageList =
-        {
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_CHAR_NAME ;
-                Text [ en-US ] = "Font" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_CHAR_EFFECTS ;
-                Text [ en-US ] = "Font Effects" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_CHAR_POSITION ;
-                Text [ en-US ] = "Position" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_CHAR_TWOLINES ;
-                Text [ en-US ] = "Asian Layout" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_STD_PARAGRAPH ;
-                Text [ en-US ] = "Indents & Spacing" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_ALIGN_PARAGRAPH ;
-                Text [ en-US ] = "Alignment" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_EXT_PARAGRAPH ;
-                Text [ en-US ] = "Text Flow" ;
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_PARA_ASIAN;
-                Text [ en-US ] = "Asian Typography";
-            };
-            PageItem
-            {
-                Identifier = RID_SVXPAGE_BACKGROUND;
-                Text [ en-US ] = "Background" ;
-            };
-        };
-    };
-};
- // RID_SVXDLG_SEARCHATTRIBUTE --------------------------------------------
+// RID_SVXDLG_SEARCHATTRIBUTE --------------------------------------------
 ModalDialog RID_SVXDLG_SEARCHATTR
 {
     HelpId = HID_SEARCHATTR ;
diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx
index 3cf3d97..a7a96c3f 100644
--- a/cui/source/factory/dlgfact.cxx
+++ b/cui/source/factory/dlgfact.cxx
@@ -1313,23 +1313,11 @@ SfxAbstractDialog* AbstractDialogFactory_Impl::CreateSfxDialog( sal_uInt32,
     return new CuiAbstractSfxDialog_Impl( pDlg );
 }
 
-SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTabItemDialog( Window* pParent,
-                                            const SfxItemSet& rSet,
-                                            sal_uInt32 nResId)
+SfxAbstractTabDialog* AbstractDialogFactory_Impl::CreateTabItemDialog(Window* pParent,
+    const SfxItemSet& rSet)
 {
-    SfxTabDialog* pDlg=NULL;
-    switch ( nResId )
-    {
-        case RID_SVXDLG_SEARCHFORMAT :
-            pDlg = new SvxSearchFormatDialog( pParent, rSet );
-            break;
-        default:
-            break;
-    }
-
-    if ( pDlg )
-        return new CuiAbstractTabDialog_Impl( pDlg );
-    return 0;
+    SfxTabDialog* pDlg = new SvxSearchFormatDialog(pParent, rSet);
+    return new CuiAbstractTabDialog_Impl(pDlg);
 }
 
 VclAbstractDialog*      AbstractDialogFactory_Impl::CreateSvxSearchAttributeDialog( Window* pParent,
diff --git a/cui/source/factory/dlgfact.hxx b/cui/source/factory/dlgfact.hxx
index 784130e..cee1226 100644
--- a/cui/source/factory/dlgfact.hxx
+++ b/cui/source/factory/dlgfact.hxx
@@ -552,9 +552,8 @@ public:
                                             const SfxItemSet* pAttrSet,
                                             SdrView* pView,
                                             SdrModel* pModel=0 );
-    virtual SfxAbstractTabDialog*       CreateTabItemDialog( Window* pParent,
-                                            const SfxItemSet& rSet,
-                                            sal_uInt32 nResId);
+    virtual SfxAbstractTabDialog*       CreateTabItemDialog(Window* pParent,
+                                            const SfxItemSet& rSet);
     virtual AbstractSvxCaptionDialog*   CreateCaptionDialog( Window* pParent,
                                             const SdrView* pView,
                                             sal_uInt16 nAnchorTypes = 0 );
diff --git a/cui/source/inc/srchxtra.hxx b/cui/source/inc/srchxtra.hxx
index 642f3c7..d505204 100644
--- a/cui/source/inc/srchxtra.hxx
+++ b/cui/source/inc/srchxtra.hxx
@@ -26,19 +26,21 @@
 #include <svx/checklbx.hxx>
 #include <svx/srchdlg.hxx>
 
-// class SvxSearchFormatDialog -------------------------------------------
-
 class SvxSearchFormatDialog : public SfxTabDialog
 {
 public:
     SvxSearchFormatDialog( Window* pParent, const SfxItemSet& rSet );
-    ~SvxSearchFormatDialog();
+    virtual ~SvxSearchFormatDialog();
 
 protected:
     virtual void    PageCreated( sal_uInt16 nId, SfxTabPage &rPage );
 
 private:
-    FontList*       pFontList;
+    FontList*  m_pFontList;
+    sal_uInt16 m_nNamePageId;
+    sal_uInt16 m_nParaStdPageId;
+    sal_uInt16 m_nParaAlignPageId;
+    sal_uInt16 m_nBackPageId;
 };
 
 // class SvxSearchFormatDialog -------------------------------------------
diff --git a/cui/uiconfig/ui/searchformatdialog.ui b/cui/uiconfig/ui/searchformatdialog.ui
new file mode 100644
index 0000000..0e1e9ab
--- /dev/null
+++ b/cui/uiconfig/ui/searchformatdialog.ui
@@ -0,0 +1,233 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkDialog" id="SearchFormatDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="title" translatable="yes">Text Format</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="can_default">True</property>
+                <property name="has_default">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>
+            <child>
+              <object class="GtkButton" id="help">
+                <property name="label">gtk-help</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">2</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="reset">
+                <property name="label">gtk-revert-to-saved</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">3</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="GtkNotebook" id="tabcontrol">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="font">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Font</property>
+              </object>
+              <packing>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="fonteffects">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Font Effects</property>
+              </object>
+              <packing>
+                <property name="position">1</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="position">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Position</property>
+              </object>
+              <packing>
+                <property name="position">2</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="asianlayout">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Asian Layout</property>
+              </object>
+              <packing>
+                <property name="position">3</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="labelTP_PARA_STD">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Indents & Spacing</property>
+              </object>
+              <packing>
+                <property name="position">4</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="labelTP_PARA_ALIGN">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="xalign">0.4699999988079071</property>
+                <property name="label" translatable="yes">Alignment</property>
+              </object>
+              <packing>
+                <property name="position">5</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="labelTP_PARA_EXT">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="xalign">0.46000000834465027</property>
+                <property name="label" translatable="yes">Text Flow</property>
+              </object>
+              <packing>
+                <property name="position">6</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="labelTP_PARA_ASIAN">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Asian Typography</property>
+              </object>
+              <packing>
+                <property name="position">7</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="background">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Background</property>
+              </object>
+              <packing>
+                <property name="position">8</property>
+                <property name="tab_fill">False</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-widget response="0">help</action-widget>
+      <action-widget response="0">reset</action-widget>
+    </action-widgets>
+  </object>
+</interface>
diff --git a/include/svx/dialogs.hrc b/include/svx/dialogs.hrc
index 95c0691..a422d2d 100644
--- a/include/svx/dialogs.hrc
+++ b/include/svx/dialogs.hrc
@@ -107,7 +107,6 @@
 #define RID_SVX_GRFFILTER_DLG_SOLARIZE      (RID_SVX_START + 333)
 #define RID_SVX_GRFFILTER_DLG_EMBOSS        (RID_SVX_START + 336)
 #define RID_SVX_GRFFILTER_DLG_SMOOTH        (RID_SVX_START + 337)
-#define RID_SVXDLG_SEARCHFORMAT             (RID_SVX_START +  21)
 #define RID_SVXDLG_CHARMAP                  ( RID_SVX_START +  10 )
 
 // IDs of options pages of applications
diff --git a/include/svx/svxdlg.hxx b/include/svx/svxdlg.hxx
index 919f6f5..34ae403 100644
--- a/include/svx/svxdlg.hxx
+++ b/include/svx/svxdlg.hxx
@@ -358,9 +358,8 @@ public:
                                             TargetList& rTargetList ) = 0;
     virtual AbstractSvxHlinkDlgMarkWnd* CreateSvxHlinkDlgMarkWndDialog( SvxHyperlinkTabPageBase* pParent, sal_uInt32 nResId ) =0;
 
-    virtual SfxAbstractTabDialog* CreateTabItemDialog( Window* pParent,
-                                            const SfxItemSet& rSet,
-                                            sal_uInt32 nResId) = 0;
+    virtual SfxAbstractTabDialog* CreateTabItemDialog(Window* pParent,
+                                            const SfxItemSet& rSet) = 0;
     virtual VclAbstractDialog*      CreateSvxSearchAttributeDialog( Window* pParent,
                                             SearchAttrItemList& rLst,
                                             const sal_uInt16* pWhRanges)=0;
diff --git a/svx/source/dialog/srchdlg.cxx b/svx/source/dialog/srchdlg.cxx
index e6afc1c..e5df140 100644
--- a/svx/source/dialog/srchdlg.cxx
+++ b/svx/source/dialog/srchdlg.cxx
@@ -1950,7 +1950,7 @@ IMPL_LINK_NOARG(SvxSearchDialog, FormatHdl_Impl)
     SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
     if(pFact)
     {
-        SfxAbstractTabDialog* pDlg = pFact->CreateTabItemDialog( this, aSet, RID_SVXDLG_SEARCHFORMAT );
+        SfxAbstractTabDialog* pDlg = pFact->CreateTabItemDialog(this, aSet);
         DBG_ASSERT(pDlg, "Dialogdiet fail!");
         aTxt = pDlg->GetText() + aTxt;
         pDlg->SetText( aTxt );
commit 297f5b525f22e05bad8b17c98be2a716463d0408
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Dec 25 21:37:41 2013 +0000

    convert col width and row height dialogs to .ui
    
    Change-Id: Ic64d2e0e296b8d2ed06162e1f778194486fb6fed

diff --git a/dbaccess/AllLangResTarget_dbu.mk b/dbaccess/AllLangResTarget_dbu.mk
index 3b75501..72c0321 100644
--- a/dbaccess/AllLangResTarget_dbu.mk
+++ b/dbaccess/AllLangResTarget_dbu.mk
@@ -49,7 +49,6 @@ $(eval $(call gb_SrsTarget_add_files,dbaccess/dbu,\
     dbaccess/source/ui/dlg/directsql.src \
     dbaccess/source/ui/dlg/dlgattr.src \
     dbaccess/source/ui/dlg/dlgsave.src \
-    dbaccess/source/ui/dlg/dlgsize.src \
     dbaccess/source/ui/dlg/dsselect.src \
     dbaccess/source/ui/dlg/indexdialog.src \
     dbaccess/source/ui/dlg/paramdialog.src \
diff --git a/dbaccess/UIConfig_dbaccess.mk b/dbaccess/UIConfig_dbaccess.mk
index cace6a8..e6e003c 100644
--- a/dbaccess/UIConfig_dbaccess.mk
+++ b/dbaccess/UIConfig_dbaccess.mk
@@ -10,10 +10,12 @@
 $(eval $(call gb_UIConfig_UIConfig,dbaccess))
 
 $(eval $(call gb_UIConfig_add_uifiles,dbaccess, \
+    dbaccess/uiconfig/ui/colwidthdialog \
     dbaccess/uiconfig/ui/directsqldialog  \
-    dbaccess/uiconfig/ui/querypropertiesdialog  \
     dbaccess/uiconfig/ui/generalpagedialog \
     dbaccess/uiconfig/ui/generalpagewizard \
+    dbaccess/uiconfig/ui/querypropertiesdialog  \
+    dbaccess/uiconfig/ui/rowheightdialog \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/dbaccess/inc/dbaccess_helpid.hrc b/dbaccess/inc/dbaccess_helpid.hrc
index 314660f..cfccb9e 100644
--- a/dbaccess/inc/dbaccess_helpid.hrc
+++ b/dbaccess/inc/dbaccess_helpid.hrc
@@ -78,10 +78,6 @@
 #define HID_BROWSER_CLOSECONN                             "DBACCESS_HID_BROWSER_CLOSECONN"
 #define HID_BROWSER_REFRESHCONN                           "DBACCESS_HID_BROWSER_REFRESHCONN"
 
-#define HID_DLG_ROWHEIGHT                                 "DBACCESS_HID_DLG_ROWHEIGHT"
-#define HID_DLG_COLWIDTH                                  "DBACCESS_HID_DLG_COLWIDTH"
-
-
 #define HID_TLB_QUERYDESIGN                               "DBACCESS_HID_TLB_QUERYDESIGN"
 #define HID_CTL_QRYSQLEDIT                                "DBACCESS_HID_CTL_QRYSQLEDIT"
 #define HID_DSADMIN_SPECIAL_MESSAGE                       "DBACCESS_HID_DSADMIN_SPECIAL_MESSAGE"
diff --git a/dbaccess/source/ui/dlg/dlgsize.cxx b/dbaccess/source/ui/dlg/dlgsize.cxx
index c60d0f1..c764514 100644
--- a/dbaccess/source/ui/dlg/dlgsize.cxx
+++ b/dbaccess/source/ui/dlg/dlgsize.cxx
@@ -17,7 +17,6 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-#include "dlgsize.hrc"
 #include "dlgsize.hxx"
 #include "dbu_dlg.hrc"
 #include "moduledbu.hxx"
@@ -30,64 +29,52 @@ namespace dbaui
 
 DBG_NAME(DlgSize)
 DlgSize::DlgSize( Window* pParent, sal_Int32 nVal, sal_Bool bRow, sal_Int32 _nAlternativeStandard )
-        :ModalDialog( pParent, ModuleRes(bRow ? DLG_ROWHEIGHT : DLG_COLWIDTH))
-        ,m_nPrevValue(nVal)
-        ,m_nStandard(bRow ? DEF_ROW_HEIGHT : DEF_COL_WIDTH)
-        ,aFT_VALUE(this,    ModuleRes( FT_VALUE))
-        ,aMF_VALUE(this,    ModuleRes( MF_VALUE))
-        ,aCB_STANDARD(this, ModuleRes(CB_STANDARD))
-        ,aPB_OK(this,       ModuleRes(PB_OK))
-        ,aPB_CANCEL(this,   ModuleRes(PB_CANCEL))
-        ,aPB_HELP(this,     ModuleRes(PB_HELP))
+    : ModalDialog(pParent, bRow ? OString("RowHeightDialog") : OString("ColWidthDialog"),
+        bRow ? OUString("dbaccess/ui/rowheightdialog.ui") : OUString("dbaccess/ui/colwidthdialog.ui"))
+    , m_nPrevValue(nVal)
+    , m_nStandard(bRow ? DEF_ROW_HEIGHT : DEF_COL_WIDTH)
 {
-    DBG_CTOR(DlgSize,NULL);
+    get(m_pMF_VALUE, "value");
+    get(m_pCB_STANDARD, "automatic");
 
     if ( _nAlternativeStandard > 0 )
         m_nStandard = _nAlternativeStandard;
-    aCB_STANDARD.SetClickHdl(LINK(this,DlgSize,CbClickHdl));
+    m_pCB_STANDARD->SetClickHdl(LINK(this,DlgSize,CbClickHdl));
 
-    aMF_VALUE.EnableEmptyFieldValue(sal_True);
+    m_pMF_VALUE->EnableEmptyFieldValue(sal_True);
     sal_Bool bDefault = -1 == nVal;
-    aCB_STANDARD.Check(bDefault);
+    m_pCB_STANDARD->Check(bDefault);
     if (bDefault)
     {
         SetValue(m_nStandard);
         m_nPrevValue = m_nStandard;
     }
-    LINK(this,DlgSize,CbClickHdl).Call(&aCB_STANDARD);
-
-    FreeResource();
-}
-
-DlgSize::~DlgSize()
-{
-
-    DBG_DTOR(DlgSize,NULL);
+    LINK(this,DlgSize,CbClickHdl).Call(m_pCB_STANDARD);
 }
 
 void DlgSize::SetValue( sal_Int32 nVal )
 {
-    aMF_VALUE.SetValue(nVal, FUNIT_CM );
+    m_pMF_VALUE->SetValue(nVal, FUNIT_CM );
 }
 
 sal_Int32 DlgSize::GetValue()
 {
-    if (aCB_STANDARD.IsChecked())
+    if (m_pCB_STANDARD->IsChecked())
         return -1;
-    return (sal_Int32)aMF_VALUE.GetValue( FUNIT_CM );
+    return (sal_Int32)m_pMF_VALUE->GetValue( FUNIT_CM );
 }
 
 IMPL_LINK( DlgSize, CbClickHdl, Button *, pButton )
 {
 
-    if( pButton == &aCB_STANDARD )
+    if( pButton == m_pCB_STANDARD )
     {
-        aMF_VALUE.Enable(!aCB_STANDARD.IsChecked());
-        if (aCB_STANDARD.IsChecked())
+        m_pMF_VALUE->Enable(!m_pCB_STANDARD->IsChecked());
+        if (m_pCB_STANDARD->IsChecked())
         {
-            m_nPrevValue = static_cast<sal_Int32>(aMF_VALUE.GetValue(FUNIT_CM));
-                // don't use getValue as this will use aCB_STANDARD.to determine if we're standard
-            aMF_VALUE.SetEmptyFieldValue();
+            m_nPrevValue = static_cast<sal_Int32>(m_pMF_VALUE->GetValue(FUNIT_CM));
+                // don't use getValue as this will use m_pCB_STANDARD->to determine if we're standard
+            m_pMF_VALUE->SetEmptyFieldValue();
         }
         else
         {
diff --git a/dbaccess/source/ui/dlg/dlgsize.hrc b/dbaccess/source/ui/dlg/dlgsize.hrc
deleted file mode 100644
index 6815bb9..0000000
--- a/dbaccess/source/ui/dlg/dlgsize.hrc
+++ /dev/null
@@ -1,32 +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/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef DBAUI_DLGSIZE_HRC
-#define DBAUI_DLGSIZE_HRC
-
-#define FT_VALUE    1
-#define MF_VALUE    1
-#define CB_STANDARD 2
-#define PB_OK       1
-#define PB_CANCEL   1
-#define PB_HELP     1
-
-#endif //DBAUI_DLGSIZE_HRC
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dlgsize.src b/dbaccess/source/ui/dlg/dlgsize.src
deleted file mode 100644
index 6b9deda..0000000
--- a/dbaccess/source/ui/dlg/dlgsize.src
+++ /dev/null
@@ -1,139 +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/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "dlgsize.hrc"
-#include "dbaccess_helpid.hrc"
-#include "dbu_dlg.hrc"
-
-ModalDialog DLG_ROWHEIGHT
-{
-    OutputSize = TRUE ;
-    SVLook = TRUE ;
-    HelpId = HID_DLG_ROWHEIGHT ;
-    Size = MAP_APPFONT ( 159 , 59 ) ;
-    Moveable = TRUE ;
-    Closeable = TRUE ;
-    FixedText FT_VALUE
-    {
-        Pos = MAP_APPFONT ( 6 , 8 ) ;
-        Size = MAP_APPFONT ( 23 , 10 ) ;
-        Text [ en-US ] = "~Height" ;
-    };
-    MetricField MF_VALUE
-    {
-        HelpID = "dbaccess:MetricField:DLG_ROWHEIGHT:MF_VALUE";
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 36 , 6 ) ;
-        Size = MAP_APPFONT ( 63 , 12 ) ;
-        TabStop = TRUE ;
-        Spin = TRUE ;
-        Minimum = 10 ;
-        Maximum = 1600 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Repeat = TRUE ;
-    };
-    CheckBox CB_STANDARD
-    {
-        HelpID = "dbaccess:CheckBox:DLG_ROWHEIGHT:CB_STANDARD";
-        Pos = MAP_APPFONT ( 36 , 25 ) ;
-        Size = MAP_APPFONT ( 62 , 12 ) ;
-        TabStop = TRUE ;
-        Text [ en-US ] = "~Automatic";
-    };
-    OKButton PB_OK
-    {
-        Pos = MAP_APPFONT ( 105 , 6 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        TabStop = TRUE ;
-        DefButton = TRUE ;
-    };
-    CancelButton PB_CANCEL
-    {
-        Pos = MAP_APPFONT ( 105 , 23 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        TabStop = TRUE ;
-    };
-    HelpButton PB_HELP
-    {
-        Pos = MAP_APPFONT ( 105 , 42 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        TabStop = TRUE ;
-    };
-    Text [ en-US ] = "Row Height" ;
-};
-ModalDialog DLG_COLWIDTH
-{
-    OutputSize = TRUE ;
-    SVLook = TRUE ;
-    HelpId = HID_DLG_COLWIDTH ;
-    Size = MAP_APPFONT ( 159 , 59 ) ;
-    Moveable = TRUE ;
-    Closeable = TRUE ;
-    FixedText FT_VALUE
-    {
-        Pos = MAP_APPFONT ( 6 , 8 ) ;
-        Size = MAP_APPFONT ( 23 , 10 ) ;
-        Text [ en-US ] = "~Width" ;
-    };
-    MetricField MF_VALUE
-    {
-        HelpID = "dbaccess:MetricField:DLG_COLWIDTH:MF_VALUE";
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 36 , 6 ) ;
-        Size = MAP_APPFONT ( 63 , 12 ) ;
-        TabStop = TRUE ;
-        Spin = TRUE ;
-        Minimum = 10 ;
-        Maximum = 20000 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Repeat = TRUE ;
-    };
-    CheckBox CB_STANDARD
-    {
-        HelpID = "dbaccess:CheckBox:DLG_COLWIDTH:CB_STANDARD";
-        Pos = MAP_APPFONT ( 36 , 25 ) ;
-        Size = MAP_APPFONT ( 62 , 12 ) ;
-        TabStop = TRUE ;
-        Text [ en-US ] = "~Automatic";
-    };
-    OKButton PB_OK
-    {
-        Pos = MAP_APPFONT ( 105 , 6 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        TabStop = TRUE ;
-        DefButton = TRUE ;
-    };
-    CancelButton PB_CANCEL
-    {
-        Pos = MAP_APPFONT ( 105 , 23 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        TabStop = TRUE ;
-    };
-    HelpButton PB_HELP
-    {
-        Pos = MAP_APPFONT ( 105 , 42 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        TabStop = TRUE ;
-    };
-    Text [ en-US ] = "Column Width" ;
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbu_resource.hrc b/dbaccess/source/ui/inc/dbu_resource.hrc
index 0eebf9c..dc0ed4f 100644
--- a/dbaccess/source/ui/inc/dbu_resource.hrc
+++ b/dbaccess/source/ui/inc/dbu_resource.hrc
@@ -83,8 +83,7 @@
 #define DLG_PARAMETERS                  RID_DIALOG_START +  5
 #define DLG_FILTERCRIT                  RID_DIALOG_START +  6
 #define DLG_ORDERCRIT                   RID_DIALOG_START +  7
-#define DLG_ROWHEIGHT                   RID_DIALOG_START +  8
-#define DLG_COLWIDTH                    RID_DIALOG_START +  9
+
 #define DLG_ATTR                        RID_DIALOG_START + 10
 #define DLG_SAVE_AS                     RID_DIALOG_START + 11
 #define DLG_JOIN_TABADD                 RID_DIALOG_START + 14
diff --git a/dbaccess/source/ui/inc/dlgsize.hxx b/dbaccess/source/ui/inc/dlgsize.hxx
index ddfcbaa..d61ca8e 100644
--- a/dbaccess/source/ui/inc/dlgsize.hxx
+++ b/dbaccess/source/ui/inc/dlgsize.hxx
@@ -39,17 +39,11 @@ namespace dbaui
     protected:
         DECL_LINK( CbClickHdl, Button * );
 
-        FixedText       aFT_VALUE;
-        MetricField     aMF_VALUE;
-        CheckBox        aCB_STANDARD;
-        OKButton        aPB_OK;
-        CancelButton    aPB_CANCEL;
-        HelpButton      aPB_HELP;
+        MetricField*    m_pMF_VALUE;
+        CheckBox*       m_pCB_STANDARD;
 
     public:
         DlgSize( Window * pParent, sal_Int32 nVal, sal_Bool bRow, sal_Int32 _nAlternativeStandard = -1 );
-        ~DlgSize();
-
         sal_Int32 GetValue();
     };
 }   // namespace dbaui
diff --git a/dbaccess/uiconfig/ui/colwidthdialog.ui b/dbaccess/uiconfig/ui/colwidthdialog.ui
new file mode 100644
index 0000000..89fe59f
--- /dev/null
+++ b/dbaccess/uiconfig/ui/colwidthdialog.ui
@@ -0,0 +1,153 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkAdjustment" id="adjustment1">
+    <property name="lower">0.10000000000000001</property>
+    <property name="upper">200</property>
+    <property name="value">2.27</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkDialog" id="ColWidthDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="title" translatable="yes">Column Width</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="can_default">True</property>
+                <property name="has_default">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>
+            <child>
+              <object class="GtkButton" id="help">
+                <property name="label">gtk-help</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">2</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="GtkGrid" id="grid2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="valign">start</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+            <property name="row_spacing">6</property>
+            <property name="column_spacing">12</property>
+            <child>
+              <object class="GtkLabel" id="label1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="xalign">0</property>
+                <property name="label" translatable="yes">_Width</property>
+                <property name="use_underline">True</property>
+                <property name="mnemonic_widget">value:0.00cm</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="GtkSpinButton" id="value:0.00cm">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="invisible_char">•</property>
+                <property name="adjustment">adjustment1</property>
+                <property name="digits">2</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="GtkCheckButton" id="automatic">
+                <property name="label" translatable="yes">_Automatic</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">False</property>
+                <property name="use_underline">True</property>
+                <property name="xalign">0</property>
+                <property name="draw_indicator">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>
+            <child>
+              <placeholder/>
+            </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-widget response="0">help</action-widget>
+    </action-widgets>
+  </object>
+</interface>
diff --git a/dbaccess/uiconfig/ui/rowheightdialog.ui b/dbaccess/uiconfig/ui/rowheightdialog.ui
new file mode 100644
index 0000000..9d98a3f
--- /dev/null
+++ b/dbaccess/uiconfig/ui/rowheightdialog.ui
@@ -0,0 +1,153 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkAdjustment" id="adjustment1">
+    <property name="lower">0.10000000000000001</property>
+    <property name="upper">160</property>
+    <property name="value">2.27</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkDialog" id="RowHeightDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="title" translatable="yes">Row Height</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="can_default">True</property>
+                <property name="has_default">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>
+            <child>
+              <object class="GtkButton" id="help">
+                <property name="label">gtk-help</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">2</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="GtkGrid" id="grid2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="valign">start</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+            <property name="row_spacing">6</property>
+            <property name="column_spacing">12</property>
+            <child>
+              <object class="GtkLabel" id="label1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="xalign">0</property>
+                <property name="label" translatable="yes">_Height</property>
+                <property name="use_underline">True</property>
+                <property name="mnemonic_widget">value:0.00cm</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="GtkSpinButton" id="value:0.00cm">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="invisible_char">•</property>
+                <property name="adjustment">adjustment1</property>
+                <property name="digits">2</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="GtkCheckButton" id="automatic">
+                <property name="label" translatable="yes">_Automatic</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">False</property>
+                <property name="use_underline">True</property>
+                <property name="xalign">0</property>
+                <property name="draw_indicator">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>
+            <child>
+              <placeholder/>
+            </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-widget response="0">help</action-widget>
+    </action-widgets>
+  </object>
+</interface>
commit c4792c86a7addb4a77301d78ac1fc11d5c2608b9
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Dec 25 21:15:21 2013 +0000

    convert grid control show columns dialog to .ui
    
    Change-Id: I5518328c2f527b910b78cb20358f4e55acf07ead

diff --git a/cui/AllLangResTarget_cui.mk b/cui/AllLangResTarget_cui.mk
index 9bf5505..16a1feb 100644
--- a/cui/AllLangResTarget_cui.mk
+++ b/cui/AllLangResTarget_cui.mk
@@ -40,7 +40,6 @@ $(eval $(call gb_SrsTarget_add_files,cui/res,\
     cui/source/dialogs/multipat.src \
     cui/source/dialogs/passwdomdlg.src \
     cui/source/dialogs/scriptdlg.src \
-    cui/source/dialogs/showcols.src \
     cui/source/dialogs/srchxtra.src \
     cui/source/dialogs/svuidlg.src \
     cui/source/options/certpath.src \
diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index d2bb6c6..b508acc 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -131,6 +131,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/securityoptionsdialog \
 	cui/uiconfig/ui/select_persona_dialog \
 	cui/uiconfig/ui/shadowtabpage \
+	cui/uiconfig/ui/showcoldialog \
 	cui/uiconfig/ui/similaritysearchdialog \
 	cui/uiconfig/ui/slantcornertabpage \
 	cui/uiconfig/ui/specialcharacters \
diff --git a/cui/source/dialogs/fmsearch.hrc b/cui/source/dialogs/fmsearch.hrc
index 3b65fdb..5403f5f 100644
--- a/cui/source/dialogs/fmsearch.hrc
+++ b/cui/source/dialogs/fmsearch.hrc
@@ -21,7 +21,6 @@
 
 #include "svl/solar.hrc"
 
-#define RID_SVX_DLG_SHOWGRIDCOLUMNS                 (RID_FORMS_START + 11)
 #define RID_SVXDLG_SEARCHFORM                       (RID_FORMS_START + 7)
 #define RID_STR_SEARCH_ANYWHERE                     (RID_FORMS_START +  85)
 #define RID_STR_SEARCH_BEGINNING                    (RID_FORMS_START +  86)
diff --git a/cui/source/dialogs/showcols.cxx b/cui/source/dialogs/showcols.cxx
index 7bce6ac..599cd1c 100644
--- a/cui/source/dialogs/showcols.cxx
+++ b/cui/source/dialogs/showcols.cxx
@@ -36,23 +36,14 @@
 DBG_NAME(FmShowColsDialog)
 //--------------------------------------------------------------------------
 FmShowColsDialog::FmShowColsDialog(Window* pParent)
-    :ModalDialog(pParent, CUI_RES(RID_SVX_DLG_SHOWGRIDCOLUMNS))
-    ,m_aList(this, CUI_RES(1))
-    ,m_aLabel(this, CUI_RES(1))
-    ,m_aOK(this, CUI_RES(1))
-    ,m_aCancel(this, CUI_RES(1))
+    : ModalDialog(pParent, "ShowColDialog", "cui/ui/showcoldialog.ui")
 {
-    DBG_CTOR(FmShowColsDialog,NULL);
-    m_aList.EnableMultiSelection(sal_True);
-    m_aOK.SetClickHdl( LINK( this, FmShowColsDialog, OnClickedOk ) );
-
-    FreeResource();
-}
-
-//--------------------------------------------------------------------------
-FmShowColsDialog::~FmShowColsDialog()
-{
-    DBG_DTOR(FmShowColsDialog,NULL);
+    get(m_pOK, "ok");
+    get(m_pList, "treeview");
+    m_pList->set_height_request(m_pList->GetTextHeight() * 8);
+    m_pList->set_width_request(m_pList->approximate_char_width() * 56);
+    m_pList->EnableMultiSelection(true);
+    m_pOK->SetClickHdl( LINK( this, FmShowColsDialog, OnClickedOk ) );
 }
 
 //--------------------------------------------------------------------------
@@ -62,9 +53,9 @@ IMPL_LINK_NOARG(FmShowColsDialog, OnClickedOk)
     if (m_xColumns.is())
     {
         ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > xCol;
-        for (sal_uInt16 i=0; i<m_aList.GetSelectEntryCount(); ++i)
+        for (sal_uInt16 i=0; i < m_pList->GetSelectEntryCount(); ++i)
         {
-            m_xColumns->getByIndex(sal::static_int_cast<sal_Int32>(reinterpret_cast<sal_uIntPtr>(m_aList.GetEntryData(m_aList.GetSelectEntryPos(i))))) >>= xCol;
+            m_xColumns->getByIndex(sal::static_int_cast<sal_Int32>(reinterpret_cast<sal_uIntPtr>(m_pList->GetEntryData(m_pList->GetSelectEntryPos(i))))) >>= xCol;
             if (xCol.is())
             {
                 try
@@ -91,7 +82,7 @@ void FmShowColsDialog::SetColumns(const ::com::sun::star::uno::Reference< ::com:
         return;
     m_xColumns = xCols.get();
 
-    m_aList.Clear();
+    m_pList->Clear();
 
     ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet>  xCurCol;
     OUString sCurName;
@@ -116,7 +107,7 @@ void FmShowColsDialog::SetColumns(const ::com::sun::star::uno::Reference< ::com:
 
         // if the col is hidden, put it into the list
         if (bIsHidden)
-            m_aList.SetEntryData( m_aList.InsertEntry(sCurName), reinterpret_cast<void*>((sal_Int64)i) );
+            m_pList->SetEntryData( m_pList->InsertEntry(sCurName), reinterpret_cast<void*>((sal_Int64)i) );
     }
 }
 
diff --git a/cui/source/dialogs/showcols.src b/cui/source/dialogs/showcols.src
deleted file mode 100644
index f8bd455..0000000
--- a/cui/source/dialogs/showcols.src
+++ /dev/null
@@ -1,68 +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/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "fmsearch.hrc"
-
-ModalDialog RID_SVX_DLG_SHOWGRIDCOLUMNS
-{
-    HelpID = "cui:ModalDialog:RID_SVX_DLG_SHOWGRIDCOLUMNS";
-    OutputSize = TRUE;
-    SVLook = TRUE ;
-    Size = MAP_APPFONT( 200, 117 );
-    Moveable = TRUE;
-    Closeable = TRUE;
-
-    FixedText 1
-    {
-        Pos = MAP_APPFONT( 6, 6 );
-        Size = MAP_APPFONT( 188, 30 );
-        WordBreak = TRUE;
-        Text [ en-US ] = "The following columns are currently hidden. Please mark the fields you want to show and choose OK.";
-    };
-
-    ListBox 1
-    {
-        HelpID = "cui:ListBox:RID_SVX_DLG_SHOWGRIDCOLUMNS:1";
-        Border = TRUE;
-        Pos = MAP_APPFONT( 6, 39 );
-        Size = MAP_APPFONT( 188, 55 );
-        TabStop = TRUE;
-        DropDown = FALSE;
-        AutoHScroll = TRUE;
-        VScroll = TRUE;
-    };
-
-    OKButton 1
-    {
-        Pos = MAP_APPFONT( 6, 97 );
-        Size = MAP_APPFONT( 50, 14 );
-        TabStop = TRUE;
-        DefButton = TRUE ;
-    };
-
-    CancelButton 1
-    {
-        Pos = MAP_APPFONT( 144, 97 );
-        Size = MAP_APPFONT( 50, 14 );
-        TabStop = TRUE;
-    };
-    Text [ en-US ] = "Show columns";
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/inc/showcols.hxx b/cui/source/inc/showcols.hxx
index aca17dd..65ee785 100644
--- a/cui/source/inc/showcols.hxx
+++ b/cui/source/inc/showcols.hxx
@@ -35,16 +35,13 @@
 
 class FmShowColsDialog : public ModalDialog
 {
-    ListBox         m_aList;
-    FixedText       m_aLabel;
-    OKButton        m_aOK;
-    CancelButton    m_aCancel;
+    ListBox*        m_pList;
+    OKButton*       m_pOK;
 
     ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >   m_xColumns;
 
 public:
-    FmShowColsDialog( Window* pParent );
-    virtual ~FmShowColsDialog();
+    FmShowColsDialog(Window* pParent);
 
     void SetColumns(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexContainer>& xCols);
 
diff --git a/cui/uiconfig/ui/showcoldialog.ui b/cui/uiconfig/ui/showcoldialog.ui
new file mode 100644
index 0000000..ee1a23b
--- /dev/null
+++ b/cui/uiconfig/ui/showcoldialog.ui
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkDialog" id="ShowColDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="title" translatable="yes">Show columns</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="can_default">True</property>
+                <property name="has_default">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="GtkGrid" id="grid1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+            <property name="row_spacing">6</property>
+            <child>
+              <object class="GtkLabel" id="label1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="xalign">0</property>
+                <property name="label" translatable="yes">The following columns are currently hidden. Please mark the fields you want to show and choose OK.</property>
+                <property name="use_underline">True</property>
+                <property name="wrap">True</property>
+                <property name="mnemonic_widget">treeview:border</property>
+                <property name="max_width_chars">56</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="GtkTreeView" id="treeview:border">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="vexpand">True</property>
+                <child internal-child="selection">
+                  <object class="GtkTreeSelection" id="treeview-selection1"/>
+                </child>
+              </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>
+          </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>
commit 0f19e2897ba8c3c60ae36f231badcf7969fb9dbe
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Dec 25 21:39:50 2013 +0000

    Updated core
    Project: help  07e930aa8406a8a85ffe7b3cb08b97f9d7747687

diff --git a/helpcontent2 b/helpcontent2
index 0dc1069..07e930a 160000
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 0dc1069fa953547ac90aebf058b6ff18a83e820f
+Subproject commit 07e930aa8406a8a85ffe7b3cb08b97f9d7747687


More information about the Libreoffice-commits mailing list