convert conditional format src fragment to .ui and layout
this is a difficult widget
Change-Id: If4ea45230679c46f7ad763f07c876dd74d4478d0
diff --git a/sc/AllLangResTarget_sc.mk b/sc/AllLangResTarget_sc.mk
index 6674502..cd43a8c 100644
--- a/sc/AllLangResTarget_sc.mk
+++ b/sc/AllLangResTarget_sc.mk
@@ -35,7 +35,6 @@ $(eval $(call gb_SrsTarget_add_files,sc/res,\
sc/source/ui/src/scerrors.src \
sc/source/ui/src/scstring.src \
sc/source/ui/src/filter.src \
sc/source/ui/src/condformatdlg.src \
sc/source/ui/cctrl/checklistmenu.src \
sc/source/ui/navipi/navipi.src \
sc/source/ui/styleui/scstyles.src \
diff --git a/sc/UIConfig_scalc.mk b/sc/UIConfig_scalc.mk
index db0f9a2..056dbda 100644
--- a/sc/UIConfig_scalc.mk
+++ b/sc/UIConfig_scalc.mk
@@ -101,6 +101,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/scalc,\
sc/uiconfig/scalc/ui/colwidthdialog \
sc/uiconfig/scalc/ui/condformatmanager \
sc/uiconfig/scalc/ui/conditionalformatdialog \
sc/uiconfig/scalc/ui/conditionalentry \
sc/uiconfig/scalc/ui/conditionaliconset \
sc/uiconfig/scalc/ui/conflictsdialog \
sc/uiconfig/scalc/ui/consolidatedialog \
diff --git a/sc/inc/sc.hrc b/sc/inc/sc.hrc
index 07844b5..f490654 100644
--- a/sc/inc/sc.hrc
+++ b/sc/inc/sc.hrc
@@ -1092,7 +1092,6 @@
#define RID_SCDLG_DPSHOWDETAIL (SC_DIALOGS_START + 137)
#define RID_POPUP_FILTER (SC_DIALOGS_START + 153)
#define RID_COND_ENTRY (SC_DIALOGS_START + 156)
#define RID_SCDLG_COND_FORMAT_MANAGER (SC_DIALOGS_START + 159)
diff --git a/sc/source/ui/condformat/condformatdlg.cxx b/sc/source/ui/condformat/condformatdlg.cxx
index 82fb406..4d03fcf 100644
--- a/sc/source/ui/condformat/condformatdlg.cxx
+++ b/sc/source/ui/condformat/condformatdlg.cxx
@@ -8,7 +8,6 @@
*/
#include "condformatdlg.hxx"
#include "condformatdlg.hrc"
#include <vcl/vclevent.hxx>
#include <svl/style.hxx>
@@ -158,7 +157,7 @@ VCL_BUILDER_DECL_FACTORY(ScCondFormatList)
Size ScCondFormatList::GetOptimalSize() const
{
return LogicToPixel(Size(290, 185), MapUnit::MapAppFont);
return LogicToPixel(Size(300, 185), MapUnit::MapAppFont);
}
void ScCondFormatList::Resize()
diff --git a/sc/source/ui/condformat/condformatdlgentry.cxx b/sc/source/ui/condformat/condformatdlgentry.cxx
index 8bfabee..415aa11 100644
--- a/sc/source/ui/condformat/condformatdlgentry.cxx
+++ b/sc/source/ui/condformat/condformatdlgentry.cxx
@@ -9,7 +9,6 @@
#include "condformatdlg.hxx"
#include "condformatdlgentry.hxx"
#include "condformatdlg.hrc"
#include "conditio.hxx"
#include "document.hxx"
@@ -33,20 +32,25 @@
#include "colorformat.hxx"
#include "globstr.hrc"
#include "sc.hrc"
#include <set>
ScCondFrmtEntry::ScCondFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos):
Control(pParent, ScResId( RID_COND_ENTRY ) ),
mbActive(false),
maFtCondNr( VclPtr<FixedText>::Create( this, ScResId( FT_COND_NR ) ) ),
maFtCondition( VclPtr<FixedText>::Create( this, ScResId( FT_CONDITION ) ) ),
mnIndex(0),
maStrCondition(ScResId(SCSTR_CONDITION).toString()),
maLbType( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE ) ) ),
mpDoc(pDoc),
maPos(rPos)
ScCondFrmtEntry::ScCondFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos)
: VclContainer(pParent, WB_CLIPCHILDREN | WB_BORDER)
, mbActive(false)
, mnIndex(0)
, maStrCondition(ScResId(SCSTR_CONDITION).toString())
, mpDoc(pDoc)
, maPos(rPos)
{
m_pUIBuilder = new VclBuilder(this, getUIRootDir(), "modules/scalc/ui/conditionalentry.ui");
get(maGrid, "grid");
get(maFtCondNr, "number");
get(maFtCondition, "condition");
get(maLbType, "type");
Color aBack(GetSettings().GetStyleSettings().GetWindowColor());
SetControlBackground(aBack);
@@ -60,6 +64,8 @@ ScCondFrmtEntry::ScCondFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const S
maLbType->SetSelectHdl( LINK( pParent, ScCondFormatList, TypeListHdl ) );
maClickHdl = LINK( pParent, ScCondFormatList, EntrySelectHdl );
Show();
}
ScCondFrmtEntry::~ScCondFrmtEntry()
@@ -67,21 +73,33 @@ ScCondFrmtEntry::~ScCondFrmtEntry()
disposeOnce();
}
Size ScCondFrmtEntry::calculateRequisition() const
{
return getLayoutRequisition(*maGrid);
}
void ScCondFrmtEntry::setAllocation(const Size &rAllocation)
{
setLayoutPosSize(*maGrid, Point(0, 0), rAllocation);
}
void ScCondFrmtEntry::dispose()
{
maFtCondNr.disposeAndClear();
maFtCondition.disposeAndClear();
maLbType.disposeAndClear();
Control::dispose();
maFtCondNr.clear();
maFtCondition.clear();
maLbType.clear();
maGrid.clear();
disposeBuilder();
VclContainer::dispose();
}
bool ScCondFrmtEntry::Notify( NotifyEvent& rNEvt )
{
if( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
if (rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN)
{
ImplCallEventListenersAndHandler( VCLEVENT_WINDOW_MOUSEBUTTONDOWN, [this] () { maClickHdl.Call(*this); } );
maClickHdl.Call(*this);
}
return Control::Notify(rNEvt);
return VclContainer::Notify(rNEvt);
}
void ScCondFrmtEntry::SetIndex(sal_Int32 nIndex)
@@ -94,24 +112,11 @@ void ScCondFrmtEntry::SetIndex(sal_Int32 nIndex)
void ScCondFrmtEntry::SetHeight()
{
long nPad = LogicToPixel(Size(42,2), MapMode(MapUnit::MapAppFont)).getHeight();
// Calculate maximum height we need from visible widgets
sal_uInt16 nChildren = GetChildCount();
long nMaxHeight = 0;
for(sal_uInt16 i = 0; i < nChildren; i++)
const long nMaxHeight = get_preferred_size().Height();
if (nMaxHeight > 0)
{
vcl::Window *pChild = GetChild(i);
if(!pChild || !pChild->IsVisible())
continue;
Point aPos = pChild->GetPosPixel();
Size aSize = pChild->GetSizePixel();
nMaxHeight = std::max(aPos.Y() + aSize.Height(), nMaxHeight);
}
Size aSize = GetSizePixel();
if(nMaxHeight > 0)
{
Size aSize = GetSizePixel();
const long nPad = LogicToPixel(Size(0, 2), MapMode(MapUnit::MapAppFont)).getHeight();
aSize.Height() = nMaxHeight + nPad;
SetSizePixel(aSize);
}
@@ -186,20 +191,20 @@ const ScConditionMode ScConditionFrmtEntry::mpEntryToCond[ScConditionFrmtEntry::
SC_COND_NOT_CONTAINS_TEXT
};
ScConditionFrmtEntry::ScConditionFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, ScCondFormatDlg* pDialogParent,
const ScAddress& rPos, const ScCondFormatEntry* pFormatEntry ):
ScCondFrmtEntry( pParent, pDoc, rPos ),
maLbCondType( VclPtr<ListBox>::Create( this, ScResId( LB_CELLIS_TYPE ) ) ),
maEdVal1( VclPtr<formula::RefEdit>::Create( this, nullptr, nullptr, ScResId( ED_VAL1 ) ) ),
maEdVal2( VclPtr<formula::RefEdit>::Create( this, nullptr, nullptr, ScResId( ED_VAL2 ) ) ),
maFtVal( VclPtr<FixedText>::Create( this, ScResId( FT_VAL ) ) ),
maFtStyle( VclPtr<FixedText>::Create( this, ScResId( FT_STYLE ) ) ),
maLbStyle( VclPtr<ListBox>::Create( this, ScResId( LB_STYLE ) ) ),
maWdPreview( VclPtr<SvxFontPrevWindow>::Create( this, ScResId( WD_PREVIEW ) ) ),
mbIsInStyleCreate(false)
ScConditionFrmtEntry::ScConditionFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, ScCondFormatDlg* pDialogParent,
const ScAddress& rPos, const ScCondFormatEntry* pFormatEntry)
: ScCondFrmtEntry(pParent, pDoc, rPos)
, mbIsInStyleCreate(false)
{
get(maLbCondType, "typeis");
get(maEdVal1, "val1");
get(maEdVal2, "val2");
get(maFtVal, "valueft");
get(maFtStyle, "styleft");
get(maLbStyle, "style");
get(maWdPreview, "preview");
maWdPreview->set_height_request(maLbStyle->get_preferred_size().Height());
FreeResource();
maLbType->SelectEntryPos(1);
Init(pDialogParent);
@@ -252,13 +257,13 @@ ScConditionFrmtEntry::~ScConditionFrmtEntry()
void ScConditionFrmtEntry::dispose()
{
maLbCondType.disposeAndClear();
maEdVal1.disposeAndClear();
maEdVal2.disposeAndClear();
maFtVal.disposeAndClear();
maFtStyle.disposeAndClear();
maLbStyle.disposeAndClear();
maWdPreview.disposeAndClear();
maLbCondType.clear();
maEdVal1.clear();
maEdVal2.clear();
maFtVal.clear();
maFtStyle.clear();
maLbStyle.clear();
maWdPreview.clear();
ScCondFrmtEntry::dispose();
}
@@ -348,7 +353,6 @@ void ScConditionFrmtEntry::Deselect()
ScCondFrmtEntry::Deselect();
}
sal_Int32 ScConditionFrmtEntry::ConditionModeToEntryPos( ScConditionMode eMode )
{
for ( sal_Int32 i = 0; i < NUM_COND_ENTRIES; ++i )
@@ -552,16 +556,17 @@ IMPL_LINK_NOARG(ScConditionFrmtEntry, StyleSelectHdl, ListBox&, void)
// formula
ScFormulaFrmtEntry::ScFormulaFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, ScCondFormatDlg* pDialogParent, const ScAddress& rPos, const ScCondFormatEntry* pFormat ):
ScCondFrmtEntry( pParent, pDoc, rPos ),
maFtStyle( VclPtr<FixedText>::Create( this, ScResId( FT_STYLE ) ) ),
maLbStyle( VclPtr<ListBox>::Create( this, ScResId( LB_STYLE ) ) ),
maWdPreview( VclPtr<SvxFontPrevWindow>::Create( this, ScResId( WD_PREVIEW ) ) ),
maEdFormula( VclPtr<formula::RefEdit>::Create(this, nullptr, nullptr, ScResId( ED_FORMULA ) ) )
ScFormulaFrmtEntry::ScFormulaFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, ScCondFormatDlg* pDialogParent, const ScAddress& rPos, const ScCondFormatEntry* pFormat )
: ScCondFrmtEntry(pParent, pDoc, rPos)
{
get(maFtStyle, "styleft");
get(maLbStyle, "style");
get(maWdPreview, "preview");
maWdPreview->set_height_request(maLbStyle->get_preferred_size().Height());
get(maEdFormula, "formula");
Init(pDialogParent);
FreeResource();
maLbType->SelectEntryPos(2);
if(pFormat)
@@ -584,10 +589,10 @@ ScFormulaFrmtEntry::~ScFormulaFrmtEntry()
void ScFormulaFrmtEntry::dispose()
{
maFtStyle.disposeAndClear();
maLbStyle.disposeAndClear();
maWdPreview.disposeAndClear();
maEdFormula.disposeAndClear();
maFtStyle.clear();
maLbStyle.clear();
maWdPreview.clear();
maEdFormula.clear();
ScCondFrmtEntry::dispose();
}
@@ -733,16 +738,17 @@ ScColorScaleEntry* createColorScaleEntry( const ListBox& rType, const ColorListB
}
ScColorScale2FrmtEntry::ScColorScale2FrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScColorScaleFormat* pFormat ):
ScCondFrmtEntry( pParent, pDoc, rPos ),
maLbColorFormat( VclPtr<ListBox>::Create( this, ScResId( LB_COLOR_FORMAT ) ) ),
maLbEntryTypeMin( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MIN ) ) ),
maLbEntryTypeMax( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MAX ) ) ),
maEdMin( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MIN ) ) ),
maEdMax( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MAX ) ) ),
maLbColMin( VclPtr<ColorListBox>::Create( this, ScResId( LB_COL_MIN ) ) ),
maLbColMax( VclPtr<ColorListBox>::Create( this, ScResId( LB_COL_MAX ) ) )
ScColorScale2FrmtEntry::ScColorScale2FrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScColorScaleFormat* pFormat )
: ScCondFrmtEntry(pParent, pDoc, rPos)
{
get(maLbColorFormat, "colorformat");
get(maLbEntryTypeMin, "colscalemin");
get(maLbEntryTypeMax, "colscalemax");
get(maEdMin, "edcolscalemin");
get(maEdMax, "edcolscalemax");
get(maLbColMin, "lbcolmin");
get(maLbColMax, "lbcolmax");
// remove the automatic entry from color scales
maLbEntryTypeMin->RemoveEntry(0);
maLbEntryTypeMax->RemoveEntry(0);
@@ -762,7 +768,6 @@ ScColorScale2FrmtEntry::ScColorScale2FrmtEntry( vcl::Window* pParent, ScDocument
maLbEntryTypeMin->SelectEntryPos(0);
maLbEntryTypeMax->SelectEntryPos(1);
}
FreeResource();
maLbColorFormat->SetSelectHdl( LINK( pParent, ScCondFormatList, ColFormatTypeHdl ) );
@@ -777,13 +782,13 @@ ScColorScale2FrmtEntry::~ScColorScale2FrmtEntry()
void ScColorScale2FrmtEntry::dispose()
{
maLbColorFormat.disposeAndClear();
maLbEntryTypeMin.disposeAndClear();
maLbEntryTypeMax.disposeAndClear();
maEdMin.disposeAndClear();
maEdMax.disposeAndClear();
maLbColMin.disposeAndClear();
maLbColMax.disposeAndClear();
maLbColorFormat.clear();
maLbEntryTypeMin.clear();
maLbEntryTypeMax.clear();
maEdMin.clear();
maEdMax.clear();
maLbColMin.clear();
maLbColMax.clear();
ScCondFrmtEntry::dispose();
}
@@ -899,19 +904,20 @@ IMPL_LINK( ScColorScale2FrmtEntry, EntryTypeHdl, ListBox&, rBox, void )
pEd->Disable();
}
ScColorScale3FrmtEntry::ScColorScale3FrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScColorScaleFormat* pFormat ):
ScCondFrmtEntry( pParent, pDoc, rPos ),
maLbColorFormat( VclPtr<ListBox>::Create( this, ScResId( LB_COLOR_FORMAT ) ) ),
maLbEntryTypeMin( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MIN ) ) ),
maLbEntryTypeMiddle( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MIDDLE ) ) ),
maLbEntryTypeMax( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MAX ) ) ),
maEdMin( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MIN ) ) ),
maEdMiddle( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MIDDLE ) ) ),
maEdMax( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MAX ) ) ),
maLbColMin( VclPtr<ColorListBox>::Create( this, ScResId( LB_COL_MIN ) ) ),
maLbColMiddle( VclPtr<ColorListBox>::Create( this, ScResId( LB_COL_MIDDLE ) ) ),
maLbColMax( VclPtr<ColorListBox>::Create( this, ScResId( LB_COL_MAX ) ) )
ScColorScale3FrmtEntry::ScColorScale3FrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScColorScaleFormat* pFormat )
: ScCondFrmtEntry(pParent, pDoc, rPos)
{
get(maLbColorFormat, "colorformat");
get(maLbEntryTypeMin, "colscalemin");
get(maLbEntryTypeMiddle, "colscalemiddle");
get(maLbEntryTypeMax, "colscalemax");
get(maEdMin, "edcolscalemin");
get(maEdMiddle, "edcolscalemiddle");
get(maEdMax, "edcolscalemax");
get(maLbColMin, "lbcolmin");
get(maLbColMiddle, "lbcolmiddle");
get(maLbColMax, "lbcolmax");
// remove the automatic entry from color scales
maLbEntryTypeMin->RemoveEntry(0);
maLbEntryTypeMiddle->RemoveEntry(0);
@@ -938,7 +944,6 @@ ScColorScale3FrmtEntry::ScColorScale3FrmtEntry( vcl::Window* pParent, ScDocument
maLbEntryTypeMax->SelectEntryPos(1);
maEdMiddle->SetText(OUString::number(50));
}
FreeResource();
maLbColorFormat->SetSelectHdl( LINK( pParent, ScCondFormatList, ColFormatTypeHdl ) );
EntryTypeHdl(*maLbEntryTypeMin.get());
@@ -953,16 +958,16 @@ ScColorScale3FrmtEntry::~ScColorScale3FrmtEntry()
void ScColorScale3FrmtEntry::dispose()
{
maLbColorFormat.disposeAndClear();
maLbEntryTypeMin.disposeAndClear();
maLbEntryTypeMiddle.disposeAndClear();
maLbEntryTypeMax.disposeAndClear();
maEdMin.disposeAndClear();
maEdMiddle.disposeAndClear();
maEdMax.disposeAndClear();
maLbColMin.disposeAndClear();
maLbColMiddle.disposeAndClear();
maLbColMax.disposeAndClear();
maLbColorFormat.clear();
maLbEntryTypeMin.clear();
maLbEntryTypeMiddle.clear();
maLbEntryTypeMax.clear();
maEdMin.clear();
maEdMiddle.clear();
maEdMax.clear();
maLbColMin.clear();
maLbColMiddle.clear();
maLbColMax.clear();
ScCondFrmtEntry::dispose();
}
@@ -1149,15 +1154,16 @@ void SetDataBarEntryTypes( const ScColorScaleEntry& rEntry, ListBox& rLbType, Ed
}
ScDataBarFrmtEntry::ScDataBarFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScDataBarFormat* pFormat ):
ScCondFrmtEntry( pParent, pDoc, rPos ),
maLbColorFormat( VclPtr<ListBox>::Create( this, ScResId( LB_COLOR_FORMAT ) ) ),
maLbDataBarMinType( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MIN ) ) ),
maLbDataBarMaxType( VclPtr<ListBox>::Create( this, ScResId( LB_TYPE_COL_SCALE_MAX ) ) ),
maEdDataBarMin( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MIN ) ) ),
maEdDataBarMax( VclPtr<Edit>::Create( this, ScResId( ED_COL_SCALE_MAX ) ) ),
maBtOptions( VclPtr<PushButton>::Create( this, ScResId( BTN_OPTIONS ) ) )
ScDataBarFrmtEntry::ScDataBarFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScDataBarFormat* pFormat )
: ScCondFrmtEntry(pParent, pDoc, rPos)
{
get(maLbColorFormat, "colorformat");
get(maLbDataBarMinType, "colscalemin");
get(maLbDataBarMaxType, "colscalemax");
get(maEdDataBarMin, "edcolscalemin");
get(maEdDataBarMax, "edcolscalemax");
get(maBtOptions, "options");
maLbColorFormat->SelectEntryPos(2);
maLbType->SelectEntryPos(0);
if(pFormat)
@@ -1176,8 +1182,6 @@ ScDataBarFrmtEntry::ScDataBarFrmtEntry( vcl::Window* pParent, ScDocument* pDoc,
Init();
maLbColorFormat->SetSelectHdl( LINK( pParent, ScCondFormatList, ColFormatTypeHdl ) );
FreeResource();
}
ScDataBarFrmtEntry::~ScDataBarFrmtEntry()
@@ -1187,12 +1191,12 @@ ScDataBarFrmtEntry::~ScDataBarFrmtEntry()
void ScDataBarFrmtEntry::dispose()
{
maLbColorFormat.disposeAndClear();
maLbDataBarMinType.disposeAndClear();
maLbDataBarMaxType.disposeAndClear();
maEdDataBarMin.disposeAndClear();
maEdDataBarMax.disposeAndClear();
maBtOptions.disposeAndClear();
maLbColorFormat.clear();
maLbDataBarMinType.clear();
maLbDataBarMaxType.clear();
maEdDataBarMin.clear();
maEdDataBarMax.clear();
maBtOptions.clear();
ScCondFrmtEntry::dispose();
}
@@ -1288,16 +1292,17 @@ IMPL_LINK_NOARG( ScDataBarFrmtEntry, OptionBtnHdl, Button*, void )
}
}
ScDateFrmtEntry::ScDateFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScCondDateFormatEntry* pFormat ):
ScCondFrmtEntry( pParent, pDoc, ScAddress() ),
maLbDateEntry( VclPtr<ListBox>::Create( this, ScResId( LB_DATE_TYPE ) ) ),
maFtStyle( VclPtr<FixedText>::Create( this, ScResId( FT_STYLE ) ) ),
maLbStyle( VclPtr<ListBox>::Create( this, ScResId( LB_STYLE ) ) ),
maWdPreview( VclPtr<SvxFontPrevWindow>::Create( this, ScResId( WD_PREVIEW ) ) ),
mbIsInStyleCreate(false)
ScDateFrmtEntry::ScDateFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const ScCondDateFormatEntry* pFormat)
: ScCondFrmtEntry(pParent, pDoc, ScAddress())
, mbIsInStyleCreate(false)
{
get(maLbDateEntry, "datetype");
get(maFtStyle, "styleft");
get(maLbStyle, "style");
get(maWdPreview, "preview");
maWdPreview->set_height_request(maLbStyle->get_preferred_size().Height());
Init();
FreeResource();
StartListening(*pDoc->GetStyleSheetPool(), true);
@@ -1320,10 +1325,10 @@ ScDateFrmtEntry::~ScDateFrmtEntry()
void ScDateFrmtEntry::dispose()
{
maLbDateEntry.disposeAndClear();
maFtStyle.disposeAndClear();
maLbStyle.disposeAndClear();
maWdPreview.disposeAndClear();
maLbDateEntry.clear();
maFtStyle.clear();
maLbStyle.clear();
maWdPreview.clear();
ScCondFrmtEntry::dispose();
}
@@ -1524,13 +1529,13 @@ void ScIconSetFrmtDataEntry::SetFirstEntry()
maLbEntryType->SelectEntryPos(1);
}
ScIconSetFrmtEntry::ScIconSetFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScIconSetFormat* pFormat ):
ScCondFrmtEntry( pParent, pDoc, rPos ),
maLbColorFormat( VclPtr<ListBox>::Create( this, ScResId( LB_COLOR_FORMAT ) ) ),
maLbIconSetType( VclPtr<ListBox>::Create( this, ScResId( LB_ICONSET_TYPE ) ) )
ScIconSetFrmtEntry::ScIconSetFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos, const ScIconSetFormat* pFormat)
: ScCondFrmtEntry(pParent, pDoc, rPos)
{
get(maLbColorFormat, "colorformat");
get(maLbIconSetType, "iconsettype");
Init();
FreeResource();
maLbColorFormat->SetSelectHdl( LINK( pParent, ScCondFormatList, ColFormatTypeHdl ) );
if(pFormat)
@@ -1566,8 +1571,8 @@ void ScIconSetFrmtEntry::dispose()
for (auto it = maEntries.begin(); it != maEntries.end(); ++it)
it->disposeAndClear();
maEntries.clear();
maLbColorFormat.disposeAndClear();
maLbIconSetType.disposeAndClear();
maLbColorFormat.clear();
maLbIconSetType.clear();
ScCondFrmtEntry::dispose();
}
diff --git a/sc/source/ui/inc/condformatdlg.hrc b/sc/source/ui/inc/condformatdlg.hrc
deleted file mode 100644
index 5390597..0000000
--- a/sc/source/ui/inc/condformatdlg.hrc
+++ /dev/null
@@ -1,55 +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/.
*/
#include "sc.hrc"
#define BTN_OK 1
#define BTN_CANCEL 2
#define BTN_ADD 10
#define BTN_REMOVE 11
#define LB_TYPE 14
#define FT_COND_NR 15
#define FT_CONDITION 16
#define LB_CELLIS_TYPE 17
#define ED_VAL1 18
#define ED_VAL2 19
#define LB_STYLE 20
#define FT_STYLE 21
#define LB_COLOR_FORMAT 22
#define WD_PREVIEW 26
#define BTN_OPTIONS 30
#define FT_RANGE 32
#define ED_RANGE 33
#define RB_RANGE 34
#define ED_FORMULA 35
#define ED_COL_SCALE_MIN 36
#define ED_COL_SCALE_MIDDLE 37
#define ED_COL_SCALE_MAX 38
#define LB_COL_MIN 39
#define LB_COL_MIDDLE 40
#define LB_COL_MAX 41
#define LB_TYPE_COL_SCALE_MIN 42
#define LB_TYPE_COL_SCALE_MIDDLE 43
#define LB_TYPE_COL_SCALE_MAX 44
#define LB_DATE_TYPE 45
#define LB_ICONSET_TYPE 47
#define FT_VAL 51
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/inc/condformatdlgentry.hxx b/sc/source/ui/inc/condformatdlgentry.hxx
index d5c99b7..cba1224 100644
--- a/sc/source/ui/inc/condformatdlgentry.hxx
+++ b/sc/source/ui/inc/condformatdlgentry.hxx
@@ -38,7 +38,8 @@ enum ScCondFrmtEntryType
}
class ScCondFrmtEntry : public Control
class ScCondFrmtEntry : public VclContainer
, public VclBuilderContainer
{
private:
bool mbActive;
@@ -46,6 +47,7 @@ private:
Link<ScCondFrmtEntry&,void> maClickHdl;
//general ui elements
VclPtr<VclContainer> maGrid;
VclPtr<FixedText> maFtCondNr;
VclPtr<FixedText> maFtCondition;
@@ -65,6 +67,8 @@ protected:
public:
ScCondFrmtEntry( vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos );
virtual ~ScCondFrmtEntry() override;
virtual Size calculateRequisition() const override;
virtual void setAllocation(const Size &rAllocation) override;
virtual void dispose() override;
virtual bool Notify( NotifyEvent& rNEvt ) override;
diff --git a/sc/source/ui/src/condformatdlg.src b/sc/source/ui/src/condformatdlg.src
deleted file mode 100644
index 70d5b36..0000000
--- a/sc/source/ui/src/condformatdlg.src
+++ /dev/null
@@ -1,294 +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/.
*/
#include "condformatdlg.hrc"
Control RID_COND_ENTRY
{
Pos = MAP_APPFONT( 0, 0 );
Size = MAP_APPFONT( 290, 40 );
Border = TRUE;
DialogControl = TRUE;
FixedText FT_COND_NR
{
Pos = MAP_APPFONT( 2, 2 );
Size = MAP_APPFONT( 50, 10 );
};
FixedText FT_CONDITION
{
Pos = MAP_APPFONT( 60, 2 );
Size = MAP_APPFONT( 120, 10 );
};
ListBox LB_TYPE
{
Pos = MAP_APPFONT( 5, 15 );
Size = MAP_APPFONT( 80, 60 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"All Cells";
"Cell value is";
"Formula is";
"Date is";
};
};
ListBox LB_CELLIS_TYPE
{
Pos = MAP_APPFONT( 90, 15 );
Size = MAP_APPFONT( 80, 80 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"equal to";
"less than";
"greater than";
"less than or equal to";
"greater than or equal to";
"not equal to";
"between";
"not between";
"duplicate";
"not duplicate";
"top 10 elements";
"bottom 10 elements";
"top 10 percent";
"bottom 10 percent";
"above average";
"below average";
"above or equal average";
"below or equal average";
"Error";
"No Error";
"Begins with";
"Ends with";
"Contains";
"Not Contains";
};
};
Edit ED_VAL1
{
Pos = MAP_APPFONT( 175, 15 );
Size = MAP_APPFONT( 50, 12 );
Border = TRUE;
};
Edit ED_FORMULA
{
Pos = MAP_APPFONT( 90, 15 );
Size = MAP_APPFONT( 135, 12 );
Border = TRUE;
};
Edit ED_VAL2
{
Pos = MAP_APPFONT( 230, 15 );
Size = MAP_APPFONT( 50, 12 );
Border = TRUE;
};
ListBox LB_COLOR_FORMAT
{
Pos = MAP_APPFONT( 100, 15 );
Size = MAP_APPFONT( 80, 60);
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"Color Scale (2 Entries)";
"Color Scale (3 Entries)";
"Data Bar";
"Icon Set";
};
};
FixedText FT_STYLE
{
Pos = MAP_APPFONT( 5, 32 );
Size = MAP_APPFONT( 50, 14 );
Text [ en-US ] = "Apply Style";
};
ListBox LB_STYLE
{
Pos = MAP_APPFONT( 90, 32 );
Size = MAP_APPFONT( 80, 80 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"New Style...";
};
};
ListBox LB_TYPE_COL_SCALE_MIN
{
Pos = MAP_APPFONT( 5, 32 );
Size = MAP_APPFONT( 80, 60 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"Automatic";
"Min";
"Max";
"Percentile";
"Value";
"Percent";
"Formula";
};
};
ListBox LB_TYPE_COL_SCALE_MIDDLE
{
Pos = MAP_APPFONT( 100, 32 );
Size = MAP_APPFONT( 80, 60 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"Automatic";
"Min";
"Max";
"Percentile";
"Value";
"Percent";
"Formula";
};
};
ListBox LB_TYPE_COL_SCALE_MAX
{
Pos = MAP_APPFONT( 195, 32 );
Size = MAP_APPFONT( 80, 60 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"Automatic";
"Min";
"Max";
"Percentile";
"Value";
"Percent";
"Formula";
};
};
Window WD_PREVIEW
{
Pos = MAP_APPFONT( 175, 32 );
Size = MAP_APPFONT( 105, 14 );
Text [ en-US ] = "Example";
Border = TRUE;
};
FixedText FT_VAL
{
Pos = MAP_APPFONT( 5, 48 );
Size = MAP_APPFONT( 300, 12 );
Text[ en-US ] = "Enter a value!";
};
Edit ED_COL_SCALE_MIN
{
Pos = MAP_APPFONT( 5, 48 );
Size = MAP_APPFONT( 80, 12 );
Border = TRUE;
};
Edit ED_COL_SCALE_MIDDLE
{
Pos = MAP_APPFONT( 100, 48 );
Size = MAP_APPFONT( 80, 12 );
Border = TRUE;
};
Edit ED_COL_SCALE_MAX
{
Pos = MAP_APPFONT( 195, 48 );
Size = MAP_APPFONT( 80, 12 );
Border = TRUE;
};
ListBox LB_COL_MIN
{
Pos = MAP_APPFONT( 5, 62 );
Size = MAP_APPFONT( 80, 40 );
Border = TRUE;
DropDown = TRUE;
};
ListBox LB_COL_MIDDLE
{
Pos = MAP_APPFONT( 100, 62 );
Size = MAP_APPFONT( 80, 40 );
Border = TRUE;
DropDown = TRUE;
};
ListBox LB_COL_MAX
{
Pos = MAP_APPFONT( 195, 62 );
Size = MAP_APPFONT( 80, 40 );
Border = TRUE;
DropDown = TRUE;
};
PushButton BTN_OPTIONS
{
Pos = MAP_APPFONT( 120, 62 );
Size = MAP_APPFONT( 60, 14 );
Text [ en-US ] = "More Options...";
};
ListBox LB_DATE_TYPE
{
Pos = MAP_APPFONT( 100, 15 );
Size = MAP_APPFONT( 100, 60 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"Today";
"Yesterday";
"Tomorrow";
"Last 7 days";
"This week";
"Last week";
"Next week";
"This month";
"Last month";
"Next month";
"This year";
"Last year";
"Next year";
};
};
ListBox LB_ICONSET_TYPE
{
Pos = MAP_APPFONT( 200, 15 );
Size = MAP_APPFONT( 80, 50 );
Border = TRUE;
DropDown = TRUE;
StringList [ en-US ] =
{
"3 Arrows";
"3 Gray Arrows";
"3 Flags";
"3 Traffic Lights 1";
"3 Traffic Lights 2";
"3 Signs";
"3 Symbols 1";
"3 Symbols 2";
"3 Smileys";
"3 Stars";
"3 Triangles";
"3 Colored Smileys";
"4 Arrows";
"4 Gray Arrows";
"4 Circles Red to Black";
"4 Ratings";
"4 Traffic Lights";
"5 Arrows";
"5 Gray Arrows";
"5 Ratings";
"5 Quarters";
"5 Boxes";
};
};
};
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/uiconfig/scalc/ui/conditionalentry.ui b/sc/uiconfig/scalc/ui/conditionalentry.ui
new file mode 100644
index 0000000..86d18e1
--- /dev/null
+++ b/sc/uiconfig/scalc/ui/conditionalentry.ui
@@ -0,0 +1,425 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Generated with glade 3.20.0 -->
<interface>
<requires lib="gtk+" version="3.0"/>
<requires lib="LibreOffice" version="1.0"/>
<object class="GtkGrid" id="grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="border_width">6</property>
<property name="row_spacing">6</property>
<property name="column_spacing">12</property>
<child>
<object class="GtkGrid" id="grid1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="column_spacing">12</property>
<child>
<object class="GtkLabel" id="number">
<property name="visible">True</property>
<property name="can_focus">False</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="condition">
<property name="visible">True</property>
<property name="can_focus">False</property>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
</packing>
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkGrid" id="grid2">
<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>
<property name="column_homogeneous">True</property>
<child>
<object class="GtkComboBoxText" id="type">
<property name="visible">True</property>
<property name="can_focus">False</property>
<items>
<item translatable="yes">All Cells</item>
<item translatable="yes">Cell value is</item>
<item translatable="yes">Formula is</item>
<item translatable="yes">Date is</item>
</items>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="styleft">
<property name="can_focus">False</property>
<property name="label" translatable="yes">Apply Style:</property>
<property name="use_underline">True</property>
<property name="mnemonic_widget">style</property>
<property name="xalign">0</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">2</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="style">
<property name="can_focus">False</property>
<items>
<item translatable="yes">New Style...</item>
</items>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">2</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="valueft">
<property name="can_focus">False</property>
<property name="label" translatable="yes">Enter a value:</property>
<property name="xalign">0</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">3</property>
<property name="width">3</property>
</packing>
</child>
<child>
<object class="GtkEntry" id="edcolscalemin">
<property name="can_focus">True</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">4</property>
</packing>
</child>
<child>
<object class="GtkEntry" id="edcolscalemiddle">
<property name="can_focus">True</property>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">4</property>
</packing>
</child>
<child>
<object class="GtkEntry" id="edcolscalemax">
<property name="can_focus">True</property>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">4</property>
</packing>
</child>
<child>
<object class="svtlo-ColorListBox" id="lbcolmin">
<property name="can_focus">False</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">5</property>
</packing>
</child>
<child>
<object class="svtlo-ColorListBox" id="lbcolmiddle">
<property name="can_focus">False</property>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">5</property>
</packing>
</child>
<child>
<object class="svtlo-ColorListBox" id="lbcolmax">
<property name="can_focus">False</property>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">5</property>
</packing>
</child>
<child>
<object class="GtkButton" id="options">
<property name="label" translatable="yes">More Options...</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">6</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="colscalemin">
<property name="can_focus">False</property>
<items>
<item translatable="yes">Automatic</item>
<item translatable="yes">Min</item>
<item translatable="yes">Max</item>
<item translatable="yes">Percentile</item>
<item translatable="yes">Value</item>
<item translatable="yes">Percent</item>
<item translatable="yes">Formula</item>
</items>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">1</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="colscalemiddle">
<property name="can_focus">False</property>
<items>
<item translatable="yes">Automatic</item>
<item translatable="yes">Min</item>
<item translatable="yes">Max</item>
<item translatable="yes">Percentile</item>
<item translatable="yes">Value</item>
<item translatable="yes">Percent</item>
<item translatable="yes">Formula</item>
</items>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">1</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="colscalemax">
<property name="can_focus">False</property>
<items>
<item translatable="yes">Automatic</item>
<item translatable="yes">Min</item>
<item translatable="yes">Max</item>
<item translatable="yes">Percentile</item>
<item translatable="yes">Value</item>
<item translatable="yes">Percent</item>
<item translatable="yes">Formula</item>
</items>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">1</property>
</packing>
</child>
<child>
<object class="svxlo-SvxFontPrevWindow" id="preview:border">
<property name="can_focus">False</property>
<property name="tooltip_text" translatable="yes">Example</property>
<property name="hexpand">True</property>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">2</property>
</packing>
</child>
<child>
<object class="GtkGrid">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="column_spacing">12</property>
<property name="column_homogeneous">True</property>
<child>
<object class="GtkGrid">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
<object class="GtkComboBoxText" id="typeis">
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<items>
<item translatable="yes">equal to</item>
<item translatable="yes">less than</item>
<item translatable="yes">greater than</item>
<item translatable="yes">less than or equal to</item>
<item translatable="yes">greater than or equal to</item>
<item translatable="yes">not equal to</item>
<item translatable="yes">between</item>
<item translatable="yes">not between</item>
<item translatable="yes">duplicate</item>
<item translatable="yes">not duplicate</item>
<item translatable="yes">top 10 elements</item>
<item translatable="yes">bottom 10 elements</item>
<item translatable="yes">top 10 percent</item>
<item translatable="yes">bottom 10 percent</item>
<item translatable="yes">above average</item>
<item translatable="yes">below average</item>
<item translatable="yes">above or equal average</item>
<item translatable="yes">below or equal average</item>
<item translatable="yes">Error</item>
<item translatable="yes">No Error</item>
<item translatable="yes">Begins with</item>
<item translatable="yes">Ends with</item>
<item translatable="yes">Contains</item>
<item translatable="yes">Not Contains</item>
</items>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="datetype">
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<items>
<item translatable="yes">Today</item>
<item translatable="yes">Yesterday</item>
<item translatable="yes">Tomorrow</item>
<item translatable="yes">Last 7 days</item>
<item translatable="yes">This week</item>
<item translatable="yes">Last week</item>
<item translatable="yes">Next week</item>
<item translatable="yes">This month</item>
<item translatable="yes">Last month</item>
<item translatable="yes">Next month</item>
<item translatable="yes">This year</item>
<item translatable="yes">Last year</item>
<item translatable="yes">Next year</item>
</items>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="colorformat">
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<items>
<item translatable="yes">Color Scale (2 Entries)</item>
<item translatable="yes">Color Scale (3 Entries)</item>
<item translatable="yes">Data Bar</item>
<item translatable="yes">Icon Set</item>
</items>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">0</property>
</packing>
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkGrid">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="column_spacing">12</property>
<child>
<object class="foruilo-RefEdit" id="val1">
<property name="can_focus">True</property>
<property name="hexpand">True</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="foruilo-RefEdit" id="val2">
<property name="can_focus">True</property>
<property name="hexpand">True</property>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="iconsettype">
<property name="can_focus">False</property>
<items>
<item translatable="yes">3 Arrows</item>
<item translatable="yes">3 Gray Arrows</item>
<item translatable="yes">3 Flags</item>
<item translatable="yes">3 Traffic Lights 1</item>
<item translatable="yes">3 Traffic Lights 2</item>
<item translatable="yes">3 Signs</item>
<item translatable="yes">3 Symbols 1</item>
<item translatable="yes">3 Symbols 2</item>
<item translatable="yes">3 Smileys</item>
<item translatable="yes">3 Stars</item>
<item translatable="yes">3 Triangles</item>
<item translatable="yes">3 Colored Smileys</item>
<item translatable="yes">4 Arrows</item>
<item translatable="yes">4 Gray Arrows</item>
<item translatable="yes">4 Circles Red to Black</item>
<item translatable="yes">4 Ratings</item>
<item translatable="yes">4 Traffic Lights</item>
<item translatable="yes">5 Arrows</item>
<item translatable="yes">5 Gray Arrows</item>
<item translatable="yes">5 Ratings</item>
<item translatable="yes">5 Quarters</item>
<item translatable="yes">5 Boxes</item>
</items>
</object>
<packing>
<property name="left_attach">2</property>
<property name="top_attach">0</property>
</packing>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
</packing>
</child>
<child>
<object class="foruilo-RefEdit" id="formula">
<property name="can_focus">True</property>
<property name="hexpand">True</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">1</property>
<property name="width">2</property>
</packing>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
<property name="width">2</property>
</packing>
</child>
<child>
<placeholder/>
</child>
<child>
<placeholder/>
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">1</property>
</packing>
</child>
</object>
</interface>