From 931c84e697dc69745d1c07c40f810638f9f71eda Mon Sep 17 00:00:00 2001 From: Mohammed Abdul Azeem Date: Sat, 21 Oct 2017 16:24:50 +0530 Subject: tdf#110431: Fixed losing listbos entries on opening .ods file For some reason, XML_TOKEN_INVALID was taking wrong value in windows, causing to fail imports with unknown entries. I've also added some of the tokens I found from several test files to the list. Change-Id: Idd2e7db165b9b4b5a2d8c7a837786fde252fe938 Reviewed-on: https://gerrit.libreoffice.org/43677 Tested-by: Jenkins Reviewed-by: Michael Meeks --- xmloff/source/core/fasttokenhandler.cxx | 2 +- xmloff/source/core/xmltoken.cxx | 9 +++++++++ xmloff/source/token/tokens.txt | 9 +++++++++ 3 files changed, 19 insertions(+), 1 deletion(-) (limited to 'xmloff') diff --git a/xmloff/source/core/fasttokenhandler.cxx b/xmloff/source/core/fasttokenhandler.cxx index b5fa379c9de7..e7eeb0803717 100644 --- a/xmloff/source/core/fasttokenhandler.cxx +++ b/xmloff/source/core/fasttokenhandler.cxx @@ -60,7 +60,7 @@ TokenMap::~TokenMap() sal_Int32 TokenMap::getTokenPerfectHash( const char *pStr, sal_Int32 nLength ) { const struct xmltoken *pToken = Perfect_Hash::in_word_set( pStr, nLength ); - return pToken ? pToken->nToken : XML_TOKEN_INVALID; + return pToken ? pToken->nToken : xmloff::XML_TOKEN_INVALID; } FastTokenHandler::FastTokenHandler() : diff --git a/xmloff/source/core/xmltoken.cxx b/xmloff/source/core/xmltoken.cxx index 521e304cf3e1..3d33a489493a 100644 --- a/xmloff/source/core/xmltoken.cxx +++ b/xmloff/source/core/xmltoken.cxx @@ -267,6 +267,7 @@ namespace xmloff { namespace token { TOKEN( "author-initials", XML_AUTHOR_INITIALS ), TOKEN( "author-name", XML_AUTHOR_NAME ), TOKEN( "auto", XML_AUTO ), + TOKEN( "auto-complete", XML_AUTO_COMPLETE ), TOKEN( "auto-grow-height", XML_AUTO_GROW_HEIGHT ), TOKEN( "auto-grow-width", XML_AUTO_GROW_WIDTH ), TOKEN( "auto-reload", XML_AUTO_RELOAD ), @@ -349,6 +350,7 @@ namespace xmloff { namespace token { TOKEN( "bottom values", XML_BOTTOM_VALUES ), TOKEN( "bottom-arc", XML_BOTTOMARC ), TOKEN( "bottom-circle", XML_BOTTOMCIRCLE ), + TOKEN( "bound-column", XML_BOUND_COLUMN ), TOKEN( "break-after", XML_BREAK_AFTER ), TOKEN( "break-before", XML_BREAK_BEFORE ), TOKEN( "break-inside", XML_BREAK_INSIDE ), @@ -606,6 +608,7 @@ namespace xmloff { namespace token { TOKEN( "default-style-name", XML_DEFAULT_STYLE_NAME ), TOKEN( "degree", XML_DEGREE ), TOKEN( "delay", XML_DELAY ), + TOKEN( "delay-for-repeat", XML_DELAY_FOR_REPEAT ), TOKEN( "delete-columns", XML_DELETE_COLUMNS ), TOKEN( "delete-rows", XML_DELETE_ROWS ), TOKEN( "deletion", XML_DELETION ), @@ -669,6 +672,7 @@ namespace xmloff { namespace token { TOKEN( "drawing", XML_DRAWING ), TOKEN( "drawings", XML_DRAWINGS ), TOKEN( "drawpool", XML_DRAWPOOL ), + TOKEN( "dropdown", XML_DROPDOWN ), TOKEN( "drop-cap", XML_DROP_CAP ), TOKEN( "dynamic", XML_DYNAMIC ), TOKEN( "edge-rounding", XML_EDGE_ROUNDING ), @@ -1137,6 +1141,7 @@ namespace xmloff { namespace token { TOKEN( "linenumbering-separator", XML_LINENUMBERING_SEPARATOR ), TOKEN( "lines", XML_LINES ), TOKEN( "lines-used", XML_LINES_USED ), + TOKEN( "linked-cell", XML_LINKED_CELL ), TOKEN( "link-to-source-data", XML_LINK_TO_SOURCE_DATA ), TOKEN( "list", XML_LIST ), TOKEN( "list-block", XML_LIST_BLOCK ), @@ -1147,6 +1152,7 @@ namespace xmloff { namespace token { TOKEN( "list-level-style-bullet", XML_LIST_LEVEL_STYLE_BULLET ), TOKEN( "list-level-style-image", XML_LIST_LEVEL_STYLE_IMAGE ), TOKEN( "list-level-style-number", XML_LIST_LEVEL_STYLE_NUMBER ), + TOKEN( "list-linkage-type", XML_LIST_LINKAGE_TYPE ), TOKEN( "list-name", XML_LIST_NAME ), TOKEN( "list-style", XML_LIST_STYLE ), TOKEN( "list-style-name", XML_LIST_STYLE_NAME ), @@ -1356,6 +1362,7 @@ namespace xmloff { namespace token { TOKEN( "operation", XML_OPERATION ), TOKEN( "operator", XML_OPERATOR ), TOKEN( "optimal", XML_OPTIMAL ), + TOKEN( "option", XML_OPTION ), TOKEN( "or", XML_OR ), TOKEN( "order", XML_ORDER ), TOKEN( "ordered-list", XML_ORDERED_LIST ), @@ -1753,6 +1760,7 @@ namespace xmloff { namespace token { TOKEN( "stdev", XML_STDEV ), TOKEN( "stdevp", XML_STDEVP ), TOKEN( "steps", XML_STEPS ), + TOKEN( "step-size", XML_STEP_SIZE ), TOKEN( "stock", XML_STOCK ), TOKEN( "stock-updown-bars", XML_STOCK_UPDOWN_BARS ), TOKEN( "stock-with-volume", XML_STOCK_WITH_VOLUME ), @@ -1832,6 +1840,7 @@ namespace xmloff { namespace token { TOKEN( "tan", XML_TAN ), TOKEN( "tanh", XML_TANH ), TOKEN( "target-cell-address", XML_TARGET_CELL_ADDRESS ), + TOKEN( "target-frame", XML_TARGET_FRAME ), TOKEN( "target-frame-name", XML_TARGET_FRAME_NAME ), TOKEN( "target-range-address", XML_TARGET_RANGE_ADDRESS ), TOKEN( "tb-rl", XML_TB_RL ), diff --git a/xmloff/source/token/tokens.txt b/xmloff/source/token/tokens.txt index fc54aaf1b65b..4e58356c7c07 100644 --- a/xmloff/source/token/tokens.txt +++ b/xmloff/source/token/tokens.txt @@ -190,6 +190,7 @@ author author-initials author-name auto +auto-complete auto-grow-height auto-grow-width auto-reload @@ -272,6 +273,7 @@ bottom-right BOTTOM_VALUES_DUMMY bottom-arc bottom-circle +bound-column break-after break-before break-inside @@ -529,6 +531,7 @@ default-style default-style-name degree delay +delay-for-repeat delete-columns delete-rows deletion @@ -592,6 +595,7 @@ ole-draw-aspect drawing drawings drawpool +dropdown drop-cap dynamic edge-rounding @@ -1055,6 +1059,7 @@ linenumbering-configuration linenumbering-separator lines lines-used +linked-cell link-to-source-data list list-block @@ -1065,6 +1070,7 @@ list-level list-level-style-bullet list-level-style-image list-level-style-number +list-linkage-type list-name list-style list-style-name @@ -1274,6 +1280,7 @@ open-vertical operation operator optimal +option or order ordered-list @@ -1671,6 +1678,7 @@ stay-on-top stdev stdevp steps +step-size stock stock-updown-bars stock-with-volume @@ -1750,6 +1758,7 @@ tables tan tanh target-cell-address +target-frame target-frame-name target-range-address tb-rl -- cgit v1.2.3