summaryrefslogtreecommitdiff
path: root/svx/source/sdr/properties/textproperties.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'svx/source/sdr/properties/textproperties.cxx')
-rw-r--r--svx/source/sdr/properties/textproperties.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/svx/source/sdr/properties/textproperties.cxx b/svx/source/sdr/properties/textproperties.cxx
index d361080e2062..c21111892923 100644
--- a/svx/source/sdr/properties/textproperties.cxx
+++ b/svx/source/sdr/properties/textproperties.cxx
@@ -81,6 +81,14 @@ namespace sdr::properties
return std::unique_ptr<BaseProperties>(new TextProperties(*this, rObj));
}
+ bool TextProperties::WantItemSetInItemSetChanged() const
+ {
+ // The itemset construction is fairly expensive, and we only need it
+ // if this text (or sub-type of text, eg. rectangle) actually has text.
+ const svx::ITextProvider& rTextProvider(getTextProvider());
+ return rTextProvider.getTextCount() != 0;
+ }
+
void TextProperties::ItemSetChanged(const SfxItemSet* pSet)
{
SdrTextObj& rObj = static_cast<SdrTextObj&>(GetSdrObject());
@@ -145,7 +153,7 @@ namespace sdr::properties
}
// Extra-Repaint for radical layout changes (#43139#)
- if(SfxItemState::SET == pSet->GetItemState(SDRATTR_TEXT_CONTOURFRAME))
+ if(pSet && SfxItemState::SET == pSet->GetItemState(SDRATTR_TEXT_CONTOURFRAME))
{
// Here only repaint wanted
rObj.ActionChanged();