Kaydet (Commit) d07193a2 authored tarafından Caolán McNamara's avatar Caolán McNamara

weld OfaQuoteTabPage

Change-Id: I7da18597e85a03d96197f32862686a49f9d8e153
Reviewed-on: https://gerrit.libreoffice.org/64504
Tested-by: Jenkins
Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst 4c092454
...@@ -320,54 +320,48 @@ class OfaQuoteTabPage : public SfxTabPage ...@@ -320,54 +320,48 @@ class OfaQuoteTabPage : public SfxTabPage
using TabPage::ActivatePage; using TabPage::ActivatePage;
private: private:
/// For anything but writer
VclPtr<SvxCheckListBox> m_pCheckLB;
/// Just for writer
VclPtr<OfaACorrCheckListBox> m_pSwCheckLB;
OUString sNonBrkSpace; OUString sNonBrkSpace;
OUString sOrdinal; OUString sOrdinal;
std::unique_ptr<SvLBoxButtonData> m_xCheckButtonData;
VclPtr<CheckBox> m_pSingleTypoCB;
VclPtr<PushButton> m_pSglStartQuotePB;
VclPtr<FixedText> m_pSglStartExFT;
VclPtr<PushButton> m_pSglEndQuotePB;
VclPtr<FixedText> m_pSglEndExFT;
VclPtr<PushButton> m_pSglStandardPB;
VclPtr<CheckBox> m_pDoubleTypoCB;
VclPtr<PushButton> m_pDblStartQuotePB;
VclPtr<FixedText> m_pDblStartExFT;
VclPtr<PushButton> m_pDblEndQuotePB;
VclPtr<FixedText> m_pDblEndExFT;
VclPtr<PushButton> m_pDblStandardPB;
OUString m_sStandard;
sal_UCS4 cSglStartQuote; sal_UCS4 cSglStartQuote;
sal_UCS4 cSglEndQuote; sal_UCS4 cSglEndQuote;
sal_UCS4 cStartQuote; sal_UCS4 cStartQuote;
sal_UCS4 cEndQuote; sal_UCS4 cEndQuote;
DECL_LINK( QuoteHdl, Button*, void ); std::unique_ptr<weld::CheckButton> m_xSingleTypoCB;
DECL_LINK( StdQuoteHdl, Button*, void ); std::unique_ptr<weld::Button> m_xSglStartQuotePB;
std::unique_ptr<weld::Label> m_xSglStartExFT;
std::unique_ptr<weld::Button> m_xSglEndQuotePB;
std::unique_ptr<weld::Label> m_xSglEndExFT;
std::unique_ptr<weld::Button> m_xSglStandardPB;
std::unique_ptr<weld::CheckButton> m_xDoubleTypoCB;
std::unique_ptr<weld::Button> m_xDblStartQuotePB;
std::unique_ptr<weld::Label> m_xDblStartExFT;
std::unique_ptr<weld::Button> m_xDblEndQuotePB;
std::unique_ptr<weld::Label> m_xDblEndExFT;
std::unique_ptr<weld::Button> m_xDblStandardPB;
std::unique_ptr<weld::Label> m_xStandard;
/// For anything but writer
std::unique_ptr<weld::TreeView> m_xCheckLB;
/// Just for writer
std::unique_ptr<weld::TreeView> m_xSwCheckLB;
DECL_LINK(QuoteHdl, weld::Button&, void);
DECL_LINK(StdQuoteHdl, weld::Button&, void);
OUString ChangeStringExt_Impl( sal_UCS4 ); OUString ChangeStringExt_Impl( sal_UCS4 );
SvTreeListEntry* CreateEntry(OUString& rTxt, sal_uInt16 nCol); static void CreateEntry(weld::TreeView& rLstBox, const OUString& rTxt,
sal_uInt16 nCol, sal_uInt16 nTextCol);
OfaQuoteTabPage( vcl::Window* pParent, const SfxItemSet& rSet ); OfaQuoteTabPage(TabPageParent pParent, const SfxItemSet& rSet);
public: public:
virtual ~OfaQuoteTabPage() override; virtual ~OfaQuoteTabPage() override;
virtual void dispose() override;
static VclPtr<SfxTabPage> Create( TabPageParent pParent, static VclPtr<SfxTabPage> Create(TabPageParent pParent,
const SfxItemSet* rAttrSet); const SfxItemSet* rAttrSet);
virtual bool FillItemSet( SfxItemSet* rSet ) override; virtual bool FillItemSet( SfxItemSet* rSet ) override;
virtual void Reset( const SfxItemSet* rSet ) override; virtual void Reset( const SfxItemSet* rSet ) override;
......
...@@ -317,62 +317,6 @@ public: ...@@ -317,62 +317,6 @@ public:
} }
}; };
/*********************************************************************/
/* */
/* changed LBoxString */
/* */
/*********************************************************************/
class OfaImpBrwString : public SvLBoxString
{
public:
explicit OfaImpBrwString( const OUString& rStr ) : SvLBoxString(rStr){}
virtual void Paint(const Point& rPos, SvTreeListBox& rDev, vcl::RenderContext& rRenderContext,
const SvViewDataEntry* pView, const SvTreeListEntry& rEntry) override;
};
void OfaImpBrwString::Paint(const Point& rPos, SvTreeListBox& /*rDev*/, vcl::RenderContext& rRenderContext,
const SvViewDataEntry* /*pView*/, const SvTreeListEntry& rEntry)
{
rRenderContext.DrawText(rPos, GetText());
if (rEntry.GetUserData())
{
ImpUserData* pUserData = static_cast<ImpUserData*>(rEntry.GetUserData());
Point aNewPos(rPos);
aNewPos.AdjustX(rRenderContext.GetTextWidth(GetText()) );
vcl::Font aOldFont(rRenderContext.GetFont());
vcl::Font aFont(aOldFont);
if (pUserData->pFont)
{
aFont = *pUserData->pFont;
aFont.SetColor(aOldFont.GetColor());
aFont.SetFontSize(aOldFont.GetFontSize());
}
aFont.SetWeight(WEIGHT_BOLD);
bool bFett = true;
sal_Int32 nPos = 0;
do {
OUString sTxt(pUserData->pString->getToken(0, 1, nPos));
if (bFett)
rRenderContext.SetFont(aFont);
rRenderContext.DrawText(aNewPos, sTxt);
if (-1 != nPos)
aNewPos.AdjustX(rRenderContext.GetTextWidth(sTxt) );
if (bFett)
rRenderContext.SetFont(aOldFont);
bFett = !bFett;
} while(-1 != nPos);
}
}
/*********************************************************************/ /*********************************************************************/
/* */ /* */
/* use TabPage autoformat */ /* use TabPage autoformat */
...@@ -1691,66 +1635,44 @@ enum OfaQuoteOptions ...@@ -1691,66 +1635,44 @@ enum OfaQuoteOptions
REPLACE_1ST REPLACE_1ST
}; };
SvTreeListEntry* OfaQuoteTabPage::CreateEntry(OUString& rTxt, sal_uInt16 nCol) void OfaQuoteTabPage::CreateEntry(weld::TreeView& rCheckLB, const OUString& rTxt, sal_uInt16 nCol, sal_uInt16 nTextCol)
{ {
SvTreeListEntry* pEntry = new SvTreeListEntry; rCheckLB.insert(nullptr, -1, nullptr, nullptr, nullptr,
nullptr, nullptr, false);
if (!m_xCheckButtonData) const int nRow = rCheckLB.n_children() - 1;
{ if (nCol == CBCOL_FIRST || nCol == CBCOL_BOTH)
m_xCheckButtonData.reset(new SvLBoxButtonData(m_pSwCheckLB)); rCheckLB.set_toggle(nRow, false, CBCOL_FIRST);
m_pSwCheckLB->SetCheckButtonData(m_xCheckButtonData.get()); if (nCol == CBCOL_SECOND || nCol == CBCOL_BOTH)
} rCheckLB.set_toggle(nRow, false, CBCOL_SECOND);
rCheckLB.set_text(nRow, rTxt, nTextCol);
pEntry->AddItem(o3tl::make_unique<SvLBoxContextBmp>(Image(), Image(), false));
if (nCol == CBCOL_SECOND)
pEntry->AddItem(o3tl::make_unique<SvLBoxString>(""));
else
pEntry->AddItem(o3tl::make_unique<SvLBoxButton>(SvLBoxButtonKind::EnabledCheckbox, m_xCheckButtonData.get()));
if (nCol == CBCOL_FIRST)
pEntry->AddItem(o3tl::make_unique<SvLBoxString>(""));
else
pEntry->AddItem(o3tl::make_unique<SvLBoxButton>(SvLBoxButtonKind::EnabledCheckbox, m_xCheckButtonData.get()));
pEntry->AddItem(o3tl::make_unique<OfaImpBrwString>(rTxt));
return pEntry;
} }
OfaQuoteTabPage::OfaQuoteTabPage(vcl::Window* pParent, const SfxItemSet& rSet) OfaQuoteTabPage::OfaQuoteTabPage(TabPageParent pParent, const SfxItemSet& rSet)
: SfxTabPage(pParent, "ApplyLocalizedPage", "cui/ui/applylocalizedpage.ui", &rSet) : SfxTabPage(pParent, "cui/ui/applylocalizedpage.ui", "ApplyLocalizedPage", &rSet)
, sNonBrkSpace(CuiResId(RID_SVXSTR_NON_BREAK_SPACE)) , sNonBrkSpace(CuiResId(RID_SVXSTR_NON_BREAK_SPACE))
, sOrdinal(CuiResId(RID_SVXSTR_ORDINAL)) , sOrdinal(CuiResId(RID_SVXSTR_ORDINAL))
, cSglStartQuote(0) , cSglStartQuote(0)
, cSglEndQuote(0) , cSglEndQuote(0)
, cStartQuote(0) , cStartQuote(0)
, cEndQuote(0) , cEndQuote(0)
{ , m_xSingleTypoCB(m_xBuilder->weld_check_button("singlereplace"))
get(m_pCheckLB, "checklist"); , m_xSglStartQuotePB(m_xBuilder->weld_button("startsingle"))
, m_xSglStartExFT(m_xBuilder->weld_label("singlestartex"))
SvSimpleTableContainer *pListContainer = get<SvSimpleTableContainer>("list"); , m_xSglEndQuotePB(m_xBuilder->weld_button("endsingle"))
Size aControlSize(252 , 85); , m_xSglEndExFT(m_xBuilder->weld_label("singleendex"))
aControlSize = LogicToPixel(aControlSize, MapMode(MapUnit::MapAppFont)); , m_xSglStandardPB(m_xBuilder->weld_button("defaultsingle"))
pListContainer->set_width_request(aControlSize.Width()); , m_xDoubleTypoCB(m_xBuilder->weld_check_button("doublereplace"))
pListContainer->set_height_request(aControlSize.Height()); , m_xDblStartQuotePB(m_xBuilder->weld_button("startdouble"))
m_pSwCheckLB = VclPtr<OfaACorrCheckListBox>::Create(*pListContainer); , m_xDblStartExFT(m_xBuilder->weld_label("doublestartex"))
, m_xDblEndQuotePB(m_xBuilder->weld_button("enddouble"))
get(m_pSingleTypoCB, "singlereplace"); , m_xDblEndExFT(m_xBuilder->weld_label("doubleendex"))
get(m_pSglStartQuotePB, "startsingle"); , m_xDblStandardPB(m_xBuilder->weld_button("defaultdouble"))
get(m_pSglStartExFT, "singlestartex"); , m_xStandard(m_xBuilder->weld_label("singlestartex"))
get(m_pSglEndQuotePB, "endsingle"); , m_xCheckLB(m_xBuilder->weld_tree_view("checklist"))
get(m_pSglEndExFT, "singleendex"); , m_xSwCheckLB(m_xBuilder->weld_tree_view("list"))
get(m_pSglStandardPB, "defaultsingle"); {
m_xSwCheckLB->set_size_request(m_xSwCheckLB->get_approximate_digit_width() * 50,
get(m_pDoubleTypoCB, "doublereplace"); m_xSwCheckLB->get_height_rows(6));
get(m_pDblStartQuotePB, "startdouble");
get(m_pDblStartExFT, "doublestartex");
get(m_pDblEndQuotePB, "enddouble");
get(m_pDblEndExFT, "doubleendex");
get(m_pDblStandardPB, "defaultdouble");
m_sStandard = get<FixedText>("singlestartex")->GetText();
bool bShowSWOptions = false; bool bShowSWOptions = false;
...@@ -1760,30 +1682,26 @@ OfaQuoteTabPage::OfaQuoteTabPage(vcl::Window* pParent, const SfxItemSet& rSet) ...@@ -1760,30 +1682,26 @@ OfaQuoteTabPage::OfaQuoteTabPage(vcl::Window* pParent, const SfxItemSet& rSet)
if ( bShowSWOptions ) if ( bShowSWOptions )
{ {
static long const aStaticTabs[]= std::vector<int> aWidths;
{ aWidths.push_back(m_xSwCheckLB->get_pixel_size(m_xSwCheckLB->get_column_title(0)).Width() * 2);
0, 20, 40 aWidths.push_back(m_xSwCheckLB->get_pixel_size(m_xSwCheckLB->get_column_title(1)).Width() * 2);
}; m_xSwCheckLB->set_column_fixed_widths(aWidths);
m_xCheckLB->hide();
m_pSwCheckLB->SetStyle(m_pSwCheckLB->GetStyle() | WB_HSCROLL| WB_VSCROLL);
m_pSwCheckLB->SvSimpleTable::SetTabs(SAL_N_ELEMENTS(aStaticTabs), aStaticTabs);
OUString sHeader = get<vcl::Window>("m")->GetText() + "\t" + get<vcl::Window>("t")->GetText() + "\t";
m_pSwCheckLB->InsertHeaderEntry( sHeader, HEADERBAR_APPEND,
HeaderBarItemBits::CENTER | HeaderBarItemBits::VCENTER | HeaderBarItemBits::FIXEDPOS | HeaderBarItemBits::FIXED);
m_pCheckLB->Hide();
} }
else else
{ {
m_pSwCheckLB->HideTable(); std::vector<int> aWidths;
aWidths.push_back(m_xSwCheckLB->get_approximate_digit_width() * 3 + 6);
m_xCheckLB->set_column_fixed_widths(aWidths);
m_xSwCheckLB->hide();
} }
m_pDblStartQuotePB->SetClickHdl(LINK(this, OfaQuoteTabPage, QuoteHdl)); m_xDblStartQuotePB->connect_clicked(LINK(this, OfaQuoteTabPage, QuoteHdl));
m_pDblEndQuotePB->SetClickHdl(LINK(this, OfaQuoteTabPage, QuoteHdl)); m_xDblEndQuotePB->connect_clicked(LINK(this, OfaQuoteTabPage, QuoteHdl));
m_pSglStartQuotePB->SetClickHdl(LINK(this, OfaQuoteTabPage, QuoteHdl)); m_xSglStartQuotePB->connect_clicked(LINK(this, OfaQuoteTabPage, QuoteHdl));
m_pSglEndQuotePB->SetClickHdl(LINK(this, OfaQuoteTabPage, QuoteHdl)); m_xSglEndQuotePB->connect_clicked(LINK(this, OfaQuoteTabPage, QuoteHdl));
m_pDblStandardPB->SetClickHdl(LINK(this, OfaQuoteTabPage, StdQuoteHdl)); m_xDblStandardPB->connect_clicked(LINK(this, OfaQuoteTabPage, StdQuoteHdl));
m_pSglStandardPB->SetClickHdl(LINK(this, OfaQuoteTabPage, StdQuoteHdl)); m_xSglStandardPB->connect_clicked(LINK(this, OfaQuoteTabPage, StdQuoteHdl));
} }
OfaQuoteTabPage::~OfaQuoteTabPage() OfaQuoteTabPage::~OfaQuoteTabPage()
...@@ -1791,30 +1709,10 @@ OfaQuoteTabPage::~OfaQuoteTabPage() ...@@ -1791,30 +1709,10 @@ OfaQuoteTabPage::~OfaQuoteTabPage()
disposeOnce(); disposeOnce();
} }
void OfaQuoteTabPage::dispose() VclPtr<SfxTabPage> OfaQuoteTabPage::Create(TabPageParent pParent,
{ const SfxItemSet* rAttrSet)
m_xCheckButtonData.reset();
m_pSwCheckLB.disposeAndClear();
m_pCheckLB.disposeAndClear();
m_pSingleTypoCB.clear();
m_pSglStartQuotePB.clear();
m_pSglStartExFT.clear();
m_pSglEndQuotePB.clear();
m_pSglEndExFT.clear();
m_pSglStandardPB.clear();
m_pDoubleTypoCB.clear();
m_pDblStartQuotePB.clear();
m_pDblStartExFT.clear();
m_pDblEndQuotePB.clear();
m_pDblEndExFT.clear();
m_pDblStandardPB.clear();
SfxTabPage::dispose();
}
VclPtr<SfxTabPage> OfaQuoteTabPage::Create( TabPageParent pParent,
const SfxItemSet* rAttrSet)
{ {
return VclPtr<OfaQuoteTabPage>::Create(pParent.pParent, *rAttrSet); return VclPtr<OfaQuoteTabPage>::Create(pParent, *rAttrSet);
} }
bool OfaQuoteTabPage::FillItemSet( SfxItemSet* ) bool OfaQuoteTabPage::FillItemSet( SfxItemSet* )
...@@ -1823,33 +1721,33 @@ bool OfaQuoteTabPage::FillItemSet( SfxItemSet* ) ...@@ -1823,33 +1721,33 @@ bool OfaQuoteTabPage::FillItemSet( SfxItemSet* )
ACFlags nFlags = pAutoCorrect->GetFlags(); ACFlags nFlags = pAutoCorrect->GetFlags();
if (m_pCheckLB->IsVisible()) if (m_xCheckLB->get_visible())
{ {
sal_uLong nPos = 0; int nPos = 0;
pAutoCorrect->SetAutoCorrFlag(ACFlags::AddNonBrkSpace, m_pCheckLB->IsChecked(nPos++)); pAutoCorrect->SetAutoCorrFlag(ACFlags::AddNonBrkSpace, m_xCheckLB->get_toggle(nPos++));
pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgOrdinalNumber, m_pCheckLB->IsChecked(nPos++)); pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgOrdinalNumber, m_xCheckLB->get_toggle(nPos++));
} }
bool bModified = false; bool bModified = false;
if (m_pSwCheckLB->IsVisible()) if (m_xSwCheckLB->get_visible())
{ {
SvxSwAutoFormatFlags *pOpt = &pAutoCorrect->GetSwFlags(); SvxSwAutoFormatFlags *pOpt = &pAutoCorrect->GetSwFlags();
bool bCheck = m_pSwCheckLB->IsChecked(ADD_NONBRK_SPACE); bool bCheck = m_xSwCheckLB->get_toggle(ADD_NONBRK_SPACE);
bModified |= pOpt->bAddNonBrkSpace != bCheck; bModified |= pOpt->bAddNonBrkSpace != bCheck;
pOpt->bAddNonBrkSpace = bCheck; pOpt->bAddNonBrkSpace = bCheck;
pAutoCorrect->SetAutoCorrFlag(ACFlags::AddNonBrkSpace, pAutoCorrect->SetAutoCorrFlag(ACFlags::AddNonBrkSpace,
m_pSwCheckLB->IsChecked(ADD_NONBRK_SPACE, CBCOL_SECOND)); m_xSwCheckLB->get_toggle(ADD_NONBRK_SPACE, CBCOL_SECOND));
bCheck = m_pSwCheckLB->IsChecked(REPLACE_1ST); bCheck = m_xSwCheckLB->get_toggle(REPLACE_1ST);
bModified |= pOpt->bChgOrdinalNumber != bCheck; bModified |= pOpt->bChgOrdinalNumber != bCheck;
pOpt->bChgOrdinalNumber = bCheck; pOpt->bChgOrdinalNumber = bCheck;
pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgOrdinalNumber, pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgOrdinalNumber,
m_pSwCheckLB->IsChecked(REPLACE_1ST, CBCOL_SECOND)); m_xSwCheckLB->get_toggle(REPLACE_1ST, CBCOL_SECOND));
} }
pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgQuotes, m_pDoubleTypoCB->IsChecked()); pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgQuotes, m_xDoubleTypoCB->get_active());
pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgSglQuotes, m_pSingleTypoCB->IsChecked()); pAutoCorrect->SetAutoCorrFlag(ACFlags::ChgSglQuotes, m_xSingleTypoCB->get_active());
bool bReturn = nFlags != pAutoCorrect->GetFlags(); bool bReturn = nFlags != pAutoCorrect->GetFlags();
if(cStartQuote != pAutoCorrect->GetStartDoubleQuote()) if(cStartQuote != pAutoCorrect->GetStartDoubleQuote())
{ {
...@@ -1896,55 +1794,55 @@ void OfaQuoteTabPage::Reset( const SfxItemSet* ) ...@@ -1896,55 +1794,55 @@ void OfaQuoteTabPage::Reset( const SfxItemSet* )
const ACFlags nFlags = pAutoCorrect->GetFlags(); const ACFlags nFlags = pAutoCorrect->GetFlags();
// Initialize the Sw options // Initialize the Sw options
if (m_pSwCheckLB->IsVisible()) if (m_xSwCheckLB->get_visible())
{ {
SvxSwAutoFormatFlags *pOpt = &pAutoCorrect->GetSwFlags(); SvxSwAutoFormatFlags *pOpt = &pAutoCorrect->GetSwFlags();
m_pSwCheckLB->SetUpdateMode( false ); m_xSwCheckLB->freeze();
m_pSwCheckLB->Clear(); m_xSwCheckLB->clear();
m_pSwCheckLB->GetModel()->Insert(CreateEntry(sNonBrkSpace, CBCOL_BOTH )); CreateEntry(*m_xSwCheckLB, sNonBrkSpace, CBCOL_BOTH, 2);
m_pSwCheckLB->GetModel()->Insert(CreateEntry(sOrdinal, CBCOL_BOTH )); CreateEntry(*m_xSwCheckLB, sOrdinal, CBCOL_BOTH, 2);
m_pSwCheckLB->CheckEntryPos( ADD_NONBRK_SPACE, CBCOL_FIRST, pOpt->bAddNonBrkSpace ); m_xSwCheckLB->set_toggle(ADD_NONBRK_SPACE, pOpt->bAddNonBrkSpace, CBCOL_FIRST);
m_pSwCheckLB->CheckEntryPos( ADD_NONBRK_SPACE, CBCOL_SECOND, bool(nFlags & ACFlags::AddNonBrkSpace) ); m_xSwCheckLB->set_toggle(ADD_NONBRK_SPACE, bool(nFlags & ACFlags::AddNonBrkSpace), CBCOL_SECOND);
m_pSwCheckLB->CheckEntryPos( REPLACE_1ST, CBCOL_FIRST, pOpt->bChgOrdinalNumber ); m_xSwCheckLB->set_toggle(REPLACE_1ST, pOpt->bChgOrdinalNumber, CBCOL_FIRST);
m_pSwCheckLB->CheckEntryPos( REPLACE_1ST, CBCOL_SECOND, bool(nFlags & ACFlags::ChgOrdinalNumber) ); m_xSwCheckLB->set_toggle(REPLACE_1ST, bool(nFlags & ACFlags::ChgOrdinalNumber), CBCOL_SECOND);
m_pSwCheckLB->SetUpdateMode( true ); m_xSwCheckLB->thaw();
} }
// Initialize the non Sw options // Initialize the non Sw options
if (m_pCheckLB->IsVisible()) if (m_xCheckLB->get_visible())
{ {
m_pCheckLB->SetUpdateMode(false); m_xCheckLB->freeze();
m_pCheckLB->Clear(); m_xCheckLB->clear();
m_pCheckLB->InsertEntry( sNonBrkSpace ); CreateEntry(*m_xCheckLB, sNonBrkSpace, CBCOL_FIRST, 1);
m_pCheckLB->InsertEntry( sOrdinal ); CreateEntry(*m_xCheckLB, sOrdinal, CBCOL_FIRST, 1);
sal_uLong nPos = 0; int nPos = 0;
m_pCheckLB->CheckEntryPos( nPos++, bool(nFlags & ACFlags::AddNonBrkSpace) ); m_xCheckLB->set_toggle(nPos++, bool(nFlags & ACFlags::AddNonBrkSpace));
m_pCheckLB->CheckEntryPos( nPos++, bool(nFlags & ACFlags::ChgOrdinalNumber) ); m_xCheckLB->set_toggle(nPos++, bool(nFlags & ACFlags::ChgOrdinalNumber));
m_pCheckLB->SetUpdateMode(true); m_xCheckLB->thaw();
} }
// Initialize the quote stuffs // Initialize the quote stuffs
m_pDoubleTypoCB->Check(bool(nFlags & ACFlags::ChgQuotes)); m_xDoubleTypoCB->set_active(bool(nFlags & ACFlags::ChgQuotes));
m_pSingleTypoCB->Check(bool(nFlags & ACFlags::ChgSglQuotes)); m_xSingleTypoCB->set_active(bool(nFlags & ACFlags::ChgSglQuotes));
m_pDoubleTypoCB->SaveValue(); m_xDoubleTypoCB->save_state();
m_pSingleTypoCB->SaveValue(); m_xSingleTypoCB->save_state();
cStartQuote = pAutoCorrect->GetStartDoubleQuote(); cStartQuote = pAutoCorrect->GetStartDoubleQuote();
cEndQuote = pAutoCorrect->GetEndDoubleQuote(); cEndQuote = pAutoCorrect->GetEndDoubleQuote();
cSglStartQuote = pAutoCorrect->GetStartSingleQuote(); cSglStartQuote = pAutoCorrect->GetStartSingleQuote();
cSglEndQuote = pAutoCorrect->GetEndSingleQuote(); cSglEndQuote = pAutoCorrect->GetEndSingleQuote();
m_pSglStartExFT->SetText(ChangeStringExt_Impl(cSglStartQuote)); m_xSglStartExFT->set_label(ChangeStringExt_Impl(cSglStartQuote));
m_pSglEndExFT->SetText(ChangeStringExt_Impl(cSglEndQuote)); m_xSglEndExFT->set_label(ChangeStringExt_Impl(cSglEndQuote));
m_pDblStartExFT->SetText(ChangeStringExt_Impl(cStartQuote)); m_xDblStartExFT->set_label(ChangeStringExt_Impl(cStartQuote));
m_pDblEndExFT->SetText(ChangeStringExt_Impl(cEndQuote)); m_xDblEndExFT->set_label(ChangeStringExt_Impl(cEndQuote));
} }
#define SGL_START 0 #define SGL_START 0
...@@ -1953,14 +1851,14 @@ void OfaQuoteTabPage::Reset( const SfxItemSet* ) ...@@ -1953,14 +1851,14 @@ void OfaQuoteTabPage::Reset( const SfxItemSet* )
#define DBL_END 3 #define DBL_END 3
IMPL_LINK( OfaQuoteTabPage, QuoteHdl, Button*, pBtn, void ) IMPL_LINK(OfaQuoteTabPage, QuoteHdl, weld::Button&, rBtn, void)
{ {
sal_uInt16 nMode = SGL_START; sal_uInt16 nMode = SGL_START;
if (pBtn == m_pSglEndQuotePB) if (&rBtn == m_xSglEndQuotePB.get())
nMode = SGL_END; nMode = SGL_END;
else if (pBtn == m_pDblStartQuotePB) else if (&rBtn == m_xDblStartQuotePB.get())
nMode = DBL_START; nMode = DBL_START;
else if (pBtn == m_pDblEndQuotePB) else if (&rBtn == m_xDblEndQuotePB.get())
nMode = DBL_END; nMode = DBL_END;
// start character selection dialog // start character selection dialog
SvxCharacterMap aMap(GetDialogFrameWeld(), nullptr, false); SvxCharacterMap aMap(GetDialogFrameWeld(), nullptr, false);
...@@ -2007,48 +1905,47 @@ IMPL_LINK( OfaQuoteTabPage, QuoteHdl, Button*, pBtn, void ) ...@@ -2007,48 +1905,47 @@ IMPL_LINK( OfaQuoteTabPage, QuoteHdl, Button*, pBtn, void )
{ {
case SGL_START: case SGL_START:
cSglStartQuote = cNewChar; cSglStartQuote = cNewChar;
m_pSglStartExFT->SetText(ChangeStringExt_Impl(cNewChar)); m_xSglStartExFT->set_label(ChangeStringExt_Impl(cNewChar));
break; break;
case SGL_END: case SGL_END:
cSglEndQuote = cNewChar; cSglEndQuote = cNewChar;
m_pSglEndExFT->SetText(ChangeStringExt_Impl(cNewChar)); m_xSglEndExFT->set_label(ChangeStringExt_Impl(cNewChar));
break; break;
case DBL_START: case DBL_START:
cStartQuote = cNewChar; cStartQuote = cNewChar;
m_pDblStartExFT->SetText(ChangeStringExt_Impl(cNewChar)); m_xDblStartExFT->set_label(ChangeStringExt_Impl(cNewChar));
break; break;
case DBL_END: case DBL_END:
cEndQuote = cNewChar; cEndQuote = cNewChar;
m_pDblEndExFT->SetText(ChangeStringExt_Impl(cNewChar)); m_xDblEndExFT->set_label(ChangeStringExt_Impl(cNewChar));
break; break;
} }
} }
} }
IMPL_LINK( OfaQuoteTabPage, StdQuoteHdl, Button*, pBtn, void ) IMPL_LINK(OfaQuoteTabPage, StdQuoteHdl, weld::Button&, rBtn, void)
{ {
if (pBtn == m_pDblStandardPB) if (&rBtn == m_xDblStandardPB.get())
{ {
cStartQuote = 0; cStartQuote = 0;
m_pDblStartExFT->SetText(ChangeStringExt_Impl(0)); m_xDblStartExFT->set_label(ChangeStringExt_Impl(0));
cEndQuote = 0; cEndQuote = 0;
m_pDblEndExFT->SetText(ChangeStringExt_Impl(0)); m_xDblEndExFT->set_label(ChangeStringExt_Impl(0));
} }
else else
{ {
cSglStartQuote = 0; cSglStartQuote = 0;
m_pSglStartExFT->SetText(ChangeStringExt_Impl(0)); m_xSglStartExFT->set_label(ChangeStringExt_Impl(0));
cSglEndQuote = 0; cSglEndQuote = 0;
m_pSglEndExFT->SetText(ChangeStringExt_Impl(0)); m_xSglEndExFT->set_label(ChangeStringExt_Impl(0));
} }
} }
OUString OfaQuoteTabPage::ChangeStringExt_Impl( sal_UCS4 cChar ) OUString OfaQuoteTabPage::ChangeStringExt_Impl( sal_UCS4 cChar )
{ {
if (!cChar) if (!cChar)
return m_sStandard; return m_xStandard->get_label();
// convert codepoint value to unicode-hex string // convert codepoint value to unicode-hex string
sal_UCS4 aStrCodes[32] = { 0, ' ', '(', 'U', '+', '0' }; sal_UCS4 aStrCodes[32] = { 0, ' ', '(', 'U', '+', '0' };
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- Generated with glade 3.22.1 -->
<interface domain="cui"> <interface domain="cui">
<requires lib="gtk+" version="3.18"/> <requires lib="gtk+" version="3.18"/>
<requires lib="LibreOffice" version="1.0"/> <object class="GtkTreeStore" id="liststore1">
<columns>
<!-- column-name check1 -->
<column type="gboolean"/>
<!-- column-name check2 -->
<column type="gboolean"/>
<!-- column-name text -->
<column type="gchararray"/>
<!-- column-name id -->
<column type="gchararray"/>
</columns>
</object>
<object class="GtkTreeStore" id="liststore2">
<columns>
<!-- column-name check1 -->
<column type="gboolean"/>
<!-- column-name text -->
<column type="gchararray"/>
<!-- column-name id -->
<column type="gchararray"/>
</columns>
</object>
<object class="GtkBox" id="ApplyLocalizedPage"> <object class="GtkBox" id="ApplyLocalizedPage">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
...@@ -24,71 +46,133 @@ ...@@ -24,71 +46,133 @@
<property name="vexpand">True</property> <property name="vexpand">True</property>
<property name="column_homogeneous">True</property> <property name="column_homogeneous">True</property>
<child> <child>
<object class="GtkLabel" id="m"> <object class="GtkScrolledWindow">
<property name="can_focus">False</property>
<property name="no_show_all">True</property>
<property name="label" translatable="yes" context="applylocalizedpage|m">[M]</property>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="t">
<property name="can_focus">False</property>
<property name="no_show_all">True</property>
<property name="label" translatable="yes" context="applylocalizedpage|t">[T]</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="svtlo-SvSimpleTableContainer" id="list:border">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">True</property>
<property name="hexpand">True</property> <property name="hexpand">True</property>
<property name="vexpand">True</property> <property name="vexpand">True</property>
<child internal-child="selection"> <property name="shadow_type">in</property>
<object class="GtkTreeSelection" id="Simple Table Container-selection1"/> <child>
<object class="GtkTreeView" id="list">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="model">liststore1</property>
<property name="search_column">0</property>
<property name="show_expanders">False</property>
<child internal-child="selection">
<object class="GtkTreeSelection" id="Macro Library List-selection1"/>
</child>
<child>
<object class="GtkTreeViewColumn" id="treeviewcolumn1">
<property name="resizable">True</property>
<property name="spacing">6</property>
<property name="title" translatable="yes" context="applylocalizedpage|m">[M]</property>
<property name="alignment">0.5</property>
<child>
<object class="GtkCellRendererToggle" id="cellrenderer1"/>
<attributes>
<attribute name="active">0</attribute>
</attributes>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn" id="treeviewcolumn2">
<property name="resizable">True</property>
<property name="spacing">6</property>
<property name="title" translatable="yes" context="applylocalizedpage|t">[T]</property>
<property name="alignment">0.5</property>
<child>
<object class="GtkCellRendererToggle" id="cellrenderer2"/>
<attributes>
<attribute name="active">1</attribute>
</attributes>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn" id="treeviewcolumn3">
<property name="resizable">True</property>
<property name="spacing">6</property>
<child>
<object class="GtkCellRendererText" id="cellrenderer3"/>
<attributes>
<attribute name="text">0</attribute>
</attributes>
</child>
</object>
</child>
</object>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">1</property> <property name="top_attach">0</property>
<property name="width">2</property> <property name="width">2</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="svxcorelo-SvxCheckListBox" id="checklist:border"> <object class="GtkScrolledWindow">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">True</property> <property name="can_focus">True</property>
<property name="hexpand">True</property> <property name="hexpand">True</property>
<property name="vexpand">True</property> <property name="vexpand">True</property>
<child internal-child="selection"> <property name="shadow_type">in</property>
<object class="GtkTreeSelection" id="Check List Box-selection1"/> <child>
<object class="GtkTreeView" id="checklist">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="model">liststore2</property>
<property name="headers_visible">False</property>
<property name="search_column">0</property>
<property name="show_expanders">False</property>
<child internal-child="selection">
<object class="GtkTreeSelection" id="Macro Library List-selection2"/>
</child>
<child>
<object class="GtkTreeViewColumn" id="treeviewcolumn4">
<property name="resizable">True</property>
<property name="spacing">6</property>
<property name="alignment">0.5</property>
<child>
<object class="GtkCellRendererToggle" id="cellrenderer5"/>
<attributes>
<attribute name="active">0</attribute>
</attributes>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn" id="treeviewcolumn5">
<property name="resizable">True</property>
<property name="spacing">6</property>
<child>
<object class="GtkCellRendererText" id="cellrenderer4"/>
<attributes>
<attribute name="text">0</attribute>
</attributes>
</child>
</object>
</child>
</object>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">2</property> <property name="top_attach">1</property>
<property name="width">2</property> <property name="width">2</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -126,24 +210,20 @@ ...@@ -126,24 +210,20 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="startquoteft"> <object class="GtkLabel" id="startquoteft">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|startquoteft">_Start quote:</property> <property name="label" translatable="yes" context="applylocalizedpage|startquoteft">_Start quote:</property>
<property name="use_underline">True</property> <property name="use_underline">True</property>
<property name="mnemonic_widget">startsingle</property> <property name="mnemonic_widget">startsingle</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -166,30 +246,24 @@ ...@@ -166,30 +246,24 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="singlestartex"> <object class="GtkLabel" id="singlestartex">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|singlestartex">Default</property> <property name="label" translatable="yes" context="applylocalizedpage|singlestartex">Default</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">1</property> <property name="left_attach">1</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">2</property> <property name="top_attach">2</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -209,24 +283,20 @@ ...@@ -209,24 +283,20 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">5</property> <property name="top_attach">5</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="endquoteft"> <object class="GtkLabel" id="endquoteft">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|endquoteft">_End quote:</property> <property name="label" translatable="yes" context="applylocalizedpage|endquoteft">_End quote:</property>
<property name="use_underline">True</property> <property name="use_underline">True</property>
<property name="mnemonic_widget">endsingle</property> <property name="mnemonic_widget">endsingle</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">3</property> <property name="top_attach">3</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -249,30 +319,24 @@ ...@@ -249,30 +319,24 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="singleendex"> <object class="GtkLabel" id="singleendex">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|singleendex">Default</property> <property name="label" translatable="yes" context="applylocalizedpage|singleendex">Default</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">1</property> <property name="left_attach">1</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">4</property> <property name="top_attach">4</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
...@@ -293,8 +357,6 @@ ...@@ -293,8 +357,6 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -326,24 +388,20 @@ ...@@ -326,24 +388,20 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="label6"> <object class="GtkLabel" id="label6">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|label6">_Start quote:</property> <property name="label" translatable="yes" context="applylocalizedpage|label6">_Start quote:</property>
<property name="use_underline">True</property> <property name="use_underline">True</property>
<property name="mnemonic_widget">startdouble</property> <property name="mnemonic_widget">startdouble</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -366,30 +424,24 @@ ...@@ -366,30 +424,24 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="doublestartex"> <object class="GtkLabel" id="doublestartex">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|doublestartex">Default</property> <property name="label" translatable="yes" context="applylocalizedpage|doublestartex">Default</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">1</property> <property name="left_attach">1</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">2</property> <property name="top_attach">2</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -409,24 +461,20 @@ ...@@ -409,24 +461,20 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">5</property> <property name="top_attach">5</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="label8"> <object class="GtkLabel" id="label8">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|label8">_End quote:</property> <property name="label" translatable="yes" context="applylocalizedpage|label8">_End quote:</property>
<property name="use_underline">True</property> <property name="use_underline">True</property>
<property name="mnemonic_widget">enddouble</property> <property name="mnemonic_widget">enddouble</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">3</property> <property name="top_attach">3</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
...@@ -449,30 +497,24 @@ ...@@ -449,30 +497,24 @@
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
<child> <child>
<object class="GtkLabel" id="doubleendex"> <object class="GtkLabel" id="doubleendex">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes" context="applylocalizedpage|doubleendex">Default</property> <property name="label" translatable="yes" context="applylocalizedpage|doubleendex">Default</property>
<property name="xalign">0</property>
</object> </object>
<packing> <packing>
<property name="left_attach">1</property> <property name="left_attach">1</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">4</property> <property name="top_attach">4</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
...@@ -493,16 +535,12 @@ ...@@ -493,16 +535,12 @@
<packing> <packing>
<property name="left_attach">1</property> <property name="left_attach">1</property>
<property name="top_attach">0</property> <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
<packing> <packing>
<property name="left_attach">0</property> <property name="left_attach">0</property>
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing> </packing>
</child> </child>
</object> </object>
......
...@@ -1877,6 +1877,26 @@ public: ...@@ -1877,6 +1877,26 @@ public:
return OUString(); return OUString();
} }
virtual void show() override
{
SvHeaderTabListBox* pHeaderBox = dynamic_cast<SvHeaderTabListBox*>(m_xTreeView.get());
if (HeaderBar* pHeaderBar = pHeaderBox ? pHeaderBox->GetHeaderBar() : nullptr)
{
pHeaderBar->Show();
}
SalInstanceContainer::show();
}
virtual void hide() override
{
SvHeaderTabListBox* pHeaderBox = dynamic_cast<SvHeaderTabListBox*>(m_xTreeView.get());
if (HeaderBar* pHeaderBar = pHeaderBox ? pHeaderBox->GetHeaderBar() : nullptr)
{
pHeaderBar->Hide();
}
SalInstanceContainer::hide();
}
virtual void insert(weld::TreeIter* pParent, int pos, const OUString* pStr, const OUString* pId, virtual void insert(weld::TreeIter* pParent, int pos, const OUString* pStr, const OUString* pId,
const OUString* pIconName, VirtualDevice* pImageSurface, const OUString* pExpanderName, const OUString* pIconName, VirtualDevice* pImageSurface, const OUString* pExpanderName,
bool bChildrenOnDemand) override bool bChildrenOnDemand) override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment