SvxBorderBackgroundDlg::SvxBorderBackgroundDlg(weld::Window *pParent, const SfxItemSet& rCoreSet, bool bEnableSelector, bool bEnableDrawingLayerFillStyles)
: SfxTabDialogController(pParent,
bEnableDrawingLayerFillStyles
? u"cui/ui/borderareatransparencydialog.ui"_ustr
: u"cui/ui/borderbackgrounddialog.ui"_ustr,
bEnableDrawingLayerFillStyles
? u"BorderAreaTransparencyDialog"_ustr
: u"BorderBackgroundDialog"_ustr,
&rCoreSet)
, mbEnableBackgroundSelector(bEnableSelector)
{
AddTabPage(u"borders"_ustr, SvxBorderTabPage::Create, nullptr ); if (bEnableDrawingLayerFillStyles)
{ // Here we want full DrawingLayer FillStyle access, so add Area and Transparency TabPages
AddTabPage(u"area"_ustr, SvxAreaTabPage::Create, nullptr);
AddTabPage(u"transparence"_ustr, SvxTransparenceTabPage::Create, nullptr);
} else
{
AddTabPage(u"background"_ustr, SvxBkgTabPage::Create, nullptr );
}
}
void SvxBorderBackgroundDlg::PageCreated(const OUString& rPageId, SfxTabPage& rTabPage)
{ if (rPageId == "background")
{
SfxAllItemSet aSet(*(GetInputSetImpl()->GetPool())); // allow switching between Color/graphic if (mbEnableBackgroundSelector)
aSet.Put(SfxUInt32Item(SID_FLAG_TYPE, static_cast<sal_uInt32>(SvxBackgroundTabFlags::SHOW_SELECTOR)));
rTabPage.PageCreated(aSet);
} // inits for Area and Transparency TabPages // The selection attribute lists (XPropertyList derivates, e.g. XColorList for // the color table) need to be added as items (e.g. SvxColorTableItem) to make // these pages find the needed attributes for fill style suggestions. // These are added in SwDocStyleSheet::GetItemSet() for the SfxStyleFamily::Para on // demand, but could also be directly added from the DrawModel. elseif (rPageId == "area")
{
SfxItemSetFixed<SID_COLOR_TABLE, SID_PATTERN_LIST,
SID_OFFER_IMPORT, SID_OFFER_IMPORT>
aNew(*GetInputSetImpl()->GetPool());
aNew.Put(*GetInputSetImpl());
// add flag for direct graphic content selection
aNew.Put(SfxBoolItem(SID_OFFER_IMPORT, true));
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.