[Libreoffice-commits] core.git: 3 commits - cui/source filter/inc filter/source filter/uiconfig filter/UIConfig_xsltdlg.mk include/sfx2 include/vcl padmin/source sc/source sfx2/source sw/source vcl/source

Caolán McNamara caolanm at redhat.com
Fri Jun 28 03:51:12 PDT 2013


 cui/source/dialogs/scriptdlg.cxx                 |    1 
 filter/UIConfig_xsltdlg.mk                       |    5 
 filter/inc/filter.hrc                            |    1 
 filter/source/pdf/impdialog.cxx                  |  217 +++-----
 filter/source/pdf/impdialog.hxx                  |   52 -
 filter/source/pdf/impdialog.src                  |  189 -------
 filter/source/xsltdialog/xmlfiltertestdialog.cxx |    1 
 filter/uiconfig/ui/pdfsecuritypage.ui            |  604 +++++++++++++++++++++++
 include/sfx2/passwd.hxx                          |    2 
 include/vcl/dialog.hxx                           |    3 
 padmin/source/prtsetup.cxx                       |    2 
 sc/source/ui/docshell/docsh4.cxx                 |    8 
 sc/source/ui/view/tabvwsh3.cxx                   |   12 
 sfx2/source/dialog/passwd.cxx                    |    2 
 sw/source/core/text/portxt.cxx                   |    4 
 vcl/source/window/builder.cxx                    |    5 
 vcl/source/window/dialog.cxx                     |   12 
 17 files changed, 762 insertions(+), 358 deletions(-)

New commits:
commit 396ab1eba7be8dcedf09854035b9f22137540d56
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Jun 28 09:31:20 2013 +0100

    convert pdf security page to .ui
    
    Change-Id: Ie785f4b112b8992707f886720d92bd34d0823f39

diff --git a/filter/UIConfig_xsltdlg.mk b/filter/UIConfig_xsltdlg.mk
index f3f309c..d474ec5 100644
--- a/filter/UIConfig_xsltdlg.mk
+++ b/filter/UIConfig_xsltdlg.mk
@@ -10,8 +10,9 @@
 $(eval $(call gb_UIConfig_UIConfig,filter))
 
 $(eval $(call gb_UIConfig_add_uifiles,filter,\
-	filter/uiconfig/ui/pdflinkspage \
-	filter/uiconfig/ui/pdfuserinterfacepage \
+    filter/uiconfig/ui/pdflinkspage \
+    filter/uiconfig/ui/pdfsecuritypage \
+    filter/uiconfig/ui/pdfuserinterfacepage \
 	filter/uiconfig/ui/testxmlfilter \
 	filter/uiconfig/ui/xmlfiltersettings \
 ))
diff --git a/filter/inc/filter.hrc b/filter/inc/filter.hrc
index 91c936a..ec5879b 100644
--- a/filter/inc/filter.hrc
+++ b/filter/inc/filter.hrc
@@ -33,7 +33,6 @@
 
 #define HID_FILTER_PDF_OPTIONS      "HID_FILTER_PDF_OPTIONS"
 #define HID_FILTER_PDF_INITIAL_VIEW   "HID_FILTER_PDF_INITIAL_VIEW"
-#define HID_FILTER_PDF_SECURITY       "HID_FILTER_PDF_SECURITY"
 #define HID_FILTER_PDF_SIGNING        "HID_FILTER_PDF_SIGNING"
 
 #endif
diff --git a/filter/source/pdf/impdialog.cxx b/filter/source/pdf/impdialog.cxx
index 56534f0..858a8b4 100644
--- a/filter/source/pdf/impdialog.cxx
+++ b/filter/source/pdf/impdialog.cxx
@@ -25,7 +25,6 @@
 #include "vcl/msgbox.hxx"
 #include "sfx2/passwd.hxx"
 #include "svtools/miscopt.hxx"
-//#include "xmlsecurity/certificatechooser.hxx"
 
 #include "comphelper/storagehelper.hxx"
 
@@ -1084,85 +1083,42 @@ void ImpPDFTabViewerPage::SetFilterConfigItem( const  ImpPDFTabDialog* paParent
     }
 }
 
-////////////////////////////////////////////////////////
 // The Security preferences tab page
-// -----------------------------------------------------------------------------
-ImpPDFTabSecurityPage::ImpPDFTabSecurityPage( Window* i_pParent,
-                                              const SfxItemSet& i_rCoreSet ) :
-    SfxTabPage( i_pParent, PDFFilterResId( RID_PDF_TAB_SECURITY ), i_rCoreSet ),
-    maFlGroup( this, PDFFilterResId( FL_PWD_GROUP ) ),
-    maPbSetPwd( this, PDFFilterResId( BTN_SET_PWD ) ),
-    maFtUserPwd( this, PDFFilterResId( FT_USER_PWD ) ),
-    maUserPwdSet( PDFFilterResId( STR_USER_PWD_SET ) ),
-    maUserPwdUnset( PDFFilterResId( STR_USER_PWD_UNSET ) ),
-    maUserPwdPdfa( PDFFilterResId( STR_USER_PWD_PDFA ) ),
-
-    maStrSetPwd( PDFFilterResId( STR_SET_PWD ) ),
-    maFtOwnerPwd( this, PDFFilterResId( FT_OWNER_PWD ) ),
-    maOwnerPwdSet( PDFFilterResId( STR_OWNER_PWD_SET ) ),
-    maOwnerPwdUnset( PDFFilterResId( STR_OWNER_PWD_UNSET ) ),
-    maOwnerPwdPdfa( PDFFilterResId( STR_OWNER_PWD_PDFA ) ),
-
-    m_aVerticalLine(this, PDFFilterResId(FL_SECURITY_VERTICAL)),
-
-    maFlPrintPermissions( this, PDFFilterResId( FL_PRINT_PERMISSIONS ) ),
-    maRbPrintNone( this, PDFFilterResId( RB_PRINT_NONE ) ),
-    maRbPrintLowRes( this, PDFFilterResId( RB_PRINT_LOWRES ) ),
-    maRbPrintHighRes( this, PDFFilterResId( RB_PRINT_HIGHRES ) ),
-
-    maFlChangesAllowed( this, PDFFilterResId( FL_CHANGES_ALLOWED ) ),
-    maRbChangesNone( this, PDFFilterResId( RB_CHANGES_NONE ) ),
-    maRbChangesInsDel( this, PDFFilterResId( RB_CHANGES_INSDEL ) ),
-    maRbChangesFillForm( this, PDFFilterResId( RB_CHANGES_FILLFORM ) ),
-    maRbChangesComment( this, PDFFilterResId( RB_CHANGES_COMMENT ) ),
-    maRbChangesAnyNoCopy( this, PDFFilterResId( RB_CHANGES_ANY_NOCOPY ) ),
-
-    maCbEnableCopy( this, PDFFilterResId( CB_ENDAB_COPY ) ),
-    maCbEnableAccessibility( this, PDFFilterResId( CB_ENAB_ACCESS ) ),
-
-    msUserPwdTitle( PDFFilterResId( STR_PDF_EXPORT_UDPWD ) ),
-    mbHaveOwnerPassword( false ),
-    mbHaveUserPassword( false ),
-
-    msOwnerPwdTitle( PDFFilterResId( STR_PDF_EXPORT_ODPWD ) )
+ImpPDFTabSecurityPage::ImpPDFTabSecurityPage(Window* i_pParent, const SfxItemSet& i_rCoreSet)
+    : SfxTabPage(i_pParent, "PdfSecurityPage","filter/ui/pdfsecuritypage.ui", i_rCoreSet)
+    , msUserPwdTitle( PDFFilterResId( STR_PDF_EXPORT_UDPWD ) )
+    , mbHaveOwnerPassword( false )
+    , mbHaveUserPassword( false )
+    , msOwnerPwdTitle( PDFFilterResId( STR_PDF_EXPORT_ODPWD ) )
 {
-    maUserPwdSet.Append( sal_Unicode( '\n' ) );
-    maUserPwdSet.Append( String( PDFFilterResId( STR_USER_PWD_ENC ) ) );
-
-    maUserPwdUnset.Append( sal_Unicode( '\n' ) );
-    maUserPwdUnset.Append( String( PDFFilterResId( STR_USER_PWD_UNENC ) ) );
-
-    maOwnerPwdSet.Append( sal_Unicode( '\n' ) );
-    maOwnerPwdSet.Append( String( PDFFilterResId( STR_OWNER_PWD_REST ) ) );
-
-    maOwnerPwdUnset.Append( sal_Unicode( '\n' ) );
-    maOwnerPwdUnset.Append( String( PDFFilterResId( STR_OWNER_PWD_UNREST ) ) );
-
-    FreeResource();
-
-    maFtUserPwd.SetText( maUserPwdUnset );
-    maFtOwnerPwd.SetText( maOwnerPwdUnset );
-
-    // pb: #i91991# maRbChangesComment double-spaced if necessary
-    Size aSize = maRbChangesComment.GetSizePixel();
-    Size aMinSize = maRbChangesComment.CalcMinimumSize();
-    if ( aSize.Width() > aMinSize.Width() )
-    {
-        Size aNewSize = maRbChangesFillForm.GetSizePixel();
-        long nDelta = aSize.Height() - aNewSize.Height();
-        maRbChangesComment.SetSizePixel( aNewSize );
-        Window* pWins[] =
-            { &maRbChangesAnyNoCopy, &maCbEnableCopy, &maCbEnableAccessibility, NULL };
-        Window** pCurrent = pWins;
-        while ( *pCurrent )
-        {
-            Point aNewPos = (*pCurrent)->GetPosPixel();
-            aNewPos.Y() -= nDelta;
-            (*pCurrent++)->SetPosPixel( aNewPos );
-        }
-    }
-
-    maPbSetPwd.SetClickHdl( LINK( this, ImpPDFTabSecurityPage, ClickmaPbSetPwdHdl ) );
+    get(mpPbSetPwd, "setpassword");
+    msStrSetPwd = get<Window>("setpasswordstitle")->GetText();
+
+    get(mpUserPwdSet, "userpwdset");
+    get(mpUserPwdUnset, "userpwdunset");
+    get(mpUserPwdPdfa, "userpwdpdfa");
+
+    get(mpOwnerPwdSet, "ownerpwdset");
+    get(mpOwnerPwdUnset, "ownerpwdunset");
+    get(mpOwnerPwdPdfa, "ownerpwdpdfa");
+
+    get(mpPrintPermissions, "printing");
+    get(mpRbPrintNone, "printnone");
+    get(mpRbPrintLowRes, "printlow");
+    get(mpRbPrintHighRes, "printnone");
+
+    get(mpChangesAllowed, "changes");
+    get(mpRbChangesNone, "changenone");
+    get(mpRbChangesInsDel, "changeinsdel");
+    get(mpRbChangesFillForm, "changeform");
+    get(mpRbChangesComment, "changecomment");
+    get(mpRbChangesAnyNoCopy, "changeany");
+
+    get(mpContent, "content");
+    get(mpCbEnableCopy, "enablecopy");
+    get(mpCbEnableAccessibility, "enablea11y");
+
+    mpPbSetPwd->SetClickHdl( LINK( this, ImpPDFTabSecurityPage, ClickmaPbSetPwdHdl ) );
 }
 
 // -----------------------------------------------------------------------------
@@ -1190,25 +1146,25 @@ void ImpPDFTabSecurityPage::GetFilterConfigItem( ImpPDFTabDialog* paParent  )
 
 //verify print status
     paParent->mnPrint = 0;
-    if( maRbPrintLowRes.IsChecked() )
+    if( mpRbPrintLowRes->IsChecked() )
         paParent->mnPrint = 1;
-    else if( maRbPrintHighRes.IsChecked() )
+    else if( mpRbPrintHighRes->IsChecked() )
         paParent->mnPrint = 2;
 
 //verify changes permitted
     paParent->mnChangesAllowed = 0;
 
-    if( maRbChangesInsDel.IsChecked() )
+    if( mpRbChangesInsDel->IsChecked() )
         paParent->mnChangesAllowed = 1;
-    else if( maRbChangesFillForm.IsChecked() )
+    else if( mpRbChangesFillForm->IsChecked() )
         paParent->mnChangesAllowed = 2;
-    else if( maRbChangesComment.IsChecked() )
+    else if( mpRbChangesComment->IsChecked() )
         paParent->mnChangesAllowed = 3;
-    else if( maRbChangesAnyNoCopy.IsChecked() )
+    else if( mpRbChangesAnyNoCopy->IsChecked() )
         paParent->mnChangesAllowed = 4;
 
-    paParent->mbCanCopyOrExtract = maCbEnableCopy.IsChecked();
-    paParent->mbCanExtractForAccessibility = maCbEnableAccessibility.IsChecked();
+    paParent->mbCanCopyOrExtract = mpCbEnableCopy->IsChecked();
+    paParent->mbCanExtractForAccessibility = mpCbEnableAccessibility->IsChecked();
 }
 
 
@@ -1219,13 +1175,13 @@ void ImpPDFTabSecurityPage::SetFilterConfigItem( const  ImpPDFTabDialog* paParen
     {
     default:
     case 0:
-        maRbPrintNone.Check();
+        mpRbPrintNone->Check();
         break;
     case 1:
-        maRbPrintLowRes.Check();
+        mpRbPrintLowRes->Check();
         break;
     case 2:
-        maRbPrintHighRes.Check();
+        mpRbPrintHighRes->Check();
         break;
     };
 
@@ -1233,24 +1189,24 @@ void ImpPDFTabSecurityPage::SetFilterConfigItem( const  ImpPDFTabDialog* paParen
     {
     default:
     case 0:
-        maRbChangesNone.Check();
+        mpRbChangesNone->Check();
         break;
     case 1:
-        maRbChangesInsDel.Check();
+        mpRbChangesInsDel->Check();
         break;
     case 2:
-        maRbChangesFillForm.Check();
+        mpRbChangesFillForm->Check();
         break;
     case 3:
-        maRbChangesComment.Check();
+        mpRbChangesComment->Check();
         break;
     case 4:
-        maRbChangesAnyNoCopy.Check();
+        mpRbChangesAnyNoCopy->Check();
         break;
     };
 
-    maCbEnableCopy.Check( paParent->mbCanCopyOrExtract );
-    maCbEnableAccessibility.Check( paParent->mbCanExtractForAccessibility );
+    mpCbEnableCopy->Check( paParent->mbCanCopyOrExtract );
+    mpCbEnableAccessibility->Check( paParent->mbCanExtractForAccessibility );
 
 // set the status of this windows, according to the PDFA selection
     enablePermissionControls();
@@ -1266,8 +1222,8 @@ IMPL_LINK_NOARG(ImpPDFTabSecurityPage, ClickmaPbSetPwdHdl)
     aPwdDialog.SetMinLen( 0 );
     aPwdDialog.ShowMinLengthText(false);
     aPwdDialog.ShowExtras( SHOWEXTRAS_CONFIRM | SHOWEXTRAS_PASSWORD2 | SHOWEXTRAS_CONFIRM2 );
-    aPwdDialog.SetText( maStrSetPwd );
-    aPwdDialog.SetGroup2Text( msOwnerPwdTitle );
+    aPwdDialog.SetText(msStrSetPwd);
+    aPwdDialog.SetGroup2Text(msOwnerPwdTitle);
     aPwdDialog.AllowAsciiOnly();
     if( aPwdDialog.Execute() == RET_OK )  //OK issued get password and set it
     {
@@ -1294,34 +1250,61 @@ void ImpPDFTabSecurityPage::enablePermissionControls()
 {
     sal_Bool bIsPDFASel =  sal_False;
     ImpPDFTabDialog* pParent = static_cast<ImpPDFTabDialog*>(GetTabDialog());
+    fprintf(stderr, "pParent is %p\n", pParent);
     if( pParent && pParent->GetTabPage( RID_PDF_TAB_GENER ) )
+    {
+        fprintf(stderr,"got it\n");
         bIsPDFASel = ( ( ImpPDFTabGeneralPage* )pParent->
                        GetTabPage( RID_PDF_TAB_GENER ) )->IsPdfaSelected();
+    }
     if( bIsPDFASel )
-        maFtUserPwd.SetText( maUserPwdPdfa );
+    {
+        mpUserPwdPdfa->Show();
+        mpUserPwdSet->Hide();
+        mpUserPwdUnset->Hide();
+    }
     else
-        maFtUserPwd.SetText( (mbHaveUserPassword && IsEnabled()) ? maUserPwdSet : maUserPwdUnset );
+    {
+        if (mbHaveUserPassword && IsEnabled())
+        {
+            mpUserPwdSet->Show();
+            mpUserPwdUnset->Hide();
+            mpUserPwdPdfa->Hide();
+        }
+        else
+        {
+            mpUserPwdUnset->Show();
+            mpUserPwdSet->Hide();
+            mpUserPwdPdfa->Hide();
+        }
+    }
 
     sal_Bool bLocalEnable = mbHaveOwnerPassword && IsEnabled();
     if( bIsPDFASel )
-        maFtOwnerPwd.SetText( maOwnerPwdPdfa );
+    {
+        mpOwnerPwdPdfa->Show();
+        mpOwnerPwdSet->Hide();
+        mpOwnerPwdUnset->Hide();
+    }
     else
-        maFtOwnerPwd.SetText( bLocalEnable ? maOwnerPwdSet : maOwnerPwdUnset );
-
-    maFlPrintPermissions.Enable( bLocalEnable );
-    maRbPrintNone.Enable( bLocalEnable );
-    maRbPrintLowRes.Enable( bLocalEnable );
-    maRbPrintHighRes.Enable( bLocalEnable );
-
-    maFlChangesAllowed.Enable( bLocalEnable );
-    maRbChangesNone.Enable( bLocalEnable );
-    maRbChangesInsDel.Enable( bLocalEnable );
-    maRbChangesFillForm.Enable( bLocalEnable );
-    maRbChangesComment.Enable( bLocalEnable );
-    maRbChangesAnyNoCopy.Enable( bLocalEnable );
-
-    maCbEnableCopy.Enable( bLocalEnable );
-    maCbEnableAccessibility.Enable( bLocalEnable );
+    {
+        if (bLocalEnable)
+        {
+            mpOwnerPwdSet->Show();
+            mpOwnerPwdUnset->Hide();
+            mpOwnerPwdPdfa->Hide();
+        }
+        else
+        {
+            mpOwnerPwdUnset->Show();
+            mpOwnerPwdSet->Hide();
+            mpOwnerPwdPdfa->Hide();
+        }
+    }
+
+    mpPrintPermissions->Enable(bLocalEnable);
+    mpChangesAllowed->Enable(bLocalEnable);
+    mpContent->Enable(bLocalEnable);
 }
 
 ////////////////////////////////////////////////////////
diff --git a/filter/source/pdf/impdialog.hxx b/filter/source/pdf/impdialog.hxx
index 72fd6ab..e83a72a 100644
--- a/filter/source/pdf/impdialog.hxx
+++ b/filter/source/pdf/impdialog.hxx
@@ -27,6 +27,7 @@
 #include "vcl/fixed.hxx"
 #include "vcl/field.hxx"
 #include "vcl/edit.hxx"
+#include "vcl/layout.hxx"
 #include "vcl/lstbox.hxx"
 #include "vcl/combobox.hxx"
 #include "vcl/group.hxx"
@@ -326,42 +327,39 @@ public:
 //class security tab page
 class ImpPDFTabSecurityPage : public SfxTabPage
 {
-    FixedLine                   maFlGroup;
-    PushButton                  maPbSetPwd;
-    FixedText                   maFtUserPwd;
-    String                      maUserPwdSet;
-    String                      maUserPwdUnset;
-    String                      maUserPwdPdfa;
-    String                      maStrSetPwd;
-
-    FixedText                   maFtOwnerPwd;
-    String                      maOwnerPwdSet;
-    String                      maOwnerPwdUnset;
-    String                      maOwnerPwdPdfa;
+    PushButton*                 mpPbSetPwd;
+    OUString                    msStrSetPwd;
 
-    FixedLine m_aVerticalLine;
+    VclContainer*               mpUserPwdSet;
+    VclContainer*               mpUserPwdUnset;
+    VclContainer*               mpUserPwdPdfa;
+
+    VclContainer*               mpOwnerPwdSet;
+    VclContainer*               mpOwnerPwdUnset;
+    VclContainer*               mpOwnerPwdPdfa;
 
-    FixedLine                   maFlPrintPermissions;
-    RadioButton                 maRbPrintNone;
-    RadioButton                 maRbPrintLowRes;
-    RadioButton                 maRbPrintHighRes;
+    VclContainer*               mpPrintPermissions;
+    RadioButton*                mpRbPrintNone;
+    RadioButton*                mpRbPrintLowRes;
+    RadioButton*                mpRbPrintHighRes;
 
-    FixedLine                   maFlChangesAllowed;
-    RadioButton                 maRbChangesNone;
-    RadioButton                 maRbChangesInsDel;
-    RadioButton                 maRbChangesFillForm;
-    RadioButton                 maRbChangesComment;
-    RadioButton                 maRbChangesAnyNoCopy;
+    VclContainer*               mpChangesAllowed;
+    RadioButton*                mpRbChangesNone;
+    RadioButton*                mpRbChangesInsDel;
+    RadioButton*                mpRbChangesFillForm;
+    RadioButton*                mpRbChangesComment;
+    RadioButton*                mpRbChangesAnyNoCopy;
 
-    CheckBox                    maCbEnableCopy;
-    CheckBox                    maCbEnableAccessibility;
+    VclContainer*               mpContent;
+    CheckBox*                   mpCbEnableCopy;
+    CheckBox*                   mpCbEnableAccessibility;
 
-    String                      msUserPwdTitle;
+    OUString                    msUserPwdTitle;
 
     bool                        mbHaveOwnerPassword;
     bool                        mbHaveUserPassword;
     com::sun::star::uno::Sequence< com::sun::star::beans::NamedValue > maPreparedOwnerPassword;
-    String                      msOwnerPwdTitle;
+    OUString                    msOwnerPwdTitle;
 
     com::sun::star::uno::Reference< com::sun::star::beans::XMaterialHolder > mxPreparedPasswords;
 
diff --git a/filter/source/pdf/impdialog.src b/filter/source/pdf/impdialog.src
index d7889c8..c5398ef 100644
--- a/filter/source/pdf/impdialog.src
+++ b/filter/source/pdf/impdialog.src
@@ -484,195 +484,6 @@ TabPage  RID_PDF_TAB_OPNFTR
 };
 
 //----------------------------------------------------------
-//tab page for PDF Export, security
-TabPage  RID_PDF_TAB_SECURITY
-{
-    HelpId = HID_FILTER_PDF_SECURITY ;
-    Text [ en-US ] = "Security";
-    TAB_PDF_SIZE;
-    Hide = TRUE;
-
-    FixedLine FL_PWD_GROUP
-    {
-        Pos = MAP_APPFONT( 5, 5 );
-        Size = MAP_APPFONT( 125, 10 );
-        Text[ en-US ] = "File encryption and permission";
-    };
-    PushButton BTN_SET_PWD
-    {
-        HelpID = "filter:PushButton:RID_PDF_TAB_SECURITY:BTN_PWD";
-        TabStop = TRUE ;
-        Disable = TRUE ;
-        Pos = MAP_APPFONT ( 12, 20 ) ;
-        Size = MAP_APPFONT ( 120 , 13 ) ;
-        Text[ en-US ] = "Set ~passwords...";
-    };
-    String STR_SET_PWD
-    {
-        Text[ en-US ] = "Set passwords";
-    };
-
-    FixedText FT_USER_PWD
-    {
-        Pos = MAP_APPFONT(12 , 40 );
-        Size = MAP_APPFONT( 160, 20 );
-    };
-
-    String  STR_USER_PWD_SET
-    {
-        Text [ en-US ] = "Open password set";
-    };
-
-    String  STR_USER_PWD_ENC
-    {
-        Text [ en-US ] = "PDF document will be encrypted";
-    };
-
-    String  STR_USER_PWD_UNSET
-    {
-        Text [ en-US ] = "No open password set";
-    };
-
-    String  STR_USER_PWD_UNENC
-    {
-        Text [ en-US ] = "PDF document will not be encrypted";
-    };
-
-    String STR_USER_PWD_PDFA
-    {
-        Text [en-US] = "PDF document will not be encrypted due to PDF/A export.";
-    };
-
-    FixedText FT_OWNER_PWD
-    {
-        Pos = MAP_APPFONT( 12 , 65 );
-        Size = MAP_APPFONT( 160, 20 );
-    };
-
-    String  STR_OWNER_PWD_SET
-    {
-        Text [ en-US ] = "Permission password set";
-    };
-
-    String  STR_OWNER_PWD_REST
-    {
-        Text [ en-US ] = "PDF document will be restricted";
-    };
-
-    String  STR_OWNER_PWD_UNSET
-    {
-        Text [ en-US ] = "No permission password set";
-    };
-
-    String  STR_OWNER_PWD_UNREST
-    {
-        Text [ en-US ] = "PDF document will be unrestricted";
-    };
-
-    String STR_OWNER_PWD_PDFA
-    {
-        Text [en-US] = "PDF document will not be restricted due to PDF/A export.";
-    };
-
-    FixedLine FL_SECURITY_VERTICAL
-    {
-        Pos = MAP_APPFONT ( 175 , 3 ) ;
-        Size = MAP_APPFONT ( 4 , 171 ) ;
-        Vert = TRUE;
-    };
-
-    FixedLine FL_PRINT_PERMISSIONS
-    {
-        Pos = MAP_APPFONT ( 182 , 5 ) ;
-        Size = MAP_APPFONT (156  , 8 ) ;
-        Text[ en-US ] = "Printing" ;
-    };
-    RadioButton RB_PRINT_NONE
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_PRINT_NONE";
-        Pos = MAP_APPFONT ( 188 , 16 ) ;
-        Size = MAP_APPFONT ( 150 , 10 ) ;
-        Text[ en-US ] = "~Not permitted";
-    };
-    RadioButton RB_PRINT_LOWRES
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_PRINT_LOWRES";
-        Pos = MAP_APPFONT ( 188 , 27 ) ;
-        Size = MAP_APPFONT ( 150 , 10 ) ;
-        Text[ en-US ] = "~Low resolution (150 dpi)";
-    };
-    RadioButton RB_PRINT_HIGHRES
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_PRINT_HIGHRES";
-        Pos = MAP_APPFONT ( 188 , 38 ) ;
-        Size = MAP_APPFONT ( 150 , 10 ) ;
-        Text[ en-US ] = "~High resolution";
-    };
-
-/////////////////////////////
-    FixedLine FL_CHANGES_ALLOWED
-    {
-        Pos = MAP_APPFONT ( 182 , 49 ) ;
-        Size = MAP_APPFONT (156  , 8 ) ;
-        Text[ en-US ] = "Changes" ;
-    };
-    RadioButton RB_CHANGES_NONE
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_CHANGES_NONE";
-        Pos = MAP_APPFONT ( 188 , 60 ) ;
-        Size = MAP_APPFONT ( 150 , 10 ) ;
-        Text[ en-US ] = "No~t permitted";
-    };
-    RadioButton RB_CHANGES_INSDEL
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_CHANGES_INSDEL";
-        Pos = MAP_APPFONT ( 188 , 72 ) ;
-        Size = MAP_APPFONT ( 150 , 10 ) ;
-        Text[ en-US ] = "~Inserting, deleting, and rotating pages";
-    };
-    RadioButton RB_CHANGES_FILLFORM
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_CHANGES_FILLFORM";
-        Pos = MAP_APPFONT ( 188 , 83 ) ;
-        Size = MAP_APPFONT ( 150 , 10 ) ;
-        Text[ en-US ] = "~Filling in form fields";
-    };
-    RadioButton RB_CHANGES_COMMENT
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_CHANGES_COMMENT";
-        Pos = MAP_APPFONT ( 188 , 94 ) ;
-        Size = MAP_APPFONT ( 152 , 16 ) ;
-        WordBreak = TRUE ;
-        Text[ en-US ] = "~Commenting, filling in form fields";
-    };
-    RadioButton RB_CHANGES_ANY_NOCOPY
-    {
-        HelpID = "filter:RadioButton:RID_PDF_TAB_SECURITY:RB_CHANGES_ANY_NOCOPY";
-        Pos = MAP_APPFONT ( 188 , 113 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text[ en-US ] = "~Any except extracting pages";
-    };
-
-    CheckBox CB_ENDAB_COPY
-    {
-        HelpID = "filter:CheckBox:RID_PDF_TAB_SECURITY:CB_ENDAB_COPY";
-        Pos = MAP_APPFONT ( 182 , 126 ) ;
-        Size = MAP_APPFONT ( 158 , 10 ) ;
-        TabStop = TRUE ;
-        Text[ en-US ] = "Ena~ble copying of content" ;
-    };
-
-    CheckBox CB_ENAB_ACCESS
-    {
-        HelpID = "filter:CheckBox:RID_PDF_TAB_SECURITY:CB_ENAB_ACCESS";
-        Pos = MAP_APPFONT ( 182 , 139 ) ;
-        Size = MAP_APPFONT ( 158 , 10 ) ;
-        TabStop = TRUE ;
-        Text[ en-US ] = "Enable text access for acce~ssibility tools" ;
-    };
-};
-
-//----------------------------------------------------------
 //tab page for PDF Export, digital signatures
 TabPage  RID_PDF_TAB_SIGNING
 {
diff --git a/filter/uiconfig/ui/pdfsecuritypage.ui b/filter/uiconfig/ui/pdfsecuritypage.ui
new file mode 100644
index 0000000..a880a01
--- /dev/null
+++ b/filter/uiconfig/ui/pdfsecuritypage.ui
@@ -0,0 +1,604 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.6 -->
+  <object class="GtkBox" id="PdfSecurityPage">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="border_width">6</property>
+    <property name="spacing">12</property>
+    <property name="homogeneous">True</property>
+    <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="top_padding">6</property>
+            <property name="left_padding">12</property>
+            <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">18</property>
+                <child>
+                  <object class="GtkButton" id="setpassword">
+                    <property name="label" translatable="yes">Set _passwords...</property>
+                    <property name="visible">True</property>
+                    <property name="sensitive">False</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                    <property name="halign">start</property>
+                    <property name="use_underline">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="userpwdset">
+                    <property name="can_focus">False</property>
+                    <property name="no_show_all">True</property>
+                    <child>
+                      <object class="GtkLabel" id="label5">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">Open password set</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="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">PDF document will be encrypted</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>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="userpwdunset">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <child>
+                      <object class="GtkLabel" id="label7">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">No open password set</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="label8">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">PDF document will not be encrypted</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>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">2</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="userpwdpdfa">
+                    <property name="can_focus">False</property>
+                    <property name="no_show_all">True</property>
+                    <child>
+                      <object class="GtkLabel" id="label30">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">PDF document will not be encrypted due to PDF/A export.</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>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">3</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="ownerpwdset">
+                    <property name="can_focus">False</property>
+                    <property name="no_show_all">True</property>
+                    <child>
+                      <object class="GtkLabel" id="label9">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">Permission password set</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="label11">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">PDF document will be restricted</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>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">4</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="ownerpwdunset">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <child>
+                      <object class="GtkLabel" id="label12">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">No permission password set</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="label13">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">PDF document will be unrestricted</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>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">5</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="ownerpwdpdfa">
+                    <property name="can_focus">False</property>
+                    <property name="no_show_all">True</property>
+                    <child>
+                      <object class="GtkLabel" id="label14">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="xalign">0</property>
+                        <property name="label" translatable="yes">PDF document will not be restricted due to PDF/A export.</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>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">6</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkLabel" id="setpasswordstitle">
+                    <property name="can_focus">False</property>
+                    <property name="no_show_all">True</property>
+                    <property name="xalign">0</property>
+                    <property name="label" translatable="yes">Set passwords</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">7</property>
+                  </packing>
+                </child>
+              </object>
+            </child>
+          </object>
+        </child>
+        <child type="label">
+          <object class="GtkLabel" id="label2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">File encryption and permission</property>
+            <attributes>
+              <attribute name="weight" value="bold"/>
+            </attributes>
+          </object>
+        </child>
+      </object>
+      <packing>
+        <property name="expand">False</property>
+        <property name="fill">True</property>
+        <property name="position">0</property>
+      </packing>
+    </child>
+    <child>
+      <object class="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="GtkFrame" id="printing">
+            <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="top_padding">6</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <object class="GtkGrid" id="grid7">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="row_spacing">6</property>
+                    <child>
+                      <object class="GtkRadioButton" id="printnone">
+                        <property name="label" translatable="yes">_Not permitted</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">printlow</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="GtkRadioButton" id="printlow">
+                        <property name="label" translatable="yes">_Low resolution (150 dpi)</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">printhigh</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="GtkRadioButton" id="printhigh">
+                        <property name="label" translatable="yes">_High resolution</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">printnone</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>
+                  </object>
+                </child>
+              </object>
+            </child>
+            <child type="label">
+              <object class="GtkLabel" id="label1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Printing</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkFrame" id="changes">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label_xalign">0</property>
+            <property name="shadow_type">none</property>
+            <child>
+              <object class="GtkAlignment" id="alignment3">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="top_padding">6</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <object class="GtkGrid" id="grid8">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="row_spacing">6</property>
+                    <child>
+                      <object class="GtkRadioButton" id="changenone">
+                        <property name="label" translatable="yes">No_t permitted</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">changeinsdel</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="GtkRadioButton" id="changeinsdel">
+                        <property name="label" translatable="yes">_Inserting, deleting, and rotating pages</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">changeform</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="GtkRadioButton" id="changeform">
+                        <property name="label" translatable="yes">_Filling in form fields</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">changecomment</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="GtkRadioButton" id="changecomment">
+                        <property name="label" translatable="yes">_Commenting, filling in form fields</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">changeany</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>
+                    <child>
+                      <object class="GtkRadioButton" id="changeany">
+                        <property name="label" translatable="yes">_Any except extracting pages</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">changenone</property>
+                      </object>
+                      <packing>
+                        <property name="left_attach">0</property>
+                        <property name="top_attach">4</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">Changes</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkFrame" id="content">
+            <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="alignment4">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="top_padding">6</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <object class="GtkGrid" id="grid9">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="row_spacing">6</property>
+                    <child>
+                      <object class="GtkCheckButton" id="enablecopy">
+                        <property name="label" translatable="yes">Ena_ble copying of content</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>
+                      </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="GtkCheckButton" id="enablea11y">
+                        <property name="label" translatable="yes">Enable text access for acce_ssibility tools</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>
+                      </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>
+                </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">Content</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">2</property>
+          </packing>
+        </child>
+      </object>
+      <packing>
+        <property name="expand">False</property>
+        <property name="fill">True</property>
+        <property name="position">1</property>
+      </packing>
+    </child>
+  </object>
+  <object class="GtkSizeGroup" id="sizegroup1">
+    <widgets>
+      <widget name="userpwdset"/>
+      <widget name="userpwdunset"/>
+      <widget name="userpwdpdfa"/>
+      <widget name="ownerpwdset"/>
+      <widget name="ownerpwdunset"/>
+      <widget name="ownerpwdpdfa"/>
+    </widgets>
+  </object>
+</interface>
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx
index 5511b61..48ed4c6 100644
--- a/sc/source/ui/docshell/docsh4.cxx
+++ b/sc/source/ui/docshell/docsh4.cxx
@@ -1128,9 +1128,9 @@ bool ScDocShell::ExecuteChangeProtectionDialog( Window* _pParent, sal_Bool bJust
         if ( bJustQueryIfProtected && !bProtected )
             return true;
 
-        String aTitle( ScResId( bProtected ? SCSTR_CHG_UNPROTECT : SCSTR_CHG_PROTECT ) );
-        String aText( ScResId( SCSTR_PASSWORD ) );
-        String aPassword;
+        OUString aTitle( ScResId( bProtected ? SCSTR_CHG_UNPROTECT : SCSTR_CHG_PROTECT ) );
+        OUString aText( ScResId( SCSTR_PASSWORD ) );
+        OUString aPassword;
 
         SfxPasswordDialog* pDlg = new SfxPasswordDialog(
             _pParent ? _pParent : GetActiveDialogParent(), &aText );
@@ -1144,7 +1144,7 @@ bool ScDocShell::ExecuteChangeProtectionDialog( Window* _pParent, sal_Bool bJust
             aPassword = pDlg->GetPassword();
         delete pDlg;
 
-        if ( aPassword.Len() )
+        if (!aPassword.isEmpty())
         {
             if ( bProtected )
             {
diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx
index e1041b1..0e03f04 100644
--- a/sc/source/ui/view/tabvwsh3.cxx
+++ b/sc/source/ui/view/tabvwsh3.cxx
@@ -987,14 +987,14 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
                 ScDocProtection* pProtect = pDoc->GetDocProtection();
                 if (pProtect && pProtect->isProtected())
                 {
-                    sal_Bool    bCancel = false;
-                    String  aPassword;
+                    sal_Bool bCancel = false;
+                    OUString aPassword;
 
                     if (pProtect->isProtectedWithPass())
                     {
-                        String  aText( ScResId(SCSTR_PASSWORD) );
+                        OUString aText(ScResId(SCSTR_PASSWORD));
 
-                        pDlg = new SfxPasswordDialog(   GetDialogParent(), &aText );
+                        pDlg = new SfxPasswordDialog(GetDialogParent(), &aText);
                         pDlg->SetText( ScResId(SCSTR_UNPROTECTDOC) );
                         pDlg->SetMinLen( 0 );
                         pDlg->SetHelpId( GetStaticInterface()->GetSlot(FID_PROTECT_DOC)->GetCommand() );
@@ -1015,7 +1015,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
                 }
                 else
                 {
-                    String aText( ScResId(SCSTR_PASSWORDOPT) );
+                    OUString aText(ScResId(SCSTR_PASSWORDOPT));
 
                     pDlg = new SfxPasswordDialog(   GetDialogParent(), &aText );
                     pDlg->SetText( ScResId(SCSTR_PROTECTDOC) );
@@ -1065,7 +1065,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
                 ScTableProtection* pProtect = pDoc->GetTabProtection(nTab);
                 if (pProtect && pProtect->isProtectedWithPass())
                 {
-                    String aText( ScResId(SCSTR_PASSWORDOPT) );
+                    OUString aText( ScResId(SCSTR_PASSWORDOPT) );
                     auto_ptr<SfxPasswordDialog> pDlg(new SfxPasswordDialog(GetDialogParent(), &aText));
                     pDlg->SetText( ScResId(SCSTR_UNPROTECTTAB) );
                     pDlg->SetMinLen( 0 );
diff --git a/sfx2/source/dialog/passwd.cxx b/sfx2/source/dialog/passwd.cxx
index cfd28ce..a9a0fe5 100644
--- a/sfx2/source/dialog/passwd.cxx
+++ b/sfx2/source/dialog/passwd.cxx
@@ -83,7 +83,7 @@ IMPL_LINK_NOARG(SfxPasswordDialog, OKHdl)
 
 // CTOR / DTOR -----------------------------------------------------------
 
-SfxPasswordDialog::SfxPasswordDialog(Window* pParent, const String* pGroupText)
+SfxPasswordDialog::SfxPasswordDialog(Window* pParent, const OUString* pGroupText)
     : ModalDialog(pParent, "PasswordDialog", "sfx/ui/password.ui")
     , maMinLenPwdStr(SFX2_RESSTR(STR_PASSWD_MIN_LEN))
     , maEmptyPwdStr(SFX2_RESSTR(STR_PASSWD_EMPTY))
commit 31fc0b74425253589b2ac0dcecb9e8a2714954b4
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Jun 28 10:39:39 2013 +0100

    always call setDeferredProperties for dialog get/set title
    
    Change-Id: I57f9cc8fbdb9d2a304c346e03893fa55d6a61bd5

diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx
index e353412..672ff5e 100644
--- a/cui/source/dialogs/scriptdlg.cxx
+++ b/cui/source/dialogs/scriptdlg.cxx
@@ -508,7 +508,6 @@ SvxScriptOrgDialog::SvxScriptOrgDialog( Window* pParent, OUString language )
     get(m_pDelButton, "delete");
     // must be a neater way to deal with the strings than as above
     // append the language to the dialog title
-    setDeferredProperties();
     String winTitle( GetText() );
     winTitle.SearchAndReplace( OUString( "%MACROLANG" ), m_sLanguage );
     SetText( winTitle );
diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.cxx b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
index 2de74ef..0490c3f 100644
--- a/filter/source/xsltdialog/xmlfiltertestdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
@@ -162,7 +162,6 @@ XMLFilterTestDialog::XMLFilterTestDialog(Window* pParent,
     m_pPBRecentFile->SetClickHdl(LINK( this, XMLFilterTestDialog, ClickHdl_Impl ) );
     m_pPBClose->SetClickHdl(LINK( this, XMLFilterTestDialog, ClickHdl_Impl ) );
 
-    setDeferredProperties();
     m_sDialogTitle = GetText();
 
     try
diff --git a/include/sfx2/passwd.hxx b/include/sfx2/passwd.hxx
index 1f10c74..b0efa7b 100644
--- a/include/sfx2/passwd.hxx
+++ b/include/sfx2/passwd.hxx
@@ -73,7 +73,7 @@ private:
     void            SetPasswdText();
 
 public:
-    SfxPasswordDialog(Window* pParent, const String* pGroupText = NULL);
+    SfxPasswordDialog(Window* pParent, const OUString* pGroupText = NULL);
 
     String GetUser() const
     {
diff --git a/include/vcl/dialog.hxx b/include/vcl/dialog.hxx
index a8737d1..4e20d63 100644
--- a/include/vcl/dialog.hxx
+++ b/include/vcl/dialog.hxx
@@ -114,6 +114,9 @@ public:
     virtual short   Execute();
     sal_Bool            IsInExecute() const { return mbInExecute; }
 
+    virtual void      SetText( const OUString& rStr );
+    virtual OUString  GetText() const;
+
     ////////////////////////////////////////
     // Dialog::Execute replacement API
 public:
diff --git a/padmin/source/prtsetup.cxx b/padmin/source/prtsetup.cxx
index f3f42a1..5ee4958 100644
--- a/padmin/source/prtsetup.cxx
+++ b/padmin/source/prtsetup.cxx
@@ -91,8 +91,6 @@ RTSDialog::RTSDialog( const PrinterInfo& rJobData, const String& rPrinter, bool
     get(m_pCancelButton, "cancel");
     get(m_pTabControl, "notebook");
 
-    setDeferredProperties();
-
     OUString aTitle(GetText());
     SetText(aTitle.replaceAll("%s", m_aJobData.m_aPrinterName));
 
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index 4cc571f..4cea57f 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -1376,9 +1376,10 @@ void VclBuilder::setDeferredProperties()
 {
     if (!m_bToplevelHasDeferredProperties)
         return;
-    set_properties(m_pParent, m_aDeferredProperties);
-    m_aDeferredProperties.clear();
+    stringmap aDeferredProperties;
+    aDeferredProperties.swap(m_aDeferredProperties);
     m_bToplevelHasDeferredProperties = false;
+    set_properties(m_pParent, aDeferredProperties);
 }
 
 void VclBuilder::set_properties(Window *pWindow, const stringmap &rProps)
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index 8466ab2..aca80f1b 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -1265,6 +1265,18 @@ bool Dialog::set_property(const OString &rKey, const OString &rValue)
     return true;
 }
 
+void Dialog::SetText(const OUString& rStr)
+{
+    setDeferredProperties();
+    SystemWindow::SetText(rStr);
+}
+
+OUString Dialog::GetText() const
+{
+    const_cast<Dialog*>(this)->setDeferredProperties();
+    return SystemWindow::GetText();
+}
+
 VclBuilderContainer::VclBuilderContainer()
     : m_pUIBuilder(NULL)
 {
commit 1a05f14ba263bf47c5c5c8aee080ef28d5db2075
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Jun 28 09:15:44 2013 +0100

    fix build for highest debugging level
    
    Change-Id: Icc91931ec3eb4ea73476f3f570ca5eb7ef784dce

diff --git a/sw/source/core/text/portxt.cxx b/sw/source/core/text/portxt.cxx
index 7dff0bd..e65e9a6 100644
--- a/sw/source/core/text/portxt.cxx
+++ b/sw/source/core/text/portxt.cxx
@@ -459,10 +459,6 @@ sal_Bool SwTxtPortion::_Format( SwTxtFormatInfo &rInf )
 
 sal_Bool SwTxtPortion::Format( SwTxtFormatInfo &rInf )
 {
-#if OSL_DEBUG_LEVEL > 1
-    const XubString aDbgTxt( rInf.GetTxt().Copy( rInf.GetIdx(), rInf.GetLen() ) );
-#endif
-
     if( rInf.X() > rInf.Width() || (!GetLen() && !InExpGrp()) )
     {
         Height( 0 );


More information about the Libreoffice-commits mailing list