sw: add CharInteropGrabBag uno property to characters

Change-Id: I2c6d8b1e4ef6df6a6662d5db89e67e5fba3c6ade
This commit is contained in:
Jacobo Aragunde Pérez 2013-11-27 10:39:18 +01:00
parent 73cf3fd42e
commit 8a631e4718
6 changed files with 19 additions and 4 deletions

View File

@ -25,6 +25,7 @@
#include <com/sun/star/container/XNameContainer.idl>
#include <com/sun/star/table/BorderLine2.idl>
#include <com/sun/star/table/ShadowFormat.idl>
#include <com/sun/star/beans/PropertyValue.idl>
module com { module sun { module star { module style {
@ -441,6 +442,16 @@ published service CharacterProperties
**/
[optional, property] com::sun::star::util::Color CharHighlight;
/** Grab bag of character properties, used as a string-any map for interim interop purposes.
@since LibreOffice 4.2
<p>This property is intentionally not handled by the ODF filter. Any
member that should be handled there should be first moved out from this grab
bag to a separate property.</p>
*/
[optional, property] sequence<com::sun::star::beans::PropertyValue> CharInteropGrabBag;
};
}; }; }; };

View File

@ -95,7 +95,7 @@ RES_CHRATR_BEGIN = HINT_BEGIN,
RES_CHRATR_BOX, // 40
RES_CHRATR_SHADOW, // 41
RES_CHRATR_HIGHLIGHT, // 42
RES_CHRATR_DUMMY2, // 43
RES_CHRATR_GRABBAG, // 43
RES_CHRATR_DUMMY3, // 44
RES_CHRATR_END
};

View File

@ -842,6 +842,7 @@ enum SwPropNameIds
/* 0775 */ UNO_NAME_FRAME_INTEROP_GRAB_BAG,
/* 0776 */ UNO_NAME_CHAR_HIGHLIGHT,
/* 0777 */ UNO_NAME_STYLE_INTEROP_GRAB_BAG,
/* 0778 */ UNO_NAME_CHAR_INTEROP_GRAB_BAG,
SW_PROPNAME_END

View File

@ -291,7 +291,7 @@ SfxItemInfo aSlotTab[] =
{ 0, SFX_ITEM_POOLABLE }, // RES_CHRATR_BOX
{ 0, SFX_ITEM_POOLABLE }, // RES_CHRATR_SHADOW
{ 0, SFX_ITEM_POOLABLE }, // RES_CHRATR_DUMMY1
{ 0, SFX_ITEM_POOLABLE }, // RES_CHRATR_DUMMY2
{ 0, SFX_ITEM_POOLABLE }, // RES_CHRATR_GRABBAG
{ 0, SFX_ITEM_POOLABLE }, // RES_CHRATR_DUMMY3
{ 0, 0 }, // RES_TXTATR_REFMARK
@ -497,11 +497,12 @@ void _InitCore()
aAttrTab[ RES_CHRATR_BOX - POOLATTR_BEGIN ] = new SvxBoxItem( RES_CHRATR_BOX );
aAttrTab[ RES_CHRATR_SHADOW - POOLATTR_BEGIN ] = new SvxShadowItem( RES_CHRATR_SHADOW );
aAttrTab[ RES_CHRATR_HIGHLIGHT - POOLATTR_BEGIN ] = new SvxBrushItem( RES_CHRATR_HIGHLIGHT );
aAttrTab[ RES_CHRATR_GRABBAG - POOLATTR_BEGIN ] = new SfxGrabBagItem( RES_CHRATR_GRABBAG );
// CharakterAttr - Dummies
aAttrTab[ RES_CHRATR_DUMMY2 - POOLATTR_BEGIN ] = new SfxBoolItem( RES_CHRATR_DUMMY2 );
aAttrTab[ RES_CHRATR_DUMMY3 - POOLATTR_BEGIN ] = new SfxBoolItem( RES_CHRATR_DUMMY3 );
aAttrTab[ RES_TXTATR_REFMARK - POOLATTR_BEGIN ] = new SwFmtRefMark( aEmptyOUStr );
aAttrTab[ RES_TXTATR_TOXMARK - POOLATTR_BEGIN ] = new SwTOXMark;
aAttrTab[ RES_TXTATR_META - POOLATTR_BEGIN ] = SwFmtMeta::CreatePoolDefault(RES_TXTATR_META);

View File

@ -75,7 +75,8 @@ SwUnoPropertyMapProvider::~SwUnoPropertyMapProvider()
{ SW_PROP_NMID(UNO_NAME_CHAR_FONT_PITCH), RES_CHRATR_FONT, CPPU_E2T(CPPUTYPE_INT16), PropertyAttribute::MAYBEVOID, MID_FONT_PITCH }, \
{ SW_PROP_NMID(UNO_NAME_CHAR_POSTURE), RES_CHRATR_POSTURE , CPPU_E2T(CPPUTYPE_FONTSLANT), PropertyAttribute::MAYBEVOID, MID_POSTURE}, \
{ SW_PROP_NMID(UNO_NAME_RSID), RES_CHRATR_RSID, CPPU_E2T(CPPUTYPE_INT32), PropertyAttribute::MAYBEVOID, 0 }, \
{ SW_PROP_NMID(UNO_NAME_CHAR_LOCALE), RES_CHRATR_LANGUAGE , CPPU_E2T(CPPUTYPE_LOCALE) , PropertyAttribute::MAYBEVOID, MID_LANG_LOCALE },
{ SW_PROP_NMID(UNO_NAME_CHAR_LOCALE), RES_CHRATR_LANGUAGE, CPPU_E2T(CPPUTYPE_LOCALE), PropertyAttribute::MAYBEVOID, MID_LANG_LOCALE }, \
{ SW_PROP_NMID(UNO_NAME_CHAR_INTEROP_GRAB_BAG), RES_CHRATR_GRABBAG, CPPU_E2T(CPPUTYPE_PROPERTYVALUE), PROPERTY_NONE, 0 }, \
#define _CJK_FONT_PROPERTIES \
{ SW_PROP_NMID(UNO_NAME_CHAR_HEIGHT_ASIAN), RES_CHRATR_CJK_FONTSIZE , CPPU_E2T(CPPUTYPE_FLOAT), PropertyAttribute::MAYBEVOID, MID_FONTHEIGHT|CONVERT_TWIPS}, \

View File

@ -807,6 +807,7 @@ const SwPropNameTab aPropNameTab = {
/* 0775 UNO_NAME_FRAME_INTEROP_GRAB_BAG */ {MAP_CHAR_LEN("FrameInteropGrabBag")},
/* 0776 UNO_NAME_CHAR_HIGHLIGHT */ {MAP_CHAR_LEN("CharHighlight")},
/* 0777 UNO_NAME_STYLE_INTEROP_GRAB_BAG */ {MAP_CHAR_LEN("StyleInteropGrabBag")},
/* 0778 UNO_NAME_CHAR_INTEROP_GRAB_BAG */ {MAP_CHAR_LEN("CharInteropGrabBag")},
// new items in this array must match enum SwPropNameIds
};