summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-05-09 12:17:08 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-05-10 08:42:37 +0200
commit5c9ae702b42745bf6963d1cbb4e779b66ade0825 (patch)
tree323545cbc5386b483067030b66cf5ca07bc25e45 /include
parentc5f8a296fcfc08f8ac441cb8300a7565caa50b53 (diff)
store Color using boost::optional in EditCharAttribField
Change-Id: If4af5991be51cdb035c0bc0fb7668844df703073 Reviewed-on: https://gerrit.libreoffice.org/54022 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include')
-rw-r--r--include/editeng/editeng.hxx3
-rw-r--r--include/editeng/outliner.hxx2
-rw-r--r--include/editeng/unoedprx.hxx2
-rw-r--r--include/editeng/unoedsrc.hxx2
-rw-r--r--include/editeng/unofored.hxx2
-rw-r--r--include/editeng/unoforou.hxx2
-rw-r--r--include/editeng/unotext.hxx2
-rw-r--r--include/svx/ClassificationEditView.hxx2
-rw-r--r--include/svx/svdomeas.hxx2
-rw-r--r--include/svx/svdotext.hxx2
-rw-r--r--include/svx/svdoutl.hxx2
11 files changed, 12 insertions, 11 deletions
diff --git a/include/editeng/editeng.hxx b/include/editeng/editeng.hxx
index 393e0068cb64..52a052570dd0 100644
--- a/include/editeng/editeng.hxx
+++ b/include/editeng/editeng.hxx
@@ -41,6 +41,7 @@
#include <o3tl/typed_flags_set.hxx>
#include <svl/languageoptions.hxx>
#include <vcl/errcode.hxx>
+#include <boost/optional.hpp>
#include <functional>
namespace com { namespace sun { namespace star {
@@ -508,7 +509,7 @@ public:
virtual OUString GetUndoComment( sal_uInt16 nUndoId ) const;
virtual bool SpellNextDocument();
virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos );
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rTxtColor, Color*& rFldColor );
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rTxtColor, boost::optional<Color>& rFldColor );
// override this if access to bullet information needs to be provided
virtual const SvxNumberFormat * GetNumberFormat( sal_Int32 nPara ) const;
diff --git a/include/editeng/outliner.hxx b/include/editeng/outliner.hxx
index a5f0d4b1b1e3..31ba68c2c5f9 100644
--- a/include/editeng/outliner.hxx
+++ b/include/editeng/outliner.hxx
@@ -900,7 +900,7 @@ public:
bool UpdateFields();
void RemoveFields( const std::function<bool ( const SvxFieldData* )>& isFieldData = [] (const SvxFieldData* ){return true;} );
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rTxtColor, Color*& rFldColor );
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rTxtColor, boost::optional<Color>& rFldColor );
void SetSpeller( css::uno::Reference< css::linguistic2::XSpellChecker1 > const &xSpeller );
css::uno::Reference< css::linguistic2::XSpellChecker1 > const &
diff --git a/include/editeng/unoedprx.hxx b/include/editeng/unoedprx.hxx
index f4f9cd66c0a5..dd296af6375f 100644
--- a/include/editeng/unoedprx.hxx
+++ b/include/editeng/unoedprx.hxx
@@ -54,7 +54,7 @@ public:
virtual SfxItemPool* GetPool() const override;
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor ) override;
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor ) override;
virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos ) override;
virtual bool IsValid() const override;
diff --git a/include/editeng/unoedsrc.hxx b/include/editeng/unoedsrc.hxx
index 026f887f0c41..c4077bccc758 100644
--- a/include/editeng/unoedsrc.hxx
+++ b/include/editeng/unoedsrc.hxx
@@ -155,7 +155,7 @@ public:
virtual void QuickSetAttribs( const SfxItemSet& rSet, const ESelection& rSel ) = 0;
virtual void QuickInsertLineBreak( const ESelection& rSel ) = 0;
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor ) = 0;
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor ) = 0;
virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos ) = 0;
virtual SfxItemPool* GetPool() const = 0;
diff --git a/include/editeng/unofored.hxx b/include/editeng/unofored.hxx
index c450598f1c1c..58ae00896756 100644
--- a/include/editeng/unofored.hxx
+++ b/include/editeng/unofored.hxx
@@ -54,7 +54,7 @@ public:
virtual SfxItemPool* GetPool() const override;
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor ) override;
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor ) override;
virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos ) override;
virtual bool IsValid() const override;
diff --git a/include/editeng/unoforou.hxx b/include/editeng/unoforou.hxx
index a26fc406c220..b04fdcdb59f5 100644
--- a/include/editeng/unoforou.hxx
+++ b/include/editeng/unoforou.hxx
@@ -72,7 +72,7 @@ public:
virtual SfxItemPool* GetPool() const override;
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor ) override;
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor ) override;
virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos ) override;
virtual bool IsValid() const override;
diff --git a/include/editeng/unotext.hxx b/include/editeng/unotext.hxx
index ca263071bf98..3c94d3675e61 100644
--- a/include/editeng/unotext.hxx
+++ b/include/editeng/unotext.hxx
@@ -196,7 +196,7 @@ public:
virtual void QuickSetAttribs( const SfxItemSet& rSet, const ESelection& rSel ) override;
virtual void QuickInsertLineBreak( const ESelection& rSel ) override;
- virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor ) override;
+ virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor ) override;
virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos ) override;
virtual bool IsValid() const override;
diff --git a/include/svx/ClassificationEditView.hxx b/include/svx/ClassificationEditView.hxx
index cc2a30df78db..beb2fbc75a1e 100644
--- a/include/svx/ClassificationEditView.hxx
+++ b/include/svx/ClassificationEditView.hxx
@@ -27,7 +27,7 @@ class ClassificationEditEngine : public EditEngine
public:
ClassificationEditEngine(SfxItemPool* pItemPool);
- virtual OUString CalcFieldValue(const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rTxtColor, Color*& rFldColor) override;
+ virtual OUString CalcFieldValue(const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rTxtColor, boost::optional<Color>& rFldColor) override;
};
class SVX_DLLPUBLIC ClassificationEditView : public Control
diff --git a/include/svx/svdomeas.hxx b/include/svx/svdomeas.hxx
index 8b1a79797b30..72abb9abefcd 100644
--- a/include/svx/svdomeas.hxx
+++ b/include/svx/svdomeas.hxx
@@ -140,7 +140,7 @@ public:
virtual OutlinerParaObject* GetOutlinerParaObject() const override;
virtual bool CalcFieldValue(const SvxFieldItem& rField, sal_Int32 nPara, sal_uInt16 nPos,
- bool bEdit, Color*& rpTxtColor, Color*& rpFldColor, OUString& rRet) const override;
+ bool bEdit, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor, OUString& rRet) const override;
// #i97878#
virtual bool TRGetBaseGeometry(basegfx::B2DHomMatrix& rMatrix, basegfx::B2DPolyPolygon& rPolyPolygon) const override;
diff --git a/include/svx/svdotext.hxx b/include/svx/svdotext.hxx
index e0b9bbe434ba..daa749d2bf08 100644
--- a/include/svx/svdotext.hxx
+++ b/include/svx/svdotext.hxx
@@ -496,7 +496,7 @@ public:
virtual void ReformatText() override;
virtual bool CalcFieldValue(const SvxFieldItem& rField, sal_Int32 nPara, sal_uInt16 nPos,
- bool bEdit, Color*& rpTxtColor, Color*& rpFldColor, OUString& rRet) const;
+ bool bEdit, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor, OUString& rRet) const;
virtual SdrObject* DoConvertToPolyObj(bool bBezier, bool bAddText) const override;
diff --git a/include/svx/svdoutl.hxx b/include/svx/svdoutl.hxx
index c1ec4636dff6..61f889ebd57a 100644
--- a/include/svx/svdoutl.hxx
+++ b/include/svx/svdoutl.hxx
@@ -44,7 +44,7 @@ public:
void setVisualizedPage(const SdrPage* pPage) { if(pPage != mpVisualizedPage) mpVisualizedPage = pPage; }
const SdrPage* getVisualizedPage() const { return mpVisualizedPage; }
- virtual OUString CalcFieldValue(const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor) override;
+ virtual OUString CalcFieldValue(const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, boost::optional<Color>& rpTxtColor, boost::optional<Color>& rpFldColor) override;
bool hasEditViewCallbacks() const;
};