summaryrefslogtreecommitdiff
path: root/sw/inc/editsh.hxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-02-03 17:02:52 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-02-05 07:53:31 +0100
commit51ee91a3ca869be23153a235cbf33d4d20267fce (patch)
treed55ad43d12f82b2960d893a016f67e4f99ac5dd3 /sw/inc/editsh.hxx
parent90db24c33060bcb6db6ef900981c4379cd3074af (diff)
TypedWhichId in sw(1)
Change-Id: If9330b2ea7e40f4775b1edd9611d35c6ddf31a00 Reviewed-on: https://gerrit.libreoffice.org/49185 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/inc/editsh.hxx')
-rw-r--r--sw/inc/editsh.hxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/sw/inc/editsh.hxx b/sw/inc/editsh.hxx
index d290fd814130..2fd055f6c87c 100644
--- a/sw/inc/editsh.hxx
+++ b/sw/inc/editsh.hxx
@@ -280,6 +280,10 @@ public:
/// Query default attribute of document.
const SfxPoolItem& GetDefault( sal_uInt16 nFormatHint ) const;
+ template<class T> const T& GetDefault( TypedWhichId<T> nWhich ) const
+ {
+ return static_cast<const T&>(GetDefault(sal_uInt16(nWhich)));
+ }
void ResetAttr( const std::set<sal_uInt16> &attrs = std::set<sal_uInt16>(), SwPaM* pCursor = nullptr );
void GCAttr();