summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-03-11 10:27:41 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-03-11 12:18:55 +0000
commitf3609ac092bc520825bfd6b71ed20ecaba293317 (patch)
treee1b4b3a84495ff30f8d0eb93c40d3e3e90d9cafe
parent89a838c193fb428c794e9d2760535ff6bfdcaf4d (diff)
convert load template dialog to .ui
and merge the expander and the "show preview" checkbox to be the same thing, i.e. expanded is showing, and not expanded is not showing Change-Id: I10e43bc36a0e2e5d1286a4dbad793ee3a700c97c
-rw-r--r--extras/source/glade/libreoffice-catalog.xml.in3
-rw-r--r--sfx2/AllLangResTarget_sfx2.mk1
-rw-r--r--sfx2/UIConfig_sfx.mk1
-rw-r--r--sfx2/source/doc/doc.hrc1
-rw-r--r--sfx2/source/doc/new.cxx321
-rw-r--r--sfx2/source/doc/new.hrc48
-rw-r--r--sfx2/source/doc/new.src236
-rw-r--r--sfx2/source/inc/preview.hxx14
-rw-r--r--sfx2/uiconfig/ui/loadtemplatedialog.ui358
9 files changed, 472 insertions, 511 deletions
diff --git a/extras/source/glade/libreoffice-catalog.xml.in b/extras/source/glade/libreoffice-catalog.xml.in
index c48fb9d67f09..94390411f213 100644
--- a/extras/source/glade/libreoffice-catalog.xml.in
+++ b/extras/source/glade/libreoffice-catalog.xml.in
@@ -245,6 +245,9 @@
<glade-widget-class title="Token Window" name="swuilo-SwTokenWindow"
generic-name="Token Window" parent="GtkDrawingArea"
icon-name="widget-gtk-drawingarea"/>
+ <glade-widget-class title="Template Preview Window" name="sfxlo-SfxPreviewWin"
+ generic-name="Template Preview Window" parent="GtkDrawingArea"
+ icon-name="widget-gtk-drawingarea"/>
<glade-widget-class title="Mark Preview" name="swuilo-SwMarkPreview"
generic-name="Mark Preview Window" parent="GtkDrawingArea"
icon-name="widget-gtk-drawingarea"/>
diff --git a/sfx2/AllLangResTarget_sfx2.mk b/sfx2/AllLangResTarget_sfx2.mk
index 290c81452f84..42e1661ff2c1 100644
--- a/sfx2/AllLangResTarget_sfx2.mk
+++ b/sfx2/AllLangResTarget_sfx2.mk
@@ -52,7 +52,6 @@ $(eval $(call gb_SrsTarget_add_files,sfx/res,\
sfx2/source/dialog/versdlg.src \
sfx2/source/doc/doc.src \
sfx2/source/doc/doctempl.src \
- sfx2/source/doc/new.src \
sfx2/source/doc/templatelocnames.src \
sfx2/source/menu/menu.src \
sfx2/source/sidebar/Sidebar.src \
diff --git a/sfx2/UIConfig_sfx.mk b/sfx2/UIConfig_sfx.mk
index a39c171e7ae8..489d9b082a8c 100644
--- a/sfx2/UIConfig_sfx.mk
+++ b/sfx2/UIConfig_sfx.mk
@@ -28,6 +28,7 @@ $(eval $(call gb_UIConfig_add_uifiles,sfx,\
sfx2/uiconfig/ui/helpsearchpage \
sfx2/uiconfig/ui/inputdialog \
sfx2/uiconfig/ui/licensedialog \
+ sfx2/uiconfig/ui/loadtemplatedialog \
sfx2/uiconfig/ui/managestylepage \
sfx2/uiconfig/ui/newstyle \
sfx2/uiconfig/ui/optprintpage \
diff --git a/sfx2/source/doc/doc.hrc b/sfx2/source/doc/doc.hrc
index 2aa21e77fb9d..afd9c1d1a3f0 100644
--- a/sfx2/source/doc/doc.hrc
+++ b/sfx2/source/doc/doc.hrc
@@ -36,7 +36,6 @@
#define STR_DELETE_TEMPLATE (RID_SFX_DOC_START+15)
#define MSG_REGION_NOTEMPTY (RID_SFX_DOC_START+17)
-#define DLG_NEW_FILE (RID_SFX_DOC_START+1)
#define DLG_DOC_TEMPLATE (RID_SFX_DOC_START+2)
#define DLG_TEMPLATE_MANAGER (RID_SFX_DOC_START+4)
diff --git a/sfx2/source/doc/new.cxx b/sfx2/source/doc/new.cxx
index 1d12e6e4fe78..7f8afa81ded5 100644
--- a/sfx2/source/doc/new.cxx
+++ b/sfx2/source/doc/new.cxx
@@ -19,8 +19,9 @@
#include <comphelper/string.hxx>
#include <sfx2/new.hxx>
+#include <vcl/builder.hxx>
+#include <vcl/layout.hxx>
#include <vcl/msgbox.hxx>
-#include <vcl/morebtn.hxx>
#include <svtools/svmedit.hxx>
#include <svl/itemset.hxx>
#include <svl/eitem.hxx>
@@ -29,7 +30,6 @@
#include <tools/urlobj.hxx>
#include <unotools/localfilehelper.hxx>
-#include "new.hrc"
#include "doc.hrc"
#include <sfx2/app.hxx>
#include <sfx2/objsh.hxx>
@@ -39,12 +39,6 @@
#include <sfx2/printer.hxx>
#include <vcl/waitobj.hxx>
-
-
-#define MORE_BTN(x) pMoreBt->x
-
-
-
void SfxPreviewBase_Impl::SetObjectShell( SfxObjectShell* pObj )
{
::boost::shared_ptr<GDIMetaFile> pFile = pObj
@@ -55,18 +49,20 @@ void SfxPreviewBase_Impl::SetObjectShell( SfxObjectShell* pObj )
}
SfxPreviewBase_Impl::SfxPreviewBase_Impl(
- Window* pParent, const ResId& rResId )
- : Window(pParent, rResId), pMetaFile()
+ Window* pParent, WinBits nStyle)
+ : Window(pParent, nStyle)
+ , pMetaFile()
{
}
-SfxPreviewBase_Impl::~SfxPreviewBase_Impl()
+void SfxPreviewBase_Impl::Resize()
{
+ Invalidate();
}
-void SfxPreviewBase_Impl::Resize()
+Size SfxPreviewBase_Impl::GetOptimalSize() const
{
- Invalidate();
+ return LogicToPixel(Size(127, 129), MAP_APPFONT);
}
void SfxPreviewWin_Impl::ImpPaint(
@@ -119,37 +115,26 @@ void SfxPreviewWin_Impl::Paint( const Rectangle& rRect )
ImpPaint( rRect, pMetaFile.get(), this );
}
+extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeSfxPreviewWin(Window *pParent, VclBuilder::stringmap &)
+{
+ return new SfxPreviewWin_Impl(pParent, 0);
+}
+
class SfxNewFileDialog_Impl
{
- FixedText aRegionFt;
- ListBox aRegionLb;
- FixedText aTemplateFt;
- ListBox aTemplateLb;
-
- CheckBox aPreviewBtn;
- SfxPreviewWin_Impl aPreviewWin;
-
- FixedText aTitleFt;
- Edit aTitleEd;
- FixedText aThemaFt;
- Edit aThemaEd;
- FixedText aKeywordsFt;
- Edit aKeywordsEd;
- FixedText aDescFt;
- MultiLineEdit aDescEd;
- FixedLine aDocinfoGb;
-
- CheckBox aTextStyleCB;
- CheckBox aFrameStyleCB;
- CheckBox aPageStyleCB;
- CheckBox aNumStyleCB;
- CheckBox aMergeStyleCB;
- PushButton aLoadFilePB;
-
- OKButton aOkBt;
- CancelButton aCancelBt;
- HelpButton aHelpBt;
- MoreButton* pMoreBt;
+ ListBox* m_pRegionLb;
+ ListBox* m_pTemplateLb;
+
+ SfxPreviewWin_Impl* m_pPreviewWin;
+
+ CheckBox* m_pTextStyleCB;
+ CheckBox* m_pFrameStyleCB;
+ CheckBox* m_pPageStyleCB;
+ CheckBox* m_pNumStyleCB;
+ CheckBox* m_pMergeStyleCB;
+ PushButton* m_pLoadFilePB;
+
+ VclExpander* m_pMoreBt;
Timer aPrevTimer;
OUString aNone;
OUString sLoadTemplate;
@@ -167,7 +152,6 @@ class SfxNewFileDialog_Impl
DECL_LINK( DoubleClick, ListBox * );
void TogglePreview(CheckBox *);
DECL_LINK( Expand, void * );
- DECL_LINK( PreviewClick, CheckBox * );
DECL_LINK(LoadFile, void *);
sal_uInt16 GetSelectedTemplatePos() const;
@@ -186,20 +170,11 @@ public:
void SetTemplateFlags(sal_uInt16 nSet);
};
-
-
-
void SfxNewFileDialog_Impl::ClearInfo()
{
const OUString aNo;
- aTitleEd.SetText(aNo);
- aThemaEd.SetText(aNo);
- aKeywordsEd.SetText(aNo);
- aDescEd.SetText(aNo);
}
-
-
IMPL_LINK_NOARG(SfxNewFileDialog_Impl, Update)
{
if ( xDocShell.Is() )
@@ -213,15 +188,15 @@ IMPL_LINK_NOARG(SfxNewFileDialog_Impl, Update)
if(!nEntry)
{
ClearInfo();
- aPreviewWin.Invalidate();
- aPreviewWin.SetObjectShell( 0);
+ m_pPreviewWin->Invalidate();
+ m_pPreviewWin->SetObjectShell( 0);
return 0;
}
- if ( aPreviewBtn.IsChecked() && (nFlags & SFXWB_PREVIEW) == SFXWB_PREVIEW)
+ if ( m_pMoreBt->get_expanded() && (nFlags & SFXWB_PREVIEW) == SFXWB_PREVIEW)
{
- OUString aFileName = aTemplates.GetPath( aRegionLb.GetSelectEntryPos(), nEntry-1);
+ OUString aFileName = aTemplates.GetPath( m_pRegionLb->GetSelectEntryPos(), nEntry-1);
INetURLObject aTestObj( aFileName );
if( aTestObj.GetProtocol() == INET_PROT_NOT_VALID )
{
@@ -263,12 +238,12 @@ IMPL_LINK_NOARG(SfxNewFileDialog_Impl, Update)
Application::SetDefDialogParent( pParent );
if ( !xDocShell.Is() )
{
- aPreviewWin.SetObjectShell( 0 );
+ m_pPreviewWin->SetObjectShell( 0 );
return sal_False;
}
}
- aPreviewWin.SetObjectShell( xDocShell );
+ m_pPreviewWin->SetObjectShell( xDocShell );
}
return sal_True;
}
@@ -282,64 +257,39 @@ IMPL_LINK( SfxNewFileDialog_Impl, RegionSelect, ListBox *, pBox )
const sal_uInt16 nRegion = pBox->GetSelectEntryPos();
const sal_uInt16 nCount = aTemplates.GetRegionCount()? aTemplates.GetCount(nRegion): 0;
- aTemplateLb.SetUpdateMode(false);
- aTemplateLb.Clear();
- OUString aSel = aRegionLb.GetSelectEntry();
+ m_pTemplateLb->SetUpdateMode(false);
+ m_pTemplateLb->Clear();
+ OUString aSel = m_pRegionLb->GetSelectEntry();
sal_Int32 nc = aSel.indexOf('(');
if (nc != -1 && nc != 0)
aSel = aSel.replaceAt(nc-1, 1, "");
if ( aSel.compareToIgnoreAsciiCase( SfxResId(STR_STANDARD).toString() ) == 0 )
- aTemplateLb.InsertEntry(aNone);
+ m_pTemplateLb->InsertEntry(aNone);
for (sal_uInt16 i = 0; i < nCount; ++i)
- aTemplateLb.InsertEntry(aTemplates.GetName(nRegion, i));
- aTemplateLb.SelectEntryPos(0);
- aTemplateLb.SetUpdateMode(true);
- aTemplateLb.Invalidate();
- aTemplateLb.Update();
- TemplateSelect(&aTemplateLb);
+ m_pTemplateLb->InsertEntry(aTemplates.GetName(nRegion, i));
+ m_pTemplateLb->SelectEntryPos(0);
+ m_pTemplateLb->SetUpdateMode(true);
+ m_pTemplateLb->Invalidate();
+ m_pTemplateLb->Update();
+ TemplateSelect(m_pTemplateLb);
return 0;
}
-
-
IMPL_LINK_NOARG_INLINE_START(SfxNewFileDialog_Impl, Expand)
{
- TemplateSelect(&aTemplateLb);
+ TemplateSelect(m_pTemplateLb);
return 0;
}
IMPL_LINK_NOARG_INLINE_END(SfxNewFileDialog_Impl, Expand)
-
-IMPL_LINK( SfxNewFileDialog_Impl, PreviewClick, CheckBox *, pBox )
-{
- if ( xDocShell.Is() && xDocShell->GetProgress() )
- return 0;
-
- sal_uInt16 nEntry = GetSelectedTemplatePos();
- if ( nEntry && pBox->IsChecked() )
- {
- if(!Update(0))
- aPreviewWin.Invalidate();
- }
- else
- {
- if (xDocShell.Is())
- xDocShell.Clear();
- aPreviewWin.SetObjectShell( 0 );
- }
- return 0;
-}
-
-
-
IMPL_LINK_NOARG(SfxNewFileDialog_Impl, TemplateSelect)
{
// Still loading
if ( xDocShell && xDocShell->GetProgress() )
return 0;
- if ( !MORE_BTN(GetState()) )
+ if (!m_pMoreBt->get_expanded())
// Dialog is not opened
return 0;
@@ -347,8 +297,6 @@ IMPL_LINK_NOARG(SfxNewFileDialog_Impl, TemplateSelect)
return 0;
}
-
-
IMPL_LINK_INLINE_START( SfxNewFileDialog_Impl, DoubleClick, ListBox *, pListBox )
{
(void)pListBox;
@@ -371,14 +319,14 @@ IMPL_LINK_NOARG_INLINE_END(SfxNewFileDialog_Impl, LoadFile)
sal_uInt16 SfxNewFileDialog_Impl::GetSelectedTemplatePos() const
{
- sal_uInt16 nEntry = aTemplateLb.GetSelectEntryPos();
- OUString aSel = aRegionLb.GetSelectEntry();
+ sal_uInt16 nEntry = m_pTemplateLb->GetSelectEntryPos();
+ OUString aSel = m_pRegionLb->GetSelectEntry();
sal_Int32 nc = aSel.indexOf('(');
if (nc != -1 && nc != 0)
aSel = aSel.replaceAt(nc-1, 1, "");
if ( aSel.compareToIgnoreAsciiCase(SfxResId(STR_STANDARD).toString()) != 0 )
nEntry++;
- if (!aTemplateLb.GetSelectEntryCount())
+ if (!m_pTemplateLb->GetSelectEntryCount())
nEntry = 0;
return nEntry;
}
@@ -391,147 +339,91 @@ sal_Bool SfxNewFileDialog_Impl::IsTemplate() const
}
-
-
OUString SfxNewFileDialog_Impl::GetTemplateFileName() const
{
if(!IsTemplate() || !aTemplates.GetRegionCount())
return OUString();
- return aTemplates.GetPath(aRegionLb.GetSelectEntryPos(),
+ return aTemplates.GetPath(m_pRegionLb->GetSelectEntryPos(),
GetSelectedTemplatePos()-1);
}
-
-
-void AdjustPosSize_Impl(Window *pWin, short nMoveOffset, short nSizeOffset)
-{
- Point aPos(pWin->GetPosPixel());
- Size aSize(pWin->GetSizePixel());
- aPos.X() -= nMoveOffset;
- aSize.Width() += nSizeOffset;
- pWin->SetPosSizePixel(aPos, aSize);
-}
-
sal_uInt16 SfxNewFileDialog_Impl::GetTemplateFlags()const
{
- sal_uInt16 nRet = aTextStyleCB.IsChecked() ? SFX_LOAD_TEXT_STYLES : 0;
- if(aFrameStyleCB.IsChecked())
+ sal_uInt16 nRet = m_pTextStyleCB->IsChecked() ? SFX_LOAD_TEXT_STYLES : 0;
+ if(m_pFrameStyleCB->IsChecked())
nRet |= SFX_LOAD_FRAME_STYLES;
- if(aPageStyleCB.IsChecked())
+ if(m_pPageStyleCB->IsChecked())
nRet |= SFX_LOAD_PAGE_STYLES;
- if(aNumStyleCB.IsChecked())
+ if(m_pNumStyleCB->IsChecked())
nRet |= SFX_LOAD_NUM_STYLES;
- if(aMergeStyleCB.IsChecked())
+ if(m_pMergeStyleCB->IsChecked())
nRet |= SFX_MERGE_STYLES;
return nRet;
}
void SfxNewFileDialog_Impl::SetTemplateFlags(sal_uInt16 nSet)
{
- aTextStyleCB.Check( 0 != (nSet&SFX_LOAD_TEXT_STYLES ));
- aFrameStyleCB.Check( 0 != (nSet&SFX_LOAD_FRAME_STYLES));
- aPageStyleCB.Check( 0 != (nSet&SFX_LOAD_PAGE_STYLES ));
- aNumStyleCB.Check( 0 != (nSet&SFX_LOAD_NUM_STYLES ));
- aMergeStyleCB.Check( 0 != (nSet&SFX_MERGE_STYLES ));
+ m_pTextStyleCB->Check( 0 != (nSet&SFX_LOAD_TEXT_STYLES ));
+ m_pFrameStyleCB->Check( 0 != (nSet&SFX_LOAD_FRAME_STYLES));
+ m_pPageStyleCB->Check( 0 != (nSet&SFX_LOAD_PAGE_STYLES ));
+ m_pNumStyleCB->Check( 0 != (nSet&SFX_LOAD_NUM_STYLES ));
+ m_pMergeStyleCB->Check( 0 != (nSet&SFX_MERGE_STYLES ));
}
SfxNewFileDialog_Impl::SfxNewFileDialog_Impl(
SfxNewFileDialog* pAntiImplP, sal_uInt16 nFl)
- : aRegionFt( pAntiImplP, SfxResId( FT_REGION ) ),
- aRegionLb( pAntiImplP, SfxResId( LB_REGION ) ),
- aTemplateFt( pAntiImplP, SfxResId( FT_TEMPLATE ) ),
- aTemplateLb( pAntiImplP, SfxResId( LB_TEMPLATE ) ),
- aPreviewBtn( pAntiImplP, SfxResId( BTN_PREVIEW ) ),
- aPreviewWin( pAntiImplP, SfxResId( WIN_PREVIEW ) ),
- aTitleFt( pAntiImplP, SfxResId( FT_TITLE ) ),
- aTitleEd( pAntiImplP, SfxResId( ED_TITLE ) ),
- aThemaFt( pAntiImplP, SfxResId( FT_THEMA ) ),
- aThemaEd( pAntiImplP, SfxResId( ED_THEMA ) ),
- aKeywordsFt( pAntiImplP, SfxResId( FT_KEYWORDS ) ),
- aKeywordsEd( pAntiImplP, SfxResId( ED_KEYWORDS ) ),
- aDescFt( pAntiImplP, SfxResId( FT_DESC ) ),
- aDescEd( pAntiImplP, SfxResId( ED_DESC ) ),
- aDocinfoGb( pAntiImplP, SfxResId( GB_DOCINFO ) ),
- aTextStyleCB( pAntiImplP, SfxResId( CB_TEXT_STYLE )),
- aFrameStyleCB( pAntiImplP, SfxResId( CB_FRAME_STYLE )),
- aPageStyleCB( pAntiImplP, SfxResId( CB_PAGE_STYLE )),
- aNumStyleCB( pAntiImplP, SfxResId( CB_NUM_STYLE )),
- aMergeStyleCB( pAntiImplP, SfxResId( CB_MERGE_STYLE )),
- aLoadFilePB( pAntiImplP, SfxResId( PB_LOAD_FILE )),
- aOkBt( pAntiImplP, SfxResId( BT_OK ) ),
- aCancelBt( pAntiImplP, SfxResId( BT_CANCEL ) ),
- aHelpBt( pAntiImplP, SfxResId( BT_HELP ) ),
- pMoreBt( new MoreButton( pAntiImplP, SfxResId( BT_MORE ) ) ),
- aNone(SfxResId(STR_NONE).toString()),
- sLoadTemplate(SfxResId(STR_LOAD_TEMPLATE).toString()),
- nFlags(nFl),
- pAntiImpl( pAntiImplP )
+ : aNone(SfxResId(STR_NONE).toString())
+ , nFlags(nFl)
+ , pAntiImpl(pAntiImplP)
{
- short nMoveOffset = *(short *)pAntiImplP->GetClassRes();
- pAntiImplP->IncrementRes(sizeof(short));
- short nExpandSize= *(short *)pAntiImplP->GetClassRes();
- pAntiImplP->IncrementRes(sizeof(short));
- pAntiImplP->FreeResource();
+ pAntiImplP->get(m_pRegionLb, "categories");
+ pAntiImplP->get(m_pTemplateLb, "templates");
+
+ Size aSize(m_pRegionLb->LogicToPixel(Size(127, 72), MAP_APPFONT));
+ m_pRegionLb->set_width_request(aSize.Width());
+ m_pRegionLb->set_height_request(aSize.Height());
+ m_pTemplateLb->set_width_request(aSize.Width());
+ m_pTemplateLb->set_height_request(aSize.Height());
+
+ pAntiImplP->get(m_pTextStyleCB, "text");
+ pAntiImplP->get(m_pFrameStyleCB, "frame");
+ pAntiImplP->get(m_pPageStyleCB, "pages");
+ pAntiImplP->get(m_pNumStyleCB, "numbering");
+ pAntiImplP->get(m_pMergeStyleCB, "overwrite");
+ pAntiImplP->get(m_pMoreBt, "expander");
+ pAntiImplP->get(m_pPreviewWin, "image");
+ pAntiImplP->get(m_pLoadFilePB, "fromfile");
+ sLoadTemplate = pAntiImplP->get<FixedText>("alttitle")->GetText();
if (!nFlags)
- MORE_BTN(Hide());
+ m_pMoreBt->Hide();
else if(SFXWB_LOAD_TEMPLATE == nFlags)
{
- aLoadFilePB.SetClickHdl(LINK(this, SfxNewFileDialog_Impl, LoadFile));
- aLoadFilePB.Show();
- aTextStyleCB.Show();
- aFrameStyleCB.Show();
- aPageStyleCB.Show();
- aNumStyleCB.Show();
- aMergeStyleCB.Show();
- Size aSize(pAntiImplP->GetOutputSizePixel());
- Size aTmp(pAntiImplP->LogicToPixel(Size(16, 16), MAP_APPFONT));
- aSize.Height() += aTmp.Height();
- pAntiImplP->SetOutputSizePixel(aSize);
- pMoreBt->Hide();
- aTextStyleCB.Check();
+ m_pLoadFilePB->SetClickHdl(LINK(this, SfxNewFileDialog_Impl, LoadFile));
+ m_pLoadFilePB->Show();
+ m_pTextStyleCB->Show();
+ m_pFrameStyleCB->Show();
+ m_pPageStyleCB->Show();
+ m_pNumStyleCB->Show();
+ m_pMergeStyleCB->Show();
+ m_pMoreBt->Hide();
+ m_pTextStyleCB->Check();
pAntiImplP->SetText(sLoadTemplate);
}
else
{
- MORE_BTN(SetClickHdl(LINK(this, SfxNewFileDialog_Impl, Expand)));
- if((nFlags & SFXWB_PREVIEW) == SFXWB_PREVIEW)
- {
- MORE_BTN(AddWindow(&aPreviewBtn));
- MORE_BTN(AddWindow(&aPreviewWin));
- aPreviewBtn.SetClickHdl(LINK(this, SfxNewFileDialog_Impl, PreviewClick));
- }
- else
- {
- aPreviewBtn.Hide();
- aPreviewWin.Hide();
- nMoveOffset = (short)pAntiImplP->LogicToPixel(
- Size(nMoveOffset, nMoveOffset), MAP_APPFONT).Width();
- nExpandSize = (short)pAntiImplP->LogicToPixel(
- Size(nExpandSize, nExpandSize), MAP_APPFONT).Width();
- AdjustPosSize_Impl(&aTitleFt, nMoveOffset, 0);
- AdjustPosSize_Impl(&aTitleEd, nMoveOffset, nExpandSize);
- AdjustPosSize_Impl(&aThemaFt, nMoveOffset, 0);
- AdjustPosSize_Impl(&aThemaEd, nMoveOffset, nExpandSize);
- AdjustPosSize_Impl(&aKeywordsFt, nMoveOffset, 0);
- AdjustPosSize_Impl(&aKeywordsEd, nMoveOffset, nExpandSize);
- AdjustPosSize_Impl(&aDescFt , nMoveOffset, 0);
- AdjustPosSize_Impl(&aDescEd , nMoveOffset, nExpandSize);
- AdjustPosSize_Impl(&aDocinfoGb, nMoveOffset, nExpandSize);
- }
+ m_pMoreBt->SetExpandedHdl(LINK(this, SfxNewFileDialog_Impl, Expand));
+ m_pPreviewWin->Show();
}
OUString &rExtra = pAntiImplP->GetExtraData();
- sal_Int32 nTokCount = comphelper::string::getTokenCount(rExtra, '|');
- if( nTokCount > 0 && nFlags )
- MORE_BTN(SetState(comphelper::string::equals(rExtra.getToken( 0, '|'), 'Y')));
- if( nTokCount > 1 && nFlags )
- aPreviewBtn.Check(comphelper::string::equals(rExtra.getToken( 1 ,'|'), 'Y'));
+ bool bExpand = !rExtra.isEmpty() && rExtra[0] == 'Y';
+ m_pMoreBt->set_expanded(bExpand && nFlags);
- aTemplateLb.SetSelectHdl(LINK(this, SfxNewFileDialog_Impl, TemplateSelect));
- aTemplateLb.SetDoubleClickHdl(LINK(this, SfxNewFileDialog_Impl, DoubleClick));
+ m_pTemplateLb->SetSelectHdl(LINK(this, SfxNewFileDialog_Impl, TemplateSelect));
+ m_pTemplateLb->SetDoubleClickHdl(LINK(this, SfxNewFileDialog_Impl, DoubleClick));
// update the template configuration if necessary
{
@@ -543,33 +435,28 @@ SfxNewFileDialog_Impl::SfxNewFileDialog_Impl(
if (nCount)
{
for(sal_uInt16 i = 0; i < nCount; ++i)
- aRegionLb.InsertEntry(aTemplates.GetFullRegionName(i));
- aRegionLb.SetSelectHdl(LINK(this, SfxNewFileDialog_Impl, RegionSelect));
+ m_pRegionLb->InsertEntry(aTemplates.GetFullRegionName(i));
+ m_pRegionLb->SetSelectHdl(LINK(this, SfxNewFileDialog_Impl, RegionSelect));
}
aPrevTimer.SetTimeout( 500 );
aPrevTimer.SetTimeoutHdl( LINK( this, SfxNewFileDialog_Impl, Update));
- aRegionLb.SelectEntryPos(0);
- RegionSelect(&aRegionLb);
+ m_pRegionLb->SelectEntryPos(0);
+ RegionSelect(m_pRegionLb);
}
-
-
SfxNewFileDialog_Impl::~SfxNewFileDialog_Impl()
{
OUString &rExtra = pAntiImpl->GetExtraData();
- rExtra = MORE_BTN(GetState()) ? OUString("Y") : OUString("N");
- rExtra += "|";
- rExtra += aPreviewBtn.IsChecked() ? OUString("Y") : OUString("N");
-
- delete pMoreBt;
+ rExtra = m_pMoreBt->get_expanded() ? OUString("Y") : OUString("N");
}
SfxNewFileDialog::SfxNewFileDialog(Window *pParent, sal_uInt16 nFlags)
- : SfxModalDialog( pParent, SfxResId( DLG_NEW_FILE ) )
+ : SfxModalDialog(pParent, "LoadTemplateDialog",
+ "sfx/ui/loadtemplatedialog.ui")
{
- pImpl = new SfxNewFileDialog_Impl( this, nFlags );
+ pImpl = new SfxNewFileDialog_Impl(this, nFlags);
}
SfxNewFileDialog::~SfxNewFileDialog()
diff --git a/sfx2/source/doc/new.hrc b/sfx2/source/doc/new.hrc
deleted file mode 100644
index d548001906fd..000000000000
--- a/sfx2/source/doc/new.hrc
+++ /dev/null
@@ -1,48 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed
- * with this work for additional information regarding copyright
- * ownership. The ASF licenses this file to you under the Apache
- * License, Version 2.0 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#define BTN_PREVIEW 51
-#define WIN_PREVIEW 50
-#define GB_DESC 10
-#define FT_DESC 11
-#define FT_STYLESHEETS 19
-#define FT_REGION 20
-#define ED_TITLE 56
-#define ED_KEYWORDS 61
-#define FT_KEYWORDS 60
-#define FT_TITLE 55
-#define ED_DESC 71
-#define LB_REGION 21
-#define BT_OK 30
-#define BT_CANCEL 31
-#define BT_HELP 32
-#define GB_DOCINFO 70
-#define ED_THEMA 55
-#define FT_THEMA 54
-#define FT_TEMPLATE 53
-#define LB_TEMPLATE 52
-#define BT_MORE 32
-#define CB_TEXT_STYLE 33
-#define CB_FRAME_STYLE 34
-#define CB_PAGE_STYLE 35
-#define CB_NUM_STYLE 36
-#define CB_MERGE_STYLE 37
-#define PB_LOAD_FILE 38
-#define STR_LOAD_TEMPLATE 39
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/doc/new.src b/sfx2/source/doc/new.src
deleted file mode 100644
index 26d02f9a488f..000000000000
--- a/sfx2/source/doc/new.src
+++ /dev/null
@@ -1,236 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed
- * with this work for additional information regarding copyright
- * ownership. The ASF licenses this file to you under the Apache
- * License, Version 2.0 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include <sfx2/sfx.hrc>
-#include "doc.hrc"
-#include "new.hrc"
-#include <sfx2/sfxcommands.h>
-
- // DLG_NEW_FILE ----------------------------------------------------------
-ModalDialog DLG_NEW_FILE
-{
- HelpId = CMD_SID_NEWDOC ;
- OutputSize = TRUE ;
- SVLook = TRUE ;
- Size = MAP_APPFONT ( 336 , 96 ) ;
- Text [ en-US ] = "New" ;
- Moveable = TRUE ;
- OKButton BT_OK
- {
- Pos = MAP_APPFONT ( 274 , 6 ) ;
- Size = MAP_APPFONT ( 56 , 14 ) ;
- DefButton = TRUE ;
- };
- CancelButton BT_CANCEL
- {
- Pos = MAP_APPFONT ( 274 , 23 ) ;
- Size = MAP_APPFONT ( 56 , 14 ) ;
- };
- HelpButton BT_HELP
- {
- Pos = MAP_APPFONT ( 274 , 43 ) ;
- Size = MAP_APPFONT ( 56 , 14 ) ;
- };
- ListBox LB_REGION
- {
- HelpID = "sfx2:ListBox:DLG_NEW_FILE:LB_REGION";
- Border = TRUE ;
- Pos = MAP_APPFONT ( 6 , 18 ) ;
- Size = MAP_APPFONT ( 127 , 72 ) ;
- CurPos = 0 ;
- };
- FixedText FT_REGION
- {
- Pos = MAP_APPFONT ( 6 , 6 ) ;
- Size = MAP_APPFONT ( 97 , 10 ) ;
- Text [ en-US ] = "~Categories" ;
- Left = TRUE ;
- };
- FixedText FT_TEMPLATE
- {
- Pos = MAP_APPFONT ( 139 , 6 ) ;
- Size = MAP_APPFONT ( 97 , 10 ) ;
- Text [ en-US ] = "T~emplates" ;
- Left = TRUE ;
- };
- ListBox LB_TEMPLATE
- {
- HelpID = "sfx2:ListBox:DLG_NEW_FILE:LB_TEMPLATE";
- Border = TRUE ;
- Pos = MAP_APPFONT ( 139 , 18 ) ;
- Size = MAP_APPFONT ( 127 , 72 ) ;
- CurPos = 0 ;
- };
- MoreButton BT_MORE
- {
- HelpID = "sfx2:MoreButton:DLG_NEW_FILE:BT_MORE";
- Pos = MAP_APPFONT ( 274 , 70 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- Text [ en-US ] = "~More" ;
- Delta = 148 ;
- MapUnit = MAP_APPFONT ;
- };
- Window WIN_PREVIEW
- {
- Border = TRUE ;
- Pos = MAP_APPFONT ( 6 , 110 ) ;
- Size = MAP_APPFONT ( 127 , 129 ) ;
- Hide = TRUE ;
- SVLook = FALSE ;
- };
- CheckBox BTN_PREVIEW
- {
- HelpID = "sfx2:CheckBox:DLG_NEW_FILE:BTN_PREVIEW";
- Pos = MAP_APPFONT ( 6 , 96 ) ;
- Size = MAP_APPFONT ( 97 , 10 ) ;
- Text [ en-US ] = "Pre~view" ;
- Hide = TRUE ;
- };
- FixedLine GB_DOCINFO
- {
- Pos = MAP_APPFONT ( 139 , 97 ) ;
- Size = MAP_APPFONT ( 186 , 8 ) ;
- Hide = TRUE ;
- Text [ en-US ] = "Description" ;
- };
- CheckBox CB_TEXT_STYLE
- {
- HelpID = "sfx2:CheckBox:DLG_NEW_FILE:CB_TEXT_STYLE";
- Pos = MAP_APPFONT ( 6 , 94 ) ;
- Size = MAP_APPFONT ( 50 , 10 ) ;
- Hide = TRUE;
- Text [ en-US ] = "Te~xt" ;
- };
- CheckBox CB_FRAME_STYLE
- {
- HelpID = "sfx2:CheckBox:DLG_NEW_FILE:CB_FRAME_STYLE";
- Pos = MAP_APPFONT ( 60 , 94 ) ;
- Size = MAP_APPFONT ( 50 , 10 ) ;
- Hide = TRUE;
- Text [ en-US ] = "~Frame" ;
- };
- CheckBox CB_PAGE_STYLE
- {
- HelpID = "sfx2:CheckBox:DLG_NEW_FILE:CB_PAGE_STYLE";
- Pos = MAP_APPFONT ( 114 , 94 ) ;
- Size = MAP_APPFONT ( 50 , 10 ) ;
- Hide = TRUE;
- Text [ en-US ] = "~Pages" ;
- };
- CheckBox CB_NUM_STYLE
- {
- HelpID = "sfx2:CheckBox:DLG_NEW_FILE:CB_NUM_STYLE";
- Pos = MAP_APPFONT ( 168 , 94 ) ;
- Size = MAP_APPFONT ( 50 , 10 ) ;
- Hide = TRUE;
- Text [ en-US ] = "N~umbering" ;
- };
- CheckBox CB_MERGE_STYLE
- {
- HelpID = "sfx2:CheckBox:DLG_NEW_FILE:CB_MERGE_STYLE";
- Pos = MAP_APPFONT ( 222 , 94 ) ;
- Size = MAP_APPFONT ( 50 , 10 ) ;
- Hide = TRUE;
- Text [ en-US ] = "~Overwrite" ;
- };
- PushButton PB_LOAD_FILE
- {
- HelpID = "sfx2:PushButton:DLG_NEW_FILE:PB_LOAD_FILE";
- Pos = MAP_APPFONT ( 274 , 92 ) ;
- Size = MAP_APPFONT ( 56 , 14 ) ;
- Hide = TRUE;
- Text [ en-US ] = "From File...";
- };
- String STR_LOAD_TEMPLATE
- {
- Text [ en-US ] = "Load Styles" ;
- };
- FixedText FT_TITLE
- {
- Pos = MAP_APPFONT ( 145 , 108 ) ;
- Size = MAP_APPFONT ( 175 , 10 ) ;
- Text [ en-US ] = "~Title" ;
- Hide = TRUE ;
- };
- Edit ED_TITLE
- {
- HelpID = "sfx2:Edit:DLG_NEW_FILE:ED_TITLE";
- Border = TRUE ;
- Pos = MAP_APPFONT ( 145 , 121 ) ;
- Size = MAP_APPFONT ( 175 , 12 ) ;
- ReadOnly = TRUE ;
- Hide = TRUE ;
- };
- FixedText FT_THEMA
- {
- Pos = MAP_APPFONT ( 145 , 135 ) ;
- Size = MAP_APPFONT ( 175 , 10 ) ;
- Text [ en-US ] = "Subject" ;
- Hide = TRUE ;
- };
- Edit ED_THEMA
- {
- HelpID = "sfx2:Edit:DLG_NEW_FILE:ED_THEMA";
- Border = TRUE ;
- Pos = MAP_APPFONT ( 145 , 148 ) ;
- Size = MAP_APPFONT ( 175 , 12 ) ;
- ReadOnly = TRUE ;
- Hide = TRUE ;
- };
- FixedText FT_KEYWORDS
- {
- Pos = MAP_APPFONT ( 145 , 162 ) ;
- Size = MAP_APPFONT ( 175 , 10 ) ;
- Text [ en-US ] = "~Key words" ;
- Hide = TRUE ;
- };
- Edit ED_KEYWORDS
- {
- HelpID = "sfx2:Edit:DLG_NEW_FILE:ED_KEYWORDS";
- Border = TRUE ;
- Pos = MAP_APPFONT ( 145 , 175 ) ;
- Size = MAP_APPFONT ( 175 , 12 ) ;
- ReadOnly = TRUE ;
- Hide = TRUE ;
- };
- FixedText FT_DESC
- {
- Pos = MAP_APPFONT ( 145 , 189 ) ;
- Size = MAP_APPFONT ( 175 , 10 ) ;
- Text [ en-US ] = "~Description" ;
- Hide = TRUE ;
- };
- MultiLineEdit ED_DESC
- {
- HelpID = "sfx2:MultiLineEdit:DLG_NEW_FILE:ED_DESC";
- Border = TRUE ;
- Pos = MAP_APPFONT ( 144 , 202 ) ;
- Size = MAP_APPFONT ( 175 , 32 ) ;
- IgnoreTab = TRUE ;
- ReadOnly = TRUE ;
- Hide = TRUE ;
- };
- ExtraData =
- {
- 103;
- 44;
- };
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/inc/preview.hxx b/sfx2/source/inc/preview.hxx
index 19dd4a58a235..725ee3a59042 100644
--- a/sfx2/source/inc/preview.hxx
+++ b/sfx2/source/inc/preview.hxx
@@ -31,23 +31,21 @@ class SfxPreviewBase_Impl : public Window
protected:
::boost::shared_ptr<GDIMetaFile> pMetaFile;
public:
- SfxPreviewBase_Impl( Window* pParent,
- const ResId& rResId );
- ~SfxPreviewBase_Impl( );
+ SfxPreviewBase_Impl(Window* pParent, WinBits nStyle);
void SetObjectShell( SfxObjectShell* pObj );
virtual void Resize();
+ virtual Size GetOptimalSize() const;
};
-
-
class SfxPreviewWin_Impl: public SfxPreviewBase_Impl
{
protected:
virtual void Paint( const Rectangle& rRect );
public:
- SfxPreviewWin_Impl( Window* pParent,
- const ResId& rResId )
- : SfxPreviewBase_Impl( pParent, rResId ){};
+ SfxPreviewWin_Impl(Window* pParent, WinBits nStyle)
+ : SfxPreviewBase_Impl(pParent, nStyle)
+ {
+ }
static void ImpPaint(
const Rectangle& rRect, GDIMetaFile* pFile, Window* pWindow );
};
diff --git a/sfx2/uiconfig/ui/loadtemplatedialog.ui b/sfx2/uiconfig/ui/loadtemplatedialog.ui
new file mode 100644
index 000000000000..d23a8db9b8a6
--- /dev/null
+++ b/sfx2/uiconfig/ui/loadtemplatedialog.ui
@@ -0,0 +1,358 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.16.1 -->
+<interface>
+ <requires lib="gtk+" version="3.0"/>
+ <!-- interface-requires LibreOffice 1.0 -->
+ <object class="GtkDialog" id="LoadTemplateDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">New</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="hexpand">True</property>
+ <property name="vexpand">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">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="can_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="fromfile">
+ <property name="label" translatable="yes">From File...</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="no_show_all">True</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">3</property>
+ <property name="secondary">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid" id="grid1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkFrame" id="frame1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</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="hexpand">True</property>
+ <property name="vexpand">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkTreeView" id="categories:border">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection1"/>
+ </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">Categories</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ </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>
+ <child>
+ <object class="GtkFrame" id="frame2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</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="hexpand">True</property>
+ <property name="vexpand">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkTreeView" id="templates:border">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection3"/>
+ </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">Templates</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ </child>
+ </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="GtkGrid" id="optionsgrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkCheckButton" id="text">
+ <property name="label" translatable="yes">Te_xt</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="no_show_all">True</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</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="frame">
+ <property name="label" translatable="yes">_Frame</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="no_show_all">True</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="pages">
+ <property name="label" translatable="yes">_Pages</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="no_show_all">True</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="numbering">
+ <property name="label" translatable="yes">N_umbering</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="no_show_all">True</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</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>
+ <child>
+ <object class="GtkCheckButton" id="overwrite">
+ <property name="label" translatable="yes">_Overwrite</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="no_show_all">True</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="alttitle">
+ <property name="can_focus">False</property>
+ <property name="no_show_all">True</property>
+ <property name="label" translatable="yes">Load Styles</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkExpander" id="expander">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child>
+ <object class="GtkGrid" id="previewgrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="margin_top">6</property>
+ <child>
+ <object class="sfxlo-SfxPreviewWin" id="image">
+ <property name="can_focus">False</property>
+ <property name="no_show_all">True</property>
+ <property name="halign">start</property>
+ <property name="valign">start</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>
+ </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">Pre_view</property>
+ <property name="use_underline">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ <action-widget response="0">help</action-widget>
+ </action-widgets>
+ </object>
+</interface>