diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-12-20 12:30:33 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-12-20 16:52:57 +0000 |
commit | c38a1de224b911387fba74ae3039d634509085fb (patch) | |
tree | 2930f54003741c67e4c985d936f936aa547b06fe | |
parent | 2ecf108c23c041619bb8b25338dca84ff89fe8eb (diff) |
convert columns dialog (and sections/frame/page tab page) to .ui
Change-Id: I7ce64b63acba1581754e5a75ea48e3df654973ae
-rw-r--r-- | svtools/source/control/ctrlbox.cxx | 12 | ||||
-rw-r--r-- | svx/inc/svx/pagectrl.hxx | 3 | ||||
-rw-r--r-- | svx/source/dialog/pagectrl.cxx | 47 | ||||
-rw-r--r-- | sw/AllLangResTarget_sw.mk | 1 | ||||
-rw-r--r-- | sw/UI_swriter.mk | 2 | ||||
-rw-r--r-- | sw/inc/helpid.h | 2 | ||||
-rw-r--r-- | sw/source/ui/app/app.src | 11 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/colex.cxx | 48 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/column.cxx | 515 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/column.hrc | 78 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/column.src | 440 | ||||
-rw-r--r-- | sw/source/ui/inc/colex.hxx | 39 | ||||
-rw-r--r-- | sw/source/ui/inc/column.hxx | 114 | ||||
-rw-r--r-- | sw/uiconfig/swriter/ui/columndialog.ui | 81 | ||||
-rw-r--r-- | sw/uiconfig/swriter/ui/columnpage.ui | 419 |
15 files changed, 801 insertions, 1011 deletions
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx index 85eb235b1b44..e9872d7c8176 100644 --- a/svtools/source/control/ctrlbox.cxx +++ b/svtools/source/control/ctrlbox.cxx @@ -763,6 +763,18 @@ LineListBox::LineListBox( Window* pParent, WinBits nWinStyle ) : ImplInit(); } +extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeLineListBox(Window *pParent, VclBuilder::stringmap &rMap) +{ + bool bDropdown = extractDropdown(rMap); + WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP; + if (bDropdown) + nWinBits |= WB_DROPDOWN; + LineListBox *pListBox = new LineListBox(pParent, nWinBits); + if (bDropdown) + pListBox->EnableAutoSize(true); + return pListBox; +} + // ----------------------------------------------------------------------- LineListBox::LineListBox( Window* pParent, const ResId& rResId ) : diff --git a/svx/inc/svx/pagectrl.hxx b/svx/inc/svx/pagectrl.hxx index cc941e1c7795..252d3ae5de44 100644 --- a/svx/inc/svx/pagectrl.hxx +++ b/svx/inc/svx/pagectrl.hxx @@ -79,6 +79,7 @@ protected: public: SvxPageWindow( Window* pParent, const ResId& rId ); + SvxPageWindow( Window* pParent ); ~SvxPageWindow(); void SetWidth( long nW ) { aSize.Width() = nW; } @@ -153,6 +154,8 @@ public: void SetFrameDirection(sal_Int32 nFrameDirection); void ResetBackground(); + + virtual Size GetOptimalSize(WindowSizeType eType) const; }; #endif // #ifndef _SVX_PAGECTRL_HXX diff --git a/svx/source/dialog/pagectrl.cxx b/svx/source/dialog/pagectrl.cxx index 1d6b759e0268..0fadd16e876b 100644 --- a/svx/source/dialog/pagectrl.cxx +++ b/svx/source/dialog/pagectrl.cxx @@ -97,6 +97,46 @@ SvxPageWindow::SvxPageWindow( Window* pParent, const ResId& rId ) : SetBackground(); } +SvxPageWindow::SvxPageWindow( Window* pParent ) : + + Window( pParent ), + + nTop ( 0 ), + nBottom ( 0 ), + nLeft ( 0 ), + nRight ( 0 ), + aColor ( COL_TRANSPARENT ), + nHdLeft ( 0 ), + nHdRight ( 0 ), + nHdDist ( 0 ), + nHdHeight ( 0 ), + aHdColor ( COL_TRANSPARENT ), + pHdBorder ( 0 ), + nFtLeft ( 0 ), + nFtRight ( 0 ), + nFtDist ( 0 ), + nFtHeight ( 0 ), + aFtColor ( COL_TRANSPARENT ), + pFtBorder ( 0 ), + bFooter ( sal_False ), + bHeader ( sal_False ), + bTable ( sal_False ), + bHorz ( sal_False ), + bVert ( sal_False ), + eUsage ( SVX_PAGE_ALL ) +{ + pImpl = new PageWindow_Impl; + + // Count in Twips by default + SetMapMode( MapMode( MAP_TWIP ) ); + aWinSize = GetOptimalSize(WINDOWSIZE_PREFERRED); + aWinSize.Height() -= 4; + aWinSize.Width() -= 4; + + aWinSize = PixelToLogic( aWinSize ); + SetBackground(); +} + // ----------------------------------------------------------------------- SvxPageWindow::~SvxPageWindow() @@ -397,4 +437,11 @@ void SvxPageWindow::ResetBackground() pImpl->bResetBackground = sal_True; } +Size SvxPageWindow::GetOptimalSize(WindowSizeType eType) const +{ + if (eType == WINDOWSIZE_PREFERRED) + return LogicToPixel(Size(75, 46), MapMode(MAP_APPFONT)); + return Window::GetOptimalSize(eType); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/AllLangResTarget_sw.mk b/sw/AllLangResTarget_sw.mk index 8f2c8533f192..a57daca763eb 100644 --- a/sw/AllLangResTarget_sw.mk +++ b/sw/AllLangResTarget_sw.mk @@ -129,7 +129,6 @@ $(eval $(call gb_SrsTarget_add_files,sw/res,\ sw/source/ui/fldui/fldvar.src \ sw/source/ui/fldui/inpdlg.src \ sw/source/ui/fmtui/tmpdlg.src \ - sw/source/ui/frmdlg/column.src \ sw/source/ui/frmdlg/frmpage.src \ sw/source/ui/frmdlg/frmui.src \ sw/source/ui/frmdlg/wrap.src \ diff --git a/sw/UI_swriter.mk b/sw/UI_swriter.mk index e356f2996c6b..996b37a8bfe2 100644 --- a/sw/UI_swriter.mk +++ b/sw/UI_swriter.mk @@ -14,6 +14,8 @@ $(eval $(call gb_UI_add_uifiles,modules/swriter,\ sw/uiconfig/swriter/ui/bibliographyentry \ sw/uiconfig/swriter/ui/captionoptions \ sw/uiconfig/swriter/ui/charurlpage \ + sw/uiconfig/swriter/ui/columndialog \ + sw/uiconfig/swriter/ui/columnpage \ sw/uiconfig/swriter/ui/columnwidth \ sw/uiconfig/swriter/ui/converttexttable \ sw/uiconfig/swriter/ui/endnotepage \ diff --git a/sw/inc/helpid.h b/sw/inc/helpid.h index 7b674c2acc8f..145e6c46bc4d 100644 --- a/sw/inc/helpid.h +++ b/sw/inc/helpid.h @@ -25,7 +25,6 @@ #define HID_FLD_INPUT "SW_HID_FLD_INPUT" #define HID_DOCINFO_EDT "SW_HID_DOCINFO_EDT" #define HID_PASSWD "SW_HID_PASSWD" -#define HID_FORMAT_COLUMN "SW_HID_FORMAT_COLUMN" #define HID_CONFIG_SAVE "SW_HID_CONFIG_SAVE" #define HID_NUM_NAMES "SW_HID_NUM_NAMES" @@ -158,7 +157,6 @@ #define HID_FRM_EXT "SW_HID_FRM_EXT" #define HID_FRM_STD "SW_HID_FRM_STD" #define HID_GRF_EXT "SW_HID_GRF_EXT" -#define HID_COLUMN "SW_HID_COLUMN" #define HID_FOOTNOTE_PAGE "SW_HID_FOOTNOTE_PAGE" #define HID_FORMAT_TABLE "SW_HID_FORMAT_TABLE" #define HID_TABLE_COLUMN "SW_HID_TABLE_COLUMN" diff --git a/sw/source/ui/app/app.src b/sw/source/ui/app/app.src index 236af107e82d..0d27c8e17e17 100644 --- a/sw/source/ui/app/app.src +++ b/sw/source/ui/app/app.src @@ -21,6 +21,7 @@ #include <svx/dialogs.hrc> #include <svx/globlmn.hrc> #include "cmdid.h" +#include "access.hrc" #include "globals.hrc" #include "app.hrc" #include "statstr.hrc" @@ -708,6 +709,16 @@ String STR_AUTHMRK_INSERT Text [ en-US ] = "Insert Bibliography Entry"; }; +String STR_ACCESS_PAGESETUP_SPACING +{ + Text [ en-US ] = "Spacing between %1 and %2"; +}; + +String STR_ACCESS_COLUMN_WIDTH +{ + Text [ en-US ] = "Column %1 Width"; +}; + ToolBox RID_MODULE_TOOLBOX { HelpID = HID_MODULE_TOOLBOX ; diff --git a/sw/source/ui/frmdlg/colex.cxx b/sw/source/ui/frmdlg/colex.cxx index a3cc6db72e1c..4a810327a265 100644 --- a/sw/source/ui/frmdlg/colex.cxx +++ b/sw/source/ui/frmdlg/colex.cxx @@ -30,6 +30,7 @@ #include <editeng/brshitem.hxx> #include <editeng/frmdiritem.hxx> #include <vcl/bitmap.hxx> +#include <vcl/builder.hxx> #include <vcl/graph.hxx> #include <tgrditem.hxx> #include <viewopt.hxx> @@ -289,9 +290,14 @@ void SwColExample::DrawPage( const Point& rOrg, } } -SwColumnOnlyExample::SwColumnOnlyExample( Window* pParent, const ResId& rResId) : - Window(pParent, rResId), - m_aFrmSize(1,1) +extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeSwColExample(Window *pParent, VclBuilder::stringmap &) +{ + return new SwColExample(pParent); +} + +SwColumnOnlyExample::SwColumnOnlyExample( Window* pParent, const ResId& rResId) + : Window(pParent, rResId) + , m_aFrmSize(1,1) { SetMapMode( MapMode( MAP_TWIP ) ); m_aWinSize = GetOutputSizePixel(); @@ -313,6 +319,35 @@ SwColumnOnlyExample::SwColumnOnlyExample( Window* pParent, const ResId& rResId) SetMapMode( aMapMode ); } +SwColumnOnlyExample::SwColumnOnlyExample(Window* pParent) + : Window(pParent) + , m_aFrmSize(1,1) +{ + SetMapMode( MapMode( MAP_TWIP ) ); + m_aWinSize = GetOptimalSize(WINDOWSIZE_PREFERRED); + m_aWinSize.Height() -= 4; + m_aWinSize.Width() -= 4; + + m_aWinSize = PixelToLogic( m_aWinSize ); + + SetBorderStyle( WINDOW_BORDER_MONO ); + + m_aFrmSize = SvxPaperInfo::GetPaperSize(PAPER_A4);// DIN A4 + ::FitToActualSize(m_aCols, (sal_uInt16)m_aFrmSize.Width()); + + long nHeight = m_aFrmSize.Height(); + Fraction aScale( m_aWinSize.Height(), nHeight ); + MapMode aMapMode( GetMapMode() ); + aMapMode.SetScaleX( aScale ); + aMapMode.SetScaleY( aScale ); + SetMapMode( aMapMode ); +} + +extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeSwColumnOnlyExample(Window *pParent, VclBuilder::stringmap &) +{ + return new SwColumnOnlyExample(pParent); +} + void SwColumnOnlyExample::Paint( const Rectangle& /*rRect*/ ) { const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings(); @@ -445,6 +480,13 @@ void SwColumnOnlyExample::SetColumns(const SwFmtCol& rCol) } } +Size SwColumnOnlyExample::GetOptimalSize(WindowSizeType eType) const +{ + if (eType == WINDOWSIZE_PREFERRED) + return LogicToPixel(Size(75, 46), MapMode(MAP_APPFONT)); + return Window::GetOptimalSize(eType); +} + SwPageGridExample::~SwPageGridExample() { delete pGridItem; diff --git a/sw/source/ui/frmdlg/column.cxx b/sw/source/ui/frmdlg/column.cxx index 791a7151548f..42d013746f73 100644 --- a/sw/source/ui/frmdlg/column.cxx +++ b/sw/source/ui/frmdlg/column.cxx @@ -53,13 +53,18 @@ #include "paratr.hxx" #include "frmui.hrc" #include "poolfmt.hrc" -#include "column.hrc" #include <section.hxx> #include <docary.hxx> #include <pagedesc.hxx> #include "access.hrc" +//to match associated data in ColumnPage.ui +#define LISTBOX_SELECTION 0 +#define LISTBOX_SECTION 1 +#define LISTBOX_SECTIONS 2 +#define LISTBOX_PAGE 3 +#define LISTBOX_FRAME 4 using namespace ::com::sun::star; @@ -79,27 +84,20 @@ inline sal_Bool IsMarkInSameSection( SwWrtShell& rWrtSh, const SwSection* pSect return bRet; } -SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) : - SfxModalDialog(pParent, SW_RES(DLG_COLUMN)), - aOK(this, SW_RES(PB_OK)), - aCancel(this, SW_RES(PB_CANCEL)), - aHelp(this, SW_RES(PB_HELP)), - aApplyToFT(this, SW_RES(FT_APPLY_TO)), - aApplyToLB(this, SW_RES(LB_APPLY_TO)), - rWrtShell(rSh), - pPageSet(0), - pSectionSet(0), - pSelectionSet(0), - pFrameSet(0), - nOldSelection(0), - nSelectionWidth(0), - bPageChanged(sal_False), - bSectionChanged(sal_False), - bSelSectionChanged(sal_False), - bFrameChanged(sal_False) +SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) + : SfxModalDialog(pParent, "ColumnDialog", "modules/swriter/ui/columndialog.ui") + , rWrtShell(rSh) + , pPageSet(0) + , pSectionSet(0) + , pSelectionSet(0) + , pFrameSet(0) + , nOldSelection(0) + , nSelectionWidth(0) + , bPageChanged(sal_False) + , bSectionChanged(sal_False) + , bSelSectionChanged(sal_False) + , bFrameChanged(sal_False) { - FreeResource(); - SwRect aRect; rWrtShell.CalcBoundRect(aRect, FLY_AS_CHAR); @@ -121,15 +119,6 @@ SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) : pSectionSet = new SfxItemSet( rWrtShell.GetAttrPool(), aSectIds ); pSectionSet->Put( pCurrSection->GetFmt()->GetAttrSet() ); pColPgSet = pSectionSet; - aApplyToLB.RemoveEntry( aApplyToLB.GetEntryPos( - (void*)(sal_IntPtr)( 1 >= nFullSectCnt - ? LISTBOX_SECTIONS - : LISTBOX_SECTION ))); - } - else - { - aApplyToLB.RemoveEntry(aApplyToLB.GetEntryPos( (void*)(sal_IntPtr)LISTBOX_SECTION )); - aApplyToLB.RemoveEntry(aApplyToLB.GetEntryPos( (void*)(sal_IntPtr)LISTBOX_SECTIONS )); } if( rWrtShell.HasSelection() && rWrtShell.IsInsRegionAvailable() && @@ -139,8 +128,6 @@ SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) : pSelectionSet = new SfxItemSet( rWrtShell.GetAttrPool(), aSectIds ); pColPgSet = pSelectionSet; } - else - aApplyToLB.RemoveEntry(aApplyToLB.GetEntryPos( (void*)(sal_IntPtr)LISTBOX_SELECTION )); if( rWrtShell.GetFlyFrmFmt() ) { @@ -150,11 +137,8 @@ SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) : pFrameSet->Put(pFmt->GetCol()); pColPgSet = pFrameSet; } - else - aApplyToLB.RemoveEntry(aApplyToLB.GetEntryPos( (void*) LISTBOX_FRAME )); - sal_uInt16 nPagePos = aApplyToLB.GetEntryPos( (void*) LISTBOX_PAGE ); const SwPageDesc* pPageDesc = rWrtShell.GetSelectedPageDescs(); if( pPageDesc ) { @@ -164,12 +148,6 @@ SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) : RES_LR_SPACE, RES_LR_SPACE, 0 ); - String sPageStr = aApplyToLB.GetEntry(nPagePos); - aApplyToLB.RemoveEntry( nPagePos ); - sPageStr += pPageDesc->GetName(); - aApplyToLB.InsertEntry( sPageStr, nPagePos ); - aApplyToLB.SetEntryData( nPagePos, (void*) LISTBOX_PAGE); - const SwFrmFmt &rFmt = pPageDesc->GetMaster(); nPageWidth = rFmt.GetFrmSize().GetSize().Width(); @@ -181,32 +159,60 @@ SwColumnDlg::SwColumnDlg(Window* pParent, SwWrtShell& rSh) : pPageSet->Put(rFmt.GetLRSpace()); pColPgSet = pPageSet; } - else - aApplyToLB.RemoveEntry( nPagePos ); - OSL_ENSURE( pColPgSet, "" ); + assert(pColPgSet); + // create TabPage - SwColumnPage* pPage = (SwColumnPage*) SwColumnPage::Create( this, - *pColPgSet ); - pTabPage = pPage; - - // adjust size - Size aPageSize(pTabPage->GetSizePixel()); - Size aDlgSize(GetOutputSizePixel()); - aDlgSize.Height() = aPageSize.Height(); - SetOutputSizePixel(aDlgSize); - pTabPage->Show(); + pTabPage = (SwColumnPage*) SwColumnPage::Create(get_content_area(), *pColPgSet); + pTabPage->get<Window>("applytoft")->Show(); + pTabPage->get(m_pApplyToLB, "applytolb"); + m_pApplyToLB->Show(); + + if (pCurrSection && (!rWrtShell.HasSelection() || 0 != nFullSectCnt)) + { + m_pApplyToLB->RemoveEntry( m_pApplyToLB->GetEntryPos( + (void*)(sal_IntPtr)( 1 >= nFullSectCnt + ? LISTBOX_SECTIONS + : LISTBOX_SECTION ))); + } + else + { + m_pApplyToLB->RemoveEntry(m_pApplyToLB->GetEntryPos( (void*)(sal_IntPtr)LISTBOX_SECTION )); + m_pApplyToLB->RemoveEntry(m_pApplyToLB->GetEntryPos( (void*)(sal_IntPtr)LISTBOX_SECTIONS )); + } + + if (!( rWrtShell.HasSelection() && rWrtShell.IsInsRegionAvailable() && + ( !pCurrSection || ( 1 != nFullSectCnt && + IsMarkInSameSection( rWrtShell, pCurrSection ) )))) + m_pApplyToLB->RemoveEntry(m_pApplyToLB->GetEntryPos( (void*)(sal_IntPtr)LISTBOX_SELECTION )); + + if (!rWrtShell.GetFlyFrmFmt()) + m_pApplyToLB->RemoveEntry(m_pApplyToLB->GetEntryPos( (void*) LISTBOX_FRAME )); - aApplyToLB.SelectEntryPos(0); + sal_uInt16 nPagePos = m_pApplyToLB->GetEntryPos( (void*) LISTBOX_PAGE ); + if (pPageSet && pPageDesc) + { + String sPageStr = m_pApplyToLB->GetEntry(nPagePos); + m_pApplyToLB->RemoveEntry(nPagePos); + sPageStr += pPageDesc->GetName(); + m_pApplyToLB->InsertEntry( sPageStr, nPagePos ); + m_pApplyToLB->SetEntryData( nPagePos, (void*) LISTBOX_PAGE); + } + else + m_pApplyToLB->RemoveEntry( nPagePos ); + + m_pApplyToLB->SelectEntryPos(0); ObjectHdl(0); - aApplyToLB.SetSelectHdl(LINK(this, SwColumnDlg, ObjectHdl)); - aOK.SetClickHdl(LINK(this, SwColumnDlg, OkHdl)); + m_pApplyToLB->SetSelectHdl(LINK(this, SwColumnDlg, ObjectHdl)); + OKButton *pOK = get<OKButton>("ok"); + pOK->SetClickHdl(LINK(this, SwColumnDlg, OkHdl)); //#i80458# if no columns can be set then disable OK - if( !aApplyToLB.GetEntryCount() ) - aOK.Enable( sal_False ); + if( !m_pApplyToLB->GetEntryCount() ) + pOK->Enable( sal_False ); //#i97810# set focus to the TabPage pTabPage->ActivateColumnControl(); + pTabPage->Show(); } SwColumnDlg::~SwColumnDlg() @@ -246,7 +252,7 @@ IMPL_LINK(SwColumnDlg, ObjectHdl, ListBox*, pBox) { pTabPage->FillItemSet(*pSet); } - nOldSelection = (long)aApplyToLB.GetEntryData(aApplyToLB.GetSelectEntryPos()); + nOldSelection = (long)m_pApplyToLB->GetEntryData(m_pApplyToLB->GetSelectEntryPos()); long nWidth = nSelectionWidth; switch(nOldSelection) { @@ -396,89 +402,83 @@ void SwColumnPage::ResetColWidth() Description: Now as TabPage --------------------------------------------------------------------*/ SwColumnPage::SwColumnPage(Window *pParent, const SfxItemSet &rSet) - - : SfxTabPage(pParent, SW_RES(TP_COLUMN), rSet), - - aFLGroup(this, SW_RES(FL_COLUMNS )), - aClNrLbl(this, SW_RES(FT_NUMBER )), - aCLNrEdt(this, SW_RES(ED_NUMBER )), - aDefaultVS(this, SW_RES(VS_DEFAULTS)), - aBalanceColsCB(this, SW_RES(CB_BALANCECOLS)), - - aFLLayout(this, SW_RES(FL_LAYOUT)), - aBtnUp(this, SW_RES(BTN_DOWN)), - aColumnFT(this, SW_RES(FT_COLUMN)), - aWidthFT(this, SW_RES(FT_WIDTH)), - aDistFT(this, SW_RES(FT_DIST)), - aLbl1(this, SW_RES(FT_1)), - aEd1(this, SW_RES(ED_1)), - aDistEd1(this, SW_RES(ED_DIST1)), - aLbl2(this, SW_RES(FT_2)), - aEd2(this, SW_RES(ED_2)), - aDistEd2(this, SW_RES(ED_DIST2)), - aLbl3(this, SW_RES(FT_3)), - aEd3(this, SW_RES(ED_3)), - aBtnDown(this, SW_RES(BTN_UP)), - aAutoWidthBox(this, SW_RES(CB_AUTO_WIDTH)), - - aFLLineType(this, SW_RES(FL_LINETYPE)), - aLineTypeLbl(this, SW_RES(FT_STYLE)), - aLineTypeDLB(this, SW_RES(LB_STYLE)), - aLineWidthLbl(this, SW_RES(FT_LINEWIDTH)), - aLineWidthEdit(this, SW_RES(ED_LINEWIDTH)), - aLineColorLbl(this, SW_RES(FT_COLOR)), - aLineColorDLB(this, SW_RES(LB_COLOR)), - aLineHeightLbl(this, SW_RES(FT_HEIGHT)), - aLineHeightEdit(this, SW_RES(ED_HEIGHT)), - aLinePosLbl(this, SW_RES(FT_POSITION)), - aLinePosDLB(this, SW_RES(LB_POSITION)), - - aTextDirectionFT( this, SW_RES( FT_TEXTDIRECTION )), - aTextDirectionLB( this, SW_RES( LB_TEXTDIRECTION )), - - aPgeExampleWN(this, SW_RES(WN_BSP)), - aFrmExampleWN(this, SW_RES(WN_BSP)), - - pColMgr(0), - - nFirstVis(0), - nMinWidth(MINLAY), - pModifiedField(0), - bFormat(sal_False), - bFrm(sal_False), - bHtmlMode(sal_False), - bLockUpdate(sal_False) + : SfxTabPage(pParent, "ColumnPage", "modules/swriter/ui/columnpage.ui", rSet) + , pColMgr(0) + , nFirstVis(0) + , nMinWidth(MINLAY) + , pModifiedField(0) + , bFormat(sal_False) + , bFrm(sal_False) + , bHtmlMode(sal_False) + , bLockUpdate(sal_False) { - long i; + get(m_pCLNrEdt, "colsnf"); + get(m_pBalanceColsCB, "balance"); + get(m_pBtnBack, "back"); + get(m_pLbl1, "1"); + get(m_pLbl2, "2"); + get(m_pLbl3, "3"); + get(m_pBtnNext, "next"); + get(m_pAutoWidthBox, "autowidth"); + get(m_pLineTypeLbl, "linestyleft"); + get(m_pLineWidthLbl, "linewidthft"); + get(m_pLineWidthEdit, "linewidthmf"); + get(m_pLineColorLbl, "linecolorft"); + get(m_pLineHeightLbl, "lineheightft"); + get(m_pLineHeightEdit, "lineheightmf"); + get(m_pLinePosLbl, "lineposft"); + get(m_pLinePosDLB, "lineposlb"); + get(m_pTextDirectionFT, "textdirectionft"); + get(m_pTextDirectionLB, "textdirectionlb"); + get(m_pLineColorDLB, "colorlb"); + get(m_pLineTypeDLB, "linestylelb"); + + get(m_pDefaultVS, "valueset"); + get(m_pPgeExampleWN, "pageexample"); + get(m_pFrmExampleWN, "frameexample"); + + MetricField *pEd1 = get<MetricField>("width1mf"); + aEd1.set(pEd1); + MetricField *pEd2 = get<MetricField>("width2mf"); + aEd2.set(pEd2); + MetricField *pEd3 = get<MetricField>("width3mf"); + aEd3.set(pEd3); + MetricField *pDistEd1 = get<MetricField>("spacing1mf"); + aDistEd1.set(pDistEd1); + MetricField *pDistEd2 = get<MetricField>("spacing2mf"); + aDistEd2.set(pDistEd2); - FreeResource(); SetExchangeSupport(); - aBtnDown.SetAccessibleRelationMemberOf(&aFLLayout); - aEd1.SetAccessibleRelationLabeledBy(&aWidthFT); - aEd2.SetAccessibleRelationLabeledBy(&aWidthFT); - aEd3.SetAccessibleRelationLabeledBy(&aWidthFT); - aDistEd1.SetAccessibleRelationLabeledBy(&aDistFT); - aDistEd2.SetAccessibleRelationLabeledBy(&aDistFT); - aBtnUp.SetAccessibleRelationLabeledBy(&aColumnFT); - aBtnDown.SetAccessibleRelationLabeledBy(&aColumnFT); + VclFrame *pSpacing = get<VclFrame>("spacing"); + m_pBtnNext->SetAccessibleRelationMemberOf(pSpacing->get_label_widget()); + + Window *pWidth = get<Window>("widthft"); + pEd1->SetAccessibleRelationLabeledBy(pWidth); + pEd2->SetAccessibleRelationLabeledBy(pWidth); + pEd3->SetAccessibleRelationLabeledBy(pWidth); + + Window *pDist = get<Window>("distft"); + pDistEd1->SetAccessibleRelationLabeledBy(pDist); + pDistEd2->SetAccessibleRelationLabeledBy(pDist); - aDefaultVS.SetHelpId(HID_COLUMN_VALUESET); - aDefaultVS.SetColCount( 5 ); - aDefaultVS.SetStyle( aDefaultVS.GetStyle() - | WB_ITEMBORDER - | WB_DOUBLEBORDER ); + Window *pColumn = get<Window>("columnft"); + m_pBtnBack->SetAccessibleRelationLabeledBy(pColumn); + m_pBtnNext->SetAccessibleRelationLabeledBy(pColumn); - for( i = 0; i < 5; i++) - aDefaultVS.InsertItem( i + 1, i ); + m_pDefaultVS->SetHelpId(HID_COLUMN_VALUESET); + m_pDefaultVS->SetColCount( 5 ); - aDefaultVS.SetSelectHdl(LINK(this, SwColumnPage, SetDefaultsHdl)); + for (int i = 0; i < 5; ++i) + m_pDefaultVS->InsertItem( i + 1, i ); + + m_pDefaultVS->SetSelectHdl(LINK(this, SwColumnPage, SetDefaultsHdl)); // announce Controls for additional region at the MoreButton Link aCLNrLk = LINK(this, SwColumnPage, ColModify); - aCLNrEdt.SetLoseFocusHdl(aCLNrLk); - aCLNrEdt.SetUpHdl(aCLNrLk); - aCLNrEdt.SetDownHdl(aCLNrLk); + m_pCLNrEdt->SetLoseFocusHdl(aCLNrLk); + m_pCLNrEdt->SetUpHdl(aCLNrLk); + m_pCLNrEdt->SetDownHdl(aCLNrLk); Link aLk = LINK(this, SwColumnPage, GapModify); aDistEd1.SetUpHdl(aLk); aDistEd1.SetDownHdl(aLk); @@ -501,38 +501,38 @@ SwColumnPage::SwColumnPage(Window *pParent, const SfxItemSet &rSet) aEd3.SetDownHdl(aLk); aEd3.SetLoseFocusHdl(aLk); - aBtnUp.SetClickHdl(LINK(this, SwColumnPage, Up)); - aBtnDown.SetClickHdl(LINK(this, SwColumnPage, Down)); - aAutoWidthBox.SetClickHdl(LINK(this, SwColumnPage, AutoWidthHdl)); + m_pBtnBack->SetClickHdl(LINK(this, SwColumnPage, Up)); + m_pBtnNext->SetClickHdl(LINK(this, SwColumnPage, Down)); + m_pAutoWidthBox->SetClickHdl(LINK(this, SwColumnPage, AutoWidthHdl)); aLk = LINK( this, SwColumnPage, UpdateColMgr ); - aLineTypeDLB.SetSelectHdl( aLk ); - aLineWidthEdit.SetModifyHdl( aLk ); - aLineColorDLB.SetSelectHdl( aLk ); - aLineHeightEdit.SetModifyHdl( aLk ); - aLinePosDLB.SetSelectHdl( aLk ); + m_pLineTypeDLB->SetSelectHdl( aLk ); + m_pLineWidthEdit->SetModifyHdl( aLk ); + m_pLineColorDLB->SetSelectHdl( aLk ); + m_pLineHeightEdit->SetModifyHdl( aLk ); + m_pLinePosDLB->SetSelectHdl( aLk ); // Separator line - aLineTypeDLB.SetUnit( FUNIT_POINT ); - aLineTypeDLB.SetSourceUnit( FUNIT_TWIP ); + m_pLineTypeDLB->SetUnit( FUNIT_POINT ); + m_pLineTypeDLB->SetSourceUnit( FUNIT_TWIP ); // Fill the line styles listbox - aLineTypeDLB.SetNone( SVX_RESSTR( RID_SVXSTR_NONE ) ); - aLineTypeDLB.InsertEntry( + m_pLineTypeDLB->SetNone( SVX_RESSTR( RID_SVXSTR_NONE ) ); + m_pLineTypeDLB->InsertEntry( ::editeng::SvxBorderLine::getWidthImpl(table::BorderLineStyle::SOLID), table::BorderLineStyle::SOLID ); - aLineTypeDLB.InsertEntry( + m_pLineTypeDLB->InsertEntry( ::editeng::SvxBorderLine::getWidthImpl(table::BorderLineStyle::DOTTED), table::BorderLineStyle::DOTTED ); - aLineTypeDLB.InsertEntry( + m_pLineTypeDLB->InsertEntry( ::editeng::SvxBorderLine::getWidthImpl(table::BorderLineStyle::DASHED), table::BorderLineStyle::DASHED ); long nLineWidth = static_cast<long>(MetricField::ConvertDoubleValue( - aLineWidthEdit.GetValue( ), - aLineWidthEdit.GetDecimalDigits( ), - aLineWidthEdit.GetUnit(), MAP_TWIP )); - aLineTypeDLB.SetWidth( nLineWidth ); + m_pLineWidthEdit->GetValue( ), + m_pLineWidthEdit->GetDecimalDigits( ), + m_pLineWidthEdit->GetUnit(), MAP_TWIP )); + m_pLineTypeDLB->SetWidth( nLineWidth ); // Fill the color listbox SfxObjectShell* pDocSh = SfxObjectShell::Current(); @@ -547,16 +547,16 @@ SwColumnPage::SwColumnPage(Window *pParent, const SfxItemSet &rSet) if ( pColorList.is() ) { - aLineColorDLB.SetUpdateMode( sal_False ); + m_pLineColorDLB->SetUpdateMode( sal_False ); - for ( i = 0; i < pColorList->Count(); ++i ) + for (long i = 0; i < pColorList->Count(); ++i ) { XColorEntry* pEntry = pColorList->GetColor(i); - aLineColorDLB.InsertEntry( pEntry->GetColor(), pEntry->GetName() ); + m_pLineColorDLB->InsertEntry( pEntry->GetColor(), pEntry->GetName() ); } - aLineColorDLB.SetUpdateMode( sal_True ); + m_pLineColorDLB->SetUpdateMode( sal_True ); } - aLineColorDLB.SelectEntryPos( 0 ); + m_pLineColorDLB->SelectEntryPos( 0 ); } SwColumnPage::~SwColumnPage() @@ -581,20 +581,20 @@ void SwColumnPage::Reset(const SfxItemSet &rSet) if(nHtmlMode & HTMLMODE_ON) { bHtmlMode = sal_True; - aAutoWidthBox.Enable(sal_False); + m_pAutoWidthBox->Enable(sal_False); } FieldUnit aMetric = ::GetDfltMetric(bHtmlMode); - SetMetric(aEd1, aMetric); - SetMetric(aEd2, aMetric); - SetMetric(aEd3, aMetric); - SetMetric(aDistEd1, aMetric); - SetMetric(aDistEd2, aMetric); + aEd1.SetMetric(aMetric); + aEd2.SetMetric(aMetric); + aEd3.SetMetric(aMetric); + aDistEd1.SetMetric(aMetric); + aDistEd2.SetMetric(aMetric); delete pColMgr; pColMgr = new SwColMgr(rSet); nCols = pColMgr->GetCount() ; - aCLNrEdt.SetMax(Max((sal_uInt16)aCLNrEdt.GetMax(), (sal_uInt16)nCols)); - aCLNrEdt.SetLast(Max(nCols,(sal_uInt16)aCLNrEdt.GetMax())); + m_pCLNrEdt->SetMax(Max((sal_uInt16)m_pCLNrEdt->GetMax(), (sal_uInt16)nCols)); + m_pCLNrEdt->SetLast(Max(nCols,(sal_uInt16)m_pCLNrEdt->GetMax())); if(bFrm) { @@ -607,13 +607,13 @@ void SwColumnPage::Reset(const SfxItemSet &rSet) pColMgr->SetActualWidth((sal_uInt16)rSize.GetSize().Width() - rBox.GetDistance()); } } - if(aBalanceColsCB.IsVisible()) + if(m_pBalanceColsCB->IsVisible()) { const SfxPoolItem* pItem; if( SFX_ITEM_SET == rSet.GetItemState( RES_COLUMNBALANCE, sal_False, &pItem )) - aBalanceColsCB.Check(!((const SwFmtNoBalancedColumns*)pItem)->GetValue()); + m_pBalanceColsCB->Check(!((const SwFmtNoBalancedColumns*)pItem)->GetValue()); else - aBalanceColsCB.Check( sal_True ); + m_pBalanceColsCB->Check( sal_True ); } //text direction @@ -621,9 +621,9 @@ void SwColumnPage::Reset(const SfxItemSet &rSet) { const SvxFrameDirectionItem& rItem = (const SvxFrameDirectionItem&)rSet.Get(RES_FRAMEDIR); sal_uIntPtr nVal = rItem.GetValue(); - sal_uInt16 nPos = aTextDirectionLB.GetEntryPos( (void*) nVal ); - aTextDirectionLB.SelectEntryPos( nPos ); - aTextDirectionLB.SaveValue(); + sal_uInt16 nPos = m_pTextDirectionLB->GetEntryPos( (void*) nVal ); + m_pTextDirectionLB->SelectEntryPos( nPos ); + m_pTextDirectionLB->SaveValue(); } Init(); @@ -643,8 +643,8 @@ SfxTabPage* SwColumnPage::Create(Window *pParent, const SfxItemSet &rSet) --------------------------------------------------------------------*/ sal_Bool SwColumnPage::FillItemSet(SfxItemSet &rSet) { - if(aCLNrEdt.HasChildPathFocus()) - aCLNrEdt.GetDownHdl().Call(&aCLNrEdt); + if(m_pCLNrEdt->HasChildPathFocus()) + m_pCLNrEdt->GetDownHdl().Call(m_pCLNrEdt); // set in ItemSet setzen // the current settings are already present // @@ -654,16 +654,16 @@ sal_Bool SwColumnPage::FillItemSet(SfxItemSet &rSet) rCol != *pOldItem ) rSet.Put(rCol); - if(aBalanceColsCB.IsVisible() ) + if(m_pBalanceColsCB->IsVisible() ) { - rSet.Put(SwFmtNoBalancedColumns(!aBalanceColsCB.IsChecked() )); + rSet.Put(SwFmtNoBalancedColumns(!m_pBalanceColsCB->IsChecked() )); } sal_uInt16 nPos; - if( aTextDirectionLB.IsVisible() && - ( nPos = aTextDirectionLB.GetSelectEntryPos() ) != - aTextDirectionLB.GetSavedValue() ) + if( m_pTextDirectionLB->IsVisible() && + ( nPos = m_pTextDirectionLB->GetSelectEntryPos() ) != + m_pTextDirectionLB->GetSavedValue() ) { - sal_uInt32 nDirection = (sal_uInt32)(sal_IntPtr)aTextDirectionLB.GetEntryData( nPos ); + sal_uInt32 nDirection = (sal_uInt32)(sal_IntPtr)m_pTextDirectionLB->GetEntryData( nPos ); rSet.Put( SvxFrameDirectionItem( (SvxFrameDirection)nDirection, RES_FRAMEDIR)); } return sal_True; @@ -685,7 +685,7 @@ IMPL_LINK( SwColumnPage, UpdateColMgr, void *, /*pField*/ ) for( i = 1; i < nCols; ++i) nMin = Min(nMin, nColWidth[i]); - sal_Bool bAutoWidth = aAutoWidthBox.IsChecked(); + sal_Bool bAutoWidth = m_pAutoWidthBox->IsChecked(); if(!bAutoWidth) { pColMgr->SetAutoWidth(sal_False); @@ -715,32 +715,32 @@ IMPL_LINK( SwColumnPage, UpdateColMgr, void *, /*pField*/ ) } // nothing is turned off - const sal_uInt16 nPos = aLineTypeDLB.GetSelectEntryPos(); + const sal_uInt16 nPos = m_pLineTypeDLB->GetSelectEntryPos(); sal_Bool bEnable = 0 != nPos; - aLineHeightEdit.Enable( bEnable ); - aLineHeightLbl.Enable( bEnable ); + m_pLineHeightEdit->Enable( bEnable ); + m_pLineHeightLbl->Enable( bEnable ); long nLineWidth = static_cast<long>(MetricField::ConvertDoubleValue( - aLineWidthEdit.GetValue( ), - aLineWidthEdit.GetDecimalDigits( ), - aLineWidthEdit.GetUnit(), MAP_TWIP )); + m_pLineWidthEdit->GetValue( ), + m_pLineWidthEdit->GetDecimalDigits( ), + m_pLineWidthEdit->GetUnit(), MAP_TWIP )); if( !bEnable ) pColMgr->SetNoLine(); else if( LISTBOX_ENTRY_NOTFOUND != nPos ) { pColMgr->SetLineWidthAndColor( - ::editeng::SvxBorderStyle( aLineTypeDLB.GetSelectEntryStyle( ) ), + ::editeng::SvxBorderStyle( m_pLineTypeDLB->GetSelectEntryStyle( ) ), nLineWidth, - aLineColorDLB.GetSelectEntryColor() ); + m_pLineColorDLB->GetSelectEntryColor() ); pColMgr->SetAdjust( SwColLineAdj( - aLinePosDLB.GetSelectEntryPos() + 1) ); - pColMgr->SetLineHeightPercent((short)aLineHeightEdit.GetValue()); + m_pLinePosDLB->GetSelectEntryPos() + 1) ); + pColMgr->SetLineHeightPercent((short)m_pLineHeightEdit->GetValue()); bEnable = pColMgr->GetLineHeightPercent() != 100; } - aLinePosLbl.Enable( bEnable ); - aLinePosDLB.Enable( bEnable ); + m_pLinePosLbl->Enable( bEnable ); + m_pLinePosDLB->Enable( bEnable ); - aLineTypeDLB.SetWidth( nLineWidth ); - aLineTypeDLB.SetColor( aLineColorDLB.GetSelectEntryColor( ) ); + m_pLineTypeDLB->SetWidth( nLineWidth ); + m_pLineTypeDLB->SetColor( m_pLineColorDLB->GetSelectEntryColor( ) ); } else { @@ -749,21 +749,21 @@ IMPL_LINK( SwColumnPage, UpdateColMgr, void *, /*pField*/ ) } //set maximum values - aCLNrEdt.SetMax(Max(1L, + m_pCLNrEdt->SetMax(Max(1L, Min(long(nMaxCols), long( pColMgr->GetActualSize() / (nGutterWidth + MINLAY)) ))); - aCLNrEdt.SetLast(aCLNrEdt.GetMax()); - aCLNrEdt.Reformat(); + m_pCLNrEdt->SetLast(m_pCLNrEdt->GetMax()); + m_pCLNrEdt->Reformat(); //prompt example window if(!bLockUpdate) { if(bFrm) { - aFrmExampleWN.SetColumns( pColMgr->GetColumns() ); - aFrmExampleWN.Invalidate(); + m_pFrmExampleWN->SetColumns( pColMgr->GetColumns() ); + m_pFrmExampleWN->Invalidate(); } else - aPgeExampleWN.Invalidate(); + m_pPgeExampleWN->Invalidate(); } return 0; @@ -774,10 +774,10 @@ IMPL_LINK( SwColumnPage, UpdateColMgr, void *, /*pField*/ ) ------------------------------------------------------------------------*/ void SwColumnPage::Init() { - aCLNrEdt.SetValue(nCols); + m_pCLNrEdt->SetValue(nCols); sal_Bool bAutoWidth = pColMgr->IsAutoWidth() || bHtmlMode; - aAutoWidthBox.Check( bAutoWidth ); + m_pAutoWidthBox->Check( bAutoWidth ); sal_Int32 nColumnWidthSum = 0; // set the widths @@ -804,26 +804,26 @@ void SwColumnPage::Init() { eAdj = COLADJ_TOP; //without Adjust no line type - aLineTypeDLB.SelectEntryPos( 0 ); - aLineHeightEdit.SetValue( 100 ); + m_pLineTypeDLB->SelectEntryPos( 0 ); + m_pLineHeightEdit->SetValue( 100 ); } else { // Need to multiply by 100 because of the 2 decimals - aLineWidthEdit.SetValue( pColMgr->GetLineWidth() * 100, FUNIT_TWIP ); - aLineColorDLB.SelectEntry( pColMgr->GetLineColor() ); - aLineTypeDLB.SelectEntry( pColMgr->GetLineStyle() ); - aLineTypeDLB.SetWidth( pColMgr->GetLineWidth( ) ); - aLineHeightEdit.SetValue( pColMgr->GetLineHeightPercent() ); + m_pLineWidthEdit->SetValue( pColMgr->GetLineWidth() * 100, FUNIT_TWIP ); + m_pLineColorDLB->SelectEntry( pColMgr->GetLineColor() ); + m_pLineTypeDLB->SelectEntry( pColMgr->GetLineStyle() ); + m_pLineTypeDLB->SetWidth( pColMgr->GetLineWidth( ) ); + m_pLineHeightEdit->SetValue( pColMgr->GetLineHeightPercent() ); } - aLinePosDLB.SelectEntryPos( static_cast< sal_uInt16 >(eAdj - 1) ); + m_pLinePosDLB->SelectEntryPos( static_cast< sal_uInt16 >(eAdj - 1) ); } else { - aLinePosDLB.SelectEntryPos( 0 ); - aLineTypeDLB.SelectEntryPos( 0 ); - aLineHeightEdit.SetValue( 100 ); + m_pLinePosDLB->SelectEntryPos( 0 ); + m_pLineTypeDLB->SelectEntryPos( 0 ); + m_pLineHeightEdit->SetValue( 100 ); } UpdateCols(); @@ -831,7 +831,7 @@ void SwColumnPage::Init() // set maximum number of columns // values below 1 are not allowed - aCLNrEdt.SetMax(Max(1L, + m_pCLNrEdt->SetMax(Max(1L, Min(long(nMaxCols), long( pColMgr->GetActualSize() / nMinWidth) ))); } @@ -849,7 +849,7 @@ void SwColumnPage::UpdateCols() sal_Bool bEnableBtns= sal_False; sal_Bool bEnable12 = sal_False; sal_Bool bEnable3 = sal_False; - const sal_Bool bEdit = !aAutoWidthBox.IsChecked(); + const sal_Bool bEdit = !m_pAutoWidthBox->IsChecked(); if ( nCols > nVisCols ) { bEnableBtns = sal_True && !bHtmlMode; @@ -870,27 +870,27 @@ void SwColumnPage::UpdateCols() aEd2.Enable( bEnable12 ); aDistEd2.Enable(bEnable3); aEd3.Enable( bEnable3 ); - aLbl1.Enable(bEnable12 ); - aLbl2.Enable(bEnable12 ); - aLbl3.Enable(bEnable3 ); - aBtnUp.Enable( bEnableBtns ); - aBtnDown.Enable( bEnableBtns ); + m_pLbl1->Enable(bEnable12 ); + m_pLbl2->Enable(bEnable12 ); + m_pLbl3->Enable(bEnable3 ); + m_pBtnBack->Enable( bEnableBtns ); + m_pBtnNext->Enable( bEnableBtns ); const sal_Bool bEnable = nCols > 1; if( !bEnable ) { - aLinePosDLB.Enable( sal_False ); - aLinePosLbl.Enable( sal_False ); + m_pLinePosDLB->Enable( sal_False ); + m_pLinePosLbl->Enable( sal_False ); } - aLineHeightEdit.Enable( bEnable ); - aLineHeightLbl.Enable( bEnable ); - aLineTypeDLB.Enable( bEnable ); - aLineTypeLbl.Enable( bEnable ); - aLineWidthLbl.Enable( bEnable ); - aLineWidthEdit.Enable( bEnable ); - aLineColorDLB.Enable( bEnable ); - aLineColorLbl.Enable( bEnable ); - aAutoWidthBox.Enable( bEnable && !bHtmlMode ); + m_pLineHeightEdit->Enable( bEnable ); + m_pLineHeightLbl->Enable( bEnable ); + m_pLineTypeDLB->Enable( bEnable ); + m_pLineTypeLbl->Enable( bEnable ); + m_pLineWidthLbl->Enable( bEnable ); + m_pLineWidthEdit->Enable( bEnable ); + m_pLineColorDLB->Enable( bEnable ); + m_pLineColorLbl->Enable( bEnable ); + m_pAutoWidthBox->Enable( bEnable && !bHtmlMode ); } void SwColumnPage::SetLabels( sal_uInt16 nVis ) @@ -900,17 +900,17 @@ void SwColumnPage::SetLabels( sal_uInt16 nVis ) String sLbl2( String::CreateFromInt32( nVis + 1 )); String tmp1(sLbl2); sLbl2.Insert(sLbl, sLbl2.Len() - 1); - aLbl1.SetText(sLbl2); + m_pLbl1->SetText(sLbl2); sLbl2 = String::CreateFromInt32( nVis + 2 ); String tmp2(sLbl2); sLbl2.Insert(sLbl, sLbl2.Len() - 1); - aLbl2.SetText(sLbl2); + m_pLbl2->SetText(sLbl2); sLbl2 = String::CreateFromInt32( nVis + 3 ); String tmp3(sLbl2); sLbl2.Insert(sLbl, sLbl2.Len() - 1); - aLbl3.SetText(sLbl2); + m_pLbl3->SetText(sLbl2); String sColumnWidth = SW_RESSTR( STR_ACCESS_COLUMN_WIDTH ) ; sColumnWidth.SearchAndReplaceAscii("%1", tmp1); aEd1.SetAccessibleName(sColumnWidth); @@ -942,16 +942,16 @@ void SwColumnPage::SetLabels( sal_uInt16 nVis ) ------------------------------------------------------------------------*/ IMPL_LINK( SwColumnPage, ColModify, NumericField *, pNF ) { - nCols = (sal_uInt16)aCLNrEdt.GetValue(); + nCols = (sal_uInt16)m_pCLNrEdt->GetValue(); //#107890# the handler is also called from LoseFocus() //then no change has been made and thus no action should be taken // #i17816# changing the displayed types within the ValueSet //from two columns to two columns with different settings doesn't invalidate the // example windows in ::ColModify() - if(!pNF ||(pColMgr->GetCount() != nCols)) + if (!pNF || pColMgr->GetCount() != nCols) { if(pNF) - aDefaultVS.SetNoSelection(); + m_pDefaultVS->SetNoSelection(); long nDist = static_cast< long >(aDistEd1.DenormalizePercent(aDistEd1.GetValue(FUNIT_TWIP))); pColMgr->SetCount(nCols, (sal_uInt16)nDist); for(sal_uInt16 i = 0; i < nCols; i++) @@ -974,12 +974,12 @@ IMPL_LINK( SwColumnPage, ColModify, NumericField *, pNF ) of the column width is overruled; only an alteration of the column number leads back to that default. ------------------------------------------------------------------------*/ -IMPL_LINK( SwColumnPage, GapModify, PercentField *, pFld ) +IMPL_LINK( SwColumnPage, GapModify, PercentFieldWrap *, pFld ) { long nActValue = static_cast< long >(pFld->DenormalizePercent(pFld->GetValue(FUNIT_TWIP))); if(nCols < 2) return 0; - if(aAutoWidthBox.IsChecked()) + if(m_pAutoWidthBox->IsChecked()) { sal_uInt16 nMaxGap = pColMgr->GetActualSize() - nCols * MINLAY; OSL_ENSURE(nCols, "Abstand kann nicht ohne Spalten eingestellt werden"); @@ -1045,7 +1045,7 @@ IMPL_LINK( SwColumnPage, GapModify, PercentField *, pFld ) return 0; } -IMPL_LINK( SwColumnPage, EdModify, PercentField *, pField ) +IMPL_LINK( SwColumnPage, EdModify, PercentFieldWrap *, pField ) { pModifiedField = pField; Timeout(); @@ -1155,7 +1155,7 @@ void SwColumnPage::Timeout() ------------------------------------------------------------------------*/ void SwColumnPage::Update() { - aBalanceColsCB.Enable(nCols > 1); + m_pBalanceColsCB->Enable(nCols > 1); if(nCols >= 2) { aEd1.SetPrcntValue(aEd1.NormalizePercent(nColWidth[nFirstVis]), FUNIT_TWIP); @@ -1207,15 +1207,15 @@ void SwColumnPage::ActivatePage(const SfxItemSet& rSet) UpdateColMgr( 0 ); } } - aFrmExampleWN.Hide(); - aPgeExampleWN.UpdateExample( rSet, pColMgr ); - aPgeExampleWN.Show(); + m_pFrmExampleWN->Hide(); + m_pPgeExampleWN->UpdateExample( rSet, pColMgr ); + m_pPgeExampleWN->Show(); } else { - aPgeExampleWN.Hide(); - aFrmExampleWN.Show(); + m_pPgeExampleWN->Hide(); + m_pFrmExampleWN->Show(); // Size const SwFmtFrmSize& rSize = (const SwFmtFrmSize&)rSet.Get(RES_FRM_SIZE); @@ -1254,8 +1254,8 @@ void SwColumnPage::ActivatePage(const SfxItemSet& rSet) aEd3.ShowPercent(bPercent); aDistEd1.ShowPercent(bPercent); aDistEd2.ShowPercent(bPercent); - aDistEd1.MetricField::SetMin(0); - aDistEd2.MetricField::SetMin(0); + aDistEd1.SetMetricFieldMin(0); + aDistEd2.SetMetricFieldMin(0); } Update(); } @@ -1278,16 +1278,16 @@ IMPL_LINK( SwColumnPage, SetDefaultsHdl, ValueSet *, pVS ) sal_uInt16 nItem = pVS->GetSelectItemId(); if( nItem < 4 ) { - aCLNrEdt.SetValue( nItem ); - aAutoWidthBox.Check(); + m_pCLNrEdt->SetValue( nItem ); + m_pAutoWidthBox->Check(); aDistEd1.SetPrcntValue(0); ColModify(0); } else { bLockUpdate = sal_True; - aCLNrEdt.SetValue( 2 ); - aAutoWidthBox.Check(sal_False); + m_pCLNrEdt->SetValue( 2 ); + m_pAutoWidthBox->Check(sal_False); aDistEd1.SetPrcntValue(0); ColModify(0); // now set the width ratio to 2 : 1 or 1 : 2 respectively @@ -1319,8 +1319,8 @@ void SwColumnPage::SetInSection(sal_Bool bSet) if(!SW_MOD()->GetCTLOptions().IsCTLFontEnabled()) return; - aTextDirectionFT.Show(bSet); - aTextDirectionLB.Show(bSet); + m_pTextDirectionFT->Show(bSet); + m_pTextDirectionLB->Show(bSet); } void ColumnValueSet::UserDraw( const UserDrawEvent& rUDEvt ) @@ -1388,10 +1388,6 @@ void ColumnValueSet::UserDraw( const UserDrawEvent& rUDEvt ) pDev->SetLineColor(aLineColor); } -ColumnValueSet::~ColumnValueSet() -{ -} - void ColumnValueSet::DataChanged( const DataChangedEvent& rDCEvt ) { if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) && @@ -1402,4 +1398,9 @@ void ColumnValueSet::DataChanged( const DataChangedEvent& rDCEvt ) ValueSet::DataChanged( rDCEvt ); } +extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeColumnValueSet(Window *pParent, VclBuilder::stringmap &) +{ + return new ColumnValueSet(pParent); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/frmdlg/column.hrc b/sw/source/ui/frmdlg/column.hrc deleted file mode 100644 index 6aa876d9660d..000000000000 --- a/sw/source/ui/frmdlg/column.hrc +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 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 FT_NUMBER 1 -#define ED_NUMBER 2 -#define FT_DISTANCE 3 -#define CB_AUTO_WIDTH 4 -#define FL_COLUMNS 6 - -#define FT_1 20 -#define FT_2 21 -#define FT_3 22 - - -#define ED_1 25 -#define ED_2 26 -#define ED_3 27 - - -#define BTN_UP 30 -#define BTN_DOWN 31 -#define FL_LAYOUT 32 - -#define FT_STYLE 33 -#define LB_STYLE 34 -#define FT_HEIGHT 35 -#define ED_HEIGHT 36 -#define FT_POSITION 37 -#define LB_POSITION 38 -#define FL_LINETYPE 39 - -#define WN_BSP 41 - -#define CB_REGISTER 43 -#define FL_REGISTER 44 -#define FT_REFERENCE 45 - -#define ED_DIST1 46 -#define ED_DIST2 47 - -#define FT_COLUMN 48 -#define FT_WIDTH 49 -#define FT_DIST 50 -#define VS_DEFAULTS 51 - -#define FT_APPLY_TO 53 -#define LB_APPLY_TO 54 -#define PB_HELP 55 -#define PB_CANCEL 56 -#define PB_OK 57 -#define CB_BALANCECOLS 58 -#define FT_TEXTDIRECTION 60 -#define LB_TEXTDIRECTION 61 - -#define FT_LINEWIDTH 63 -#define ED_LINEWIDTH 64 -#define FT_COLOR 65 -#define LB_COLOR 66 - -#define LISTBOX_SELECTION 0 -#define LISTBOX_SECTION 1 -#define LISTBOX_SECTIONS 2 -#define LISTBOX_PAGE 3 -#define LISTBOX_FRAME 4 diff --git a/sw/source/ui/frmdlg/column.src b/sw/source/ui/frmdlg/column.src deleted file mode 100644 index f0fb36de6ede..000000000000 --- a/sw/source/ui/frmdlg/column.src +++ /dev/null @@ -1,440 +0,0 @@ -/* - * 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 "globals.hrc" -#include "column.hrc" -#include "frmui.hrc" -#include "cmdid.h" -#include "helpid.h" -#include "access.hrc" - -TabPage TP_COLUMN -{ - HelpID = HID_COLUMN ; - Hide = TRUE; - Size = MAP_APPFONT ( TP_WIDTH , TP_HEIGHT ) ; - Text [ en-US ] = "Columns" ; - FixedText FT_NUMBER - { - Pos = MAP_APPFONT ( 12 , 19 ) ; - Size = MAP_APPFONT ( 28 , 8 ) ; - Left = TRUE ; - Text [ en-US ] = "Columns"; - }; - NumericField ED_NUMBER - { - HelpID = "sw:NumericField:TP_COLUMN:ED_NUMBER"; - Border = TRUE ; - Pos = MAP_APPFONT ( 12 , 30 ) ; - Size = MAP_APPFONT ( 24 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 1 ; - Maximum = 20 ; - Value = 1 ; - First = 1 ; - Last = 20 ; - SpinSize = 1 ; - }; - Control VS_DEFAULTS - { - Pos = MAP_APPFONT ( 50 , 14 ) ; - Size = MAP_APPFONT ( 110 , 28 ) ; - TabStop = TRUE ; - }; - CheckBox CB_BALANCECOLS - { - HelpID = "sw:CheckBox:TP_COLUMN:CB_BALANCECOLS"; - Pos = MAP_APPFONT ( 7 , 46 ) ; - Size = MAP_APPFONT ( 163 , 10 ) ; - Hide = TRUE; - Text [ en-US ] = "Evenly distribute contents ~to all columns"; - }; - FixedLine FL_COLUMNS - { - Pos = MAP_APPFONT ( 6 , 3 ) ; - Size = MAP_APPFONT ( 164 , 8 ) ; - Text [ en-US ] = "Settings"; - }; - FixedText FT_COLUMN - { - Pos = MAP_APPFONT ( 12 , 86 ) ; - Size = MAP_APPFONT ( 50 , 8 ) ; - Left = TRUE ; - Text [ en-US ] = "Column"; - }; - Window WN_BSP - { - Pos = MAP_APPFONT ( 176 , 6 ) ; - Size = MAP_APPFONT ( 75 , 46 ) ; - }; - ImageButton BTN_DOWN - { - HelpID = "sw:ImageButton:TP_COLUMN:BTN_DOWN"; - Disable = TRUE ; - Pos = MAP_APPFONT ( 62 , 85 ) ; - Size = MAP_APPFONT ( 10 , 10 ) ; - TabStop = TRUE ; - SYMBOL = IMAGEBUTTON_ARROW_LEFT ; - }; - FixedText FT_1 - { - Pos = MAP_APPFONT ( 100 , 87 ) ; - Size = MAP_APPFONT ( 10 , 8 ) ; - Text = "~1" ; - Center = TRUE ; - }; - FixedText FT_2 - { - Pos = MAP_APPFONT ( 150 , 87 ) ; - Size = MAP_APPFONT ( 10 , 8 ) ; - Text = "~2" ; - Center = TRUE ; - }; - FixedText FT_3 - { - Pos = MAP_APPFONT ( 200 , 87 ) ; - Size = MAP_APPFONT ( 10 , 8 ) ; - Text = "~3" ; - Center = TRUE ; - }; - ImageButton BTN_UP - { - HelpID = "sw:ImageButton:TP_COLUMN:BTN_UP"; - Disable = TRUE ; - Pos = MAP_APPFONT ( 238 , 85 ) ; - Size = MAP_APPFONT ( 10 , 10 ) ; - TabStop = TRUE ; - SYMBOL = IMAGEBUTTON_ARROW_RIGHT ; - }; - FixedText FT_WIDTH - { - Pos = MAP_APPFONT ( 12 , 101 ) ; - Size = MAP_APPFONT ( 50 , 8 ) ; - Left = TRUE ; - Text [ en-US ] = "Width" ; - }; - MetricField ED_1 - { - HelpID = "sw:MetricField:TP_COLUMN:ED_1"; - Disable = TRUE ; - Border = TRUE ; - Pos = MAP_APPFONT ( 87 , 99 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 1 ; - Maximum = 5600 ; - DecimalDigits = 2 ; - Unit = FUNIT_CM ; - First = 10 ; - Last = 5600 ; - SpinSize = 10 ; - }; - MetricField ED_2 - { - HelpID = "sw:MetricField:TP_COLUMN:ED_2"; - Disable = TRUE ; - Border = TRUE ; - Pos = MAP_APPFONT ( 137 , 99 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 1 ; - Maximum = 5600 ; - DecimalDigits = 2 ; - Unit = FUNIT_CM ; - First = 10 ; - Last = 5600 ; - SpinSize = 10 ; - }; - MetricField ED_3 - { - HelpID = "sw:MetricField:TP_COLUMN:ED_3"; - Disable = TRUE ; - Border = TRUE ; - Pos = MAP_APPFONT ( 187 , 99 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 1 ; - Maximum = 5600 ; - DecimalDigits = 2 ; - Unit = FUNIT_CM ; - First = 10 ; - Last = 5600 ; - SpinSize = 10 ; - }; - FixedText FT_DIST - { - Pos = MAP_APPFONT ( 12 , 117 ) ; - Size = MAP_APPFONT ( 50 , 8 ) ; - Left = TRUE ; - Text [ en-US ] = "Spacing" ; - }; - MetricField ED_DIST1 - { - HelpID = "sw:MetricField:TP_COLUMN:ED_DIST1"; - Disable = TRUE ; - Border = TRUE ; - Pos = MAP_APPFONT ( 112 , 115 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 0 ; - Maximum = 5600 ; - DecimalDigits = 2 ; - Unit = FUNIT_CM ; - First = 10 ; - Last = 5600 ; - SpinSize = 10 ; - }; - MetricField ED_DIST2 - { - HelpID = "sw:MetricField:TP_COLUMN:ED_DIST2"; - Disable = TRUE ; - Border = TRUE ; - Pos = MAP_APPFONT ( 162 , 115 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 0 ; - Maximum = 5600 ; - DecimalDigits = 2 ; - Unit = FUNIT_CM ; - First = 10 ; - Last = 5600 ; - SpinSize = 10 ; - }; - CheckBox CB_AUTO_WIDTH - { - HelpID = "sw:CheckBox:TP_COLUMN:CB_AUTO_WIDTH"; - Pos = MAP_APPFONT ( 87 , 131 ) ; - Size = MAP_APPFONT ( 100 , 10 ) ; - Text [ en-US ] = "Auto~Width" ; - TabStop = TRUE ; - }; - FixedLine FL_LAYOUT - { - Pos = MAP_APPFONT ( 6 , 74 ) ; - Size = MAP_APPFONT ( 248 , 8 ) ; - Text [ en-US ] = "Width and spacing"; - }; - - FixedText FT_STYLE - { - Pos = MAP_APPFONT ( 12 , 156 ) ; - Size = MAP_APPFONT ( 30 , 8 ) ; - Text [ en-US ] = "St~yle" ; - Left = TRUE ; - }; - ListBox LB_STYLE - { - HelpID = "sw:ListBox:TP_COLUMN:LB_STYLE"; - Pos = MAP_APPFONT ( 45 , 154 ) ; - Size = MAP_APPFONT ( 40 , 66 ) ; - TabStop = TRUE ; - DropDown = TRUE ; - }; - FixedText FT_LINEWIDTH - { - Pos = MAP_APPFONT ( 12 , 172 ) ; - Size = MAP_APPFONT ( 30 , 8 ) ; - Text [ en-US ] = "~Width" ; - Left = TRUE ; - }; - MetricField ED_LINEWIDTH - { - Border = TRUE ; - Pos = MAP_APPFONT ( 45 , 170 ) ; - Size = MAP_APPFONT ( 40 , 12 ) ; - TabStop = TRUE ; - Spin = TRUE ; - Repeat = TRUE ; - First = 25 ; - Last = 900 ; - Minimum = 25 ; - Maximum = 900 ; - DecimalDigits = 2 ; - SpinSize = 25 ; - Unit = FUNIT_POINT ; - }; - FixedText FT_COLOR - { - Pos = MAP_APPFONT ( 165 , 156 ) ; - Size = MAP_APPFONT ( 25 , 8 ) ; - Text [ en-US ] = "~Color" ; - Left = TRUE ; - }; - ListBox LB_COLOR - { - Border = TRUE ; - Pos = MAP_APPFONT ( 193 , 154 ) ; - Size = MAP_APPFONT ( 60 , 68 ) ; - DropDown = TRUE ; - DDExtraWidth = TRUE ; - TabStop = TRUE ; - }; - FixedText FT_HEIGHT - { - Pos = MAP_APPFONT ( 91 , 156 ) ; - Size = MAP_APPFONT ( 30 , 8 ) ; - Text [ en-US ] = "H~eight" ; - Left = TRUE ; - }; - MetricField ED_HEIGHT - { - HelpID = "sw:MetricField:TP_COLUMN:ED_HEIGHT"; - Border = TRUE ; - Pos = MAP_APPFONT ( 124 , 154 ) ; - Size = MAP_APPFONT ( 35 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = 25 ; - Maximum = 100 ; - Value = 100 ; - Unit = FUNIT_CUSTOM ; - CustomUnitText = "%" ; - First = 25 ; - Last = 100 ; - }; - FixedText FT_POSITION - { - Pos = MAP_APPFONT ( 91 , 172 ) ; - Size = MAP_APPFONT ( 30 , 8 ) ; - Left = TRUE ; - Text [ en-US ] = "~Position" ; - }; - ListBox LB_POSITION - { - HelpID = "sw:ListBox:TP_COLUMN:LB_POSITION"; - Pos = MAP_APPFONT ( 124 , 170 ) ; - Size = MAP_APPFONT ( 35 , 40 ) ; - TabStop = TRUE ; - DropDown = TRUE ; - StringList [ en-US ] = - { - < "Top" ; Default ; > ; - < "Centered" ; Default ; > ; - < "Bottom" ; Default ; > ; - }; - }; - FixedLine FL_LINETYPE - { - Pos = MAP_APPFONT ( 6 , 143 ) ; - Size = MAP_APPFONT ( 248 , 8 ) ; - Text [ en-US ] = "Separator line" ; - }; - FixedText FT_TEXTDIRECTION - { - Pos = MAP_APPFONT ( 12 , 60 ) ; - Size = MAP_APPFONT ( 60 , 8 ) ; - Hide = TRUE ; - Text [ en-US ] = "Text ~direction"; - }; - ListBox LB_TEXTDIRECTION - { - HelpID = "sw:ListBox:TP_COLUMN:LB_TEXTDIRECTION"; - Border = TRUE ; - Pos = MAP_APPFONT ( 75 , 58 ) ; - Size = MAP_APPFONT ( 150 , 50 ) ; - DropDown = TRUE ; - Hide = TRUE ; - StringList [ en-US ] = - { - < "Left-to-right" ; 0; > ; - < "Right-to-left" ; 1; > ; - < "Use superordinate object settings" ; 4; > ; - }; - }; -}; - -ModalDialog DLG_COLUMN -{ - HelpID = HID_FORMAT_COLUMN; - Hide = TRUE; - Moveable = TRUE; - Size = MAP_APPFONT ( 316 , 135 ) ; - OKButton PB_OK - { - DefButton = TRUE ; - Pos = MAP_APPFONT ( 260 , 6 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - }; - CancelButton PB_CANCEL - { - Pos = MAP_APPFONT ( 260 , 23 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - }; - HelpButton PB_HELP - { - Pos = MAP_APPFONT ( 260 , 43 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - }; - FixedText FT_APPLY_TO - { - Pos = MAP_APPFONT ( 260 , 63 ) ; - Size = MAP_APPFONT ( 50 , 8 ) ; - Left = TRUE ; - Text [ en-US ] = "~Apply to"; - }; - ListBox LB_APPLY_TO - { - HelpID = "sw:ListBox:DLG_COLUMN:LB_APPLY_TO"; - Pos = MAP_APPFONT ( 260 , 74 ) ; - Size = MAP_APPFONT ( 50 , 66 ) ; - TabStop = TRUE ; - DropDown = TRUE ; - StringList [ en-US ] = - { - < "Selection" ; LISTBOX_SELECTION; > ; - < "Current Section" ; LISTBOX_SECTION ; > ; - < "Selected section" ; LISTBOX_SECTIONS ; > ; - < "Frame" ; LISTBOX_FRAME ; > ; - < "Page Style: " ; LISTBOX_PAGE ; > ; - }; - }; - Text [ en-US ] = "Columns"; -}; - -String STR_ACCESS_PAGESETUP_SPACING -{ - Text [ en-US ] = "Spacing between %1 and %2"; -}; - -String STR_ACCESS_COLUMN_WIDTH -{ - Text [ en-US ] = "Column %1 Width"; -}; diff --git a/sw/source/ui/inc/colex.hxx b/sw/source/ui/inc/colex.hxx index 40d653abfdf3..5bfe2bd7654c 100644 --- a/sw/source/ui/inc/colex.hxx +++ b/sw/source/ui/inc/colex.hxx @@ -31,9 +31,17 @@ class SfxItemSet; class SW_DLLPUBLIC SwPageExample : public SvxPageWindow { public: - SwPageExample(Window* pPar, const ResId& rResId ) : - SvxPageWindow(pPar, rResId ) - {SetSize(SvxPaperInfo::GetPaperSize(PAPER_A4));/*DIN A4*/} + SwPageExample(Window* pPar, const ResId& rResId) + : SvxPageWindow(pPar, rResId) + { + SetSize(SvxPaperInfo::GetPaperSize(PAPER_A4)); + } + + SwPageExample(Window* pPar) + : SvxPageWindow(pPar) + { + SetSize(SvxPaperInfo::GetPaperSize(PAPER_A4)); + } void UpdateExample( const SfxItemSet& rSet ); }; @@ -69,14 +77,23 @@ protected: const sal_Bool bEnabled ); public: - SwColExample(Window* pPar, const ResId& rResId ) : - SwPageExample(pPar, rResId ), - pColMgr(0){} + SwColExample(Window* pPar, const ResId& rResId) + : SwPageExample(pPar, rResId) + , pColMgr(0) + { + } + + SwColExample(Window* pPar) + : SwPageExample(pPar) + , pColMgr(0) + { + } void UpdateExample( const SfxItemSet& rSet, SwColMgr* pMgr ) - { pColMgr = pMgr; - SwPageExample::UpdateExample(rSet); - } + { + pColMgr = pMgr; + SwPageExample::UpdateExample(rSet); + } }; class SW_DLLPUBLIC SwColumnOnlyExample : public Window @@ -91,10 +108,12 @@ protected: virtual void Paint( const Rectangle& rRect ); public: - SwColumnOnlyExample( Window* , const ResId& ); + SwColumnOnlyExample(Window* , const ResId&); + SwColumnOnlyExample(Window*); void SetColumns(const SwFmtCol& rCol); + virtual Size GetOptimalSize(WindowSizeType eType) const; }; #endif // _COLEX_HXX diff --git a/sw/source/ui/inc/column.hxx b/sw/source/ui/inc/column.hxx index 1f39ebcbd5b2..f8df7ab7df4a 100644 --- a/sw/source/ui/inc/column.hxx +++ b/sw/source/ui/inc/column.hxx @@ -44,12 +44,7 @@ class SwColumnPage; class SwColumnDlg : public SfxModalDialog { - OKButton aOK; - CancelButton aCancel; - HelpButton aHelp; - - FixedText aApplyToFT; - ListBox aApplyToLB; + ListBox* m_pApplyToLB; SwWrtShell& rWrtShell; SwColumnPage* pTabPage; @@ -80,11 +75,15 @@ public: class ColumnValueSet : public ValueSet { - public: - ColumnValueSet(Window* pParent, const ResId& rResId) : - ValueSet(pParent, rResId){} - ~ColumnValueSet(); - +public: + ColumnValueSet(Window* pParent, const ResId& rResId) + : ValueSet(pParent, rResId) + { + } + ColumnValueSet(Window* pParent) + : ValueSet(pParent, WB_TABSTOP | WB_ITEMBORDER | WB_DOUBLEBORDER) + { + } virtual void UserDraw( const UserDrawEvent& rUDEvt ); virtual void DataChanged( const DataChangedEvent& rDCEvt ); }; @@ -94,48 +93,39 @@ class ColumnValueSet : public ValueSet --------------------------------------------------------------------*/ class SwColumnPage : public SfxTabPage { - FixedLine aFLGroup; - FixedText aClNrLbl; - NumericField aCLNrEdt; - ColumnValueSet aDefaultVS; - ImageList aPreColsIL; - CheckBox aBalanceColsCB; - - FixedLine aFLLayout; - ImageButton aBtnUp; - FixedText aColumnFT; - FixedText aWidthFT; - FixedText aDistFT; - FixedText aLbl1; - PercentField aEd1; - PercentField aDistEd1; - FixedText aLbl2; - PercentField aEd2; - PercentField aDistEd2; - FixedText aLbl3; - PercentField aEd3; - ImageButton aBtnDown; - CheckBox aAutoWidthBox; - - - FixedLine aFLLineType; - FixedText aLineTypeLbl; - LineListBox aLineTypeDLB; - FixedText aLineWidthLbl; - MetricField aLineWidthEdit; - FixedText aLineColorLbl; - ColorListBox aLineColorDLB; - FixedText aLineHeightLbl; - MetricField aLineHeightEdit; - FixedText aLinePosLbl; - ListBox aLinePosDLB; - - FixedText aTextDirectionFT; - ListBox aTextDirectionLB; + NumericField* m_pCLNrEdt; + ColumnValueSet* m_pDefaultVS; + CheckBox* m_pBalanceColsCB; + + PushButton* m_pBtnBack; + FixedText* m_pLbl1; + PercentFieldWrap aEd1; + FixedText* m_pLbl2; + PercentFieldWrap aEd2; + FixedText* m_pLbl3; + PercentFieldWrap aEd3; + PushButton* m_pBtnNext; + PercentFieldWrap aDistEd1; + PercentFieldWrap aDistEd2; + CheckBox* m_pAutoWidthBox; + + FixedText* m_pLineTypeLbl; + LineListBox* m_pLineTypeDLB; + FixedText* m_pLineWidthLbl; + MetricField* m_pLineWidthEdit; + FixedText* m_pLineColorLbl; + ColorListBox* m_pLineColorDLB; + FixedText* m_pLineHeightLbl; + MetricField* m_pLineHeightEdit; + FixedText* m_pLinePosLbl; + ListBox* m_pLinePosDLB; + + FixedText* m_pTextDirectionFT; + ListBox* m_pTextDirectionLB; // Example - SwColExample aPgeExampleWN; - SwColumnOnlyExample aFrmExampleWN; + SwColExample* m_pPgeExampleWN; + SwColumnOnlyExample* m_pFrmExampleWN; SwColMgr* pColMgr; @@ -144,7 +134,7 @@ class SwColumnPage : public SfxTabPage long nColWidth[nMaxCols]; long nColDist[nMaxCols]; sal_uInt16 nMinWidth; - PercentField *pModifiedField; + PercentFieldWrap* pModifiedField; sal_Bool bFormat; sal_Bool bFrm; sal_Bool bHtmlMode; @@ -152,8 +142,8 @@ class SwColumnPage : public SfxTabPage // Handler DECL_LINK( ColModify, NumericField * ); - DECL_LINK( GapModify, PercentField * ); - DECL_LINK( EdModify, PercentField * ); + DECL_LINK( GapModify, PercentFieldWrap * ); + DECL_LINK( EdModify, PercentFieldWrap * ); DECL_LINK( AutoWidthHdl, CheckBox * ); DECL_LINK( SetDefaultsHdl, ValueSet * ); @@ -189,12 +179,22 @@ public: void SetFrmMode(sal_Bool bMod); void SetPageWidth(long nPageWidth); - void SetFormatUsed(sal_Bool bFmt) { bFormat = bFmt; } + void SetFormatUsed(sal_Bool bFmt) + { + bFormat = bFmt; + } + + void ShowBalance(sal_Bool bShow) + { + m_pBalanceColsCB->Show(bShow); + } - void ShowBalance(sal_Bool bShow) {aBalanceColsCB.Show(bShow);} void SetInSection(sal_Bool bSet); - void ActivateColumnControl() {aCLNrEdt.GrabFocus();} + void ActivateColumnControl() + { + m_pCLNrEdt->GrabFocus(); + } }; #endif diff --git a/sw/uiconfig/swriter/ui/columndialog.ui b/sw/uiconfig/swriter/ui/columndialog.ui new file mode 100644 index 000000000000..914c6262d8d2 --- /dev/null +++ b/sw/uiconfig/swriter/ui/columndialog.ui @@ -0,0 +1,81 @@ +<?xml version="1.0" encoding="UTF-8"?> +<interface> + <!-- interface-requires gtk+ 3.0 --> + <object class="GtkDialog" id="ColumnDialog"> + <property name="can_focus">False</property> + <property name="border_width">5</property> + <property name="title" translatable="yes">Columns</property> + <property name="type_hint">dialog</property> + <child internal-child="vbox"> + <object class="GtkBox" id="dialog-vbox1"> + <property name="can_focus">False</property> + <property name="spacing">2</property> + <child internal-child="action_area"> + <object class="GtkButtonBox" id="dialog-action_area1"> + <property name="can_focus">False</property> + <property name="orientation">vertical</property> + <property name="layout_style">start</property> + <child> + <object class="GtkButton" id="ok"> + <property name="label">gtk-ok</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="can_default">True</property> + <property name="has_default">True</property> + <property name="receives_default">True</property> + <property name="use_stock">True</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">0</property> + </packing> + </child> + <child> + <object class="GtkButton" id="cancel"> + <property name="label">gtk-cancel</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">True</property> + <property name="use_stock">True</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">1</property> + </packing> + </child> + <child> + <object class="GtkButton" id="help"> + <property name="label">gtk-help</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">True</property> + <property name="use_stock">True</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">2</property> + </packing> + </child> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="pack_type">end</property> + <property name="position">0</property> + </packing> + </child> + <child> + <placeholder/> + </child> + </object> + </child> + <action-widgets> + <action-widget response="0">ok</action-widget> + <action-widget response="0">cancel</action-widget> + <action-widget response="0">help</action-widget> + </action-widgets> + </object> +</interface> diff --git a/sw/uiconfig/swriter/ui/columnpage.ui b/sw/uiconfig/swriter/ui/columnpage.ui index bc3e7075a524..15fa2f3740a5 100644 --- a/sw/uiconfig/swriter/ui/columnpage.ui +++ b/sw/uiconfig/swriter/ui/columnpage.ui @@ -1,32 +1,71 @@ <?xml version="1.0" encoding="UTF-8"?> <interface> <!-- interface-requires gtk+ 3.0 --> + <object class="GtkAdjustment" id="adjustment1"> + <property name="lower">1</property> + <property name="upper">20</property> + <property name="value">1</property> + <property name="step_increment">1</property> + <property name="page_increment">10</property> + </object> + <object class="GtkAdjustment" id="adjustment2"> + <property name="lower">0.01</property> + <property name="upper">56</property> + <property name="step_increment">0.10000000000000001</property> + <property name="page_increment">1</property> + </object> + <object class="GtkAdjustment" id="adjustment3"> + <property name="upper">56</property> + <property name="step_increment">0.01</property> + <property name="page_increment">1</property> + </object> + <object class="GtkAdjustment" id="adjustment4"> + <property name="lower">0.25</property> + <property name="upper">9</property> + <property name="value">0.25</property> + <property name="step_increment">0.25</property> + <property name="page_increment">10</property> + </object> + <object class="GtkAdjustment" id="adjustment5"> + <property name="lower">25</property> + <property name="upper">100</property> + <property name="value">100</property> + <property name="step_increment">1</property> + <property name="page_increment">10</property> + </object> <object class="GtkGrid" id="ColumnPage"> <property name="visible">True</property> <property name="can_focus">False</property> + <property name="hexpand">True</property> <property name="row_spacing">12</property> <child> <object class="GtkGrid" id="grid3"> <property name="visible">True</property> <property name="can_focus">False</property> + <property name="hexpand">True</property> + <property name="vexpand">True</property> <property name="row_spacing">3</property> <property name="column_spacing">30</property> <child> <object class="GtkFrame" id="frame2"> <property name="visible">True</property> <property name="can_focus">False</property> + <property name="valign">start</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="top_padding">6</property> <property name="left_padding">12</property> <child> <object class="GtkGrid" id="grid4"> <property name="visible">True</property> <property name="can_focus">False</property> + <property name="hexpand">True</property> <property name="row_spacing">6</property> <property name="column_spacing">18</property> <child> @@ -49,11 +88,12 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton1"> + <object class="GtkSpinButton" id="colsnf"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment1</property> </object> <packing> <property name="left_attach">0</property> @@ -71,92 +111,14 @@ </packing> </child> <child> - <object class="GtkGrid" id="grid1"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="column_spacing">6</property> - <child> - <object class="GtkImage" id="image2"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</property> - </object> - <packing> - <property name="left_attach">0</property> - <property name="top_attach">0</property> - <property name="width">1</property> - <property name="height">1</property> - </packing> - </child> - <child> - <object class="GtkImage" id="image3"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</property> - </object> - <packing> - <property name="left_attach">1</property> - <property name="top_attach">0</property> - <property name="width">1</property> - <property name="height">1</property> - </packing> - </child> - <child> - <object class="GtkImage" id="image4"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</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="GtkImage" id="image5"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</property> - </object> - <packing> - <property name="left_attach">3</property> - <property name="top_attach">0</property> - <property name="width">1</property> - <property name="height">1</property> - </packing> - </child> - <child> - <object class="GtkImage" id="image6"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</property> - </object> - <packing> - <property name="left_attach">4</property> - <property name="top_attach">0</property> - <property name="width">1</property> - <property name="height">1</property> - </packing> - </child> - </object> - <packing> - <property name="left_attach">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="grid6"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="column_spacing">6</property> <child> - <object class="GtkLabel" id="label1"> - <property name="visible">True</property> + <object class="GtkLabel" id="applytoft"> <property name="can_focus">False</property> + <property name="no_show_all">True</property> <property name="xalign">0</property> <property name="label" translatable="yes">_Apply to</property> <property name="use_underline">True</property> @@ -169,25 +131,11 @@ </packing> </child> <child> - <object class="GtkComboBoxText" id="comboboxtext4"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="entry_text_column">0</property> - <property name="id_column">1</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="checkbutton1"> + <object class="GtkCheckButton" id="balance"> <property name="label" translatable="yes">Evenly distribute contents _to all columns</property> - <property name="visible">True</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> @@ -200,9 +148,9 @@ </packing> </child> <child> - <object class="GtkLabel" id="label7"> - <property name="visible">True</property> + <object class="GtkLabel" id="textdirectionft"> <property name="can_focus">False</property> + <property name="no_show_all">True</property> <property name="xalign">0</property> <property name="label" translatable="yes">Text _direction</property> <property name="use_underline">True</property> @@ -215,11 +163,10 @@ </packing> </child> <child> - <object class="GtkComboBoxText" id="comboboxtext5"> - <property name="visible">True</property> + <object class="GtkComboBox" id="textdirectionlb"> <property name="can_focus">False</property> - <property name="entry_text_column">0</property> - <property name="id_column">1</property> + <property name="no_show_all">True</property> + <property name="model">liststore1</property> </object> <packing> <property name="left_attach">1</property> @@ -228,6 +175,19 @@ <property name="height">1</property> </packing> </child> + <child> + <object class="GtkComboBox" id="applytolb"> + <property name="can_focus">False</property> + <property name="no_show_all">True</property> + <property name="model">liststore2</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> </object> <packing> <property name="left_attach">0</property> @@ -236,6 +196,19 @@ <property name="height">1</property> </packing> </child> + <child> + <object class="swuilo:ColumnValueSet" id="valueset"> + <property name="visible">True</property> + <property name="hexpand">True</property> + <property name="vexpand">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> </object> </child> </object> @@ -259,10 +232,35 @@ </packing> </child> <child> - <object class="GtkImage" id="image1"> + <object class="GtkGrid" id="grid1"> <property name="visible">True</property> <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</property> + <child> + <object class="swuilo:SwColExample" id="pageexample"> + <property name="visible">True</property> + <property name="halign">center</property> + <property name="valign">center</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="swuilo:SwColumnOnlyExample" id="frameexample"> + <property name="visible">True</property> + <property name="halign">center</property> + <property name="valign">center</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> </object> <packing> <property name="left_attach">1</property> @@ -280,25 +278,28 @@ </packing> </child> <child> - <object class="GtkFrame" id="frame3"> + <object class="GtkFrame" id="spacing"> <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="alignment3"> <property name="visible">True</property> <property name="can_focus">False</property> + <property name="hexpand">True</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="hexpand">True</property> <property name="row_spacing">6</property> <property name="column_spacing">12</property> <child> - <object class="GtkLabel" id="label5"> + <object class="GtkLabel" id="columnft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -312,10 +313,11 @@ </packing> </child> <child> - <object class="GtkLabel" id="label8"> + <object class="GtkLabel" id="1"> <property name="visible">True</property> <property name="can_focus">False</property> - <property name="label" translatable="yes">_1</property> + <property name="hexpand">True</property> + <property name="label">_1</property> <property name="use_underline">True</property> </object> <packing> @@ -326,10 +328,11 @@ </packing> </child> <child> - <object class="GtkLabel" id="label9"> + <object class="GtkLabel" id="2"> <property name="visible">True</property> <property name="can_focus">False</property> - <property name="label" translatable="yes">_2</property> + <property name="hexpand">True</property> + <property name="label">_2</property> <property name="use_underline">True</property> <attributes> <attribute name="background" value="#ffffffffffff"/> @@ -343,10 +346,11 @@ </packing> </child> <child> - <object class="GtkLabel" id="label10"> + <object class="GtkLabel" id="3"> <property name="visible">True</property> <property name="can_focus">False</property> - <property name="label" translatable="yes">_3</property> + <property name="hexpand">True</property> + <property name="label">_3</property> <property name="use_underline">True</property> </object> <packing> @@ -357,33 +361,7 @@ </packing> </child> <child> - <object class="GtkArrow" id="arrow1"> - <property name="visible">True</property> - <property name="can_focus">False</property> - </object> - <packing> - <property name="left_attach">5</property> - <property name="top_attach">0</property> - <property name="width">1</property> - <property name="height">1</property> - </packing> - </child> - <child> - <object class="GtkArrow" id="arrow2"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="arrow_type">left</property> - <property name="shadow_type">in</property> - </object> - <packing> - <property name="left_attach">1</property> - <property name="top_attach">0</property> - <property name="width">1</property> - <property name="height">1</property> - </packing> - </child> - <child> - <object class="GtkLabel" id="label6"> + <object class="GtkLabel" id="widthft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -397,11 +375,15 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton6"> + <object class="GtkSpinButton" id="width3mf:0.00cm"> <property name="visible">True</property> <property name="can_focus">True</property> + <property name="halign">center</property> + <property name="hexpand">True</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment2</property> + <property name="digits">2</property> </object> <packing> <property name="left_attach">4</property> @@ -411,11 +393,15 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton5"> + <object class="GtkSpinButton" id="width2mf:0.00cm"> <property name="visible">True</property> <property name="can_focus">True</property> + <property name="halign">center</property> + <property name="hexpand">True</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment2</property> + <property name="digits">2</property> </object> <packing> <property name="left_attach">3</property> @@ -425,11 +411,15 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton4"> + <object class="GtkSpinButton" id="width1mf:0.00cm"> <property name="visible">True</property> <property name="can_focus">True</property> + <property name="halign">center</property> + <property name="hexpand">True</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment2</property> + <property name="digits">2</property> </object> <packing> <property name="left_attach">2</property> @@ -439,9 +429,10 @@ </packing> </child> <child> - <object class="GtkLabel" id="label21"> + <object class="GtkLabel" id="distft"> <property name="visible">True</property> <property name="can_focus">False</property> + <property name="xalign">0</property> <property name="label" translatable="yes">Spacing</property> </object> <packing> @@ -458,11 +449,14 @@ <property name="halign">center</property> <property name="column_spacing">24</property> <child> - <object class="GtkSpinButton" id="spinbutton12"> + <object class="GtkSpinButton" id="spacing1mf:0.00cm"> <property name="visible">True</property> <property name="can_focus">True</property> + <property name="halign">center</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment3</property> + <property name="digits">2</property> </object> <packing> <property name="left_attach">0</property> @@ -472,11 +466,14 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton13"> + <object class="GtkSpinButton" id="spacing2mf:0.00cm"> <property name="visible">True</property> <property name="can_focus">True</property> + <property name="halign">center</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment3</property> + <property name="digits">2</property> </object> <packing> <property name="left_attach">1</property> @@ -494,7 +491,7 @@ </packing> </child> <child> - <object class="GtkCheckButton" id="checkbutton2"> + <object class="GtkCheckButton" id="autowidth"> <property name="label" translatable="yes">Auto_Width</property> <property name="visible">True</property> <property name="can_focus">True</property> @@ -511,6 +508,34 @@ </packing> </child> <child> + <object class="GtkButton" id="back"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">True</property> + <property name="image">image7</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="GtkButton" id="next"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">True</property> + <property name="image">image8</property> + </object> + <packing> + <property name="left_attach">5</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> <placeholder/> </child> <child> @@ -572,7 +597,7 @@ <property name="row_spacing">6</property> <property name="column_spacing">12</property> <child> - <object class="GtkLabel" id="label12"> + <object class="GtkLabel" id="linestyleft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -587,7 +612,7 @@ </packing> </child> <child> - <object class="GtkLabel" id="label13"> + <object class="GtkLabel" id="linewidthft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -602,7 +627,7 @@ </packing> </child> <child> - <object class="GtkLabel" id="label14"> + <object class="GtkLabel" id="lineheightft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -617,7 +642,7 @@ </packing> </child> <child> - <object class="GtkLabel" id="label15"> + <object class="GtkLabel" id="lineposft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -632,7 +657,7 @@ </packing> </child> <child> - <object class="GtkLabel" id="label16"> + <object class="GtkLabel" id="linecolorft"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="xalign">0</property> @@ -647,11 +672,9 @@ </packing> </child> <child> - <object class="GtkComboBoxText" id="comboboxtext1"> + <object class="svtlo:LineListBox" id="linestylelb"> <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="entry_text_column">0</property> - <property name="id_column">1</property> + <property name="dropdown">True</property> </object> <packing> <property name="left_attach">1</property> @@ -661,11 +684,16 @@ </packing> </child> <child> - <object class="GtkComboBoxText" id="comboboxtext2"> + <object class="GtkComboBoxText" id="lineposlb"> <property name="visible">True</property> <property name="can_focus">False</property> <property name="entry_text_column">0</property> <property name="id_column">1</property> + <items> + <item translatable="yes">Top</item> + <item translatable="yes">Centered</item> + <item translatable="yes">Bottom</item> + </items> </object> <packing> <property name="left_attach">3</property> @@ -675,11 +703,12 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton2"> + <object class="GtkSpinButton" id="lineheightmf:0%"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment5</property> </object> <packing> <property name="left_attach">3</property> @@ -689,11 +718,13 @@ </packing> </child> <child> - <object class="GtkSpinButton" id="spinbutton3"> + <object class="GtkSpinButton" id="linewidthmf:0.00pt"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="invisible_char">•</property> <property name="invisible_char_set">True</property> + <property name="adjustment">adjustment4</property> + <property name="digits">2</property> </object> <packing> <property name="left_attach">1</property> @@ -703,11 +734,9 @@ </packing> </child> <child> - <object class="GtkComboBoxText" id="comboboxtext3"> + <object class="svtlo:ColorListBox" id="colorlb"> <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="entry_text_column">0</property> - <property name="id_column">1</property> + <property name="dropdown">True</property> </object> <packing> <property name="left_attach">5</property> @@ -745,4 +774,68 @@ </packing> </child> </object> + <object class="GtkListStore" id="liststore2"> + <columns> + <!-- column-name gchararray1 --> + <column type="gchararray"/> + <!-- column-name gint1 --> + <column type="gint"/> + </columns> + <data> + <row> + <col id="0" translatable="yes">Selection</col> + <col id="1">0</col> + </row> + <row> + <col id="0" translatable="yes">Current Section</col> + <col id="1">1</col> + </row> + <row> + <col id="0" translatable="yes">Selected section</col> + <col id="1">2</col> + </row> + <row> + <col id="0" translatable="yes">Frame</col> + <col id="1">4</col> + </row> + <row> + <col id="0" translatable="yes">Page Style: </col> + <col id="1">3</col> + </row> + </data> + </object> + <object class="GtkImage" id="image7"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="stock">gtk-go-back</property> + <property name="icon-size">1</property> + </object> + <object class="GtkImage" id="image8"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="stock">gtk-go-forward</property> + <property name="icon-size">1</property> + </object> + <object class="GtkListStore" id="liststore1"> + <columns> + <!-- column-name gchararray1 --> + <column type="gchararray"/> + <!-- column-name gint1 --> + <column type="gint"/> + </columns> + <data> + <row> + <col id="0" translatable="yes">Left-to-right</col> + <col id="1">0</col> + </row> + <row> + <col id="0" translatable="yes">Right-to-left</col> + <col id="1">1</col> + </row> + <row> + <col id="0" translatable="yes">Use superordinate object settings</col> + <col id="1">4</col> + </row> + </data> + </object> </interface> |