39 :
SfxTabPage(pPage, pController,
"modules/swriter/ui/conditionpage.ui",
"ConditionPage", &rSet)
43 , m_xTbLinks(m_xBuilder->weld_tree_view(
"links"))
44 , m_xStyleLB(m_xBuilder->weld_tree_view(
"styles"))
45 , m_xFilterLB(m_xBuilder->weld_combo_box(
"filter"))
46 , m_xRemovePB(m_xBuilder->weld_button(
"remove"))
47 , m_xAssignPB(m_xBuilder->weld_button(
"apply"))
50 const auto nHeightRequest =
m_xStyleLB->get_height_rows(12);
51 m_xStyleLB->set_size_request(-1, nHeightRequest);
52 m_xTbLinks->set_size_request(-1, nHeightRequest);
53 std::vector<int> aWidths
55 o3tl::narrowing<int>(
m_xTbLinks->get_approximate_digit_width() * 40)
59 const sal_Int32 nStrCount =
m_xFilterLB->get_count();
60 for (sal_Int32
i = 0;
i < nStrCount; ++
i)
75 std::optional<SfxStyleFamilies> xFamilies(
SW_MOD()->CreateStyleFamilies());
76 size_t nCount = xFamilies->size();
77 for (
size_t j = 0; j < nCount; ++j)
80 if (SfxStyleFamily::Para == rFamilyItem.
GetFamily())
83 for (
size_t i = 0;
i < rFilterList.size(); ++
i)
84 m_xFilterLB->append(OUString::number(
int(rFilterList[
i].nFlags)), rFilterList[i].aName);
102 return DeactivateRC::LeavePage;
107 return std::make_unique<SwCondCollPage>(pPage, pController, *rSet);
115 const OUString sEntry =
m_xTbLinks->get_text(
i, 1);
118 rSet->
Put(aCondItem);
133 pBase = pPool->
Next();
201 const sal_Int32 nSelPos =
m_xFilterLB->get_active();
214 pBase = pPool->
Next();
221 int nSelected =
m_xTbLinks->get_selected_index();
222 const OUString sTbEntry = nSelected != -1
225 const OUString sStyle =
m_xStyleLB->get_selected_text();
#define LINK(Instance, Class, Member)
virtual DeactivateRC DeactivatePage(SfxItemSet *pSet) override
static std::unique_ptr< SfxTabPage > Create(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet *rSet)
SfxStyleSheetBase * First(SfxStyleFamily eFamily, SfxStyleSearchBits eMask=SfxStyleSearchBits::All)
virtual ~SwCondCollPage() override
SwCondCollPage(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet &rSet)
constexpr TypedWhichId< SwConditionTextFormatColl > RES_CONDTXTFMTCOLL(160)
virtual bool FillItemSet(SfxItemSet *rSet) override
SwTextFormatColl * GetTextFormatColl() const
const SfxStyleFilter & GetFilterList() const
const SwView & GetView() const
std::unique_ptr< weld::TreeView > m_xTbLinks
const OUString & GetName() const
void SetExchangeSupport()
void AssignRemove(const weld::Widget *)
IMPL_LINK(SwCondCollPage, AssignRemoveClickHdl, weld::Button &, rBtn, void)
const CommandStruct * m_pCmds
void SelectHdl(const weld::Widget *)
virtual void Reset(const SfxItemSet *rSet) override
virtual SfxStyleSheetBasePool * GetStyleSheetPool() override
For Style PI.
std::unique_ptr< weld::ComboBox > m_xFilterLB
void SetCollection(SwFormat *pFormat)
std::unique_ptr< weld::Button > m_xAssignPB
SwDocShell * GetDocShell()
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
std::vector< SfxFilterTuple > SfxStyleFilter
SfxStyleFamily GetFamily() const
SfxStyleSheetBase * Next()
std::unique_ptr< weld::TreeView > m_xStyleLB
std::unique_ptr< weld::Button > m_xRemovePB
void SetStyle(const OUString *pStyle, sal_uInt16 nPos)
static const WhichRangesContainer m_aPageRg
std::vector< OUString > m_aStrArr