[Libreoffice-commits] core.git: 3 commits - sw/uiconfig vcl/inc vcl/source xmlsecurity/inc xmlsecurity/source xmlsecurity/uiconfig xmlsecurity/UI_xmlsec.mk

Caolán McNamara caolanm at redhat.com
Thu Feb 14 01:51:54 PST 2013


 sw/uiconfig/swriter/ui/macrosecurity.ui        |  498 -------------------------
 vcl/inc/unx/gtk/gtkframe.hxx                   |    4 
 vcl/inc/vcl/tabpage.hxx                        |    2 
 vcl/source/window/builder.cxx                  |   14 
 xmlsecurity/UI_xmlsec.mk                       |    2 
 xmlsecurity/inc/xmlsecurity/macrosecurity.hxx  |   30 -
 xmlsecurity/source/dialogs/dialogs.hrc         |   21 -
 xmlsecurity/source/dialogs/helpids.hrc         |    1 
 xmlsecurity/source/dialogs/macrosecurity.cxx   |   81 ++--
 xmlsecurity/source/dialogs/macrosecurity.src   |   52 --
 xmlsecurity/uiconfig/ui/macrosecuritydialog.ui |  394 +++++++++++++++++++
 xmlsecurity/uiconfig/ui/securitylevelpage.ui   |  149 +++++++
 12 files changed, 619 insertions(+), 629 deletions(-)

New commits:
commit 2848277180b9cb6dde639001a0f9612af5bd5992
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Feb 13 23:43:32 2013 +0000

    move macro security dialog to xmlsecurity
    
    split out security page and adapt code
    
    Change-Id: I51dbd48b2ff4f65f6806fac70bda27ee15d4e176

diff --git a/sw/uiconfig/swriter/ui/macrosecurity.ui b/sw/uiconfig/swriter/ui/macrosecurity.ui
deleted file mode 100644
index 9d44ddc..0000000
--- a/sw/uiconfig/swriter/ui/macrosecurity.ui
+++ /dev/null
@@ -1,498 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<interface>
-  <!-- interface-requires gtk+ 3.0 -->
-  <object class="GtkDialog" id="Macro Security">
-    <property name="can_focus">False</property>
-    <property name="border_width">5</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">2</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="use_action_appearance">False</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</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="use_action_appearance">False</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</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="use_action_appearance">False</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</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" translatable="yes">~Reset</property>
-                <property name="use_action_appearance">False</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</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="notebook1">
-            <property name="visible">True</property>
-            <property name="can_focus">True</property>
-            <child>
-              <object class="GtkBox" id="box1">
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <property name="orientation">vertical</property>
-                <property name="spacing">12</property>
-                <child>
-                  <object class="GtkRadioButton" id="radiobutton1">
-                    <property name="label" translatable="yes">~Very high.
-Only macros from trusted file locations are allowed to run. All other macros,
-regardless whether signed or not,are disabled.</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="expand">False</property>
-                    <property name="fill">True</property>
-                    <property name="position">0</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="radiobutton2">
-                    <property name="label" translatable="yes">H~igh.
-Only Signed macros from trusted sources are allowed to run. Unsigned macros
-are disabled.</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="expand">False</property>
-                    <property name="fill">True</property>
-                    <property name="position">1</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="radiobutton3">
-                    <property name="label" translatable="yes">~Medium.
-Confirmation required before executing macros from untrusted sources.</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="expand">False</property>
-                    <property name="fill">True</property>
-                    <property name="position">2</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="radiobutton4">
-                    <property name="label" translatable="yes">~Low(not recommended).
-All macros will be executed without confirmation. Use this setting only if you
-are certain that all document that will be opened are safe.</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="use_action_appearance">False</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="expand">False</property>
-                    <property name="fill">True</property>
-                    <property name="position">3</property>
-                  </packing>
-                </child>
-              </object>
-            </child>
-            <child type="tab">
-              <object class="GtkLabel" id="label1">
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <property name="label" translatable="yes">Security Level</property>
-                <attributes>
-                  <attribute name="weight" value="bold"/>
-                </attributes>
-              </object>
-              <packing>
-                <property name="tab_fill">False</property>
-              </packing>
-            </child>
-            <child>
-              <object class="GtkBox" id="box2">
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <property name="orientation">vertical</property>
-                <property name="spacing">6</property>
-                <child>
-                  <object class="GtkFrame" id="frame1">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="label_xalign">0</property>
-                    <property name="shadow_type">none</property>
-                    <child>
-                      <object class="GtkAlignment" id="alignment1">
-                        <property name="visible">True</property>
-                        <property name="can_focus">False</property>
-                        <property name="left_padding">12</property>
-                        <child>
-                          <object class="GtkGrid" id="grid1">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="margin_top">6</property>
-                            <property name="row_spacing">6</property>
-                            <property name="column_spacing">6</property>
-                            <child>
-                              <object class="GtkScrolledWindow" id="scrolledwindow1">
-                                <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="shadow_type">in</property>
-                                <child>
-                                  <placeholder/>
-                                </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>
-                            <child>
-                              <object class="GtkButtonBox" id="buttonbox1">
-                                <property name="visible">True</property>
-                                <property name="can_focus">False</property>
-                                <property name="spacing">12</property>
-                                <property name="layout_style">end</property>
-                                <child>
-                                  <object class="GtkButton" id="button5">
-                                    <property name="label" translatable="yes">~View...</property>
-                                    <property name="use_action_appearance">False</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">True</property>
-                                    <property name="receives_default">True</property>
-                                    <property name="use_action_appearance">False</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="button6">
-                                    <property name="label">gtk-remove</property>
-                                    <property name="use_action_appearance">False</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">True</property>
-                                    <property name="receives_default">True</property>
-                                    <property name="use_action_appearance">False</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="left_attach">0</property>
-                                <property name="top_attach">2</property>
-                                <property name="width">1</property>
-                                <property name="height">1</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkGrid" id="grid2">
-                                <property name="visible">True</property>
-                                <property name="can_focus">False</property>
-                                <child>
-                                  <object class="GtkLabel" id="label5">
-                                    <property name="width_request">150</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">False</property>
-                                    <property name="xalign">0</property>
-                                    <property name="label" translatable="yes">Issued to</property>
-                                  </object>
-                                  <packing>
-                                    <property name="left_attach">0</property>
-                                    <property name="top_attach">0</property>
-                                    <property name="width">1</property>
-                                    <property name="height">1</property>
-                                  </packing>
-                                </child>
-                                <child>
-                                  <object class="GtkLabel" id="label6">
-                                    <property name="width_request">150</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">False</property>
-                                    <property name="xalign">0</property>
-                                    <property name="label" translatable="yes">issued by</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="GtkLabel" id="label7">
-                                    <property name="width_request">150</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">False</property>
-                                    <property name="xalign">0</property>
-                                    <property name="label" translatable="yes">Expiration date</property>
-                                  </object>
-                                  <packing>
-                                    <property name="left_attach">2</property>
-                                    <property name="top_attach">0</property>
-                                    <property name="width">1</property>
-                                    <property name="height">1</property>
-                                  </packing>
-                                </child>
-                              </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>
-                          </object>
-                        </child>
-                      </object>
-                    </child>
-                    <child type="label">
-                      <object class="GtkLabel" id="label3">
-                        <property name="visible">True</property>
-                        <property name="can_focus">False</property>
-                        <property name="label" translatable="yes">Trusted certificates</property>
-                      </object>
-                    </child>
-                  </object>
-                  <packing>
-                    <property name="expand">False</property>
-                    <property name="fill">True</property>
-                    <property name="position">0</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkFrame" id="frame2">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="label_xalign">0</property>
-                    <property name="shadow_type">none</property>
-                    <child>
-                      <object class="GtkAlignment" id="alignment2">
-                        <property name="visible">True</property>
-                        <property name="can_focus">False</property>
-                        <property name="left_padding">12</property>
-                        <child>
-                          <object class="GtkGrid" id="grid3">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="margin_top">6</property>
-                            <property name="row_spacing">12</property>
-                            <child>
-                              <object class="GtkLabel" id="label8">
-                                <property name="visible">True</property>
-                                <property name="can_focus">False</property>
-                                <property name="label" translatable="yes">Document macros are always executed if they have been opened from one of the
-following locations.</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="GtkScrolledWindow" id="scrolledwindow2">
-                                <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="shadow_type">in</property>
-                                <child>
-                                  <placeholder/>
-                                </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>
-                            <child>
-                              <object class="GtkButtonBox" id="buttonbox2">
-                                <property name="visible">True</property>
-                                <property name="can_focus">False</property>
-                                <property name="spacing">12</property>
-                                <property name="layout_style">end</property>
-                                <child>
-                                  <object class="GtkButton" id="button7">
-                                    <property name="label">gtk-add</property>
-                                    <property name="use_action_appearance">False</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">True</property>
-                                    <property name="receives_default">True</property>
-                                    <property name="use_action_appearance">False</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="button8">
-                                    <property name="label">gtk-remove</property>
-                                    <property name="use_action_appearance">False</property>
-                                    <property name="visible">True</property>
-                                    <property name="can_focus">True</property>
-                                    <property name="receives_default">True</property>
-                                    <property name="use_action_appearance">False</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="left_attach">0</property>
-                                <property name="top_attach">2</property>
-                                <property name="width">1</property>
-                                <property name="height">1</property>
-                              </packing>
-                            </child>
-                          </object>
-                        </child>
-                      </object>
-                    </child>
-                    <child type="label">
-                      <object class="GtkLabel" id="label4">
-                        <property name="visible">True</property>
-                        <property name="can_focus">False</property>
-                        <property name="label" translatable="yes">Trusted file locations</property>
-                      </object>
-                    </child>
-                  </object>
-                  <packing>
-                    <property name="expand">False</property>
-                    <property name="fill">True</property>
-                    <property name="position">1</property>
-                  </packing>
-                </child>
-              </object>
-              <packing>
-                <property name="position">1</property>
-              </packing>
-            </child>
-            <child type="tab">
-              <object class="GtkLabel" id="label2">
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <property name="label" translatable="yes">Trusted Sources</property>
-                <attributes>
-                  <attribute name="weight" value="bold"/>
-                </attributes>
-              </object>
-              <packing>
-                <property name="position">1</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/xmlsecurity/UI_xmlsec.mk b/xmlsecurity/UI_xmlsec.mk
index c9c7232..69f1b2b 100644
--- a/xmlsecurity/UI_xmlsec.mk
+++ b/xmlsecurity/UI_xmlsec.mk
@@ -11,7 +11,9 @@ $(eval $(call gb_UI_UI,xmlsec))
 
 $(eval $(call gb_UI_add_uifiles,xmlsec,\
 	xmlsecurity/uiconfig/ui/digitalsignaturesdialog \
+	xmlsecurity/uiconfig/ui/securitylevelpage \
 	xmlsecurity/uiconfig/ui/selectcertificatedialog \
+	xmlsecurity/uiconfig/ui/macrosecuritydialog \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/xmlsecurity/inc/xmlsecurity/macrosecurity.hxx b/xmlsecurity/inc/xmlsecurity/macrosecurity.hxx
index 9450ffa..4611f05 100644
--- a/xmlsecurity/inc/xmlsecurity/macrosecurity.hxx
+++ b/xmlsecurity/inc/xmlsecurity/macrosecurity.hxx
@@ -89,29 +89,27 @@ class MacroSecurityTP : public TabPage
 protected:
     MacroSecurity*      mpDlg;
 public:
-                        MacroSecurityTP( Window* _pParent, const ResId& _rResId, MacroSecurity* _pDlg );
-    inline void         SetTabDlg( MacroSecurity* pTabDlg );
+    MacroSecurityTP(Window* _pParent, const OString& rID,
+        const OUString& rUIXMLDescription, MacroSecurity* _pDlg);
+    MacroSecurityTP(Window* _pParent, const ResId& _rResId, MacroSecurity* _pDlg);
+
+    void SetTabDlg(MacroSecurity* pTabDlg)
+    {
+        mpDlg = pTabDlg;
+    }
 
     virtual void        ClosePage( void ) = 0;
 };
 
-inline void MacroSecurityTP::SetTabDlg( MacroSecurity* _pTabDlg )
-{
-    mpDlg = _pTabDlg;
-}
-
-
 class MacroSecurityLevelTP : public MacroSecurityTP
 {
 private:
-    FixedLine           maSecLevelFL;
-    ReadOnlyImage       maSecReadonlyFI;
-    RadioButton         maVeryHighRB;
-    RadioButton         maHighRB;
-    RadioButton         maMediumRB;
-    RadioButton         maLowRB;
-
-    sal_uInt16              mnCurLevel;
+    RadioButton* m_pVeryHighRB;
+    RadioButton* m_pHighRB;
+    RadioButton* m_pMediumRB;
+    RadioButton* m_pLowRB;
+
+    sal_uInt16   mnCurLevel;
 
 protected:
     DECL_LINK(RadioButtonHdl, void *);
diff --git a/xmlsecurity/source/dialogs/dialogs.hrc b/xmlsecurity/source/dialogs/dialogs.hrc
index ea6097a..cfc4acd 100644
--- a/xmlsecurity/source/dialogs/dialogs.hrc
+++ b/xmlsecurity/source/dialogs/dialogs.hrc
@@ -175,27 +175,6 @@
 #define MS_COL_G                        (MS_COL_F-RSC_SP_CTRL_X)
 #define MS_COL_H                        (MS_COL_G-RSC_CD_PUSHBUTTON_WIDTH)
 
-// --------- tab page security level ---------
-
-#define FL_SECLEVEL                     1
-#define RB_VERYHIGH                     2
-#define RB_HIGH                         3
-#define RB_MEDIUM                       4
-#define RB_LOW                          5
-#define FI_SEC_READONLY                 6
-
-#define RSC_BIG_RADIOBUTTON             40
-#define SL_RB_DIST_Y                    (RSC_SP_FLGR_SPACE_Y+RSC_BIG_RADIOBUTTON)
-#define SL_COL_0                        RSC_SP_TBPG_INNERBORDER_LEFT
-#define SL_COL_1                        (SL_COL_0+RSC_SP_FLGR_SPACE_X)
-#define SL_COL_3                        (TP_WIDTH-RSC_SP_TBPG_INNERBORDER_RIGHT)
-#define SL_COL_2                        ((SL_COL_3-SL_COL_1)*100/105)
-#define SL_ROW_0                        RSC_SP_TBPG_INNERBORDER_TOP
-#define SL_ROW_1                        (SL_ROW_0+SL_RB_DIST_Y)
-#define SL_ROW_2                        (SL_ROW_1+SL_RB_DIST_Y)
-#define SL_ROW_3                        (SL_ROW_2+SL_RB_DIST_Y)
-#define SL_ROW_4                        (TP_HEIGHT-RSC_SP_TBPG_INNERBORDER_BOTTOM)
-
 // --------- tab page trusted sources ---------
 
 #define FL_TRUSTCERT                    1
diff --git a/xmlsecurity/source/dialogs/helpids.hrc b/xmlsecurity/source/dialogs/helpids.hrc
index 8a3dde5..0818b82 100644
--- a/xmlsecurity/source/dialogs/helpids.hrc
+++ b/xmlsecurity/source/dialogs/helpids.hrc
@@ -24,7 +24,6 @@
 // Help-Ids --------------------------------------------------------------
 
 #define HID_XMLSEC_TP_MACROSEC                         "XMLSECURITY_HID_XMLSEC_TP_MACROSEC"
-#define HID_XMLSEC_TP_SECLEVEL                         "XMLSECURITY_HID_XMLSEC_TP_SECLEVEL"
 #define HID_XMLSEC_TP_TRUSTSOURCES                     "XMLSECURITY_HID_XMLSEC_TP_TRUSTSOURCES"
 #define HID_XMLSEC_DLG_CERTVIEWER                      "XMLSECURITY_HID_XMLSEC_DLG_CERTVIEWER"
 #define HID_XMLSEC_TP_GENERAL                          "XMLSECURITY_HID_XMLSEC_TP_GENERAL"
diff --git a/xmlsecurity/source/dialogs/macrosecurity.cxx b/xmlsecurity/source/dialogs/macrosecurity.cxx
index f87160f..53df445 100644
--- a/xmlsecurity/source/dialogs/macrosecurity.cxx
+++ b/xmlsecurity/source/dialogs/macrosecurity.cxx
@@ -91,6 +91,12 @@ MacroSecurity::~MacroSecurity()
     delete maTabCtrl.GetTabPage( RID_XMLSECTP_SECLEVEL );
 }
 
+MacroSecurityTP::MacroSecurityTP(Window* _pParent, const OString& rID,
+    const OUString& rUIXMLDescription, MacroSecurity* _pDlg)
+    : TabPage(_pParent, rID, rUIXMLDescription)
+    , mpDlg(_pDlg)
+{
+}
 
 MacroSecurityTP::MacroSecurityTP( Window* _pParent, const ResId& _rResId, MacroSecurity* _pDlg )
     :TabPage        ( _pParent, _rResId )
@@ -98,66 +104,67 @@ MacroSecurityTP::MacroSecurityTP( Window* _pParent, const ResId& _rResId, MacroS
 {
 }
 
-MacroSecurityLevelTP::MacroSecurityLevelTP( Window* _pParent, MacroSecurity* _pDlg )
-    :MacroSecurityTP    ( _pParent, XMLSEC_RES( RID_XMLSECTP_SECLEVEL ), _pDlg )
-    ,maSecLevelFL       ( this, XMLSEC_RES( FL_SECLEVEL ) )
-    ,maSecReadonlyFI    ( this, XMLSEC_RES( FI_SEC_READONLY ))
-    ,maVeryHighRB       ( this, XMLSEC_RES( RB_VERYHIGH ) )
-    ,maHighRB           ( this, XMLSEC_RES( RB_HIGH ) )
-    ,maMediumRB         ( this, XMLSEC_RES( RB_MEDIUM ) )
-    ,maLowRB            ( this, XMLSEC_RES( RB_LOW ) )
+MacroSecurityLevelTP::MacroSecurityLevelTP(Window* _pParent, MacroSecurity* _pDlg)
+    : MacroSecurityTP(_pParent, "SecurityLevelPage", "xmlsec/ui/securitylevelpage.ui", _pDlg)
 {
-    FreeResource();
+    get(m_pVeryHighRB, "vhigh");
+    get(m_pHighRB, "high");
+    get(m_pMediumRB, "med");
+    get(m_pLowRB, "low");
 
-    maLowRB.SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
-    maMediumRB.SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
-    maHighRB.SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
-    maVeryHighRB.SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
+    m_pLowRB->SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
+    m_pMediumRB->SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
+    m_pHighRB->SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
+    m_pVeryHighRB->SetClickHdl( LINK( this, MacroSecurityLevelTP, RadioButtonHdl ) );
 
     mnCurLevel = (sal_uInt16) mpDlg->maSecOptions.GetMacroSecurityLevel();
     sal_Bool bReadonly = mpDlg->maSecOptions.IsReadOnly( SvtSecurityOptions::E_MACRO_SECLEVEL );
 
     RadioButton* pCheck = 0;
-    switch( mnCurLevel )
+    FixedImage* pImage = 0;
+    switch (mnCurLevel)
     {
-        case 3: pCheck = &maVeryHighRB;   break;
-        case 2: pCheck = &maHighRB;       break;
-        case 1: pCheck = &maMediumRB;     break;
-        case 0: pCheck = &maLowRB;        break;
+        case 3:
+            pCheck = m_pVeryHighRB;
+            pImage = get<FixedImage>("vhighimg");
+            break;
+        case 2:
+            pCheck = m_pHighRB;
+            pImage = get<FixedImage>("highimg");
+            break;
+        case 1:
+            pCheck = m_pMediumRB;
+            pImage = get<FixedImage>("medimg");
+            break;
+        case 0:
+            pCheck = m_pLowRB;
+            pImage = get<FixedImage>("lowimg");
+            break;
     }
-    if(pCheck)
+    if (pCheck)
         pCheck->Check();
     else
     {
         OSL_FAIL("illegal macro security level");
     }
-    maSecReadonlyFI.Show(bReadonly);
-    if(bReadonly)
+    if (bReadonly)
     {
-        //move to the selected button
-        if( pCheck && pCheck != &maVeryHighRB)
-        {
-            long nDiff = pCheck->GetPosPixel().Y() - maVeryHighRB.GetPosPixel().Y();
-            Point aPos(maSecReadonlyFI.GetPosPixel());
-            aPos.Y() += nDiff;
-            maSecReadonlyFI.SetPosPixel(aPos);
-        }
-        maVeryHighRB.Enable(sal_False);
-        maHighRB.Enable(sal_False);
-        maMediumRB.Enable(sal_False);
-        maLowRB.Enable(sal_False);
+        pImage->Show(true);
+        m_pVeryHighRB->Enable(false);
+        m_pHighRB->Enable(false);
+        m_pMediumRB->Enable(false);
+        m_pLowRB->Enable(false);
     }
-
 }
 
 IMPL_LINK_NOARG(MacroSecurityLevelTP, RadioButtonHdl)
 {
     sal_uInt16 nNewLevel = 0;
-    if( maVeryHighRB.IsChecked() )
+    if( m_pVeryHighRB->IsChecked() )
         nNewLevel = 3;
-    else if( maHighRB.IsChecked() )
+    else if( m_pHighRB->IsChecked() )
         nNewLevel = 2;
-    else if( maMediumRB.IsChecked() )
+    else if( m_pMediumRB->IsChecked() )
         nNewLevel = 1;
 
     if ( nNewLevel != mnCurLevel )
diff --git a/xmlsecurity/source/dialogs/macrosecurity.src b/xmlsecurity/source/dialogs/macrosecurity.src
index 8d04f80..a1a6fcd 100644
--- a/xmlsecurity/source/dialogs/macrosecurity.src
+++ b/xmlsecurity/source/dialogs/macrosecurity.src
@@ -72,58 +72,6 @@ TabDialog RID_XMLSECTP_MACROSEC
     };
 };
 
-TabPage RID_XMLSECTP_SECLEVEL
-{
-    HelpId = HID_XMLSEC_TP_SECLEVEL;
-    Size = MAP_APPFONT( TP_WIDTH, TP_HEIGHT );
-    OutputSize = TRUE;
-    Hide = TRUE;
-    SVLook = TRUE;
-    FixedLine FL_SECLEVEL
-    {
-        Pos = MAP_APPFONT( SL_COL_0, SL_ROW_0 );
-        Size = MAP_APPFONT( SL_COL_3-SL_COL_0, RSC_CD_FIXEDLINE_HEIGHT );
-        Hide = TRUE;
-    };
-    FixedImage FI_SEC_READONLY
-    {
-        Pos = MAP_APPFONT( SL_COL_1 - 7, SL_ROW_0 + 4 );
-        Size = MAP_APPFONT( 6, 6 );
-    };
-    RadioButton RB_VERYHIGH
-    {
-        HelpID = "xmlsecurity:RadioButton:RID_XMLSECTP_SECLEVEL:RB_VERYHIGH";
-        Pos = MAP_APPFONT( SL_COL_1, SL_ROW_0 );
-        Size = MAP_APPFONT( SL_COL_2-SL_COL_1, RSC_BIG_RADIOBUTTON );
-        WordBreak = TRUE;
-        Text [ en-US ] = "~Very high.\nOnly macros from trusted file locations are allowed to run. All other macros, regardless whether signed or not, are disabled.";
-    };
-    RadioButton RB_HIGH
-    {
-        HelpID = "xmlsecurity:RadioButton:RID_XMLSECTP_SECLEVEL:RB_HIGH";
-        Pos = MAP_APPFONT( SL_COL_1, SL_ROW_1 );
-        Size = MAP_APPFONT( SL_COL_2-SL_COL_1, RSC_BIG_RADIOBUTTON );
-        WordBreak = TRUE;
-        Text [ en-US ] = "H~igh.\nOnly signed macros from trusted sources are allowed to run. Unsigned macros are disabled.";
-    };
-    RadioButton RB_MEDIUM
-    {
-        HelpID = "xmlsecurity:RadioButton:RID_XMLSECTP_SECLEVEL:RB_MEDIUM";
-        Pos = MAP_APPFONT( SL_COL_1, SL_ROW_2 );
-        Size = MAP_APPFONT( SL_COL_2-SL_COL_1, RSC_BIG_RADIOBUTTON );
-        WordBreak = TRUE;
-        Text [ en-US ] = "~Medium.\nConfirmation required before executing macros from untrusted sources.";
-    };
-    RadioButton RB_LOW
-    {
-        HelpID = "xmlsecurity:RadioButton:RID_XMLSECTP_SECLEVEL:RB_LOW";
-        Pos = MAP_APPFONT( SL_COL_1, SL_ROW_3 );
-        Size = MAP_APPFONT( SL_COL_2-SL_COL_1, SL_ROW_4-SL_ROW_3 );
-        WordBreak = TRUE;
-        Text [ en-US ] = "~Low (not recommended).\nAll macros will be executed without confirmation. Use this setting only if you are certain that all documents that will be opened are safe.";
-    };
-};
-
 TabPage RID_XMLSECTP_TRUSTSOURCES
 {
     HelpId = HID_XMLSEC_TP_TRUSTSOURCES;
diff --git a/xmlsecurity/uiconfig/ui/macrosecuritydialog.ui b/xmlsecurity/uiconfig/ui/macrosecuritydialog.ui
new file mode 100644
index 0000000..7d803d0
--- /dev/null
+++ b/xmlsecurity/uiconfig/ui/macrosecuritydialog.ui
@@ -0,0 +1,394 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkDialog" id="MacroSecurityDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">5</property>
+    <property name="title" translatable="yes">Macro Security</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">2</property>
+        <child internal-child="action_area">
+          <object class="GtkButtonBox" id="dialog-action_area1">
+            <property name="can_focus">False</property>
+            <property name="layout_style">end</property>
+            <child>
+              <object class="GtkButton" id="ok">
+                <property name="label">gtk-ok</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="cancel">
+                <property name="label">gtk-cancel</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+            <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" translatable="yes">~Reset</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">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="notebook1">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <child>
+              <placeholder/>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="SecurityLevelPage">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Security Level</property>
+              </object>
+              <packing>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkBox" id="box2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="border_width">6</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">6</property>
+                <child>
+                  <object class="GtkFrame" id="frame1">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="label_xalign">0</property>
+                    <property name="shadow_type">none</property>
+                    <child>
+                      <object class="GtkAlignment" id="alignment1">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="left_padding">12</property>
+                        <child>
+                          <object class="GtkGrid" id="grid1">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="margin_top">6</property>
+                            <property name="row_spacing">6</property>
+                            <property name="column_spacing">6</property>
+                            <child>
+                              <object class="GtkScrolledWindow" id="scrolledwindow1">
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="shadow_type">in</property>
+                                <child>
+                                  <placeholder/>
+                                </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>
+                            <child>
+                              <object class="GtkButtonBox" id="buttonbox1">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="spacing">12</property>
+                                <property name="layout_style">end</property>
+                                <child>
+                                  <object class="GtkButton" id="button5">
+                                    <property name="label" translatable="yes">~View...</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">True</property>
+                                    <property name="receives_default">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="button6">
+                                    <property name="label">gtk-remove</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="left_attach">0</property>
+                                <property name="top_attach">2</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkGrid" id="grid2">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <child>
+                                  <object class="GtkLabel" id="label5">
+                                    <property name="width_request">150</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">False</property>
+                                    <property name="xalign">0</property>
+                                    <property name="label" translatable="yes">Issued to</property>
+                                  </object>
+                                  <packing>
+                                    <property name="left_attach">0</property>
+                                    <property name="top_attach">0</property>
+                                    <property name="width">1</property>
+                                    <property name="height">1</property>
+                                  </packing>
+                                </child>
+                                <child>
+                                  <object class="GtkLabel" id="label6">
+                                    <property name="width_request">150</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">False</property>
+                                    <property name="xalign">0</property>
+                                    <property name="label" translatable="yes">issued by</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="GtkLabel" id="label7">
+                                    <property name="width_request">150</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">False</property>
+                                    <property name="xalign">0</property>
+                                    <property name="label" translatable="yes">Expiration date</property>
+                                  </object>
+                                  <packing>
+                                    <property name="left_attach">2</property>
+                                    <property name="top_attach">0</property>
+                                    <property name="width">1</property>
+                                    <property name="height">1</property>
+                                  </packing>
+                                </child>
+                              </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>
+                          </object>
+                        </child>
+                      </object>
+                    </child>
+                    <child type="label">
+                      <object class="GtkLabel" id="label3">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="label" translatable="yes">Trusted certificates</property>
+                      </object>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkFrame" id="frame2">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="label_xalign">0</property>
+                    <property name="shadow_type">none</property>
+                    <child>
+                      <object class="GtkAlignment" id="alignment2">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="left_padding">12</property>
+                        <child>
+                          <object class="GtkGrid" id="grid3">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="margin_top">6</property>
+                            <property name="row_spacing">12</property>
+                            <child>
+                              <object class="GtkLabel" id="label8">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="label" translatable="yes">Document macros are always executed if they have been opened from one of the
+following locations.</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="GtkScrolledWindow" id="scrolledwindow2">
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="shadow_type">in</property>
+                                <child>
+                                  <placeholder/>
+                                </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>
+                            <child>
+                              <object class="GtkButtonBox" id="buttonbox2">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="spacing">12</property>
+                                <property name="layout_style">end</property>
+                                <child>
+                                  <object class="GtkButton" id="button7">
+                                    <property name="label">gtk-add</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">True</property>
+                                    <property name="receives_default">True</property>
+                                    <property name="use_stock">True</property>
+                                  </object>
+                                  <packing>
+                                    <property name="expand">False</property>
+                                    <property name="fill">True</property>
+                                    <property name="position">0</property>
+                                  </packing>
+                                </child>
+                                <child>
+                                  <object class="GtkButton" id="button8">
+                                    <property name="label">gtk-remove</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="left_attach">0</property>
+                                <property name="top_attach">2</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                          </object>
+                        </child>
+                      </object>
+                    </child>
+                    <child type="label">
+                      <object class="GtkLabel" id="label4">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="label" translatable="yes">Trusted file locations</property>
+                      </object>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+              </object>
+              <packing>
+                <property name="position">1</property>
+              </packing>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="label2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Trusted Sources</property>
+              </object>
+              <packing>
+                <property name="position">1</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/xmlsecurity/uiconfig/ui/securitylevelpage.ui b/xmlsecurity/uiconfig/ui/securitylevelpage.ui
new file mode 100644
index 0000000..9e004dd
--- /dev/null
+++ b/xmlsecurity/uiconfig/ui/securitylevelpage.ui
@@ -0,0 +1,149 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkGrid" id="SecurityLevelPage">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="row_spacing">12</property>
+    <property name="column_spacing">12</property>
+    <property name="row_homogeneous">True</property>
+    <child>
+      <object class="GtkRadioButton" id="low:wrap">
+        <property name="label" translatable="yes">_Low (not recommended).
+All macros will be executed without confirmation. Use this setting only if you are certain that all documents that will be opened are safe.</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>
+        <property name="group">vhigh:wrap</property>
+      </object>
+      <packing>
+        <property name="left_attach">1</property>
+        <property name="top_attach">3</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <object class="GtkRadioButton" id="med:wrap">
+        <property name="label" translatable="yes">_Medium.
+Confirmation required before executing macros from untrusted sources.</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>
+        <property name="group">low:wrap</property>
+      </object>
+      <packing>
+        <property name="left_attach">1</property>
+        <property name="top_attach">2</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <object class="GtkRadioButton" id="high:wrap">
+        <property name="label" translatable="yes">H_igh.
+Only signed macros from trusted sources are allowed to run. Unsigned macros are disabled.</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="active">True</property>
+        <property name="draw_indicator">True</property>
+        <property name="group">med:wrap</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>
+      <object class="GtkRadioButton" id="vhigh:wrap">
+        <property name="label" translatable="yes">_Very high.
+Only macros from trusted file locations are allowed to run. All other macros, regardless whether signed or not, are disabled.</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>
+        <property name="group">high:wrap</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="GtkImage" id="vhighimg">
+        <property name="can_focus">False</property>
+        <property name="no_show_all">True</property>
+        <property name="halign">center</property>
+        <property name="valign">center</property>
+        <property name="pixbuf">res/lock.png</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="GtkImage" id="highimg">
+        <property name="can_focus">False</property>
+        <property name="no_show_all">True</property>
+        <property name="halign">center</property>
+        <property name="valign">center</property>
+        <property name="pixbuf">res/lock.png</property>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">1</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <object class="GtkImage" id="medimg">
+        <property name="can_focus">False</property>
+        <property name="no_show_all">True</property>
+        <property name="halign">center</property>
+        <property name="valign">center</property>
+        <property name="pixbuf">res/lock.png</property>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">2</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <object class="GtkImage" id="lowimg">
+        <property name="can_focus">False</property>
+        <property name="no_show_all">True</property>
+        <property name="halign">center</property>
+        <property name="valign">center</property>
+        <property name="pixbuf">res/lock.png</property>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">3</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+  </object>
+</interface>
commit 431f0b0d21cae98f0578f18144c9b08142544329
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Feb 14 09:39:34 2013 +0000

    add a custom wrap prop to radiobuttons/checkboxes
    
    Change-Id: Idccf3eceb8e9c8a42027dc837eb6d5b405fece67

diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index ba42b99..1f6d7d5 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -941,15 +941,23 @@ Window *VclBuilder::makeObject(Window *pParent, const OString &name, const OStri
     {
         extractGroup(id, rMap);
         extractButtonImage(id, rMap, true);
-        pWindow = new RadioButton(pParent, WB_CENTER|WB_VCENTER|WB_3DLOOK);
+        WinBits nBits = WB_CENTER|WB_VCENTER|WB_3DLOOK;
+        OString sWrap = extractCustomProperty(rMap);
+        if (!sWrap.isEmpty())
+            nBits |= WB_WORDBREAK;
+        pWindow = new RadioButton(pParent, nBits);
     }
     else if (name == "GtkCheckButton")
     {
+        WinBits nBits = WB_CENTER|WB_VCENTER|WB_3DLOOK;
+        OString sWrap = extractCustomProperty(rMap);
+        if (!sWrap.isEmpty())
+            nBits |= WB_WORDBREAK;
         //maybe always import as TriStateBox and enable/disable tristate
         bool bIsTriState = extractInconsistent(rMap);
         CheckBox *pCheckBox = bIsTriState ?
-            new TriStateBox(pParent, WB_CENTER|WB_VCENTER|WB_3DLOOK) :
-            new CheckBox(pParent, WB_CENTER|WB_VCENTER|WB_3DLOOK);
+            new TriStateBox(pParent, nBits) :
+            new CheckBox(pParent, nBits);
         if (bIsTriState)
             pCheckBox->SetState(STATE_DONTKNOW);
         pWindow = pCheckBox;
commit 97f04c8e9c3e798b0f319a4e1067c90e45e3507c
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Feb 14 08:43:02 2013 +0000

    make compilable on RHEL-6
    
    Change-Id: I5d0e2c23af1972c84e999ad458ae47703d94e9e0

diff --git a/vcl/inc/unx/gtk/gtkframe.hxx b/vcl/inc/unx/gtk/gtkframe.hxx
index a33a558..63d066a 100644
--- a/vcl/inc/unx/gtk/gtkframe.hxx
+++ b/vcl/inc/unx/gtk/gtkframe.hxx
@@ -54,6 +54,10 @@ typedef XLIB_Window GdkNativeWindow;
 #define gdk_window_foreign_new_for_display(a,b) gdk_x11_window_foreign_new_for_display(a,b)
 #endif
 
+#if !(GLIB_MAJOR_VERSION > 2 || GLIB_MINOR_VERSION >= 26)
+    typedef void GDBusConnection;
+#endif
+
 class GtkSalFrame : public SalFrame
 {
     static const int nMaxGraphics = 2;
diff --git a/vcl/inc/vcl/tabpage.hxx b/vcl/inc/vcl/tabpage.hxx
index 769003d..04dafe3 100644
--- a/vcl/inc/vcl/tabpage.hxx
+++ b/vcl/inc/vcl/tabpage.hxx
@@ -40,7 +40,7 @@ private:
 
 public:
                     TabPage( Window* pParent, WinBits nStyle = 0 );
-                    TabPage(Window *pParent, const rtl::OString& rID, const rtl::OUString& rUIXMLDescription);
+                    TabPage(Window *pParent, const OString& rID, const OUString& rUIXMLDescription);
 
                     TabPage( Window* pParent, const ResId& rResId );
 


More information about the Libreoffice-commits mailing list