1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir 28*cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove 29*cdf0e10cSrcweir #include "precompiled_xmloff.hxx" 30*cdf0e10cSrcweir #include <rtl/uuid.h> 31*cdf0e10cSrcweir #include <rtl/ustrbuf.hxx> 32*cdf0e10cSrcweir #include <comphelper/processfactory.hxx> 33*cdf0e10cSrcweir #include <xmloff/nmspmap.hxx> 34*cdf0e10cSrcweir #include "xmloff/xmlnmspe.hxx" 35*cdf0e10cSrcweir #include <xmloff/xmltoken.hxx> 36*cdf0e10cSrcweir #include "MutableAttrList.hxx" 37*cdf0e10cSrcweir #include "DeepTContext.hxx" 38*cdf0e10cSrcweir #include "StyleOOoTContext.hxx" 39*cdf0e10cSrcweir #include "FrameOOoTContext.hxx" 40*cdf0e10cSrcweir #include "EventOOoTContext.hxx" 41*cdf0e10cSrcweir #include "ControlOOoTContext.hxx" 42*cdf0e10cSrcweir #include "FormPropOOoTContext.hxx" 43*cdf0e10cSrcweir #include "ChartOOoTContext.hxx" 44*cdf0e10cSrcweir #include "ChartPlotAreaOOoTContext.hxx" 45*cdf0e10cSrcweir #include "ElemTransformerAction.hxx" 46*cdf0e10cSrcweir #include "AttrTransformerAction.hxx" 47*cdf0e10cSrcweir #include "PropertyActionsOOo.hxx" 48*cdf0e10cSrcweir #include "TransformerActions.hxx" 49*cdf0e10cSrcweir #include <xmloff/xmluconv.hxx> 50*cdf0e10cSrcweir #ifndef _XMLOFF_OOO2OOO_HXX 51*cdf0e10cSrcweir #include "OOo2Oasis.hxx" 52*cdf0e10cSrcweir #endif 53*cdf0e10cSrcweir 54*cdf0e10cSrcweir using ::rtl::OUString; 55*cdf0e10cSrcweir using namespace ::xmloff::token; 56*cdf0e10cSrcweir using namespace ::com::sun::star::uno; 57*cdf0e10cSrcweir using namespace ::com::sun::star::lang; 58*cdf0e10cSrcweir using namespace ::com::sun::star::xml::sax; 59*cdf0e10cSrcweir using namespace ::com::sun::star::beans; 60*cdf0e10cSrcweir 61*cdf0e10cSrcweir OUString SAL_CALL OOo2OasisTransformer_getImplementationName() throw(); 62*cdf0e10cSrcweir 63*cdf0e10cSrcweir enum XMLUserDefinedTransformerAction 64*cdf0e10cSrcweir { 65*cdf0e10cSrcweir XML_ETACTION_DOCUMENT=XML_ETACTION_USER_DEFINED, 66*cdf0e10cSrcweir XML_ETACTION_BODY, 67*cdf0e10cSrcweir XML_ETACTION_STYLE, 68*cdf0e10cSrcweir XML_ETACTION_STYLE_RENAME, 69*cdf0e10cSrcweir XML_ETACTION_FRAME, 70*cdf0e10cSrcweir XML_ETACTION_EVENT, 71*cdf0e10cSrcweir XML_ETACTION_TAB_STOP, 72*cdf0e10cSrcweir XML_ETACTION_FORM_CONTROL, 73*cdf0e10cSrcweir XML_ETACTION_FORM_PROPERTY, 74*cdf0e10cSrcweir XML_ETACTION_CHART, 75*cdf0e10cSrcweir XML_ETACTION_TRACKED_CHANGES, 76*cdf0e10cSrcweir XML_ETACTION_CHART_PLOT_AREA, 77*cdf0e10cSrcweir XML_ETACTION_DOCUMENT_RENAME, 78*cdf0e10cSrcweir XML_ETACTION_TABLE 79*cdf0e10cSrcweir }; 80*cdf0e10cSrcweir 81*cdf0e10cSrcweir #define ENTRY3( n, l, a, p1, p2, p3 ) \ 82*cdf0e10cSrcweir { XML_NAMESPACE_##n, XML_##l, a, p1, p2, p3 } 83*cdf0e10cSrcweir #define ENTRY3QQN( n, l, a, n1, l1, n2, l2, p3 ) \ 84*cdf0e10cSrcweir ENTRY3( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ), \ 85*cdf0e10cSrcweir XMLTransformerActionInit::QNameParam( n2, l2 ), p3 ) 86*cdf0e10cSrcweir 87*cdf0e10cSrcweir #define ENTRY2( n, l, a, p1, p2 ) \ 88*cdf0e10cSrcweir ENTRY3( n, l, a, p1, p2, 0 ) 89*cdf0e10cSrcweir #define ENTRY2QQ( n, l, a, n1, l1, n2, l2 ) \ 90*cdf0e10cSrcweir ENTRY2( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ), \ 91*cdf0e10cSrcweir XMLTransformerActionInit::QNameParam( n2, l2 ) ) 92*cdf0e10cSrcweir #define ENTRY2QN( n, l, a, n1, l1, p2 ) \ 93*cdf0e10cSrcweir ENTRY2( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ), p2 ) 94*cdf0e10cSrcweir 95*cdf0e10cSrcweir #define ENTRY1( n, l, a, p1 ) \ 96*cdf0e10cSrcweir ENTRY3( n, l, a, p1, 0, 0 ) 97*cdf0e10cSrcweir #define ENTRY1Q( n, l, a, n1, l1 ) \ 98*cdf0e10cSrcweir ENTRY1( n, l, a, XMLTransformerActionInit::QNameParam( n1, l1 ) ) 99*cdf0e10cSrcweir 100*cdf0e10cSrcweir #define ENTRY0( n, l, a ) \ 101*cdf0e10cSrcweir ENTRY3( n, l, a, 0, 0, 0 ) 102*cdf0e10cSrcweir 103*cdf0e10cSrcweir // BM: a macro to put two tokens into one sal_Int32 for the action 104*cdf0e10cSrcweir // XML_ATACTION_RENAME_ATTRIBUTE 105*cdf0e10cSrcweir #define RENAME_ENTRY( f, s ) \ 106*cdf0e10cSrcweir (static_cast< sal_Int32 >(f) | (static_cast< sal_Int32 >(s) << 16)) 107*cdf0e10cSrcweir 108*cdf0e10cSrcweir static XMLTransformerActionInit aActionTable[] = 109*cdf0e10cSrcweir { 110*cdf0e10cSrcweir // remove office:class from <office:document> and <office:document-content> 111*cdf0e10cSrcweir ENTRY0( OFFICE, DOCUMENT, XML_ETACTION_DOCUMENT ), 112*cdf0e10cSrcweir ENTRY0( OFFICE, DOCUMENT_CONTENT, XML_ETACTION_DOCUMENT ), 113*cdf0e10cSrcweir ENTRY0( OFFICE, DOCUMENT_STYLES, XML_ETACTION_DOCUMENT ), 114*cdf0e10cSrcweir ENTRY0( OFFICE, DOCUMENT_SETTINGS, XML_ETACTION_DOCUMENT ), 115*cdf0e10cSrcweir ENTRY1Q( OFFICE, AUTO_TEXT_EVENTS, XML_ETACTION_DOCUMENT_RENAME, 116*cdf0e10cSrcweir XML_NAMESPACE_OOO, XML_AUTO_TEXT_EVENTS), 117*cdf0e10cSrcweir 118*cdf0e10cSrcweir // remove <meta:keywords> 119*cdf0e10cSrcweir ENTRY0( META, KEYWORDS, XML_ETACTION_COPY_CONTENT ), 120*cdf0e10cSrcweir 121*cdf0e10cSrcweir // rename <office:script> to <office:scripts> 122*cdf0e10cSrcweir ENTRY1Q( OFFICE, SCRIPT, XML_ETACTION_RENAME_ELEM, 123*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_SCRIPTS ), 124*cdf0e10cSrcweir 125*cdf0e10cSrcweir // rename <office:script-data> to <office:script> and process attributes 126*cdf0e10cSrcweir ENTRY2QN( OFFICE, SCRIPT_DATA, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 127*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_SCRIPT, 128*cdf0e10cSrcweir OOO_SCRIPT_ACTIONS ), 129*cdf0e10cSrcweir 130*cdf0e10cSrcweir // rename <script:libraries> to <ooo:libraries> 131*cdf0e10cSrcweir ENTRY1Q( SCRIPT, LIBRARIES, XML_ETACTION_RENAME_ELEM, 132*cdf0e10cSrcweir XML_NAMESPACE_OOO, XML_LIBRARIES ), 133*cdf0e10cSrcweir 134*cdf0e10cSrcweir // rename <script:library-linked> to <ooo:library-linked> and process attributes 135*cdf0e10cSrcweir ENTRY2QN( SCRIPT, LIBRARY_LINKED, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 136*cdf0e10cSrcweir XML_NAMESPACE_OOO, XML_LIBRARY_LINKED, 137*cdf0e10cSrcweir OOO_SCRIPT_ACTIONS ), 138*cdf0e10cSrcweir 139*cdf0e10cSrcweir // rename <script:library-embedded> to <ooo:library-embedded> and process attributes 140*cdf0e10cSrcweir ENTRY2QN( SCRIPT, LIBRARY_EMBEDDED, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 141*cdf0e10cSrcweir XML_NAMESPACE_OOO, XML_LIBRARY_EMBEDDED, 142*cdf0e10cSrcweir OOO_SCRIPT_ACTIONS ), 143*cdf0e10cSrcweir 144*cdf0e10cSrcweir // rename <script:module> to <ooo:module> and process attributes 145*cdf0e10cSrcweir ENTRY2QN( SCRIPT, MODULE, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 146*cdf0e10cSrcweir XML_NAMESPACE_OOO, XML_MODULE, 147*cdf0e10cSrcweir OOO_SCRIPT_ACTIONS ), 148*cdf0e10cSrcweir 149*cdf0e10cSrcweir // rename <script:source-code> to <ooo:source-code> 150*cdf0e10cSrcweir ENTRY1Q( SCRIPT, SOURCE_CODE, XML_ETACTION_RENAME_ELEM, 151*cdf0e10cSrcweir XML_NAMESPACE_OOO, XML_SOURCE_CODE ), 152*cdf0e10cSrcweir 153*cdf0e10cSrcweir // rename <office:font-decls> to <office:font-face-decl>, 154*cdf0e10cSrcweir // rename <style:font-decl> to <style:font-face>, process attrs 155*cdf0e10cSrcweir ENTRY1Q( OFFICE, FONT_DECLS, XML_ETACTION_RENAME_ELEM, 156*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_FONT_FACE_DECLS ), 157*cdf0e10cSrcweir ENTRY2QN( STYLE, FONT_DECL, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 158*cdf0e10cSrcweir XML_NAMESPACE_STYLE, XML_FONT_FACE, 159*cdf0e10cSrcweir OOO_FONT_DECL_ACTIONS ), 160*cdf0e10cSrcweir 161*cdf0e10cSrcweir // add genre element 162*cdf0e10cSrcweir ENTRY0( OFFICE, BODY, XML_ETACTION_BODY ), 163*cdf0e10cSrcweir 164*cdf0e10cSrcweir // rename <style:page-master> to <style:page-layout> 165*cdf0e10cSrcweir ENTRY2QN( STYLE, PAGE_MASTER, XML_ETACTION_STYLE_RENAME, 166*cdf0e10cSrcweir XML_NAMESPACE_STYLE, XML_PAGE_LAYOUT, 167*cdf0e10cSrcweir XML_FAMILY_TYPE_PAGE_LAYOUT ), 168*cdf0e10cSrcweir ENTRY1( STYLE, MASTER_PAGE, XML_ETACTION_PROC_ATTRS, 169*cdf0e10cSrcweir OOO_MASTER_PAGE_ACTIONS ), 170*cdf0e10cSrcweir 171*cdf0e10cSrcweir // split <style:properties> into <style:*-properties> and do other 172*cdf0e10cSrcweir // styles processing 173*cdf0e10cSrcweir ENTRY1( STYLE, STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_END ), 174*cdf0e10cSrcweir ENTRY1( STYLE, DEFAULT_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_END ), 175*cdf0e10cSrcweir ENTRY1( NUMBER, NUMBER_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 176*cdf0e10cSrcweir ENTRY1( NUMBER, CURRENCY_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 177*cdf0e10cSrcweir ENTRY1( NUMBER, PERCENTAGE_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 178*cdf0e10cSrcweir ENTRY1( NUMBER, DATE_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 179*cdf0e10cSrcweir ENTRY1( NUMBER, TIME_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 180*cdf0e10cSrcweir ENTRY1( NUMBER, BOOLEAN_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 181*cdf0e10cSrcweir ENTRY1( NUMBER, TEXT_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_DATA ), 182*cdf0e10cSrcweir ENTRY1( TEXT, LIST_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_LIST ), 183*cdf0e10cSrcweir // ENTRY0( TEXT, OUTLINE_STYLE, STYLE ), 184*cdf0e10cSrcweir ENTRY1( STYLE, HEADER_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_HEADER_FOOTER ), 185*cdf0e10cSrcweir ENTRY1( STYLE, FOOTER_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_HEADER_FOOTER ), 186*cdf0e10cSrcweir ENTRY1( TEXT, LIST_LEVEL_STYLE_NUMBER, XML_ETACTION_STYLE, XML_FAMILY_TYPE_LIST ), 187*cdf0e10cSrcweir ENTRY1( TEXT, LIST_LEVEL_STYLE_BULLET, XML_ETACTION_STYLE, XML_FAMILY_TYPE_LIST ), 188*cdf0e10cSrcweir ENTRY1( TEXT, LIST_LEVEL_STYLE_IMAGE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_LIST ), 189*cdf0e10cSrcweir ENTRY1( TEXT, OUTLINE_LEVEL_STYLE, XML_ETACTION_STYLE, XML_FAMILY_TYPE_LIST ), 190*cdf0e10cSrcweir ENTRY1( DRAW, GRADIENT, XML_ETACTION_STYLE, 191*cdf0e10cSrcweir XML_FAMILY_TYPE_GRADIENT ), 192*cdf0e10cSrcweir ENTRY1( DRAW, FILL_IMAGE, XML_ETACTION_STYLE, 193*cdf0e10cSrcweir XML_FAMILY_TYPE_FILL_IMAGE ), 194*cdf0e10cSrcweir ENTRY2QN( DRAW, TRANSPARENCY, XML_ETACTION_STYLE_RENAME, 195*cdf0e10cSrcweir XML_NAMESPACE_DRAW, XML_OPACITY, 196*cdf0e10cSrcweir XML_FAMILY_TYPE_GRADIENT ), 197*cdf0e10cSrcweir ENTRY1( DRAW, MARKER, XML_ETACTION_STYLE, 198*cdf0e10cSrcweir XML_FAMILY_TYPE_MARKER ), 199*cdf0e10cSrcweir ENTRY1( DRAW, HATCH, XML_ETACTION_STYLE, 200*cdf0e10cSrcweir XML_FAMILY_TYPE_HATCH ), 201*cdf0e10cSrcweir ENTRY1( DRAW, STROKE_DASH, XML_ETACTION_STYLE, 202*cdf0e10cSrcweir XML_FAMILY_TYPE_STROKE_DASH ), 203*cdf0e10cSrcweir 204*cdf0e10cSrcweir // rename <text:h>'s text:level to text:outline-level 205*cdf0e10cSrcweir // process <text:h/p>: process style-name attributes, 206*cdf0e10cSrcweir ENTRY1( TEXT, H, XML_ETACTION_PROC_ATTRS, OOO_PARA_ACTIONS ), 207*cdf0e10cSrcweir ENTRY1( TEXT, P, XML_ETACTION_PROC_ATTRS, OOO_PARA_ACTIONS ), 208*cdf0e10cSrcweir 209*cdf0e10cSrcweir // rename <text:ordered-list> and <text:unordered-list> to <text:list> 210*cdf0e10cSrcweir ENTRY2QN( TEXT, UNORDERED_LIST, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 211*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_LIST, 212*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), 213*cdf0e10cSrcweir ENTRY2QN( TEXT, ORDERED_LIST, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 214*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_LIST, 215*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), 216*cdf0e10cSrcweir 217*cdf0e10cSrcweir // rename <text:footnote*> to <text:note*> 218*cdf0e10cSrcweir ENTRY3QQN( TEXT, FOOTNOTE, XML_ETACTION_RENAME_ELEM_ADD_ATTR, 219*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE, 220*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CLASS, XML_FOOTNOTE ), 221*cdf0e10cSrcweir ENTRY1Q( TEXT, FOOTNOTE_BODY, XML_ETACTION_RENAME_ELEM, 222*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_BODY ), 223*cdf0e10cSrcweir ENTRY1Q( TEXT, FOOTNOTE_CITATION, XML_ETACTION_RENAME_ELEM, 224*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CITATION ), 225*cdf0e10cSrcweir ENTRY3QQN( TEXT, FOOTNOTES_CONFIGURATION, 226*cdf0e10cSrcweir XML_ETACTION_RENAME_ELEM_ADD_PROC_ATTR, 227*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTES_CONFIGURATION, 228*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CLASS, 229*cdf0e10cSrcweir XML_FOOTNOTE | (OOO_STYLE_REF_ACTIONS << 16) ), 230*cdf0e10cSrcweir 231*cdf0e10cSrcweir // rename <text:endnote*> to <text:endnote*> 232*cdf0e10cSrcweir ENTRY3QQN( TEXT, ENDNOTE, XML_ETACTION_RENAME_ELEM_ADD_ATTR, 233*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE, 234*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CLASS, XML_ENDNOTE ), 235*cdf0e10cSrcweir ENTRY1Q( TEXT, ENDNOTE_BODY, XML_ETACTION_RENAME_ELEM, 236*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_BODY ), 237*cdf0e10cSrcweir ENTRY1Q( TEXT, ENDNOTE_CITATION, XML_ETACTION_RENAME_ELEM, 238*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CITATION ), 239*cdf0e10cSrcweir ENTRY3QQN( TEXT, ENDNOTES_CONFIGURATION, 240*cdf0e10cSrcweir XML_ETACTION_RENAME_ELEM_ADD_PROC_ATTR, 241*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTES_CONFIGURATION, 242*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CLASS, 243*cdf0e10cSrcweir XML_ENDNOTE | (OOO_STYLE_REF_ACTIONS << 16) ), 244*cdf0e10cSrcweir 245*cdf0e10cSrcweir // rename <text:footnote> and <text:endnote> to <text:note> 246*cdf0e10cSrcweir ENTRY3QQN( TEXT, ENDNOTE_REF, XML_ETACTION_RENAME_ELEM_ADD_ATTR, 247*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_REF, 248*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CLASS, XML_ENDNOTE ), 249*cdf0e10cSrcweir ENTRY3QQN( TEXT, FOOTNOTE_REF, XML_ETACTION_RENAME_ELEM_ADD_ATTR, 250*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_REF, 251*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_NOTE_CLASS, XML_FOOTNOTE ), 252*cdf0e10cSrcweir 253*cdf0e10cSrcweir // rename <text:tab-stop> to <text:tab> 254*cdf0e10cSrcweir ENTRY1Q( TEXT, TAB_STOP, XML_ETACTION_RENAME_ELEM, 255*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_TAB ), 256*cdf0e10cSrcweir 257*cdf0e10cSrcweir // replace <table:sub-table> with <table:table table:is-sub-table> 258*cdf0e10cSrcweir ENTRY3QQN( TABLE, SUB_TABLE, XML_ETACTION_RENAME_ELEM_ADD_ATTR, 259*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_TABLE, 260*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_IS_SUB_TABLE, XML_TRUE ), 261*cdf0e10cSrcweir 262*cdf0e10cSrcweir // process *:style-name attributes 263*cdf0e10cSrcweir ENTRY1( TEXT, SECTION, XML_ETACTION_PROC_ATTRS, 264*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 265*cdf0e10cSrcweir ENTRY1( TEXT, SPAN, XML_ETACTION_PROC_ATTRS, 266*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 267*cdf0e10cSrcweir ENTRY1( TEXT, A, XML_ETACTION_PROC_ATTRS, 268*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 269*cdf0e10cSrcweir ENTRY1( TEXT, RUBY, XML_ETACTION_PROC_ATTRS, 270*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 271*cdf0e10cSrcweir ENTRY1( TEXT, RUBY_TEXT, XML_ETACTION_PROC_ATTRS, 272*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 273*cdf0e10cSrcweir ENTRY1( TEXT, DATE, XML_ETACTION_PROC_ATTRS, 274*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 275*cdf0e10cSrcweir ENTRY1( TEXT, TIME, XML_ETACTION_PROC_ATTRS, 276*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 277*cdf0e10cSrcweir ENTRY1( TEXT, VARIABLE_GET, XML_ETACTION_PROC_ATTRS, 278*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 279*cdf0e10cSrcweir ENTRY1( TEXT, USER_FIELD_GET, XML_ETACTION_PROC_ATTRS, 280*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 281*cdf0e10cSrcweir ENTRY1( TEXT, USER_FIELD_INPUT, XML_ETACTION_PROC_ATTRS, 282*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 283*cdf0e10cSrcweir ENTRY1( TEXT, CREATION_DATE, XML_ETACTION_PROC_ATTRS, 284*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 285*cdf0e10cSrcweir ENTRY1( TEXT, CREATION_TIME, XML_ETACTION_PROC_ATTRS, 286*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 287*cdf0e10cSrcweir ENTRY1( TEXT, PRINT_TIME, XML_ETACTION_PROC_ATTRS, 288*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 289*cdf0e10cSrcweir ENTRY1( TEXT, PRINT_DATE, XML_ETACTION_PROC_ATTRS, 290*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 291*cdf0e10cSrcweir ENTRY1( TEXT, EDITING_DURATION, XML_ETACTION_PROC_ATTRS, 292*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 293*cdf0e10cSrcweir ENTRY1( TEXT, MODIFICATION_TIME, XML_ETACTION_PROC_ATTRS, 294*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 295*cdf0e10cSrcweir ENTRY1( TEXT, MODIFICATION_DATE, XML_ETACTION_PROC_ATTRS, 296*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 297*cdf0e10cSrcweir ENTRY1( TEXT, DATABASE_DISPLAY, XML_ETACTION_PROC_ATTRS, 298*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 299*cdf0e10cSrcweir ENTRY1( TEXT, TABLE_FORMULA, XML_ETACTION_PROC_ATTRS, 300*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 301*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_TITLE, XML_ETACTION_PROC_ATTRS, 302*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 303*cdf0e10cSrcweir ENTRY1( TEXT, TABLE_OF_CONTENT, XML_ETACTION_PROC_ATTRS, 304*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 305*cdf0e10cSrcweir ENTRY1( TEXT, TABLE_OF_CONTENT_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 306*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 307*cdf0e10cSrcweir ENTRY1( TEXT, ILLUSTRATION_INDEX, XML_ETACTION_PROC_ATTRS, 308*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 309*cdf0e10cSrcweir ENTRY1( TEXT, ILLUSTRATION_INDEX_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 310*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 311*cdf0e10cSrcweir ENTRY1( TEXT, TABLE_INDEX, XML_ETACTION_PROC_ATTRS, 312*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 313*cdf0e10cSrcweir ENTRY1( TEXT, TABLE_INDEX_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 314*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 315*cdf0e10cSrcweir ENTRY1( TEXT, OBJECT_INDEX, XML_ETACTION_PROC_ATTRS, 316*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 317*cdf0e10cSrcweir ENTRY1( TEXT, OBJECT_INDEX_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 318*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 319*cdf0e10cSrcweir ENTRY1( TEXT, USER_INDEX, XML_ETACTION_PROC_ATTRS, 320*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 321*cdf0e10cSrcweir ENTRY1( TEXT, USER_INDEX_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 322*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 323*cdf0e10cSrcweir ENTRY1( TEXT, ALPHABETICAL_INDEX, XML_ETACTION_PROC_ATTRS, 324*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 325*cdf0e10cSrcweir ENTRY1( TEXT, ALPHABETICAL_INDEX_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 326*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 327*cdf0e10cSrcweir ENTRY1( TEXT, BIBLIOGRAPHY, XML_ETACTION_PROC_ATTRS, 328*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 329*cdf0e10cSrcweir ENTRY1( TEXT, BIBLIOGRAPHY_ENTRY_TEMPLATE, XML_ETACTION_PROC_ATTRS, 330*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 331*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_SOURCE_STYLE, XML_ETACTION_PROC_ATTRS, 332*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 333*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_TITLE_TEMPLATE, XML_ETACTION_PROC_ATTRS, 334*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 335*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_CHAPTER, XML_ETACTION_PROC_ATTRS, 336*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 337*cdf0e10cSrcweir ENTRY2QN( TEXT, INDEX_ENTRY_CHAPTER_NUMBER, 338*cdf0e10cSrcweir XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 339*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_INDEX_ENTRY_CHAPTER, 340*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 341*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_TEXT, XML_ETACTION_PROC_ATTRS, 342*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 343*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_PAGE_NUMBER, XML_ETACTION_PROC_ATTRS, 344*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 345*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_SPAN, XML_ETACTION_PROC_ATTRS, 346*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 347*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_BIBLIOGRAPHY, XML_ETACTION_PROC_ATTRS, 348*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 349*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_LINK_START, XML_ETACTION_PROC_ATTRS, 350*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 351*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_LINK_END, XML_ETACTION_PROC_ATTRS, 352*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 353*cdf0e10cSrcweir ENTRY1( STYLE, HANDOUT_MASTER, XML_ETACTION_PROC_ATTRS, 354*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 355*cdf0e10cSrcweir ENTRY1( DRAW, PAGE, XML_ETACTION_PROC_ATTRS, 356*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 357*cdf0e10cSrcweir ENTRY1( STYLE, MAP, XML_ETACTION_PROC_ATTRS, 358*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 359*cdf0e10cSrcweir ENTRY1( PRESENTATION, NOTES, XML_ETACTION_PROC_ATTRS, 360*cdf0e10cSrcweir OOO_STYLE_REF_ACTIONS ), /* generated entry */ 361*cdf0e10cSrcweir ENTRY1( STYLE, PRESENTATION_PAGE_LAYOUT, XML_ETACTION_PROC_ATTRS, 362*cdf0e10cSrcweir OOO_MASTER_PAGE_ACTIONS ), 363*cdf0e10cSrcweir // --> OD 2005-01-10 #i40011#, #i40015# 364*cdf0e10cSrcweir // - consider also attribute table:style-name for <table:table>, 365*cdf0e10cSrcweir // <table:table-row> and <table:table-column>. 366*cdf0e10cSrcweir // ENTRY1( TABLE, TABLE, XML_ETACTION_PROC_ATTRS, OOO_STYLE_REF_ACTIONS ), 367*cdf0e10cSrcweir ENTRY0( TABLE, TABLE, XML_ETACTION_TABLE ), 368*cdf0e10cSrcweir 369*cdf0e10cSrcweir ENTRY1( TABLE, TABLE_ROW, XML_ETACTION_PROC_ATTRS, OOO_STYLE_REF_ACTIONS ), 370*cdf0e10cSrcweir ENTRY1( TABLE, TABLE_COLUMN, XML_ETACTION_PROC_ATTRS, OOO_STYLE_REF_ACTIONS ), 371*cdf0e10cSrcweir // <-- 372*cdf0e10cSrcweir 373*cdf0e10cSrcweir // split frame elements 374*cdf0e10cSrcweir ENTRY0( DRAW, TEXT_BOX, XML_ETACTION_FRAME ), 375*cdf0e10cSrcweir ENTRY0( DRAW, IMAGE, XML_ETACTION_FRAME ), 376*cdf0e10cSrcweir ENTRY0( DRAW, OBJECT, XML_ETACTION_FRAME ), 377*cdf0e10cSrcweir ENTRY0( DRAW, OBJECT_OLE, XML_ETACTION_FRAME ), 378*cdf0e10cSrcweir ENTRY0( DRAW, APPLET, XML_ETACTION_FRAME ), 379*cdf0e10cSrcweir ENTRY0( DRAW, PLUGIN, XML_ETACTION_FRAME ), 380*cdf0e10cSrcweir ENTRY0( DRAW, FLOATING_FRAME, XML_ETACTION_FRAME ), 381*cdf0e10cSrcweir ENTRY0( SVG, DESC, XML_ETACTION_COPY_TEXT ), 382*cdf0e10cSrcweir 383*cdf0e10cSrcweir // process events 384*cdf0e10cSrcweir ENTRY1Q( OFFICE, EVENTS, XML_ETACTION_RENAME_ELEM, 385*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_EVENT_LISTENERS ), 386*cdf0e10cSrcweir ENTRY0( SCRIPT, EVENT, XML_ETACTION_EVENT ), 387*cdf0e10cSrcweir ENTRY0( PRESENTATION, EVENT, XML_ETACTION_EVENT ), 388*cdf0e10cSrcweir 389*cdf0e10cSrcweir // process length attributes 390*cdf0e10cSrcweir ENTRY1( DRAW, RECT, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 391*cdf0e10cSrcweir ENTRY1( DRAW, LINE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 392*cdf0e10cSrcweir ENTRY1( DRAW, POLYLINE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 393*cdf0e10cSrcweir ENTRY1( DRAW, POLYGON, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 394*cdf0e10cSrcweir ENTRY1( DRAW, PATH, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 395*cdf0e10cSrcweir ENTRY1( DRAW, CIRCLE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 396*cdf0e10cSrcweir ENTRY1( DRAW, ELLIPSE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 397*cdf0e10cSrcweir ENTRY1( DRAW, CONNECTOR, XML_ETACTION_PROC_ATTRS, OOO_CONNECTOR_ACTIONS ), 398*cdf0e10cSrcweir ENTRY1( DRAW, CAPTION, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 399*cdf0e10cSrcweir ENTRY1( DRAW, CONTROL, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 400*cdf0e10cSrcweir ENTRY1( DRAW, PAGE_THUMBNAIL, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 401*cdf0e10cSrcweir ENTRY1( DRAW, MEASURE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 402*cdf0e10cSrcweir ENTRY1( DRAW, G, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 403*cdf0e10cSrcweir // ENTRY1( DRAW, TEXT_BOX, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 404*cdf0e10cSrcweir ENTRY1( PRESENTATION, PLACEHOLDER, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 405*cdf0e10cSrcweir ENTRY1( DRAW, CONTOUR_POLYGON, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 406*cdf0e10cSrcweir ENTRY1( DRAW, CONTOUR_PATH, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 407*cdf0e10cSrcweir ENTRY1( DRAW, AREA_RECTANGLE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 408*cdf0e10cSrcweir ENTRY1( DRAW, AREA_CIRCLE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 409*cdf0e10cSrcweir ENTRY1( DRAW, AREA_POLYGON, XML_ETACTION_PROC_ATTRS, OOO_DRAW_AREA_POLYGON_ACTIONS ), 410*cdf0e10cSrcweir ENTRY1( DRAW, GLUE_POINT, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 411*cdf0e10cSrcweir ENTRY1( DR3D, SCENE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 412*cdf0e10cSrcweir ENTRY1( DR3D, CUBE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 413*cdf0e10cSrcweir ENTRY1( DR3D, SPHERE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 414*cdf0e10cSrcweir ENTRY1( DR3D, EXTRUDE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 415*cdf0e10cSrcweir ENTRY1( DR3D, ROTATE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 416*cdf0e10cSrcweir ENTRY1( CHART, TITLE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 417*cdf0e10cSrcweir ENTRY1( CHART, SUBTITLE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 418*cdf0e10cSrcweir ENTRY1( CHART, FOOTER, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 419*cdf0e10cSrcweir ENTRY1( CHART, LEGEND, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 420*cdf0e10cSrcweir ENTRY1( CHART, WALL, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 421*cdf0e10cSrcweir ENTRY1( CHART, FLOOR, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 422*cdf0e10cSrcweir ENTRY1( CHART, AXIS, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 423*cdf0e10cSrcweir ENTRY1( CHART, GRID, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 424*cdf0e10cSrcweir ENTRY1( CHART, SERIES, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 425*cdf0e10cSrcweir ENTRY1( CHART, DATA_POINT, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 426*cdf0e10cSrcweir ENTRY1( CHART, MEAN_VALUE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 427*cdf0e10cSrcweir ENTRY1( CHART, ERROR_INDICATOR, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 428*cdf0e10cSrcweir ENTRY1( CHART, REGRESSION_CURVE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 429*cdf0e10cSrcweir ENTRY1( CHART, STOCK_GAIN_MARKER, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 430*cdf0e10cSrcweir ENTRY1( CHART, STOCK_LOSS_MARKER, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 431*cdf0e10cSrcweir ENTRY1( CHART, STOCK_RANGE_LINE, XML_ETACTION_PROC_ATTRS, OOO_SHAPE_ACTIONS ), 432*cdf0e10cSrcweir 433*cdf0e10cSrcweir ENTRY0( CHART, CHART, XML_ETACTION_CHART ), 434*cdf0e10cSrcweir ENTRY0( CHART, PLOT_AREA, XML_ETACTION_CHART_PLOT_AREA ), 435*cdf0e10cSrcweir 436*cdf0e10cSrcweir ENTRY1Q( TEXT, TRACKED_CHANGES, XML_ETACTION_TRACKED_CHANGES, 437*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_PROTECTION_KEY ), 438*cdf0e10cSrcweir ENTRY1Q( TABLE, TRACKED_CHANGES, XML_ETACTION_TRACKED_CHANGES, 439*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_PROTECTION_KEY ), 440*cdf0e10cSrcweir 441*cdf0e10cSrcweir ENTRY1( TEXT, INDEX_ENTRY_TAB_STOP, XML_ETACTION_PROC_ATTRS, 442*cdf0e10cSrcweir OOO_INDEX_ENTRY_TAB_STOP_ACTIONS ), 443*cdf0e10cSrcweir ENTRY0( STYLE, TAB_STOP, XML_ETACTION_TAB_STOP ), 444*cdf0e10cSrcweir ENTRY1( STYLE, BACKGROUND_IMAGE, XML_ETACTION_PROC_ATTRS, 445*cdf0e10cSrcweir OOO_BACKGROUND_IMAGE_ACTIONS ), 446*cdf0e10cSrcweir ENTRY1( TEXT, LINENUMBERING_CONFIGURATION, XML_ETACTION_PROC_ATTRS, 447*cdf0e10cSrcweir OOO_LINENUMBERING_ACTIONS ), 448*cdf0e10cSrcweir ENTRY1( STYLE, FOOTNOTE_SEP, XML_ETACTION_PROC_ATTRS, 449*cdf0e10cSrcweir OOO_FOOTNOTE_SEP_ACTIONS ), 450*cdf0e10cSrcweir ENTRY1( STYLE, DROP_CAP, XML_ETACTION_PROC_ATTRS, OOO_DROP_CAP_ACTIONS ), 451*cdf0e10cSrcweir ENTRY1( STYLE, COLUMNS, XML_ETACTION_PROC_ATTRS, OOO_COLUMNS_ACTIONS ), 452*cdf0e10cSrcweir ENTRY1( STYLE, COLUMN, XML_ETACTION_PROC_ATTRS, OOO_COLUMNS_ACTIONS ), 453*cdf0e10cSrcweir 454*cdf0e10cSrcweir // rename office:value-* to *:value-* 455*cdf0e10cSrcweir ENTRY1( TEXT, VARIABLE_DECL, XML_ETACTION_PROC_ATTRS, 456*cdf0e10cSrcweir OOO_TEXT_VALUE_TYPE_ACTIONS ), /* generated entry */ 457*cdf0e10cSrcweir ENTRY1( TEXT, VARIABLE_SET, XML_ETACTION_PROC_ATTRS, 458*cdf0e10cSrcweir OOO_TEXT_VALUE_TYPE_ACTIONS), /* generated entry */ 459*cdf0e10cSrcweir ENTRY1( TEXT, VARIABLE_INPUT, XML_ETACTION_PROC_ATTRS, 460*cdf0e10cSrcweir OOO_TEXT_VALUE_TYPE_ACTIONS), /* generated entry */ 461*cdf0e10cSrcweir ENTRY1( TEXT, USER_FIELD_DECL, XML_ETACTION_PROC_ATTRS, 462*cdf0e10cSrcweir OOO_TEXT_VALUE_TYPE_ACTIONS), /* generated entry */ 463*cdf0e10cSrcweir ENTRY1( TEXT, EXPRESSION, XML_ETACTION_PROC_ATTRS, 464*cdf0e10cSrcweir OOO_TEXT_VALUE_TYPE_ACTIONS), /* generated entry */ 465*cdf0e10cSrcweir // ENTRY1( TEXT, USER_DEFINED, XML_ETACTION_PROC_ATTRS, 466*cdf0e10cSrcweir // OOO_TEXT_VALUE_TYPE_ACTIONS), /* text:user-defined has no attrs so far */ 467*cdf0e10cSrcweir ENTRY1( TABLE, TABLE_CELL, XML_ETACTION_PROC_ATTRS, 468*cdf0e10cSrcweir OOO_TABLE_VALUE_TYPE_ACTIONS), /* generated entry */ 469*cdf0e10cSrcweir ENTRY1( TABLE, COVERED_TABLE_CELL, XML_ETACTION_PROC_ATTRS, 470*cdf0e10cSrcweir OOO_TABLE_VALUE_TYPE_ACTIONS), /* generated entry */ 471*cdf0e10cSrcweir ENTRY1( TABLE, CHANGE_TRACK_TABLE_CELL, XML_ETACTION_PROC_ATTRS, 472*cdf0e10cSrcweir OOO_TABLE_VALUE_TYPE_ACTIONS), /* generated entry */ 473*cdf0e10cSrcweir // ENTRY1( FORM, PROPERTY, XML_ETACTION_PROC_ATTRS, 474*cdf0e10cSrcweir // OOO_VALUE_TYPE_ACTIONS), /* TODO: generated entry */ 475*cdf0e10cSrcweir // ENTRY1( FORM, LIST_PROPERTY, XML_ETACTION_PROC_ATTRS, 476*cdf0e10cSrcweir // OOO_VALUE_TYPE_ACTIONS), /* generated entry */ 477*cdf0e10cSrcweir 478*cdf0e10cSrcweir ENTRY1( OFFICE, ANNOTATION, XML_ETACTION_MOVE_ATTRS_TO_ELEMS, 479*cdf0e10cSrcweir OOO_ANNOTATION_ACTIONS ), /* generated entry */ 480*cdf0e10cSrcweir ENTRY1( OFFICE, CHANGE_INFO, XML_ETACTION_MOVE_ATTRS_TO_ELEMS, 481*cdf0e10cSrcweir OOO_CHANGE_INFO_ACTIONS ), /* generated entry */ 482*cdf0e10cSrcweir 483*cdf0e10cSrcweir ENTRY1( TEXT, DDE_CONNECTION_DECL, XML_ETACTION_PROC_ATTRS, 484*cdf0e10cSrcweir OOO_DDE_CONNECTION_DECL_ACTIONS ), 485*cdf0e10cSrcweir 486*cdf0e10cSrcweir ENTRY0( FORM, CONTROL, XML_ETACTION_FORM_CONTROL ), 487*cdf0e10cSrcweir ENTRY1( FORM, COLUMN, XML_ETACTION_PROC_ATTRS, 488*cdf0e10cSrcweir OOO_FORM_COLUMN_ACTIONS ), 489*cdf0e10cSrcweir ENTRY0( FORM, PROPERTY, XML_ETACTION_FORM_PROPERTY ), 490*cdf0e10cSrcweir 491*cdf0e10cSrcweir // process xlink:href 492*cdf0e10cSrcweir ENTRY1( META, TEMPLATE, XML_ETACTION_PROC_ATTRS, 493*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 494*cdf0e10cSrcweir ENTRY1( META, AUTO_RELOAD, XML_ETACTION_PROC_ATTRS, 495*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 496*cdf0e10cSrcweir ENTRY1( TEXT, SECTION_SOURCE, XML_ETACTION_PROC_ATTRS, 497*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 498*cdf0e10cSrcweir ENTRY1( TEXT, SCRIPT, XML_ETACTION_PROC_ATTRS, 499*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 500*cdf0e10cSrcweir ENTRY1( TEXT, ALPHABETICAL_INDEX_AUTO_MARK_FILE, XML_ETACTION_PROC_ATTRS, 501*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 502*cdf0e10cSrcweir ENTRY1( TABLE, TABLE_SOURCE, XML_ETACTION_PROC_ATTRS, 503*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 504*cdf0e10cSrcweir ENTRY1( TABLE, CELL_RANGE_SOURCE, XML_ETACTION_PROC_ATTRS, 505*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 506*cdf0e10cSrcweir ENTRY1( DRAW, A, XML_ETACTION_PROC_ATTRS, 507*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 508*cdf0e10cSrcweir ENTRY1( PRESENTATION, SOUND, XML_ETACTION_PROC_ATTRS, 509*cdf0e10cSrcweir OOO_XLINK_ACTIONS ), /* generated entry */ 510*cdf0e10cSrcweir ENTRY1( FORM, FORM, XML_ETACTION_PROC_ATTRS, 511*cdf0e10cSrcweir OOO_FORM_CONTROL_ACTIONS ), 512*cdf0e10cSrcweir ENTRY2QN( STYLE, SYMBOL_IMAGE, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 513*cdf0e10cSrcweir XML_NAMESPACE_CHART, XML_SYMBOL_IMAGE, 514*cdf0e10cSrcweir OOO_BACKGROUND_IMAGE_ACTIONS ), 515*cdf0e10cSrcweir 516*cdf0e10cSrcweir ENTRY2QN( CONFIG, CONFIG_ITEM_SET, XML_ETACTION_PROC_ATTRS_COND, 517*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_SETTINGS, 518*cdf0e10cSrcweir OOO_CONFIG_ITEM_SET_ACTIONS ), 519*cdf0e10cSrcweir 520*cdf0e10cSrcweir // add namespace prefix 521*cdf0e10cSrcweir // text:formula 522*cdf0e10cSrcweir ENTRY1( TEXT, SEQUENCE, XML_ETACTION_PROC_ATTRS, 523*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), /* generated entry */ 524*cdf0e10cSrcweir // text:condition 525*cdf0e10cSrcweir ENTRY1( TEXT, DATABASE_NEXT, XML_ETACTION_PROC_ATTRS, 526*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), /* generated entry */ 527*cdf0e10cSrcweir // text:condition 528*cdf0e10cSrcweir ENTRY2QN( TEXT, DATABASE_SELECT, XML_ETACTION_RENAME_ELEM_PROC_ATTRS, 529*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_DATABASE_ROW_SELECT, 530*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), 531*cdf0e10cSrcweir // text:condition 532*cdf0e10cSrcweir ENTRY1( TEXT, CONDITIONAL_TEXT, XML_ETACTION_PROC_ATTRS, 533*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), /* generated entry */ 534*cdf0e10cSrcweir // text:condition 535*cdf0e10cSrcweir ENTRY1( TEXT, HIDDEN_TEXT, XML_ETACTION_PROC_ATTRS, 536*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), /* generated entry */ 537*cdf0e10cSrcweir // text:condition 538*cdf0e10cSrcweir ENTRY1( TEXT, HIDDEN_PARAGRAPH, XML_ETACTION_PROC_ATTRS, 539*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), /* generated entry */ 540*cdf0e10cSrcweir // table:condition 541*cdf0e10cSrcweir ENTRY1( TABLE, CONTENT_VALIDATION, XML_ETACTION_PROC_ATTRS, 542*cdf0e10cSrcweir OOO_FORMULA_ACTIONS ), /* generated entry */ 543*cdf0e10cSrcweir 544*cdf0e10cSrcweir // rename <table:dependences> to <table:dependencies> 545*cdf0e10cSrcweir ENTRY1Q( TABLE, DEPENDENCES, XML_ETACTION_RENAME_ELEM, 546*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_DEPENDENCIES ), 547*cdf0e10cSrcweir ENTRY1Q( TABLE, DEPENDENCE, XML_ETACTION_RENAME_ELEM, 548*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_DEPENDENCY ), 549*cdf0e10cSrcweir 550*cdf0e10cSrcweir // process table::error-macro 551*cdf0e10cSrcweir ENTRY1( TABLE, ERROR_MACRO, XML_ETACTION_PROC_ATTRS, 552*cdf0e10cSrcweir OOO_ERROR_MACRO_ACTIONS ), 553*cdf0e10cSrcweir 554*cdf0e10cSrcweir // process table::conversion-mode 555*cdf0e10cSrcweir ENTRY1( TABLE, CONVERSION_MODE, XML_ETACTION_PROC_ATTRS, 556*cdf0e10cSrcweir OOO_DDE_CONV_MODE_ACTIONS ), 557*cdf0e10cSrcweir 558*cdf0e10cSrcweir // fix <text:alphabatical-index-mark text:main-etry> 559*cdf0e10cSrcweir ENTRY1( TEXT, ALPHABETICAL_INDEX_MARK, XML_ETACTION_PROC_ATTRS, 560*cdf0e10cSrcweir OOO_ALPHABETICAL_INDEX_MARK_ACTIONS ), 561*cdf0e10cSrcweir ENTRY1( TEXT, ALPHABETICAL_INDEX_MARK_START, XML_ETACTION_PROC_ATTRS, 562*cdf0e10cSrcweir OOO_ALPHABETICAL_INDEX_MARK_ACTIONS ), 563*cdf0e10cSrcweir 564*cdf0e10cSrcweir // process table::data-pilot-member 565*cdf0e10cSrcweir ENTRY1( TABLE, DATA_PILOT_MEMBER, XML_ETACTION_PROC_ATTRS, 566*cdf0e10cSrcweir OOO_DATAPILOT_MEMBER_ACTIONS ), 567*cdf0e10cSrcweir 568*cdf0e10cSrcweir // process table::data-pilot-level 569*cdf0e10cSrcweir ENTRY1( TABLE, DATA_PILOT_LEVEL, XML_ETACTION_PROC_ATTRS, 570*cdf0e10cSrcweir OOO_DATAPILOT_LEVEL_ACTIONS ), 571*cdf0e10cSrcweir 572*cdf0e10cSrcweir // process table::source-service 573*cdf0e10cSrcweir ENTRY1( TABLE, SOURCE_SERVICE, XML_ETACTION_PROC_ATTRS, 574*cdf0e10cSrcweir OOO_SOURCE_SERVICE_ACTIONS ), 575*cdf0e10cSrcweir 576*cdf0e10cSrcweir // fix id strings in old animation elements 577*cdf0e10cSrcweir ENTRY1( PRESENTATION, DIM, XML_ETACTION_PROC_ATTRS, OOO_ANIMATION_ACTIONS ), 578*cdf0e10cSrcweir ENTRY1( PRESENTATION, PLAY, XML_ETACTION_PROC_ATTRS, OOO_ANIMATION_ACTIONS ), 579*cdf0e10cSrcweir ENTRY1( PRESENTATION, SHOW_TEXT, XML_ETACTION_PROC_ATTRS, OOO_ANIMATION_ACTIONS ), 580*cdf0e10cSrcweir ENTRY1( PRESENTATION, SHOW_SHAPE, XML_ETACTION_PROC_ATTRS, OOO_ANIMATION_ACTIONS ), 581*cdf0e10cSrcweir ENTRY1( PRESENTATION, HIDE_TEXT, XML_ETACTION_PROC_ATTRS, OOO_ANIMATION_ACTIONS ), 582*cdf0e10cSrcweir ENTRY1( PRESENTATION, HIDE_SHAPE, XML_ETACTION_PROC_ATTRS, OOO_ANIMATION_ACTIONS ), 583*cdf0e10cSrcweir 584*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ETACTION_EOT ) 585*cdf0e10cSrcweir }; 586*cdf0e10cSrcweir 587*cdf0e10cSrcweir // XML_ETACTION_STYLE 588*cdf0e10cSrcweir static XMLTransformerActionInit aStyleActionTable[] = 589*cdf0e10cSrcweir { 590*cdf0e10cSrcweir ENTRY0( STYLE, FAMILY, XML_ATACTION_STYLE_FAMILY ), 591*cdf0e10cSrcweir ENTRY0( STYLE, NAME, XML_ATACTION_ENCODE_STYLE_NAME ), 592*cdf0e10cSrcweir ENTRY0( STYLE, PARENT_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 593*cdf0e10cSrcweir ENTRY0( STYLE, NEXT_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 594*cdf0e10cSrcweir ENTRY0( STYLE, LIST_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 595*cdf0e10cSrcweir ENTRY0( STYLE, MASTER_PAGE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 596*cdf0e10cSrcweir ENTRY0( STYLE, DATA_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 597*cdf0e10cSrcweir ENTRY0( DRAW, NAME, XML_ATACTION_ENCODE_STYLE_NAME ), 598*cdf0e10cSrcweir ENTRY0( DRAW, DISTANCE, XML_ATACTION_INCH2IN ), 599*cdf0e10cSrcweir ENTRY0( DRAW, DOTS1_LENGTH, XML_ATACTION_INCH2IN ), 600*cdf0e10cSrcweir ENTRY0( DRAW, DOTS2_LENGTH, XML_ATACTION_INCH2IN ), 601*cdf0e10cSrcweir ENTRY0( SVG, WIDTH, XML_ATACTION_SVG_WIDTH_HEIGHT_OOO ), 602*cdf0e10cSrcweir ENTRY0( SVG, HEIGHT, XML_ATACTION_SVG_WIDTH_HEIGHT_OOO ), 603*cdf0e10cSrcweir ENTRY0( DRAW, START, XML_ATACTION_NEG_PERCENT ), 604*cdf0e10cSrcweir ENTRY0( DRAW, END, XML_ATACTION_NEG_PERCENT ), 605*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_True ), 606*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 607*cdf0e10cSrcweir }; 608*cdf0e10cSrcweir 609*cdf0e10cSrcweir // OOO_FRAME_ELEM_ACTIONS 610*cdf0e10cSrcweir static XMLTransformerActionInit aFrameElemActionTable[] = 611*cdf0e10cSrcweir { 612*cdf0e10cSrcweir ENTRY1Q( OFFICE, EVENTS, XML_ETACTION_RENAME_ELEM, 613*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_EVENT_LISTENERS ), 614*cdf0e10cSrcweir ENTRY0( DRAW, GLUE_POINT, XML_ETACTION_COPY ), 615*cdf0e10cSrcweir ENTRY0( DRAW, IMAGE_MAP, XML_ETACTION_COPY ), 616*cdf0e10cSrcweir ENTRY0( SVG, DESC, XML_ETACTION_COPY_TEXT ), 617*cdf0e10cSrcweir ENTRY0( DRAW, CONTOUR_POLYGON, XML_ETACTION_COPY ), 618*cdf0e10cSrcweir ENTRY0( DRAW, CONTOUR_PATH, XML_ETACTION_COPY ), 619*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ETACTION_EOT ) 620*cdf0e10cSrcweir }; 621*cdf0e10cSrcweir 622*cdf0e10cSrcweir // OOO_FRAME_ATTR_ACTIONS 623*cdf0e10cSrcweir static XMLTransformerActionInit aFrameAttrActionTable[] = 624*cdf0e10cSrcweir { 625*cdf0e10cSrcweir ENTRY0( DRAW, ZINDEX, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 626*cdf0e10cSrcweir ENTRY0( DRAW, ID, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 627*cdf0e10cSrcweir ENTRY0( DRAW, LAYER, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 628*cdf0e10cSrcweir ENTRY0( DRAW, STYLE_NAME, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 629*cdf0e10cSrcweir ENTRY0( PRESENTATION, STYLE_NAME, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 630*cdf0e10cSrcweir ENTRY0( DRAW, TRANSFORM, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 631*cdf0e10cSrcweir ENTRY0( DRAW, NAME, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 632*cdf0e10cSrcweir ENTRY0( TABLE, END_CELL_ADDRESS, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 633*cdf0e10cSrcweir ENTRY0( TABLE, END_X, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 634*cdf0e10cSrcweir ENTRY0( TABLE, END_Y, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 635*cdf0e10cSrcweir ENTRY0( TABLE, TABLE_BACKGROUND, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 636*cdf0e10cSrcweir ENTRY0( TEXT, ANCHOR_TYPE, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 637*cdf0e10cSrcweir ENTRY0( TEXT, ANCHOR_PAGE_NUMBER, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 638*cdf0e10cSrcweir ENTRY0( DRAW, TEXT_STYLE_NAME, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 639*cdf0e10cSrcweir ENTRY0( SVG, X, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 640*cdf0e10cSrcweir ENTRY0( SVG, Y, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 641*cdf0e10cSrcweir ENTRY0( SVG, WIDTH, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 642*cdf0e10cSrcweir ENTRY0( SVG, HEIGHT, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 643*cdf0e10cSrcweir ENTRY0( STYLE, REL_WIDTH, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 644*cdf0e10cSrcweir ENTRY0( STYLE, REL_HEIGHT, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 645*cdf0e10cSrcweir ENTRY0( PRESENTATION, CLASS, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 646*cdf0e10cSrcweir ENTRY0( PRESENTATION, PLACEHOLDER, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 647*cdf0e10cSrcweir ENTRY0( PRESENTATION, USER_TRANSFORMED, XML_ATACTION_MOVE_TO_ELEM ), /* generated entry */ 648*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 649*cdf0e10cSrcweir }; 650*cdf0e10cSrcweir 651*cdf0e10cSrcweir // OOO_EVENT_ELEM_ACTIONS 652*cdf0e10cSrcweir static XMLTransformerActionInit aEventActionTable[] = 653*cdf0e10cSrcweir { 654*cdf0e10cSrcweir ENTRY0( XLINK, HREF, XML_ATACTION_HREF ), 655*cdf0e10cSrcweir ENTRY1( SCRIPT, LANGUAGE, XML_ATACTION_ADD_NAMESPACE_PREFIX, 656*cdf0e10cSrcweir XML_NAMESPACE_OOO ), 657*cdf0e10cSrcweir ENTRY0( SCRIPT, EVENT_NAME, XML_ATACTION_EVENT_NAME ), 658*cdf0e10cSrcweir ENTRY0( SCRIPT, MACRO_NAME, XML_ATACTION_MACRO_NAME ), 659*cdf0e10cSrcweir ENTRY0( SCRIPT, LOCATION, XML_ATACTION_MACRO_LOCATION ), 660*cdf0e10cSrcweir ENTRY0( SCRIPT, LIBRARY, XML_ATACTION_MACRO_LOCATION ), // bug in draw 661*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 662*cdf0e10cSrcweir }; 663*cdf0e10cSrcweir 664*cdf0e10cSrcweir 665*cdf0e10cSrcweir // action table for OOO_MASTER_PAGE_ACTIONS 666*cdf0e10cSrcweir static XMLTransformerActionInit aMasterPageActionTable[] = 667*cdf0e10cSrcweir { 668*cdf0e10cSrcweir ENTRY0( STYLE, NAME, XML_ATACTION_ENCODE_STYLE_NAME ), 669*cdf0e10cSrcweir ENTRY0( STYLE, NEXT_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 670*cdf0e10cSrcweir ENTRY1Q( STYLE, PAGE_MASTER_NAME, XML_ATACTION_RENAME_ENCODE_STYLE_NAME_REF, 671*cdf0e10cSrcweir XML_NAMESPACE_STYLE, XML_PAGE_LAYOUT_NAME ), 672*cdf0e10cSrcweir ENTRY0( DRAW, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 673*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 674*cdf0e10cSrcweir }; 675*cdf0e10cSrcweir 676*cdf0e10cSrcweir static XMLTransformerActionInit aFontDeclActionTable[] = 677*cdf0e10cSrcweir { 678*cdf0e10cSrcweir ENTRY1Q( FO, FONT_FAMILY, XML_ATACTION_RENAME, 679*cdf0e10cSrcweir XML_NAMESPACE_SVG, XML_FONT_FAMILY ), 680*cdf0e10cSrcweir ENTRY1Q( STYLE, FONT_STYLE_NAME, XML_ATACTION_RENAME, 681*cdf0e10cSrcweir XML_NAMESPACE_STYLE, XML_FONT_ADORNMENTS ), 682*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 683*cdf0e10cSrcweir }; 684*cdf0e10cSrcweir 685*cdf0e10cSrcweir // action table for OOO_PARA_ACTIONS 686*cdf0e10cSrcweir static XMLTransformerActionInit aParaActionTable[] = 687*cdf0e10cSrcweir { 688*cdf0e10cSrcweir ENTRY0( TEXT, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 689*cdf0e10cSrcweir ENTRY0( TEXT, COND_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 690*cdf0e10cSrcweir // ENTRY0( TEXT, CLASS_NAMES, XML_ATACTION_REMOVE ), 691*cdf0e10cSrcweir ENTRY1Q( TEXT, LEVEL, XML_ATACTION_RENAME, 692*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_OUTLINE_LEVEL ), 693*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 694*cdf0e10cSrcweir }; 695*cdf0e10cSrcweir 696*cdf0e10cSrcweir // action table for OOO_STYLE_REF_ACTIONS 697*cdf0e10cSrcweir static XMLTransformerActionInit aStyleRefActionTable[] = 698*cdf0e10cSrcweir { 699*cdf0e10cSrcweir ENTRY0( TEXT, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 700*cdf0e10cSrcweir ENTRY0( TEXT, VISITED_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 701*cdf0e10cSrcweir ENTRY0( TEXT, MAIN_ENTRY_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 702*cdf0e10cSrcweir ENTRY0( TEXT, CITATION_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 703*cdf0e10cSrcweir ENTRY0( TEXT, CITATION_BODY_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 704*cdf0e10cSrcweir ENTRY0( TEXT, DEFAULT_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 705*cdf0e10cSrcweir ENTRY0( TEXT, MASTER_PAGE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 706*cdf0e10cSrcweir ENTRY0( STYLE, DATA_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 707*cdf0e10cSrcweir ENTRY0( STYLE, APPLY_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 708*cdf0e10cSrcweir ENTRY0( STYLE, PAGE_LAYOUT_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 709*cdf0e10cSrcweir ENTRY0( TABLE, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 710*cdf0e10cSrcweir ENTRY0( TABLE, DEFAULT_CELL_STYLE_NAME, 711*cdf0e10cSrcweir XML_ATACTION_ENCODE_STYLE_NAME_REF ), 712*cdf0e10cSrcweir ENTRY0( DRAW, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 713*cdf0e10cSrcweir ENTRY0( DRAW, MASTER_PAGE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 714*cdf0e10cSrcweir ENTRY0( PRESENTATION, PRESENTATION_PAGE_LAYOUT_NAME, 715*cdf0e10cSrcweir XML_ATACTION_ENCODE_STYLE_NAME_REF ), 716*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_False ), 717*cdf0e10cSrcweir ENTRY1( TEXT, CONDITION, XML_ATACTION_ADD_NAMESPACE_PREFIX, 718*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 719*cdf0e10cSrcweir ENTRY1( TEXT, FORMULA, XML_ATACTION_ADD_NAMESPACE_PREFIX, 720*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 721*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 722*cdf0e10cSrcweir }; 723*cdf0e10cSrcweir 724*cdf0e10cSrcweir // OOO_SHAPE_ACTIONS 725*cdf0e10cSrcweir // !!ATTENTION!! If you change something here, please also change 726*cdf0e10cSrcweir // aConnectorActionTable if apropriate 727*cdf0e10cSrcweir static XMLTransformerActionInit aShapeActionTable[] = 728*cdf0e10cSrcweir { 729*cdf0e10cSrcweir ENTRY0( SVG, X, XML_ATACTION_INCH2IN ), 730*cdf0e10cSrcweir ENTRY0( SVG, Y, XML_ATACTION_INCH2IN ), 731*cdf0e10cSrcweir ENTRY0( SVG, X1, XML_ATACTION_INCH2IN ), 732*cdf0e10cSrcweir ENTRY0( SVG, Y1, XML_ATACTION_INCH2IN ), 733*cdf0e10cSrcweir ENTRY0( SVG, X2, XML_ATACTION_INCH2IN ), 734*cdf0e10cSrcweir ENTRY0( SVG, Y2, XML_ATACTION_INCH2IN ), 735*cdf0e10cSrcweir ENTRY0( SVG, CX, XML_ATACTION_INCH2IN ), 736*cdf0e10cSrcweir ENTRY0( SVG, CY, XML_ATACTION_INCH2IN ), 737*cdf0e10cSrcweir ENTRY0( SVG, R, XML_ATACTION_INCH2IN ), 738*cdf0e10cSrcweir ENTRY0( SVG, RX, XML_ATACTION_INCH2IN ), 739*cdf0e10cSrcweir ENTRY0( SVG, RY, XML_ATACTION_INCH2IN ), 740*cdf0e10cSrcweir ENTRY0( SVG, WIDTH, XML_ATACTION_SVG_WIDTH_HEIGHT_OOO ), 741*cdf0e10cSrcweir ENTRY0( SVG, HEIGHT, XML_ATACTION_SVG_WIDTH_HEIGHT_OOO ), 742*cdf0e10cSrcweir ENTRY0( FO, MIN_WIDTH, XML_ATACTION_INCH2IN ), 743*cdf0e10cSrcweir ENTRY0( FO, MIN_HEIGHT, XML_ATACTION_INCH2IN ), 744*cdf0e10cSrcweir ENTRY0( FO, MAX_WIDTH, XML_ATACTION_INCH2IN ), 745*cdf0e10cSrcweir ENTRY0( FO, MAX_HEIGHT, XML_ATACTION_INCH2IN ), 746*cdf0e10cSrcweir ENTRY0( DRAW, CORNER_RADIUS, XML_ATACTION_INCH2IN ), 747*cdf0e10cSrcweir ENTRY0( DRAW, LINE_SKEW, XML_ATACTION_INCHS2INS ), 748*cdf0e10cSrcweir ENTRY0( DRAW, CAPTION_POINT_X, XML_ATACTION_INCH2IN ), 749*cdf0e10cSrcweir ENTRY0( DRAW, CAPTION_POINT_Y, XML_ATACTION_INCH2IN ), 750*cdf0e10cSrcweir ENTRY0( DRAW, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 751*cdf0e10cSrcweir ENTRY0( DRAW, TEXT_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 752*cdf0e10cSrcweir ENTRY0( DRAW, END_X, XML_ATACTION_INCH2IN ), 753*cdf0e10cSrcweir ENTRY0( DRAW, END_Y, XML_ATACTION_INCH2IN ), 754*cdf0e10cSrcweir ENTRY0( PRESENTATION, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 755*cdf0e10cSrcweir ENTRY0( DR3D, DISTANCE, XML_ATACTION_INCH2IN ), 756*cdf0e10cSrcweir ENTRY0( DR3D, FOCAL_LENGTH, XML_ATACTION_INCH2IN ), 757*cdf0e10cSrcweir ENTRY1Q( FORM, ID, XML_ATACTION_RENAME, 758*cdf0e10cSrcweir XML_NAMESPACE_DRAW, XML_CONTROL ), 759*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_True ), 760*cdf0e10cSrcweir 761*cdf0e10cSrcweir // BM: needed by chart:legend. The legend needs also the draw actions. As 762*cdf0e10cSrcweir // there is no merge mechanism, all actions have to be in the same table 763*cdf0e10cSrcweir ENTRY2( CHART, LEGEND_POSITION, XML_ATACTION_RENAME_ATTRIBUTE, 764*cdf0e10cSrcweir RENAME_ENTRY( XML_LEFT, XML_START ), 765*cdf0e10cSrcweir RENAME_ENTRY( XML_RIGHT, XML_END )), 766*cdf0e10cSrcweir ENTRY0( DRAW, ID, XML_ATACTION_SHAPEID ), 767*cdf0e10cSrcweir ENTRY0( DRAW, START_SHAPE, XML_ATACTION_SHAPEID ), 768*cdf0e10cSrcweir ENTRY0( DRAW, END_SHAPE, XML_ATACTION_SHAPEID ), 769*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 770*cdf0e10cSrcweir }; 771*cdf0e10cSrcweir 772*cdf0e10cSrcweir static XMLTransformerActionInit aConnectorActionTable[] = 773*cdf0e10cSrcweir { 774*cdf0e10cSrcweir ENTRY0( SVG, X1, XML_ATACTION_TWIPS2IN ), 775*cdf0e10cSrcweir ENTRY0( SVG, Y1, XML_ATACTION_TWIPS2IN ), 776*cdf0e10cSrcweir ENTRY0( SVG, X2, XML_ATACTION_TWIPS2IN ), 777*cdf0e10cSrcweir ENTRY0( SVG, Y2, XML_ATACTION_TWIPS2IN ), 778*cdf0e10cSrcweir ENTRY0( SVG, WIDTH, XML_ATACTION_SVG_WIDTH_HEIGHT_OOO ), 779*cdf0e10cSrcweir ENTRY0( SVG, HEIGHT, XML_ATACTION_SVG_WIDTH_HEIGHT_OOO ), 780*cdf0e10cSrcweir ENTRY0( FO, MIN_WIDTH, XML_ATACTION_INCH2IN ), 781*cdf0e10cSrcweir ENTRY0( FO, MIN_HEIGHT, XML_ATACTION_INCH2IN ), 782*cdf0e10cSrcweir ENTRY0( FO, MAX_WIDTH, XML_ATACTION_INCH2IN ), 783*cdf0e10cSrcweir ENTRY0( FO, MAX_HEIGHT, XML_ATACTION_INCH2IN ), 784*cdf0e10cSrcweir ENTRY0( DRAW, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 785*cdf0e10cSrcweir ENTRY0( DRAW, TEXT_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 786*cdf0e10cSrcweir ENTRY0( DRAW, END_X, XML_ATACTION_INCH2IN ), 787*cdf0e10cSrcweir ENTRY0( DRAW, END_Y, XML_ATACTION_INCH2IN ), 788*cdf0e10cSrcweir ENTRY0( PRESENTATION, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 789*cdf0e10cSrcweir ENTRY1Q( FORM, ID, XML_ATACTION_RENAME, 790*cdf0e10cSrcweir XML_NAMESPACE_DRAW, XML_CONTROL ), 791*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_True ), 792*cdf0e10cSrcweir ENTRY0( DRAW, ID, XML_ATACTION_SHAPEID ), 793*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 794*cdf0e10cSrcweir }; 795*cdf0e10cSrcweir 796*cdf0e10cSrcweir // OOO_INDEX_ENTRY_TAB_STOP_ACTIONS 797*cdf0e10cSrcweir static XMLTransformerActionInit aIndexEntryTabStopActionTable[] = 798*cdf0e10cSrcweir { 799*cdf0e10cSrcweir ENTRY0( STYLE, POSITION, XML_ATACTION_INCH2IN ), 800*cdf0e10cSrcweir ENTRY0( TEXT, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 801*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 802*cdf0e10cSrcweir }; 803*cdf0e10cSrcweir 804*cdf0e10cSrcweir // OOO_TAB_STOP_ACTIONS 805*cdf0e10cSrcweir static XMLTransformerActionInit aTabStopActionTable[] = 806*cdf0e10cSrcweir { 807*cdf0e10cSrcweir ENTRY0( STYLE, POSITION, XML_ATACTION_INCH2IN ), 808*cdf0e10cSrcweir ENTRY1Q( STYLE, LEADER_CHAR, XML_ATACTION_RENAME, 809*cdf0e10cSrcweir XML_NAMESPACE_STYLE, XML_LEADER_TEXT ), 810*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 811*cdf0e10cSrcweir }; 812*cdf0e10cSrcweir 813*cdf0e10cSrcweir // OOO_LINENUMBERING_ACTIONS 814*cdf0e10cSrcweir static XMLTransformerActionInit aLineNumberingActionTable[] = 815*cdf0e10cSrcweir { 816*cdf0e10cSrcweir ENTRY0( TEXT, OFFSET, XML_ATACTION_INCH2IN ), 817*cdf0e10cSrcweir ENTRY0( TEXT, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 818*cdf0e10cSrcweir ENTRY1Q( TEXT, COUNT_IN_FLOATING_FRAMES, XML_ATACTION_RENAME, 819*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_COUNT_IN_TEXT_BOXES ), 820*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 821*cdf0e10cSrcweir }; 822*cdf0e10cSrcweir 823*cdf0e10cSrcweir static XMLTransformerActionInit aFootnoteSepActionTable[] = 824*cdf0e10cSrcweir { 825*cdf0e10cSrcweir ENTRY0( STYLE, WIDTH, XML_ATACTION_INCH2IN ), 826*cdf0e10cSrcweir ENTRY0( STYLE, DISTANCE_BEFORE_SEP, XML_ATACTION_INCH2IN ), 827*cdf0e10cSrcweir ENTRY0( STYLE, DISTANCE_AFTER_SEP, XML_ATACTION_INCH2IN ), 828*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 829*cdf0e10cSrcweir }; 830*cdf0e10cSrcweir 831*cdf0e10cSrcweir // OOO_DROP_CAP_ACTIONS 832*cdf0e10cSrcweir static XMLTransformerActionInit aDropCapActionTable[] = 833*cdf0e10cSrcweir { 834*cdf0e10cSrcweir ENTRY0( STYLE, DISTANCE, XML_ATACTION_INCH2IN ), 835*cdf0e10cSrcweir ENTRY0( STYLE, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 836*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 837*cdf0e10cSrcweir }; 838*cdf0e10cSrcweir 839*cdf0e10cSrcweir static XMLTransformerActionInit aColumnsActionTable[] = 840*cdf0e10cSrcweir { 841*cdf0e10cSrcweir ENTRY0( STYLE, COLUMN_GAP, XML_ATACTION_INCH2IN ), 842*cdf0e10cSrcweir // ENTRY0( STYLE, SPACE_BEFORE, XML_ATACTION_INCH2IN ), 843*cdf0e10cSrcweir // ENTRY0( STYLE, SPACE_AFTER, XML_ATACTION_INCH2IN ), 844*cdf0e10cSrcweir ENTRY1Q( FO, MARGIN_LEFT, XML_ATACTION_RENAME_INCH2IN, 845*cdf0e10cSrcweir XML_NAMESPACE_FO, XML_START_INDENT ), 846*cdf0e10cSrcweir ENTRY1Q( FO, MARGIN_RIGHT, XML_ATACTION_RENAME_INCH2IN, 847*cdf0e10cSrcweir XML_NAMESPACE_FO, XML_END_INDENT ), 848*cdf0e10cSrcweir ENTRY0( STYLE, WIDTH, XML_ATACTION_INCH2IN ), 849*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 850*cdf0e10cSrcweir }; 851*cdf0e10cSrcweir 852*cdf0e10cSrcweir // OOO_TEXT_VALUE_TYPE_ACTIONS 853*cdf0e10cSrcweir static XMLTransformerActionInit aTextValueTypeActionTable[] = 854*cdf0e10cSrcweir { 855*cdf0e10cSrcweir ENTRY1Q( TEXT, VALUE_TYPE, XML_ATACTION_RENAME, 856*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_VALUE_TYPE ), 857*cdf0e10cSrcweir ENTRY1Q( TEXT, VALUE, XML_ATACTION_RENAME, 858*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_VALUE ), 859*cdf0e10cSrcweir ENTRY1Q( TEXT, CURRENCY, XML_ATACTION_RENAME, 860*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_CURRENCY ), 861*cdf0e10cSrcweir ENTRY1Q( TEXT, DATE_VALUE, XML_ATACTION_RENAME, 862*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_DATE_VALUE ), 863*cdf0e10cSrcweir ENTRY1Q( TEXT, TIME_VALUE, XML_ATACTION_RENAME, 864*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_TIME_VALUE ), 865*cdf0e10cSrcweir ENTRY1Q( TEXT, BOOLEAN_VALUE, XML_ATACTION_RENAME, 866*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_BOOLEAN_VALUE ), 867*cdf0e10cSrcweir ENTRY1Q( TEXT, STRING_VALUE, XML_ATACTION_RENAME, 868*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_STRING_VALUE ), 869*cdf0e10cSrcweir ENTRY0( STYLE, DATA_STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 870*cdf0e10cSrcweir ENTRY1( TEXT, FORMULA, XML_ATACTION_ADD_NAMESPACE_PREFIX, 871*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 872*cdf0e10cSrcweir ENTRY0( TEXT, TOKEN_INVALID, XML_ATACTION_EOT ) 873*cdf0e10cSrcweir }; 874*cdf0e10cSrcweir 875*cdf0e10cSrcweir // OOO_TABLE_VALUE_TYPE_ACTIONS 876*cdf0e10cSrcweir static XMLTransformerActionInit aTableValueTypeActionTable[] = 877*cdf0e10cSrcweir { 878*cdf0e10cSrcweir ENTRY1Q( TABLE, VALUE_TYPE, XML_ATACTION_RENAME, 879*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_VALUE_TYPE ), 880*cdf0e10cSrcweir ENTRY1Q( TABLE, VALUE, XML_ATACTION_RENAME, 881*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_VALUE ), 882*cdf0e10cSrcweir ENTRY1Q( TABLE, CURRENCY, XML_ATACTION_RENAME, 883*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_CURRENCY ), 884*cdf0e10cSrcweir ENTRY1Q( TABLE, DATE_VALUE, XML_ATACTION_RENAME, 885*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_DATE_VALUE ), 886*cdf0e10cSrcweir ENTRY1Q( TABLE, TIME_VALUE, XML_ATACTION_RENAME, 887*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_TIME_VALUE ), 888*cdf0e10cSrcweir ENTRY1Q( TABLE, BOOLEAN_VALUE, XML_ATACTION_RENAME, 889*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_BOOLEAN_VALUE ), 890*cdf0e10cSrcweir ENTRY1Q( TABLE, STRING_VALUE, XML_ATACTION_RENAME, 891*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_STRING_VALUE ), 892*cdf0e10cSrcweir ENTRY0( TABLE, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 893*cdf0e10cSrcweir ENTRY1( TABLE, FORMULA, XML_ATACTION_ADD_APP_NAMESPACE_PREFIX, 894*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 895*cdf0e10cSrcweir ENTRY1Q( TABLE, VALIDATION_NAME, XML_ATACTION_RENAME, 896*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_CONTENT_VALIDATION_NAME ), 897*cdf0e10cSrcweir ENTRY0( TABLE, TOKEN_INVALID, XML_ATACTION_EOT ) 898*cdf0e10cSrcweir }; 899*cdf0e10cSrcweir 900*cdf0e10cSrcweir // action table for OOO_ANNOTATION_ACTIONS 901*cdf0e10cSrcweir static XMLTransformerActionInit aAnnotationActionTable[] = 902*cdf0e10cSrcweir { 903*cdf0e10cSrcweir ENTRY1Q( OFFICE, AUTHOR, XML_ATACTION_MOVE_TO_ELEM, 904*cdf0e10cSrcweir XML_NAMESPACE_DC, XML_CREATOR ), 905*cdf0e10cSrcweir ENTRY1Q( OFFICE, CREATE_DATE, XML_ATACTION_MOVE_TO_ELEM, 906*cdf0e10cSrcweir XML_NAMESPACE_DC, XML_DATE ), 907*cdf0e10cSrcweir ENTRY1Q( OFFICE, CREATE_DATE_STRING, XML_ATACTION_MOVE_TO_ELEM, 908*cdf0e10cSrcweir XML_NAMESPACE_META, XML_DATE_STRING ), 909*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 910*cdf0e10cSrcweir }; 911*cdf0e10cSrcweir 912*cdf0e10cSrcweir // action table for OOO_CHANGE_INFO_ACTIONS 913*cdf0e10cSrcweir static XMLTransformerActionInit aChangeInfoActionTable[] = 914*cdf0e10cSrcweir { 915*cdf0e10cSrcweir ENTRY1Q( OFFICE, CHG_AUTHOR, XML_ATACTION_MOVE_TO_ELEM, 916*cdf0e10cSrcweir XML_NAMESPACE_DC, XML_CREATOR ), 917*cdf0e10cSrcweir ENTRY1Q( OFFICE, CHG_DATE_TIME, XML_ATACTION_MOVE_TO_ELEM, 918*cdf0e10cSrcweir XML_NAMESPACE_DC, XML_DATE ), 919*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 920*cdf0e10cSrcweir }; 921*cdf0e10cSrcweir 922*cdf0e10cSrcweir // OOO_BACKGROUND_IMAGE_ACTIONS 923*cdf0e10cSrcweir static XMLTransformerActionInit aBackgroundImageActionTable[] = 924*cdf0e10cSrcweir { 925*cdf0e10cSrcweir ENTRY1Q( DRAW, TRANSPARENCY, XML_ATACTION_RENAME_NEG_PERCENT, 926*cdf0e10cSrcweir XML_NAMESPACE_DRAW, XML_OPACITY ), 927*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_True ), 928*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 929*cdf0e10cSrcweir }; 930*cdf0e10cSrcweir 931*cdf0e10cSrcweir // --> OD 2005-06-10 #i50322# 932*cdf0e10cSrcweir // OOO_BACKGROUND_IMAGE_ACTIONS for OpenOffice.org text documents 933*cdf0e10cSrcweir // OpenOffice.org text documents, written by OpenOffice.org, contain 934*cdf0e10cSrcweir // wrong value for the transparency of the background graphic 935*cdf0e10cSrcweir static XMLTransformerActionInit aWriterBackgroundImageActionTable[] = 936*cdf0e10cSrcweir { 937*cdf0e10cSrcweir ENTRY1Q( DRAW, TRANSPARENCY, XML_ATACTION_WRITER_BACK_GRAPHIC_TRANSPARENCY, XML_NAMESPACE_DRAW, XML_OPACITY ), 938*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_True ), 939*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 940*cdf0e10cSrcweir }; 941*cdf0e10cSrcweir // <-- 942*cdf0e10cSrcweir 943*cdf0e10cSrcweir // OOO_DDE_CONNECTION_DECL 944*cdf0e10cSrcweir static XMLTransformerActionInit aDDEConnectionDeclActionTable[] = 945*cdf0e10cSrcweir { 946*cdf0e10cSrcweir ENTRY1Q( TEXT, NAME, XML_ATACTION_RENAME, 947*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_NAME ), 948*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 949*cdf0e10cSrcweir }; 950*cdf0e10cSrcweir 951*cdf0e10cSrcweir // OOO_FORM_CONTROL_ACTIONS 952*cdf0e10cSrcweir static XMLTransformerActionInit aFormControlActionTable[] = 953*cdf0e10cSrcweir { 954*cdf0e10cSrcweir ENTRY2QN( FORM, SERVICE_NAME, 955*cdf0e10cSrcweir XML_ATACTION_RENAME_ADD_NAMESPACE_PREFIX, 956*cdf0e10cSrcweir XML_NAMESPACE_FORM, XML_CONTROL_IMPLEMENTATION, 957*cdf0e10cSrcweir XML_NAMESPACE_OOO ), 958*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_False ), 959*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 960*cdf0e10cSrcweir }; 961*cdf0e10cSrcweir 962*cdf0e10cSrcweir // OOO_FORM_COLUMN_ACTIONS 963*cdf0e10cSrcweir static XMLTransformerActionInit aFormColumnActionTable[] = 964*cdf0e10cSrcweir { 965*cdf0e10cSrcweir ENTRY1Q( FORM, COLUMN_STYLE_NAME, XML_ATACTION_RENAME_ENCODE_STYLE_NAME_REF, 966*cdf0e10cSrcweir XML_NAMESPACE_FORM, XML_TEXT_STYLE_NAME ), 967*cdf0e10cSrcweir ENTRY2QN( FORM, SERVICE_NAME, 968*cdf0e10cSrcweir XML_ATACTION_RENAME_ADD_NAMESPACE_PREFIX, 969*cdf0e10cSrcweir XML_NAMESPACE_FORM, XML_CONTROL_IMPLEMENTATION, 970*cdf0e10cSrcweir XML_NAMESPACE_OOO ), 971*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 972*cdf0e10cSrcweir }; 973*cdf0e10cSrcweir 974*cdf0e10cSrcweir // OOO_FORM_PROP_ACTIONS 975*cdf0e10cSrcweir static XMLTransformerActionInit aFormPropActionTable[] = 976*cdf0e10cSrcweir { 977*cdf0e10cSrcweir ENTRY1Q( FORM, PROPERTY_TYPE, XML_ATACTION_RENAME, 978*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, XML_VALUE_TYPE ), 979*cdf0e10cSrcweir ENTRY0( FORM, PROPERTY_IS_LIST, XML_ATACTION_REMOVE ), 980*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 981*cdf0e10cSrcweir }; 982*cdf0e10cSrcweir 983*cdf0e10cSrcweir // OOO_XLINK_ACTIONS 984*cdf0e10cSrcweir static XMLTransformerActionInit aXLinkActionTable[] = 985*cdf0e10cSrcweir { 986*cdf0e10cSrcweir ENTRY1( XLINK, HREF, XML_ATACTION_URI_OOO, sal_False ), 987*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 988*cdf0e10cSrcweir }; 989*cdf0e10cSrcweir 990*cdf0e10cSrcweir // OOO_CONFIG_ITEM_SET_ACTIONS 991*cdf0e10cSrcweir static XMLTransformerActionInit aConfigItemSetActionTable[] = 992*cdf0e10cSrcweir { 993*cdf0e10cSrcweir ENTRY1( CONFIG, NAME, XML_ATACTION_ADD_NAMESPACE_PREFIX, 994*cdf0e10cSrcweir XML_NAMESPACE_OOO ), 995*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 996*cdf0e10cSrcweir }; 997*cdf0e10cSrcweir 998*cdf0e10cSrcweir // OASIS_FORMULA_ACTIONS 999*cdf0e10cSrcweir static XMLTransformerActionInit aFormulaActionTable[] = 1000*cdf0e10cSrcweir { 1001*cdf0e10cSrcweir ENTRY1( TEXT, CONDITION, XML_ATACTION_ADD_NAMESPACE_PREFIX, 1002*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 1003*cdf0e10cSrcweir ENTRY1( TEXT, FORMULA, XML_ATACTION_ADD_NAMESPACE_PREFIX, 1004*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 1005*cdf0e10cSrcweir ENTRY1( TABLE, CONDITION, XML_ATACTION_ADD_APP_NAMESPACE_PREFIX, 1006*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 1007*cdf0e10cSrcweir ENTRY1( TABLE, FORMULA, XML_ATACTION_ADD_APP_NAMESPACE_PREFIX, 1008*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 1009*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1010*cdf0e10cSrcweir }; 1011*cdf0e10cSrcweir 1012*cdf0e10cSrcweir // OOO_ERROR_MACRO_ACTIONS 1013*cdf0e10cSrcweir static XMLTransformerActionInit aErrorMacroActionTable[] = 1014*cdf0e10cSrcweir { 1015*cdf0e10cSrcweir ENTRY0( TABLE, NAME, XML_ATACTION_REMOVE ), 1016*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1017*cdf0e10cSrcweir }; 1018*cdf0e10cSrcweir 1019*cdf0e10cSrcweir // OOO_DDE_CONV_MODE_ACTIONS 1020*cdf0e10cSrcweir static XMLTransformerActionInit aDDEConvModeActionTable[] = 1021*cdf0e10cSrcweir { 1022*cdf0e10cSrcweir ENTRY1Q( TABLE, LET_TEXT, XML_ATACTION_RENAME, 1023*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_KEEP_TEXT ), 1024*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1025*cdf0e10cSrcweir }; 1026*cdf0e10cSrcweir 1027*cdf0e10cSrcweir // OOO_DATAPILOT_MEMBER_ACTIONS 1028*cdf0e10cSrcweir static XMLTransformerActionInit aDataPilotMemberActionTable[] = 1029*cdf0e10cSrcweir { 1030*cdf0e10cSrcweir ENTRY1Q( TABLE, DISPLAY_DETAILS, XML_ATACTION_RENAME, 1031*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_SHOW_DETAILS ), 1032*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1033*cdf0e10cSrcweir }; 1034*cdf0e10cSrcweir 1035*cdf0e10cSrcweir // OOO_DATAPILOT_LEVEL_ACTIONS 1036*cdf0e10cSrcweir static XMLTransformerActionInit aDataPilotLevelActionTable[] = 1037*cdf0e10cSrcweir { 1038*cdf0e10cSrcweir ENTRY1Q( TABLE, DISPLAY_EMPTY, XML_ATACTION_RENAME, 1039*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_SHOW_EMPTY ), 1040*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1041*cdf0e10cSrcweir }; 1042*cdf0e10cSrcweir 1043*cdf0e10cSrcweir // OOO_SOURCE_SERVICE_ACTIONS 1044*cdf0e10cSrcweir static XMLTransformerActionInit aSourceServiceActionTable[] = 1045*cdf0e10cSrcweir { 1046*cdf0e10cSrcweir ENTRY1Q( TABLE, USERNAME, XML_ATACTION_RENAME, 1047*cdf0e10cSrcweir XML_NAMESPACE_TABLE, XML_USER_NAME ), 1048*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1049*cdf0e10cSrcweir }; 1050*cdf0e10cSrcweir 1051*cdf0e10cSrcweir // OOO_ANIMATION_ACTIONS 1052*cdf0e10cSrcweir static XMLTransformerActionInit aAnimationsActionTable[] = 1053*cdf0e10cSrcweir { 1054*cdf0e10cSrcweir ENTRY0( DRAW, SHAPE_ID, XML_ATACTION_SHAPEID ), 1055*cdf0e10cSrcweir ENTRY0( PRESENTATION, PATH_ID, XML_ATACTION_SHAPEID ), 1056*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1057*cdf0e10cSrcweir }; 1058*cdf0e10cSrcweir 1059*cdf0e10cSrcweir // OOO_DRAW_AREA_POLYGON_ACTIONS (to be added to OOO_SHAPE_ACTIONS) 1060*cdf0e10cSrcweir static XMLTransformerActionInit aDrawAreaPolygonActionTable[] = 1061*cdf0e10cSrcweir { 1062*cdf0e10cSrcweir ENTRY1Q( SVG, POINTS, XML_ATACTION_RENAME, 1063*cdf0e10cSrcweir XML_NAMESPACE_DRAW, XML_POINTS ), 1064*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1065*cdf0e10cSrcweir }; 1066*cdf0e10cSrcweir 1067*cdf0e10cSrcweir // OOO_CHART_ACTIONS 1068*cdf0e10cSrcweir static XMLTransformerActionInit aChartActionTable[] = 1069*cdf0e10cSrcweir { 1070*cdf0e10cSrcweir ENTRY1( CHART, CLASS, XML_ATACTION_ADD_NAMESPACE_PREFIX, 1071*cdf0e10cSrcweir XML_NAMESPACE_CHART ), 1072*cdf0e10cSrcweir ENTRY0( CHART, ADD_IN_NAME, XML_ATACTION_REMOVE ), 1073*cdf0e10cSrcweir ENTRY0( SVG, WIDTH, XML_ATACTION_INCH2IN ), 1074*cdf0e10cSrcweir ENTRY0( SVG, HEIGHT, XML_ATACTION_INCH2IN ), 1075*cdf0e10cSrcweir ENTRY0( CHART, STYLE_NAME, XML_ATACTION_ENCODE_STYLE_NAME_REF ), 1076*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1077*cdf0e10cSrcweir }; 1078*cdf0e10cSrcweir 1079*cdf0e10cSrcweir // OOO_ALPHABETICAL_INDEX_MARK_ACTIONS 1080*cdf0e10cSrcweir static XMLTransformerActionInit aAlphabeticalIndexMarkActionTable[] = 1081*cdf0e10cSrcweir { 1082*cdf0e10cSrcweir ENTRY1Q( TEXT, MAIN_ETRY, XML_ATACTION_RENAME, 1083*cdf0e10cSrcweir XML_NAMESPACE_TEXT, XML_MAIN_ENTRY ), 1084*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1085*cdf0e10cSrcweir }; 1086*cdf0e10cSrcweir 1087*cdf0e10cSrcweir // OOO_SCRIPT_ACTIONS 1088*cdf0e10cSrcweir static XMLTransformerActionInit aScriptActionTable[] = 1089*cdf0e10cSrcweir { 1090*cdf0e10cSrcweir ENTRY1( SCRIPT, LANGUAGE, XML_ATACTION_ADD_NAMESPACE_PREFIX, XML_NAMESPACE_OOO ), 1091*cdf0e10cSrcweir ENTRY1Q( SCRIPT, NAME, XML_ATACTION_RENAME, XML_NAMESPACE_OOO, XML_NAME ), 1092*cdf0e10cSrcweir ENTRY1Q( SCRIPT, READONLY, XML_ATACTION_RENAME, XML_NAMESPACE_OOO, XML_READONLY ), 1093*cdf0e10cSrcweir ENTRY0( OFFICE, TOKEN_INVALID, XML_ATACTION_EOT ) 1094*cdf0e10cSrcweir }; 1095*cdf0e10cSrcweir 1096*cdf0e10cSrcweir static XMLTokenEnum aTokenMap[] = 1097*cdf0e10cSrcweir { 1098*cdf0e10cSrcweir XML_NONE, XML_SINGLE, XML_DOUBLE, XML_BOLD, XML_BOLD_DOTTED, 1099*cdf0e10cSrcweir XML_BOLD_DASH, XML_BOLD_LONG_DASH, XML_BOLD_DOT_DASH, 1100*cdf0e10cSrcweir XML_BOLD_DOT_DOT_DASH, XML_BOLD_WAVE, XML_DOUBLE_WAVE, 1101*cdf0e10cSrcweir XML_SINGLE_LINE, XML_DOUBLE_LINE, XML_THICK_LINE, XML_SLASH, XML_uX, 1102*cdf0e10cSrcweir XML_TOKEN_END 1103*cdf0e10cSrcweir }; 1104*cdf0e10cSrcweir 1105*cdf0e10cSrcweir //----------------------------------------------------------------------------- 1106*cdf0e10cSrcweir 1107*cdf0e10cSrcweir class XMLDocumentTransformerContext_Impl : public XMLTransformerContext 1108*cdf0e10cSrcweir { 1109*cdf0e10cSrcweir ::rtl::OUString m_aElemQName; 1110*cdf0e10cSrcweir ::rtl::OUString m_aOldClass; 1111*cdf0e10cSrcweir 1112*cdf0e10cSrcweir public: 1113*cdf0e10cSrcweir TYPEINFO(); 1114*cdf0e10cSrcweir 1115*cdf0e10cSrcweir XMLDocumentTransformerContext_Impl( XMLTransformerBase& rTransformer, 1116*cdf0e10cSrcweir const ::rtl::OUString& rQName ); 1117*cdf0e10cSrcweir XMLDocumentTransformerContext_Impl( XMLTransformerBase& rTransformer, 1118*cdf0e10cSrcweir const ::rtl::OUString& rQName, 1119*cdf0e10cSrcweir sal_uInt16 nPrefix, 1120*cdf0e10cSrcweir ::xmloff::token::XMLTokenEnum eToken ); 1121*cdf0e10cSrcweir 1122*cdf0e10cSrcweir virtual ~XMLDocumentTransformerContext_Impl(); 1123*cdf0e10cSrcweir 1124*cdf0e10cSrcweir virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList ); 1125*cdf0e10cSrcweir virtual void EndElement(); 1126*cdf0e10cSrcweir }; 1127*cdf0e10cSrcweir 1128*cdf0e10cSrcweir TYPEINIT1( XMLDocumentTransformerContext_Impl, XMLTransformerContext ); 1129*cdf0e10cSrcweir 1130*cdf0e10cSrcweir XMLDocumentTransformerContext_Impl::XMLDocumentTransformerContext_Impl( 1131*cdf0e10cSrcweir XMLTransformerBase& rImp, 1132*cdf0e10cSrcweir const OUString& rQName ) : 1133*cdf0e10cSrcweir XMLTransformerContext( rImp, rQName ), 1134*cdf0e10cSrcweir m_aElemQName( rQName ) 1135*cdf0e10cSrcweir { 1136*cdf0e10cSrcweir } 1137*cdf0e10cSrcweir XMLDocumentTransformerContext_Impl::XMLDocumentTransformerContext_Impl( 1138*cdf0e10cSrcweir XMLTransformerBase& rImp, 1139*cdf0e10cSrcweir const OUString& rQName , 1140*cdf0e10cSrcweir sal_uInt16 nPrefix, 1141*cdf0e10cSrcweir ::xmloff::token::XMLTokenEnum eToken) : 1142*cdf0e10cSrcweir XMLTransformerContext( rImp, rQName ), 1143*cdf0e10cSrcweir m_aElemQName( rImp.GetNamespaceMap().GetQNameByKey( nPrefix, 1144*cdf0e10cSrcweir ::xmloff::token::GetXMLToken( eToken ) ) ) 1145*cdf0e10cSrcweir { 1146*cdf0e10cSrcweir } 1147*cdf0e10cSrcweir 1148*cdf0e10cSrcweir XMLDocumentTransformerContext_Impl::~XMLDocumentTransformerContext_Impl() 1149*cdf0e10cSrcweir { 1150*cdf0e10cSrcweir } 1151*cdf0e10cSrcweir 1152*cdf0e10cSrcweir void XMLDocumentTransformerContext_Impl::StartElement( 1153*cdf0e10cSrcweir const Reference< XAttributeList >& rAttrList ) 1154*cdf0e10cSrcweir { 1155*cdf0e10cSrcweir Reference< XAttributeList > xAttrList( rAttrList ); 1156*cdf0e10cSrcweir 1157*cdf0e10cSrcweir m_aOldClass = GetTransformer().GetClass(); 1158*cdf0e10cSrcweir 1159*cdf0e10cSrcweir XMLMutableAttributeList *pMutableAttrList = 0; 1160*cdf0e10cSrcweir sal_Bool bOOo = sal_False, bOOoW = sal_False, bOOoC = sal_False, 1161*cdf0e10cSrcweir bDOM=sal_False, bDC = sal_False, bSVG = sal_False; 1162*cdf0e10cSrcweir sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0; 1163*cdf0e10cSrcweir for( sal_Int16 i=0; i < nAttrCount; i++ ) 1164*cdf0e10cSrcweir { 1165*cdf0e10cSrcweir const OUString& rAttrName = xAttrList->getNameByIndex( i ); 1166*cdf0e10cSrcweir OUString aLocalName; 1167*cdf0e10cSrcweir sal_uInt16 nPrefix = 1168*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName, 1169*cdf0e10cSrcweir &aLocalName ); 1170*cdf0e10cSrcweir if( XML_NAMESPACE_OFFICE == nPrefix && 1171*cdf0e10cSrcweir IsXMLToken( aLocalName, XML_CLASS ) ) 1172*cdf0e10cSrcweir { 1173*cdf0e10cSrcweir const OUString& rValue = xAttrList->getValueByIndex( i ); 1174*cdf0e10cSrcweir GetTransformer().SetClass( rValue ); 1175*cdf0e10cSrcweir 1176*cdf0e10cSrcweir pMutableAttrList = new XMLMutableAttributeList( xAttrList ); 1177*cdf0e10cSrcweir xAttrList = pMutableAttrList; 1178*cdf0e10cSrcweir OUString sMime(RTL_CONSTASCII_USTRINGPARAM("application/vnd.oasis.opendocument.") ); 1179*cdf0e10cSrcweir sMime += rValue; 1180*cdf0e10cSrcweir pMutableAttrList->SetValueByIndex( i, sMime ); 1181*cdf0e10cSrcweir OUString aNewAttrQName( GetTransformer().GetNamespaceMap().GetQNameByKey( XML_NAMESPACE_OFFICE, ::xmloff::token::GetXMLToken( XML_MIMETYPE ) ) ); 1182*cdf0e10cSrcweir pMutableAttrList->RenameAttributeByIndex(i, aNewAttrQName ); 1183*cdf0e10cSrcweir break; 1184*cdf0e10cSrcweir } 1185*cdf0e10cSrcweir else if( XML_NAMESPACE_XMLNS == nPrefix ) 1186*cdf0e10cSrcweir { 1187*cdf0e10cSrcweir const OUString& rAttrValue = xAttrList->getValueByIndex( i ); 1188*cdf0e10cSrcweir if( IsXMLToken( rAttrValue, XML_N_OOO ) ) 1189*cdf0e10cSrcweir bOOo = sal_True; 1190*cdf0e10cSrcweir else if( IsXMLToken( rAttrValue, XML_N_OOOW ) ) 1191*cdf0e10cSrcweir bOOoW = sal_True; 1192*cdf0e10cSrcweir else if( IsXMLToken( rAttrValue, XML_N_OOOC ) ) 1193*cdf0e10cSrcweir bOOoC = sal_True; 1194*cdf0e10cSrcweir else if( IsXMLToken( rAttrValue, XML_N_DOM ) ) 1195*cdf0e10cSrcweir bDOM = sal_True; 1196*cdf0e10cSrcweir else if( IsXMLToken( rAttrValue, XML_N_DC ) ) 1197*cdf0e10cSrcweir bDC = sal_True; 1198*cdf0e10cSrcweir else if( IsXMLToken( rAttrValue, XML_N_SVG ) ) 1199*cdf0e10cSrcweir bSVG = sal_True; 1200*cdf0e10cSrcweir } 1201*cdf0e10cSrcweir } 1202*cdf0e10cSrcweir if( !(bOOo && bOOoW && bOOoC && bDOM && bDC && bSVG) ) 1203*cdf0e10cSrcweir { 1204*cdf0e10cSrcweir if( !pMutableAttrList ) 1205*cdf0e10cSrcweir { 1206*cdf0e10cSrcweir pMutableAttrList = new XMLMutableAttributeList( xAttrList ); 1207*cdf0e10cSrcweir xAttrList = pMutableAttrList; 1208*cdf0e10cSrcweir } 1209*cdf0e10cSrcweir if( !bOOo ) 1210*cdf0e10cSrcweir pMutableAttrList->AddAttribute( 1211*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetAttrNameByKey( 1212*cdf0e10cSrcweir XML_NAMESPACE_OOO ), 1213*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetNameByKey( 1214*cdf0e10cSrcweir XML_NAMESPACE_OOO ) ); 1215*cdf0e10cSrcweir if( !bOOoW ) 1216*cdf0e10cSrcweir pMutableAttrList->AddAttribute( 1217*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetAttrNameByKey( 1218*cdf0e10cSrcweir XML_NAMESPACE_OOOW ), 1219*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetNameByKey( 1220*cdf0e10cSrcweir XML_NAMESPACE_OOOW ) ); 1221*cdf0e10cSrcweir if( !bOOoC ) 1222*cdf0e10cSrcweir pMutableAttrList->AddAttribute( 1223*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetAttrNameByKey( 1224*cdf0e10cSrcweir XML_NAMESPACE_OOOC ), 1225*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetNameByKey( 1226*cdf0e10cSrcweir XML_NAMESPACE_OOOC ) ); 1227*cdf0e10cSrcweir if( !bDOM ) 1228*cdf0e10cSrcweir pMutableAttrList->AddAttribute( 1229*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetAttrNameByKey( 1230*cdf0e10cSrcweir XML_NAMESPACE_DOM ), 1231*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetNameByKey( 1232*cdf0e10cSrcweir XML_NAMESPACE_DOM ) ); 1233*cdf0e10cSrcweir if( !bDC ) 1234*cdf0e10cSrcweir pMutableAttrList->AddAttribute( 1235*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetAttrNameByKey( 1236*cdf0e10cSrcweir XML_NAMESPACE_DC ), 1237*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetNameByKey( 1238*cdf0e10cSrcweir XML_NAMESPACE_DC ) ); 1239*cdf0e10cSrcweir if( !bSVG ) 1240*cdf0e10cSrcweir pMutableAttrList->AddAttribute( 1241*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetAttrNameByKey( 1242*cdf0e10cSrcweir XML_NAMESPACE_SVG ), 1243*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetNameByKey( 1244*cdf0e10cSrcweir XML_NAMESPACE_SVG ) ); 1245*cdf0e10cSrcweir } 1246*cdf0e10cSrcweir 1247*cdf0e10cSrcweir GetTransformer().GetDocHandler()->startElement( m_aElemQName, xAttrList ); 1248*cdf0e10cSrcweir } 1249*cdf0e10cSrcweir 1250*cdf0e10cSrcweir void XMLDocumentTransformerContext_Impl::EndElement() 1251*cdf0e10cSrcweir { 1252*cdf0e10cSrcweir GetTransformer().GetDocHandler()->endElement( m_aElemQName ); 1253*cdf0e10cSrcweir 1254*cdf0e10cSrcweir GetTransformer().SetClass( m_aOldClass ); 1255*cdf0e10cSrcweir } 1256*cdf0e10cSrcweir 1257*cdf0e10cSrcweir //----------------------------------------------------------------------------- 1258*cdf0e10cSrcweir 1259*cdf0e10cSrcweir class XMLBodyTransformerContext_Impl : public XMLTransformerContext 1260*cdf0e10cSrcweir { 1261*cdf0e10cSrcweir OUString m_aClassQName; 1262*cdf0e10cSrcweir 1263*cdf0e10cSrcweir public: 1264*cdf0e10cSrcweir TYPEINFO(); 1265*cdf0e10cSrcweir 1266*cdf0e10cSrcweir XMLBodyTransformerContext_Impl( XMLTransformerBase& rTransformer, 1267*cdf0e10cSrcweir const ::rtl::OUString& rQName ); 1268*cdf0e10cSrcweir 1269*cdf0e10cSrcweir virtual ~XMLBodyTransformerContext_Impl(); 1270*cdf0e10cSrcweir 1271*cdf0e10cSrcweir virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList ); 1272*cdf0e10cSrcweir virtual void EndElement(); 1273*cdf0e10cSrcweir }; 1274*cdf0e10cSrcweir 1275*cdf0e10cSrcweir TYPEINIT1( XMLBodyTransformerContext_Impl, XMLTransformerContext ); 1276*cdf0e10cSrcweir 1277*cdf0e10cSrcweir XMLBodyTransformerContext_Impl::XMLBodyTransformerContext_Impl( 1278*cdf0e10cSrcweir XMLTransformerBase& rImp, 1279*cdf0e10cSrcweir const OUString& rQName ) : 1280*cdf0e10cSrcweir XMLTransformerContext( rImp, rQName ) 1281*cdf0e10cSrcweir { 1282*cdf0e10cSrcweir } 1283*cdf0e10cSrcweir 1284*cdf0e10cSrcweir XMLBodyTransformerContext_Impl::~XMLBodyTransformerContext_Impl() 1285*cdf0e10cSrcweir { 1286*cdf0e10cSrcweir } 1287*cdf0e10cSrcweir 1288*cdf0e10cSrcweir void XMLBodyTransformerContext_Impl::StartElement( 1289*cdf0e10cSrcweir const Reference< XAttributeList >& rAttrList ) 1290*cdf0e10cSrcweir { 1291*cdf0e10cSrcweir XMLTransformerContext::StartElement( rAttrList ); 1292*cdf0e10cSrcweir 1293*cdf0e10cSrcweir XMLMutableAttributeList *pMutableAttrList = 1294*cdf0e10cSrcweir new XMLMutableAttributeList( rAttrList ); 1295*cdf0e10cSrcweir Reference< XAttributeList > xAttrList = pMutableAttrList; 1296*cdf0e10cSrcweir OUString aClass( GetTransformer().GetClass() ); 1297*cdf0e10cSrcweir if( !aClass.getLength() ) 1298*cdf0e10cSrcweir { 1299*cdf0e10cSrcweir aClass = GetXMLToken( XML_TEXT ); 1300*cdf0e10cSrcweir } 1301*cdf0e10cSrcweir else if( IsXMLToken( aClass, XML_TEXT_GLOBAL ) ) 1302*cdf0e10cSrcweir { 1303*cdf0e10cSrcweir OUString aGlobalQName( 1304*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetQNameByKey( 1305*cdf0e10cSrcweir XML_NAMESPACE_TEXT, GetXMLToken(XML_GLOBAL ) ) ); 1306*cdf0e10cSrcweir pMutableAttrList->AddAttribute( aGlobalQName, GetXMLToken(XML_TRUE) ); 1307*cdf0e10cSrcweir 1308*cdf0e10cSrcweir aClass = GetXMLToken( XML_TEXT ); 1309*cdf0e10cSrcweir } 1310*cdf0e10cSrcweir 1311*cdf0e10cSrcweir m_aClassQName = GetTransformer().GetNamespaceMap().GetQNameByKey( 1312*cdf0e10cSrcweir XML_NAMESPACE_OFFICE, aClass ); 1313*cdf0e10cSrcweir GetTransformer().GetDocHandler()->startElement( m_aClassQName, 1314*cdf0e10cSrcweir xAttrList ); 1315*cdf0e10cSrcweir } 1316*cdf0e10cSrcweir 1317*cdf0e10cSrcweir void XMLBodyTransformerContext_Impl::EndElement() 1318*cdf0e10cSrcweir { 1319*cdf0e10cSrcweir GetTransformer().GetDocHandler()->endElement( m_aClassQName ); 1320*cdf0e10cSrcweir XMLTransformerContext::EndElement(); 1321*cdf0e10cSrcweir } 1322*cdf0e10cSrcweir 1323*cdf0e10cSrcweir //----------------------------------------------------------------------------- 1324*cdf0e10cSrcweir 1325*cdf0e10cSrcweir class XMLTabStopOOoTContext_Impl : public XMLPersElemContentTContext 1326*cdf0e10cSrcweir { 1327*cdf0e10cSrcweir public: 1328*cdf0e10cSrcweir TYPEINFO(); 1329*cdf0e10cSrcweir 1330*cdf0e10cSrcweir XMLTabStopOOoTContext_Impl( XMLTransformerBase& rTransformer, 1331*cdf0e10cSrcweir const ::rtl::OUString& rQName ); 1332*cdf0e10cSrcweir 1333*cdf0e10cSrcweir virtual ~XMLTabStopOOoTContext_Impl(); 1334*cdf0e10cSrcweir 1335*cdf0e10cSrcweir virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList ); 1336*cdf0e10cSrcweir }; 1337*cdf0e10cSrcweir 1338*cdf0e10cSrcweir TYPEINIT1( XMLTabStopOOoTContext_Impl, XMLPersElemContentTContext ); 1339*cdf0e10cSrcweir 1340*cdf0e10cSrcweir XMLTabStopOOoTContext_Impl::XMLTabStopOOoTContext_Impl( 1341*cdf0e10cSrcweir XMLTransformerBase& rImp, 1342*cdf0e10cSrcweir const OUString& rQName ) : 1343*cdf0e10cSrcweir XMLPersElemContentTContext( rImp, rQName ) 1344*cdf0e10cSrcweir { 1345*cdf0e10cSrcweir } 1346*cdf0e10cSrcweir 1347*cdf0e10cSrcweir XMLTabStopOOoTContext_Impl::~XMLTabStopOOoTContext_Impl() 1348*cdf0e10cSrcweir { 1349*cdf0e10cSrcweir } 1350*cdf0e10cSrcweir 1351*cdf0e10cSrcweir void XMLTabStopOOoTContext_Impl::StartElement( 1352*cdf0e10cSrcweir const Reference< XAttributeList >& rAttrList ) 1353*cdf0e10cSrcweir { 1354*cdf0e10cSrcweir XMLTransformerActions *pActions = 1355*cdf0e10cSrcweir GetTransformer().GetUserDefinedActions( OOO_TAB_STOP_ACTIONS ); 1356*cdf0e10cSrcweir OSL_ENSURE( pActions, "go no actions" ); 1357*cdf0e10cSrcweir 1358*cdf0e10cSrcweir Reference< XAttributeList > xAttrList( rAttrList ); 1359*cdf0e10cSrcweir XMLMutableAttributeList *pMutableAttrList = 0; 1360*cdf0e10cSrcweir sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0; 1361*cdf0e10cSrcweir for( sal_Int16 i=0; i < nAttrCount; i++ ) 1362*cdf0e10cSrcweir { 1363*cdf0e10cSrcweir const OUString& rAttrName = xAttrList->getNameByIndex( i ); 1364*cdf0e10cSrcweir OUString aLocalName; 1365*cdf0e10cSrcweir sal_uInt16 nPrefix = 1366*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName, 1367*cdf0e10cSrcweir &aLocalName ); 1368*cdf0e10cSrcweir XMLTransformerActions::key_type aKey( nPrefix, aLocalName ); 1369*cdf0e10cSrcweir XMLTransformerActions::const_iterator aIter = 1370*cdf0e10cSrcweir pActions->find( aKey ); 1371*cdf0e10cSrcweir if( !(aIter == pActions->end() ) ) 1372*cdf0e10cSrcweir { 1373*cdf0e10cSrcweir if( !pMutableAttrList ) 1374*cdf0e10cSrcweir { 1375*cdf0e10cSrcweir pMutableAttrList = 1376*cdf0e10cSrcweir new XMLMutableAttributeList( xAttrList ); 1377*cdf0e10cSrcweir xAttrList = pMutableAttrList; 1378*cdf0e10cSrcweir } 1379*cdf0e10cSrcweir const OUString& rAttrValue = xAttrList->getValueByIndex( i ); 1380*cdf0e10cSrcweir switch( (*aIter).second.m_nActionType ) 1381*cdf0e10cSrcweir { 1382*cdf0e10cSrcweir case XML_ATACTION_RENAME: 1383*cdf0e10cSrcweir { 1384*cdf0e10cSrcweir OUString aNewAttrQName( 1385*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetQNameByKey( 1386*cdf0e10cSrcweir (*aIter).second.GetQNamePrefixFromParam1(), 1387*cdf0e10cSrcweir ::xmloff::token::GetXMLToken( 1388*cdf0e10cSrcweir (*aIter).second.GetQNameTokenFromParam1()) ) ); 1389*cdf0e10cSrcweir pMutableAttrList->RenameAttributeByIndex( i, 1390*cdf0e10cSrcweir aNewAttrQName ); 1391*cdf0e10cSrcweir } 1392*cdf0e10cSrcweir if( IsXMLToken( aLocalName, XML_LEADER_CHAR ) && 1393*cdf0e10cSrcweir rAttrValue.getLength() > 0 && 1394*cdf0e10cSrcweir rAttrValue[0] != ' ' ) 1395*cdf0e10cSrcweir { 1396*cdf0e10cSrcweir OUString aNewAttrQName( 1397*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetQNameByKey( 1398*cdf0e10cSrcweir XML_NAMESPACE_STYLE, 1399*cdf0e10cSrcweir ::xmloff::token::GetXMLToken(XML_LEADER_STYLE) ) ); 1400*cdf0e10cSrcweir pMutableAttrList->AddAttribute( aNewAttrQName, 1401*cdf0e10cSrcweir GetXMLToken( XML_SOLID ) ); 1402*cdf0e10cSrcweir } 1403*cdf0e10cSrcweir break; 1404*cdf0e10cSrcweir case XML_ATACTION_INCH2IN: 1405*cdf0e10cSrcweir { 1406*cdf0e10cSrcweir OUString aAttrValue( rAttrValue ); 1407*cdf0e10cSrcweir if( XMLTransformerBase::ReplaceSingleInchWithIn( 1408*cdf0e10cSrcweir aAttrValue ) ) 1409*cdf0e10cSrcweir pMutableAttrList->SetValueByIndex( i, aAttrValue ); 1410*cdf0e10cSrcweir } 1411*cdf0e10cSrcweir break; 1412*cdf0e10cSrcweir default: 1413*cdf0e10cSrcweir OSL_ENSURE( !this, "unknown action" ); 1414*cdf0e10cSrcweir break; 1415*cdf0e10cSrcweir } 1416*cdf0e10cSrcweir } 1417*cdf0e10cSrcweir } 1418*cdf0e10cSrcweir 1419*cdf0e10cSrcweir XMLPersElemContentTContext::StartElement( xAttrList ); 1420*cdf0e10cSrcweir } 1421*cdf0e10cSrcweir 1422*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 1423*cdf0e10cSrcweir 1424*cdf0e10cSrcweir class XMLTrackedChangesOOoTContext_Impl : public XMLTransformerContext 1425*cdf0e10cSrcweir { 1426*cdf0e10cSrcweir sal_uInt16 m_nPrefix; 1427*cdf0e10cSrcweir XMLTokenEnum m_eToken; 1428*cdf0e10cSrcweir 1429*cdf0e10cSrcweir public: 1430*cdf0e10cSrcweir 1431*cdf0e10cSrcweir TYPEINFO(); 1432*cdf0e10cSrcweir 1433*cdf0e10cSrcweir XMLTrackedChangesOOoTContext_Impl( XMLTransformerBase& rTransformer, 1434*cdf0e10cSrcweir const ::rtl::OUString& rQName, 1435*cdf0e10cSrcweir sal_uInt16 nPrefix, 1436*cdf0e10cSrcweir XMLTokenEnum eToken ); 1437*cdf0e10cSrcweir 1438*cdf0e10cSrcweir virtual ~XMLTrackedChangesOOoTContext_Impl(); 1439*cdf0e10cSrcweir 1440*cdf0e10cSrcweir virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList ); 1441*cdf0e10cSrcweir }; 1442*cdf0e10cSrcweir 1443*cdf0e10cSrcweir TYPEINIT1( XMLTrackedChangesOOoTContext_Impl, XMLTransformerContext ); 1444*cdf0e10cSrcweir 1445*cdf0e10cSrcweir XMLTrackedChangesOOoTContext_Impl::XMLTrackedChangesOOoTContext_Impl( 1446*cdf0e10cSrcweir XMLTransformerBase& rImp, 1447*cdf0e10cSrcweir const OUString& rQName, 1448*cdf0e10cSrcweir sal_uInt16 nPrefix, 1449*cdf0e10cSrcweir XMLTokenEnum eToken ) : 1450*cdf0e10cSrcweir XMLTransformerContext( rImp, rQName ), 1451*cdf0e10cSrcweir m_nPrefix( nPrefix ), 1452*cdf0e10cSrcweir m_eToken( eToken ) 1453*cdf0e10cSrcweir { 1454*cdf0e10cSrcweir } 1455*cdf0e10cSrcweir 1456*cdf0e10cSrcweir XMLTrackedChangesOOoTContext_Impl::~XMLTrackedChangesOOoTContext_Impl() 1457*cdf0e10cSrcweir { 1458*cdf0e10cSrcweir } 1459*cdf0e10cSrcweir 1460*cdf0e10cSrcweir void XMLTrackedChangesOOoTContext_Impl::StartElement( 1461*cdf0e10cSrcweir const Reference< XAttributeList >& rAttrList ) 1462*cdf0e10cSrcweir { 1463*cdf0e10cSrcweir Reference< XAttributeList > xAttrList( rAttrList ); 1464*cdf0e10cSrcweir sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0; 1465*cdf0e10cSrcweir for( sal_Int16 i=0; i < nAttrCount; i++ ) 1466*cdf0e10cSrcweir { 1467*cdf0e10cSrcweir const OUString& rAttrName = xAttrList->getNameByIndex( i ); 1468*cdf0e10cSrcweir OUString aLocalName; 1469*cdf0e10cSrcweir sal_uInt16 nPrefix = 1470*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName, 1471*cdf0e10cSrcweir &aLocalName ); 1472*cdf0e10cSrcweir if( m_nPrefix == nPrefix && IsXMLToken( aLocalName, m_eToken ) ) 1473*cdf0e10cSrcweir { 1474*cdf0e10cSrcweir const Reference< XPropertySet > rPropSet = 1475*cdf0e10cSrcweir GetTransformer().GetPropertySet(); 1476*cdf0e10cSrcweir OSL_ENSURE( rPropSet.is(), "no info property set" ); 1477*cdf0e10cSrcweir if( rPropSet.is() ) 1478*cdf0e10cSrcweir { 1479*cdf0e10cSrcweir const sal_Char sRedlineProtectionKey[] = "RedlineProtectionKey"; 1480*cdf0e10cSrcweir OUString aPropName(RTL_CONSTASCII_USTRINGPARAM(sRedlineProtectionKey)); 1481*cdf0e10cSrcweir Reference< XPropertySetInfo > xPropSetInfo( 1482*cdf0e10cSrcweir rPropSet->getPropertySetInfo() ); 1483*cdf0e10cSrcweir if( xPropSetInfo.is() && 1484*cdf0e10cSrcweir xPropSetInfo->hasPropertyByName( aPropName ) ) 1485*cdf0e10cSrcweir { 1486*cdf0e10cSrcweir Sequence < sal_Int8 > aKey; 1487*cdf0e10cSrcweir SvXMLUnitConverter::decodeBase64( aKey, 1488*cdf0e10cSrcweir xAttrList->getValueByIndex( i ) ); 1489*cdf0e10cSrcweir rPropSet->setPropertyValue( aPropName, makeAny( aKey ) ); 1490*cdf0e10cSrcweir } 1491*cdf0e10cSrcweir else 1492*cdf0e10cSrcweir { 1493*cdf0e10cSrcweir OSL_ENSURE( !this, "RedineProtectionKey is missing" ); 1494*cdf0e10cSrcweir } 1495*cdf0e10cSrcweir } 1496*cdf0e10cSrcweir break; 1497*cdf0e10cSrcweir } 1498*cdf0e10cSrcweir } 1499*cdf0e10cSrcweir XMLTransformerContext::StartElement( xAttrList ); 1500*cdf0e10cSrcweir } 1501*cdf0e10cSrcweir 1502*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 1503*cdf0e10cSrcweir 1504*cdf0e10cSrcweir class XMLTableOOoTransformerContext_Impl : public XMLTransformerContext 1505*cdf0e10cSrcweir { 1506*cdf0e10cSrcweir ::rtl::OUString m_aElemQName; 1507*cdf0e10cSrcweir 1508*cdf0e10cSrcweir public: 1509*cdf0e10cSrcweir TYPEINFO(); 1510*cdf0e10cSrcweir 1511*cdf0e10cSrcweir XMLTableOOoTransformerContext_Impl( XMLTransformerBase& rTransformer, 1512*cdf0e10cSrcweir const ::rtl::OUString& rQName ); 1513*cdf0e10cSrcweir 1514*cdf0e10cSrcweir virtual ~XMLTableOOoTransformerContext_Impl(); 1515*cdf0e10cSrcweir 1516*cdf0e10cSrcweir virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList ); 1517*cdf0e10cSrcweir virtual void EndElement(); 1518*cdf0e10cSrcweir }; 1519*cdf0e10cSrcweir 1520*cdf0e10cSrcweir TYPEINIT1( XMLTableOOoTransformerContext_Impl, XMLTransformerContext ); 1521*cdf0e10cSrcweir 1522*cdf0e10cSrcweir XMLTableOOoTransformerContext_Impl::XMLTableOOoTransformerContext_Impl( 1523*cdf0e10cSrcweir XMLTransformerBase& rImp, 1524*cdf0e10cSrcweir const OUString& rQName ) : 1525*cdf0e10cSrcweir XMLTransformerContext( rImp, rQName ), 1526*cdf0e10cSrcweir m_aElemQName( rQName ) 1527*cdf0e10cSrcweir { 1528*cdf0e10cSrcweir } 1529*cdf0e10cSrcweir 1530*cdf0e10cSrcweir XMLTableOOoTransformerContext_Impl::~XMLTableOOoTransformerContext_Impl() 1531*cdf0e10cSrcweir { 1532*cdf0e10cSrcweir } 1533*cdf0e10cSrcweir 1534*cdf0e10cSrcweir void XMLTableOOoTransformerContext_Impl::StartElement( 1535*cdf0e10cSrcweir const Reference< XAttributeList >& rAttrList ) 1536*cdf0e10cSrcweir { 1537*cdf0e10cSrcweir // --> OD 2005-07-05 #i50521# - perform OOO_STYLE_REF_ACTIONS for all applications 1538*cdf0e10cSrcweir Reference< XAttributeList > xAttrList( rAttrList ); 1539*cdf0e10cSrcweir XMLMutableAttributeList* pMutableAttrList = 1540*cdf0e10cSrcweir GetTransformer().ProcessAttrList( xAttrList, OOO_STYLE_REF_ACTIONS, sal_False ); 1541*cdf0e10cSrcweir // <-- 1542*cdf0e10cSrcweir if( rAttrList->getLength() && IsXMLToken( GetTransformer().GetClass(), XML_SPREADSHEET ) ) 1543*cdf0e10cSrcweir { 1544*cdf0e10cSrcweir sal_Bool bPrintRanges(sal_False); 1545*cdf0e10cSrcweir 1546*cdf0e10cSrcweir sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0; 1547*cdf0e10cSrcweir for( sal_Int16 i=0; i < nAttrCount; i++ ) 1548*cdf0e10cSrcweir { 1549*cdf0e10cSrcweir const OUString& rAttrName = xAttrList->getNameByIndex( i ); 1550*cdf0e10cSrcweir OUString aLocalName; 1551*cdf0e10cSrcweir sal_uInt16 nPrefix = 1552*cdf0e10cSrcweir GetTransformer().GetNamespaceMap().GetKeyByAttrName( rAttrName, 1553*cdf0e10cSrcweir &aLocalName ); 1554*cdf0e10cSrcweir if( XML_NAMESPACE_TABLE == nPrefix && 1555*cdf0e10cSrcweir IsXMLToken( aLocalName, XML_PRINT_RANGES ) ) 1556*cdf0e10cSrcweir { 1557*cdf0e10cSrcweir bPrintRanges = sal_True; 1558*cdf0e10cSrcweir } 1559*cdf0e10cSrcweir } 1560*cdf0e10cSrcweir if (!bPrintRanges && pMutableAttrList) 1561*cdf0e10cSrcweir { 1562*cdf0e10cSrcweir xAttrList = pMutableAttrList; 1563*cdf0e10cSrcweir pMutableAttrList->AddAttribute(GetTransformer().GetNamespaceMap().GetQNameByKey( 1564*cdf0e10cSrcweir XML_NAMESPACE_TABLE, 1565*cdf0e10cSrcweir GetXMLToken( XML_PRINT ) ), GetXMLToken ( XML_FALSE )); 1566*cdf0e10cSrcweir } 1567*cdf0e10cSrcweir } 1568*cdf0e10cSrcweir 1569*cdf0e10cSrcweir GetTransformer().GetDocHandler()->startElement( m_aElemQName, xAttrList ); 1570*cdf0e10cSrcweir } 1571*cdf0e10cSrcweir 1572*cdf0e10cSrcweir void XMLTableOOoTransformerContext_Impl::EndElement() 1573*cdf0e10cSrcweir { 1574*cdf0e10cSrcweir GetTransformer().GetDocHandler()->endElement( m_aElemQName ); 1575*cdf0e10cSrcweir } 1576*cdf0e10cSrcweir 1577*cdf0e10cSrcweir 1578*cdf0e10cSrcweir //----------------------------------------------------------------------------- 1579*cdf0e10cSrcweir 1580*cdf0e10cSrcweir XMLTransformerContext *OOo2OasisTransformer::CreateUserDefinedContext( 1581*cdf0e10cSrcweir const TransformerAction_Impl& rAction, 1582*cdf0e10cSrcweir const OUString& rQName, 1583*cdf0e10cSrcweir sal_Bool bPersistent ) 1584*cdf0e10cSrcweir { 1585*cdf0e10cSrcweir switch( rAction.m_nActionType ) 1586*cdf0e10cSrcweir { 1587*cdf0e10cSrcweir case XML_ETACTION_DOCUMENT: 1588*cdf0e10cSrcweir return new XMLDocumentTransformerContext_Impl( *this, rQName ); 1589*cdf0e10cSrcweir case XML_ETACTION_DOCUMENT_RENAME: 1590*cdf0e10cSrcweir return new XMLDocumentTransformerContext_Impl( *this, rQName, 1591*cdf0e10cSrcweir rAction.GetQNamePrefixFromParam1(), 1592*cdf0e10cSrcweir rAction.GetQNameTokenFromParam1() ); 1593*cdf0e10cSrcweir case XML_ETACTION_BODY: 1594*cdf0e10cSrcweir return new XMLBodyTransformerContext_Impl( *this, rQName ); 1595*cdf0e10cSrcweir case XML_ETACTION_STYLE: 1596*cdf0e10cSrcweir return new XMLStyleOOoTContext( *this, rQName, 1597*cdf0e10cSrcweir static_cast< XMLFamilyType >( rAction.m_nParam1 ), 1598*cdf0e10cSrcweir bPersistent ); 1599*cdf0e10cSrcweir case XML_ETACTION_STYLE_RENAME: 1600*cdf0e10cSrcweir return new XMLStyleOOoTContext( *this, rQName, 1601*cdf0e10cSrcweir static_cast< XMLFamilyType >( rAction.m_nParam2 ), 1602*cdf0e10cSrcweir rAction.GetQNamePrefixFromParam1(), 1603*cdf0e10cSrcweir rAction.GetQNameTokenFromParam1(), 1604*cdf0e10cSrcweir bPersistent ); 1605*cdf0e10cSrcweir case XML_ETACTION_FRAME: 1606*cdf0e10cSrcweir return new XMLFrameOOoTransformerContext( *this, rQName ); 1607*cdf0e10cSrcweir case XML_ETACTION_EVENT: 1608*cdf0e10cSrcweir return new XMLEventOOoTransformerContext( *this, rQName, bPersistent ); 1609*cdf0e10cSrcweir case XML_ETACTION_TAB_STOP: 1610*cdf0e10cSrcweir return new XMLTabStopOOoTContext_Impl( *this, rQName ); 1611*cdf0e10cSrcweir case XML_ETACTION_FORM_CONTROL: 1612*cdf0e10cSrcweir return new XMLControlOOoTransformerContext( *this, rQName ); 1613*cdf0e10cSrcweir case XML_ETACTION_FORM_PROPERTY: 1614*cdf0e10cSrcweir return new XMLFormPropOOoTransformerContext( *this, rQName ); 1615*cdf0e10cSrcweir case XML_ETACTION_CHART: 1616*cdf0e10cSrcweir return new XMLChartOOoTransformerContext( *this, rQName ); 1617*cdf0e10cSrcweir case XML_ETACTION_TRACKED_CHANGES: 1618*cdf0e10cSrcweir return new XMLTrackedChangesOOoTContext_Impl( *this, rQName, 1619*cdf0e10cSrcweir rAction.GetQNamePrefixFromParam1(), 1620*cdf0e10cSrcweir rAction.GetQNameTokenFromParam1() ); 1621*cdf0e10cSrcweir case XML_ETACTION_CHART_PLOT_AREA: 1622*cdf0e10cSrcweir return new XMLChartPlotAreaOOoTContext( *this, rQName ); 1623*cdf0e10cSrcweir case XML_ETACTION_TABLE: 1624*cdf0e10cSrcweir return new XMLTableOOoTransformerContext_Impl( *this, rQName ); 1625*cdf0e10cSrcweir default: 1626*cdf0e10cSrcweir OSL_ENSURE( !this, "no user defined context found!" ); 1627*cdf0e10cSrcweir } 1628*cdf0e10cSrcweir 1629*cdf0e10cSrcweir // default is copying 1630*cdf0e10cSrcweir return new XMLTransformerContext( *this, rQName ); 1631*cdf0e10cSrcweir } 1632*cdf0e10cSrcweir 1633*cdf0e10cSrcweir XMLTransformerActions *OOo2OasisTransformer::GetUserDefinedActions( 1634*cdf0e10cSrcweir sal_uInt16 n ) 1635*cdf0e10cSrcweir { 1636*cdf0e10cSrcweir XMLTransformerActions *pActions = 0; 1637*cdf0e10cSrcweir if( n < MAX_OOO_ACTIONS ) 1638*cdf0e10cSrcweir { 1639*cdf0e10cSrcweir if( !m_aActions[n] ) 1640*cdf0e10cSrcweir { 1641*cdf0e10cSrcweir if( n<MAX_OOO_PROP_ACTIONS ) 1642*cdf0e10cSrcweir { 1643*cdf0e10cSrcweir m_aActions[n] = 1644*cdf0e10cSrcweir XMLStyleOOoTContext::CreateTransformerActions( n ); 1645*cdf0e10cSrcweir } 1646*cdf0e10cSrcweir else switch( n ) 1647*cdf0e10cSrcweir { 1648*cdf0e10cSrcweir case OOO_STYLE_ACTIONS: 1649*cdf0e10cSrcweir m_aActions[OOO_STYLE_ACTIONS] = 1650*cdf0e10cSrcweir new XMLTransformerActions( aStyleActionTable ); 1651*cdf0e10cSrcweir break; 1652*cdf0e10cSrcweir case OOO_FONT_DECL_ACTIONS: 1653*cdf0e10cSrcweir m_aActions[OOO_FONT_DECL_ACTIONS] = 1654*cdf0e10cSrcweir new XMLTransformerActions( aFontDeclActionTable ); 1655*cdf0e10cSrcweir break; 1656*cdf0e10cSrcweir case OOO_SHAPE_ACTIONS: 1657*cdf0e10cSrcweir m_aActions[OOO_SHAPE_ACTIONS] = 1658*cdf0e10cSrcweir new XMLTransformerActions( aShapeActionTable ); 1659*cdf0e10cSrcweir break; 1660*cdf0e10cSrcweir case OOO_CONNECTOR_ACTIONS: 1661*cdf0e10cSrcweir m_aActions[OOO_CONNECTOR_ACTIONS] = 1662*cdf0e10cSrcweir new XMLTransformerActions( aConnectorActionTable ); 1663*cdf0e10cSrcweir break; 1664*cdf0e10cSrcweir case OOO_TAB_STOP_ACTIONS: 1665*cdf0e10cSrcweir m_aActions[OOO_TAB_STOP_ACTIONS] = 1666*cdf0e10cSrcweir new XMLTransformerActions( aTabStopActionTable ); 1667*cdf0e10cSrcweir break; 1668*cdf0e10cSrcweir case OOO_INDEX_ENTRY_TAB_STOP_ACTIONS: 1669*cdf0e10cSrcweir m_aActions[OOO_INDEX_ENTRY_TAB_STOP_ACTIONS] = 1670*cdf0e10cSrcweir new XMLTransformerActions( aIndexEntryTabStopActionTable ); 1671*cdf0e10cSrcweir break; 1672*cdf0e10cSrcweir case OOO_LINENUMBERING_ACTIONS: 1673*cdf0e10cSrcweir m_aActions[OOO_LINENUMBERING_ACTIONS] = 1674*cdf0e10cSrcweir new XMLTransformerActions( aLineNumberingActionTable ); 1675*cdf0e10cSrcweir break; 1676*cdf0e10cSrcweir case OOO_FOOTNOTE_SEP_ACTIONS: 1677*cdf0e10cSrcweir m_aActions[OOO_FOOTNOTE_SEP_ACTIONS] = 1678*cdf0e10cSrcweir new XMLTransformerActions( aFootnoteSepActionTable ); 1679*cdf0e10cSrcweir break; 1680*cdf0e10cSrcweir case OOO_DROP_CAP_ACTIONS: 1681*cdf0e10cSrcweir m_aActions[OOO_DROP_CAP_ACTIONS] = 1682*cdf0e10cSrcweir new XMLTransformerActions( aDropCapActionTable ); 1683*cdf0e10cSrcweir break; 1684*cdf0e10cSrcweir case OOO_COLUMNS_ACTIONS: 1685*cdf0e10cSrcweir m_aActions[OOO_COLUMNS_ACTIONS] = 1686*cdf0e10cSrcweir new XMLTransformerActions( aColumnsActionTable ); 1687*cdf0e10cSrcweir break; 1688*cdf0e10cSrcweir case OOO_TEXT_VALUE_TYPE_ACTIONS: 1689*cdf0e10cSrcweir m_aActions[OOO_TEXT_VALUE_TYPE_ACTIONS] = 1690*cdf0e10cSrcweir new XMLTransformerActions( aTextValueTypeActionTable ); 1691*cdf0e10cSrcweir break; 1692*cdf0e10cSrcweir case OOO_TABLE_VALUE_TYPE_ACTIONS: 1693*cdf0e10cSrcweir m_aActions[OOO_TABLE_VALUE_TYPE_ACTIONS] = 1694*cdf0e10cSrcweir new XMLTransformerActions( aTableValueTypeActionTable ); 1695*cdf0e10cSrcweir break; 1696*cdf0e10cSrcweir case OOO_PARA_ACTIONS: 1697*cdf0e10cSrcweir m_aActions[OOO_PARA_ACTIONS] = 1698*cdf0e10cSrcweir new XMLTransformerActions( aParaActionTable ); 1699*cdf0e10cSrcweir break; 1700*cdf0e10cSrcweir case OOO_STYLE_REF_ACTIONS: 1701*cdf0e10cSrcweir m_aActions[OOO_STYLE_REF_ACTIONS] = 1702*cdf0e10cSrcweir new XMLTransformerActions( aStyleRefActionTable ); 1703*cdf0e10cSrcweir break; 1704*cdf0e10cSrcweir case OOO_MASTER_PAGE_ACTIONS: 1705*cdf0e10cSrcweir m_aActions[OOO_MASTER_PAGE_ACTIONS] = 1706*cdf0e10cSrcweir new XMLTransformerActions( aMasterPageActionTable ); 1707*cdf0e10cSrcweir break; 1708*cdf0e10cSrcweir case OOO_ANNOTATION_ACTIONS: 1709*cdf0e10cSrcweir m_aActions[OOO_ANNOTATION_ACTIONS] = 1710*cdf0e10cSrcweir new XMLTransformerActions( aAnnotationActionTable ); 1711*cdf0e10cSrcweir break; 1712*cdf0e10cSrcweir case OOO_CHANGE_INFO_ACTIONS: 1713*cdf0e10cSrcweir m_aActions[OOO_CHANGE_INFO_ACTIONS] = 1714*cdf0e10cSrcweir new XMLTransformerActions( aChangeInfoActionTable ); 1715*cdf0e10cSrcweir break; 1716*cdf0e10cSrcweir case OOO_FRAME_ELEM_ACTIONS: 1717*cdf0e10cSrcweir m_aActions[OOO_FRAME_ELEM_ACTIONS] = 1718*cdf0e10cSrcweir new XMLTransformerActions( aFrameElemActionTable ); 1719*cdf0e10cSrcweir break; 1720*cdf0e10cSrcweir case OOO_FRAME_ATTR_ACTIONS: 1721*cdf0e10cSrcweir m_aActions[OOO_FRAME_ATTR_ACTIONS] = 1722*cdf0e10cSrcweir new XMLTransformerActions( aFrameAttrActionTable ); 1723*cdf0e10cSrcweir break; 1724*cdf0e10cSrcweir case OOO_BACKGROUND_IMAGE_ACTIONS: 1725*cdf0e10cSrcweir // --> OD 2005-06-10 #i50322# 1726*cdf0e10cSrcweir // use special actions for Writer documents. 1727*cdf0e10cSrcweir m_aActions[OOO_BACKGROUND_IMAGE_ACTIONS] = 1728*cdf0e10cSrcweir isWriter() 1729*cdf0e10cSrcweir ? new XMLTransformerActions( aWriterBackgroundImageActionTable ) 1730*cdf0e10cSrcweir : new XMLTransformerActions( aBackgroundImageActionTable ); 1731*cdf0e10cSrcweir // <-- 1732*cdf0e10cSrcweir break; 1733*cdf0e10cSrcweir case OOO_DDE_CONNECTION_DECL_ACTIONS: 1734*cdf0e10cSrcweir m_aActions[OOO_DDE_CONNECTION_DECL_ACTIONS] = 1735*cdf0e10cSrcweir new XMLTransformerActions( aDDEConnectionDeclActionTable ); 1736*cdf0e10cSrcweir break; 1737*cdf0e10cSrcweir case OOO_EVENT_ACTIONS: 1738*cdf0e10cSrcweir m_aActions[OOO_EVENT_ACTIONS] = 1739*cdf0e10cSrcweir new XMLTransformerActions( aEventActionTable ); 1740*cdf0e10cSrcweir break; 1741*cdf0e10cSrcweir case OOO_FORM_CONTROL_ACTIONS: 1742*cdf0e10cSrcweir m_aActions[OOO_FORM_CONTROL_ACTIONS] = 1743*cdf0e10cSrcweir new XMLTransformerActions( aFormControlActionTable ); 1744*cdf0e10cSrcweir break; 1745*cdf0e10cSrcweir case OOO_FORM_COLUMN_ACTIONS: 1746*cdf0e10cSrcweir m_aActions[OOO_FORM_COLUMN_ACTIONS] = 1747*cdf0e10cSrcweir new XMLTransformerActions( aFormColumnActionTable ); 1748*cdf0e10cSrcweir break; 1749*cdf0e10cSrcweir case OOO_FORM_PROP_ACTIONS: 1750*cdf0e10cSrcweir m_aActions[OOO_FORM_PROP_ACTIONS] = 1751*cdf0e10cSrcweir new XMLTransformerActions( aFormPropActionTable ); 1752*cdf0e10cSrcweir break; 1753*cdf0e10cSrcweir case OOO_XLINK_ACTIONS: 1754*cdf0e10cSrcweir m_aActions[OOO_XLINK_ACTIONS] = 1755*cdf0e10cSrcweir new XMLTransformerActions( aXLinkActionTable ); 1756*cdf0e10cSrcweir break; 1757*cdf0e10cSrcweir case OOO_CONFIG_ITEM_SET_ACTIONS: 1758*cdf0e10cSrcweir m_aActions[OOO_CONFIG_ITEM_SET_ACTIONS] = 1759*cdf0e10cSrcweir new XMLTransformerActions( aConfigItemSetActionTable ); 1760*cdf0e10cSrcweir break; 1761*cdf0e10cSrcweir case OOO_FORMULA_ACTIONS: 1762*cdf0e10cSrcweir m_aActions[OOO_FORMULA_ACTIONS] = 1763*cdf0e10cSrcweir new XMLTransformerActions( aFormulaActionTable ); 1764*cdf0e10cSrcweir break; 1765*cdf0e10cSrcweir case OOO_CHART_ACTIONS: 1766*cdf0e10cSrcweir m_aActions[OOO_CHART_ACTIONS] = 1767*cdf0e10cSrcweir new XMLTransformerActions( aChartActionTable ); 1768*cdf0e10cSrcweir break; 1769*cdf0e10cSrcweir case OOO_ERROR_MACRO_ACTIONS: 1770*cdf0e10cSrcweir m_aActions[OOO_ERROR_MACRO_ACTIONS] = 1771*cdf0e10cSrcweir new XMLTransformerActions( aErrorMacroActionTable ); 1772*cdf0e10cSrcweir break; 1773*cdf0e10cSrcweir case OOO_DDE_CONV_MODE_ACTIONS: 1774*cdf0e10cSrcweir m_aActions[OOO_DDE_CONV_MODE_ACTIONS] = 1775*cdf0e10cSrcweir new XMLTransformerActions( aDDEConvModeActionTable ); 1776*cdf0e10cSrcweir break; 1777*cdf0e10cSrcweir case OOO_ALPHABETICAL_INDEX_MARK_ACTIONS: 1778*cdf0e10cSrcweir m_aActions[OOO_ALPHABETICAL_INDEX_MARK_ACTIONS] = 1779*cdf0e10cSrcweir new XMLTransformerActions( aAlphabeticalIndexMarkActionTable ); 1780*cdf0e10cSrcweir break; 1781*cdf0e10cSrcweir case OOO_DATAPILOT_MEMBER_ACTIONS: 1782*cdf0e10cSrcweir m_aActions[OOO_DATAPILOT_MEMBER_ACTIONS] = 1783*cdf0e10cSrcweir new XMLTransformerActions( aDataPilotMemberActionTable ); 1784*cdf0e10cSrcweir case OOO_DATAPILOT_LEVEL_ACTIONS: 1785*cdf0e10cSrcweir m_aActions[OOO_DATAPILOT_LEVEL_ACTIONS] = 1786*cdf0e10cSrcweir new XMLTransformerActions( aDataPilotLevelActionTable ); 1787*cdf0e10cSrcweir case OOO_SOURCE_SERVICE_ACTIONS: 1788*cdf0e10cSrcweir m_aActions[OOO_SOURCE_SERVICE_ACTIONS] = 1789*cdf0e10cSrcweir new XMLTransformerActions( aSourceServiceActionTable ); 1790*cdf0e10cSrcweir case OOO_DRAW_AREA_POLYGON_ACTIONS: 1791*cdf0e10cSrcweir m_aActions[OOO_DRAW_AREA_POLYGON_ACTIONS] = 1792*cdf0e10cSrcweir new XMLTransformerActions( aShapeActionTable ); 1793*cdf0e10cSrcweir m_aActions[OOO_DRAW_AREA_POLYGON_ACTIONS] 1794*cdf0e10cSrcweir ->Add( aDrawAreaPolygonActionTable ); 1795*cdf0e10cSrcweir break; 1796*cdf0e10cSrcweir case OOO_SCRIPT_ACTIONS: 1797*cdf0e10cSrcweir m_aActions[OOO_SCRIPT_ACTIONS] = 1798*cdf0e10cSrcweir new XMLTransformerActions( aScriptActionTable ); 1799*cdf0e10cSrcweir break; 1800*cdf0e10cSrcweir case OOO_ANIMATION_ACTIONS: 1801*cdf0e10cSrcweir m_aActions[OOO_ANIMATION_ACTIONS] = 1802*cdf0e10cSrcweir new XMLTransformerActions( aAnimationsActionTable ); 1803*cdf0e10cSrcweir break; 1804*cdf0e10cSrcweir } 1805*cdf0e10cSrcweir } 1806*cdf0e10cSrcweir pActions = m_aActions[n]; 1807*cdf0e10cSrcweir } 1808*cdf0e10cSrcweir 1809*cdf0e10cSrcweir return pActions; 1810*cdf0e10cSrcweir } 1811*cdf0e10cSrcweir 1812*cdf0e10cSrcweir OUString OOo2OasisTransformer::GetEventName( const OUString& rName, sal_Bool ) 1813*cdf0e10cSrcweir { 1814*cdf0e10cSrcweir if( !m_pEventMap ) 1815*cdf0e10cSrcweir m_pEventMap = XMLEventOOoTransformerContext::CreateEventMap(); 1816*cdf0e10cSrcweir 1817*cdf0e10cSrcweir OUString aNewName; 1818*cdf0e10cSrcweir sal_uInt16 nPrefix = XMLEventOOoTransformerContext::GetEventName( rName, 1819*cdf0e10cSrcweir aNewName, *m_pEventMap ); 1820*cdf0e10cSrcweir if( XML_NAMESPACE_UNKNOWN != nPrefix ) 1821*cdf0e10cSrcweir aNewName = GetNamespaceMap().GetQNameByKey( nPrefix, aNewName ); 1822*cdf0e10cSrcweir else 1823*cdf0e10cSrcweir aNewName = rName; 1824*cdf0e10cSrcweir 1825*cdf0e10cSrcweir return aNewName; 1826*cdf0e10cSrcweir } 1827*cdf0e10cSrcweir 1828*cdf0e10cSrcweir 1829*cdf0e10cSrcweir OOo2OasisTransformer::OOo2OasisTransformer( const sal_Char *pImplName, 1830*cdf0e10cSrcweir const sal_Char *pSubServiceName ) 1831*cdf0e10cSrcweir throw() : 1832*cdf0e10cSrcweir XMLTransformerBase( aActionTable, aTokenMap ), 1833*cdf0e10cSrcweir m_pEventMap( 0 ) 1834*cdf0e10cSrcweir { 1835*cdf0e10cSrcweir if( pImplName ) 1836*cdf0e10cSrcweir m_aImplName = OUString::createFromAscii( pImplName ); 1837*cdf0e10cSrcweir else 1838*cdf0e10cSrcweir m_aImplName = OOo2OasisTransformer_getImplementationName(); 1839*cdf0e10cSrcweir if( pSubServiceName ) 1840*cdf0e10cSrcweir m_aSubServiceName = OUString::createFromAscii( pSubServiceName ); 1841*cdf0e10cSrcweir 1842*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_OFFICE), GetXMLToken(XML_N_OFFICE_OOO), XML_NAMESPACE_OFFICE ); 1843*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_OFFICE), GetXMLToken(XML_N_OFFICE), XML_NAMESPACE_OFFICE ); 1844*cdf0e10cSrcweir 1845*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_META), GetXMLToken(XML_N_META_OOO), XML_NAMESPACE_META ); 1846*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_META), GetXMLToken(XML_N_META), XML_NAMESPACE_META ); 1847*cdf0e10cSrcweir 1848*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_STYLE), GetXMLToken(XML_N_STYLE_OOO), XML_NAMESPACE_STYLE ); 1849*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_STYLE), GetXMLToken(XML_N_STYLE), XML_NAMESPACE_STYLE ); 1850*cdf0e10cSrcweir 1851*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_NUMBER), GetXMLToken(XML_N_NUMBER_OOO), XML_NAMESPACE_NUMBER ); 1852*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_NUMBER), GetXMLToken(XML_N_NUMBER), XML_NAMESPACE_NUMBER ); 1853*cdf0e10cSrcweir 1854*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_CONFIG), GetXMLToken(XML_N_CONFIG_OOO), XML_NAMESPACE_CONFIG ); 1855*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_CONFIG), GetXMLToken(XML_N_CONFIG), XML_NAMESPACE_CONFIG ); 1856*cdf0e10cSrcweir 1857*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_TEXT), GetXMLToken(XML_N_TEXT_OOO), XML_NAMESPACE_TEXT ); 1858*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_TEXT), GetXMLToken(XML_N_TEXT), XML_NAMESPACE_TEXT ); 1859*cdf0e10cSrcweir 1860*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_TABLE), GetXMLToken(XML_N_TABLE_OOO), XML_NAMESPACE_TABLE ); 1861*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_TABLE), GetXMLToken(XML_N_TABLE), XML_NAMESPACE_TABLE ); 1862*cdf0e10cSrcweir 1863*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_DRAW), GetXMLToken(XML_N_DRAW_OOO), XML_NAMESPACE_DRAW ); 1864*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_DRAW), GetXMLToken(XML_N_DRAW), XML_NAMESPACE_DRAW ); 1865*cdf0e10cSrcweir 1866*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_DR3D), GetXMLToken(XML_N_DR3D_OOO), XML_NAMESPACE_DR3D ); 1867*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_DR3D), GetXMLToken(XML_N_DR3D), XML_NAMESPACE_DR3D ); 1868*cdf0e10cSrcweir 1869*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_PRESENTATION), GetXMLToken(XML_N_PRESENTATION_OOO), XML_NAMESPACE_PRESENTATION ); 1870*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_PRESENTATION), GetXMLToken(XML_N_PRESENTATION), XML_NAMESPACE_PRESENTATION ); 1871*cdf0e10cSrcweir 1872*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_CHART), GetXMLToken(XML_N_CHART_OOO), XML_NAMESPACE_CHART ); 1873*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_CHART), GetXMLToken(XML_N_CHART), XML_NAMESPACE_CHART ); 1874*cdf0e10cSrcweir 1875*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_FORM), GetXMLToken(XML_N_FORM_OOO), XML_NAMESPACE_FORM ); 1876*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_FORM), GetXMLToken(XML_N_FORM), XML_NAMESPACE_FORM ); 1877*cdf0e10cSrcweir 1878*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_SCRIPT), GetXMLToken(XML_N_SCRIPT_OOO), XML_NAMESPACE_SCRIPT ); 1879*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_SCRIPT), GetXMLToken(XML_N_SCRIPT), XML_NAMESPACE_SCRIPT ); 1880*cdf0e10cSrcweir 1881*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_FO), GetXMLToken(XML_N_FO), XML_NAMESPACE_FO ); 1882*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_FO), GetXMLToken(XML_N_FO_COMPAT), XML_NAMESPACE_FO ); 1883*cdf0e10cSrcweir 1884*cdf0e10cSrcweir GetNamespaceMap().Add( GetXMLToken(XML_NP_SVG), GetXMLToken(XML_N_SVG), XML_NAMESPACE_SVG ); 1885*cdf0e10cSrcweir GetReplaceNamespaceMap().Add( GetXMLToken(XML_NP_SVG), GetXMLToken(XML_N_SVG_COMPAT), XML_NAMESPACE_SVG ); 1886*cdf0e10cSrcweir 1887*cdf0e10cSrcweir for( sal_uInt16 i=0; i<MAX_OOO_ACTIONS; ++i ) 1888*cdf0e10cSrcweir m_aActions[i] = 0; 1889*cdf0e10cSrcweir } 1890*cdf0e10cSrcweir 1891*cdf0e10cSrcweir OOo2OasisTransformer::~OOo2OasisTransformer() throw() 1892*cdf0e10cSrcweir { 1893*cdf0e10cSrcweir for( sal_uInt16 i=0; i<MAX_OOO_ACTIONS; ++i ) 1894*cdf0e10cSrcweir delete m_aActions[i]; 1895*cdf0e10cSrcweir XMLEventOOoTransformerContext::FlushEventMap( m_pEventMap ); 1896*cdf0e10cSrcweir } 1897*cdf0e10cSrcweir 1898*cdf0e10cSrcweir Any OOo2OasisTransformer::queryInterface( const Type& rType ) 1899*cdf0e10cSrcweir throw (RuntimeException) 1900*cdf0e10cSrcweir { 1901*cdf0e10cSrcweir Any aRet; 1902*cdf0e10cSrcweir if ( rType == ::getCppuType((Reference<XImporter> *)0) ) 1903*cdf0e10cSrcweir { 1904*cdf0e10cSrcweir Reference<XImporter> xThis( this ); 1905*cdf0e10cSrcweir aRet <<= xThis; 1906*cdf0e10cSrcweir } 1907*cdf0e10cSrcweir else if ( rType == ::getCppuType((Reference<XFilter> *)0) ) 1908*cdf0e10cSrcweir { 1909*cdf0e10cSrcweir Reference<XFilter> xThis( this ); 1910*cdf0e10cSrcweir aRet <<= xThis; 1911*cdf0e10cSrcweir } 1912*cdf0e10cSrcweir else 1913*cdf0e10cSrcweir { 1914*cdf0e10cSrcweir aRet = XMLTransformerBase::queryInterface(rType); 1915*cdf0e10cSrcweir } 1916*cdf0e10cSrcweir 1917*cdf0e10cSrcweir return aRet; 1918*cdf0e10cSrcweir } 1919*cdf0e10cSrcweir 1920*cdf0e10cSrcweir // XImporter 1921*cdf0e10cSrcweir void SAL_CALL OOo2OasisTransformer::setTargetDocument( 1922*cdf0e10cSrcweir const Reference< XComponent >& xDoc ) 1923*cdf0e10cSrcweir throw( IllegalArgumentException, RuntimeException) 1924*cdf0e10cSrcweir { 1925*cdf0e10cSrcweir if( !GetDocHandler().is() ) 1926*cdf0e10cSrcweir { 1927*cdf0e10cSrcweir // if initialize hasn't been called, then we have to call it now 1928*cdf0e10cSrcweir // to get the sub component initialized. 1929*cdf0e10cSrcweir Sequence<Any> aArgs( 0 ); 1930*cdf0e10cSrcweir Initialize( aArgs ); 1931*cdf0e10cSrcweir } 1932*cdf0e10cSrcweir 1933*cdf0e10cSrcweir mxModel.set( xDoc, UNO_QUERY ); 1934*cdf0e10cSrcweir 1935*cdf0e10cSrcweir Reference< XImporter > xImp( GetDocHandler(), UNO_QUERY ); 1936*cdf0e10cSrcweir OSL_ENSURE( xImp.is(), "doc handler is not an importer" ); 1937*cdf0e10cSrcweir if( xImp.is() ) 1938*cdf0e10cSrcweir xImp->setTargetDocument( xDoc ); 1939*cdf0e10cSrcweir } 1940*cdf0e10cSrcweir 1941*cdf0e10cSrcweir // XFilter 1942*cdf0e10cSrcweir sal_Bool SAL_CALL OOo2OasisTransformer::filter( 1943*cdf0e10cSrcweir const Sequence< PropertyValue >& aDescriptor ) 1944*cdf0e10cSrcweir throw ( RuntimeException) 1945*cdf0e10cSrcweir { 1946*cdf0e10cSrcweir Reference< XFilter> xFilter( GetDocHandler(), UNO_QUERY ); 1947*cdf0e10cSrcweir OSL_ENSURE( xFilter.is(), "doc handler is not a filter" ); 1948*cdf0e10cSrcweir if( xFilter.is() ) 1949*cdf0e10cSrcweir return xFilter->filter( aDescriptor ); 1950*cdf0e10cSrcweir 1951*cdf0e10cSrcweir return sal_False; 1952*cdf0e10cSrcweir } 1953*cdf0e10cSrcweir 1954*cdf0e10cSrcweir void SAL_CALL OOo2OasisTransformer::cancel( ) 1955*cdf0e10cSrcweir throw ( RuntimeException) 1956*cdf0e10cSrcweir { 1957*cdf0e10cSrcweir Reference< XFilter> xFilter( GetDocHandler(), UNO_QUERY ); 1958*cdf0e10cSrcweir OSL_ENSURE( xFilter.is(), "doc handler is not a filter" ); 1959*cdf0e10cSrcweir if( xFilter.is() ) 1960*cdf0e10cSrcweir xFilter->cancel(); 1961*cdf0e10cSrcweir } 1962*cdf0e10cSrcweir 1963*cdf0e10cSrcweir // XInitialize 1964*cdf0e10cSrcweir void SAL_CALL OOo2OasisTransformer::initialize( 1965*cdf0e10cSrcweir const Sequence< Any >& rArguments ) 1966*cdf0e10cSrcweir throw( Exception, RuntimeException ) 1967*cdf0e10cSrcweir { 1968*cdf0e10cSrcweir Initialize( rArguments ); 1969*cdf0e10cSrcweir } 1970*cdf0e10cSrcweir 1971*cdf0e10cSrcweir void SAL_CALL OOo2OasisTransformer::startDocument( void ) 1972*cdf0e10cSrcweir throw( SAXException, RuntimeException ) 1973*cdf0e10cSrcweir { 1974*cdf0e10cSrcweir if( !GetDocHandler().is() ) 1975*cdf0e10cSrcweir { 1976*cdf0e10cSrcweir // if initialize hasn't been called, then we have to call it now 1977*cdf0e10cSrcweir // to get the sub component initialized. 1978*cdf0e10cSrcweir Sequence<Any> aArgs( 0 ); 1979*cdf0e10cSrcweir Initialize( aArgs ); 1980*cdf0e10cSrcweir } 1981*cdf0e10cSrcweir 1982*cdf0e10cSrcweir XMLTransformerBase::startDocument(); 1983*cdf0e10cSrcweir } 1984*cdf0e10cSrcweir 1985*cdf0e10cSrcweir 1986*cdf0e10cSrcweir void SAL_CALL OOo2OasisTransformer::Initialize( 1987*cdf0e10cSrcweir const Sequence< Any >& rArguments ) 1988*cdf0e10cSrcweir throw( Exception, RuntimeException ) 1989*cdf0e10cSrcweir { 1990*cdf0e10cSrcweir OSL_ENSURE( !GetDocHandler().is(), "duplication initialization" ); 1991*cdf0e10cSrcweir 1992*cdf0e10cSrcweir Reference< XDocumentHandler > xDocHandler; 1993*cdf0e10cSrcweir if( m_aSubServiceName.getLength() ) 1994*cdf0e10cSrcweir { 1995*cdf0e10cSrcweir Reference< XMultiServiceFactory > xFactory = 1996*cdf0e10cSrcweir comphelper::getProcessServiceFactory(); 1997*cdf0e10cSrcweir if( xFactory.is() ) 1998*cdf0e10cSrcweir { 1999*cdf0e10cSrcweir try 2000*cdf0e10cSrcweir { 2001*cdf0e10cSrcweir // get filter component 2002*cdf0e10cSrcweir xDocHandler = Reference< XDocumentHandler >( 2003*cdf0e10cSrcweir xFactory->createInstanceWithArguments( m_aSubServiceName, 2004*cdf0e10cSrcweir rArguments ), 2005*cdf0e10cSrcweir UNO_QUERY); 2006*cdf0e10cSrcweir } 2007*cdf0e10cSrcweir catch( Exception& ) 2008*cdf0e10cSrcweir { 2009*cdf0e10cSrcweir } 2010*cdf0e10cSrcweir } 2011*cdf0e10cSrcweir } 2012*cdf0e10cSrcweir 2013*cdf0e10cSrcweir OSL_ENSURE( xDocHandler.is(), "can't instantiate filter component" ); 2014*cdf0e10cSrcweir if( xDocHandler.is() ) 2015*cdf0e10cSrcweir { 2016*cdf0e10cSrcweir Sequence<Any> aArgs( 1 + rArguments.getLength() ); 2017*cdf0e10cSrcweir aArgs[0] <<= xDocHandler; 2018*cdf0e10cSrcweir for(sal_Int32 i = 0; i < rArguments.getLength(); i++) 2019*cdf0e10cSrcweir aArgs[i+1] = rArguments[i]; 2020*cdf0e10cSrcweir XMLTransformerBase::initialize( aArgs ); 2021*cdf0e10cSrcweir 2022*cdf0e10cSrcweir OSL_ENSURE( GetDocHandler() == xDocHandler, 2023*cdf0e10cSrcweir "duplicate doc handler" ); 2024*cdf0e10cSrcweir } 2025*cdf0e10cSrcweir else 2026*cdf0e10cSrcweir { 2027*cdf0e10cSrcweir XMLTransformerBase::initialize( rArguments ); 2028*cdf0e10cSrcweir } 2029*cdf0e10cSrcweir } 2030*cdf0e10cSrcweir 2031*cdf0e10cSrcweir 2032*cdf0e10cSrcweir Sequence< sal_Int8 > static CreateUnoTunnelId() 2033*cdf0e10cSrcweir { 2034*cdf0e10cSrcweir static osl::Mutex aCreateMutex; 2035*cdf0e10cSrcweir ::osl::Guard<osl::Mutex> aGuard( aCreateMutex ); 2036*cdf0e10cSrcweir Sequence< sal_Int8 > aSeq( 16 ); 2037*cdf0e10cSrcweir rtl_createUuid( (sal_uInt8*)aSeq.getArray(), 0, sal_True ); 2038*cdf0e10cSrcweir return aSeq; 2039*cdf0e10cSrcweir } 2040*cdf0e10cSrcweir 2041*cdf0e10cSrcweir const Sequence< sal_Int8 > & OOo2OasisTransformer::getUnoTunnelId() throw() 2042*cdf0e10cSrcweir { 2043*cdf0e10cSrcweir static Sequence< sal_Int8 > aSeq = ::CreateUnoTunnelId(); 2044*cdf0e10cSrcweir return aSeq; 2045*cdf0e10cSrcweir } 2046*cdf0e10cSrcweir 2047*cdf0e10cSrcweir // XUnoTunnel 2048*cdf0e10cSrcweir sal_Int64 SAL_CALL OOo2OasisTransformer::getSomething( const Sequence< sal_Int8 >& rId ) 2049*cdf0e10cSrcweir throw(RuntimeException) 2050*cdf0e10cSrcweir { 2051*cdf0e10cSrcweir if( rId.getLength() == 16 2052*cdf0e10cSrcweir && 0 == rtl_compareMemory( getUnoTunnelId().getConstArray(), 2053*cdf0e10cSrcweir rId.getConstArray(), 16 ) ) 2054*cdf0e10cSrcweir { 2055*cdf0e10cSrcweir return reinterpret_cast< sal_Int64 >( this ); 2056*cdf0e10cSrcweir } 2057*cdf0e10cSrcweir else 2058*cdf0e10cSrcweir { 2059*cdf0e10cSrcweir return (sal_Int64)0; 2060*cdf0e10cSrcweir } 2061*cdf0e10cSrcweir } 2062*cdf0e10cSrcweir 2063*cdf0e10cSrcweir // XServiceInfo 2064*cdf0e10cSrcweir OUString SAL_CALL OOo2OasisTransformer::getImplementationName() 2065*cdf0e10cSrcweir throw(RuntimeException) 2066*cdf0e10cSrcweir { 2067*cdf0e10cSrcweir return m_aImplName; 2068*cdf0e10cSrcweir } 2069*cdf0e10cSrcweir 2070*cdf0e10cSrcweir sal_Bool SAL_CALL OOo2OasisTransformer::supportsService( const OUString& ) 2071*cdf0e10cSrcweir throw(RuntimeException) 2072*cdf0e10cSrcweir { 2073*cdf0e10cSrcweir return sal_False; 2074*cdf0e10cSrcweir } 2075*cdf0e10cSrcweir 2076*cdf0e10cSrcweir Sequence< OUString > SAL_CALL OOo2OasisTransformer::getSupportedServiceNames( ) 2077*cdf0e10cSrcweir throw(RuntimeException) 2078*cdf0e10cSrcweir { 2079*cdf0e10cSrcweir Sequence<OUString> aSeq(0); 2080*cdf0e10cSrcweir return aSeq; 2081*cdf0e10cSrcweir } 2082*cdf0e10cSrcweir 2083*cdf0e10cSrcweir // XTypeProvider 2084*cdf0e10cSrcweir Sequence< ::com::sun::star::uno::Type > SAL_CALL 2085*cdf0e10cSrcweir OOo2OasisTransformer::getTypes() throw(RuntimeException) 2086*cdf0e10cSrcweir { 2087*cdf0e10cSrcweir Sequence< ::com::sun::star::uno::Type > aTypes( 2088*cdf0e10cSrcweir XMLTransformerBase::getTypes() ); 2089*cdf0e10cSrcweir 2090*cdf0e10cSrcweir sal_Int32 nIndex = aTypes.getLength(); 2091*cdf0e10cSrcweir aTypes.realloc( nIndex + 2 ); 2092*cdf0e10cSrcweir 2093*cdf0e10cSrcweir ::com::sun::star::uno::Type* pTypes = aTypes.getArray(); 2094*cdf0e10cSrcweir pTypes[nIndex++] = ::getCppuType( static_cast< Reference< XImporter > * >( 0 ) ); 2095*cdf0e10cSrcweir pTypes[nIndex++] = ::getCppuType( static_cast< Reference< XFilter > * >( 0 ) ); 2096*cdf0e10cSrcweir 2097*cdf0e10cSrcweir return aTypes; 2098*cdf0e10cSrcweir } 2099*cdf0e10cSrcweir 2100*cdf0e10cSrcweir // Service registration 2101*cdf0e10cSrcweir 2102*cdf0e10cSrcweir OUString SAL_CALL OOo2OasisTransformer_getImplementationName() throw() 2103*cdf0e10cSrcweir { 2104*cdf0e10cSrcweir return OUString( RTL_CONSTASCII_USTRINGPARAM( 2105*cdf0e10cSrcweir "com.sun.star.comp.OOo2OasisTransformer" ) ); 2106*cdf0e10cSrcweir } 2107*cdf0e10cSrcweir 2108*cdf0e10cSrcweir Sequence< OUString > SAL_CALL OOo2OasisTransformer_getSupportedServiceNames() throw() 2109*cdf0e10cSrcweir { 2110*cdf0e10cSrcweir const OUString aServiceName( OOo2OasisTransformer_getImplementationName() ); 2111*cdf0e10cSrcweir const Sequence< OUString > aSeq( &aServiceName, 1 ); 2112*cdf0e10cSrcweir return aSeq; 2113*cdf0e10cSrcweir } 2114*cdf0e10cSrcweir 2115*cdf0e10cSrcweir Reference< XInterface > SAL_CALL OOo2OasisTransformer_createInstance( 2116*cdf0e10cSrcweir const Reference< XMultiServiceFactory > & ) 2117*cdf0e10cSrcweir throw( Exception ) 2118*cdf0e10cSrcweir { 2119*cdf0e10cSrcweir return (cppu::OWeakObject*)new OOo2OasisTransformer(); 2120*cdf0e10cSrcweir } 2121*cdf0e10cSrcweir 2122*cdf0e10cSrcweir #define OOO_IMPORTER( className, implName, subServiceName ) \ 2123*cdf0e10cSrcweir OUString SAL_CALL className##_getImplementationName() throw() \ 2124*cdf0e10cSrcweir { \ 2125*cdf0e10cSrcweir return OUString( RTL_CONSTASCII_USTRINGPARAM( implName ) ); \ 2126*cdf0e10cSrcweir } \ 2127*cdf0e10cSrcweir \ 2128*cdf0e10cSrcweir Sequence< OUString > SAL_CALL className##_getSupportedServiceNames() throw()\ 2129*cdf0e10cSrcweir { \ 2130*cdf0e10cSrcweir const OUString aServiceName( className##_getImplementationName() ); \ 2131*cdf0e10cSrcweir const Sequence< OUString > aSeq( &aServiceName, 1 ); \ 2132*cdf0e10cSrcweir return aSeq; \ 2133*cdf0e10cSrcweir } \ 2134*cdf0e10cSrcweir \ 2135*cdf0e10cSrcweir Reference< XInterface > SAL_CALL className##_createInstance( \ 2136*cdf0e10cSrcweir const Reference< XMultiServiceFactory > & ) \ 2137*cdf0e10cSrcweir throw( Exception ) \ 2138*cdf0e10cSrcweir { \ 2139*cdf0e10cSrcweir return (cppu::OWeakObject*)new OOo2OasisTransformer( implName, \ 2140*cdf0e10cSrcweir subServiceName ); \ 2141*cdf0e10cSrcweir } 2142*cdf0e10cSrcweir 2143*cdf0e10cSrcweir OOO_IMPORTER( XMLWriterImportOOO, 2144*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLImporter", 2145*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLOasisImporter" ) 2146*cdf0e10cSrcweir OOO_IMPORTER( XMLWriterStylesImportOOO, 2147*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLStylesImporter", 2148*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLOasisStylesImporter" ) 2149*cdf0e10cSrcweir OOO_IMPORTER( XMLWriterContentImportOOO, 2150*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLContentImporter", 2151*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLOasisContentImporter" ) 2152*cdf0e10cSrcweir OOO_IMPORTER( XMLWriterMetaImportOOO, 2153*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLMetaImporter", 2154*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLOasisMetaImporter" ) 2155*cdf0e10cSrcweir OOO_IMPORTER( XMLWriterSettingsImportOOO, 2156*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLSettingsImporter", 2157*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLOasisSettingsImporter" ) 2158*cdf0e10cSrcweir 2159*cdf0e10cSrcweir OOO_IMPORTER( XMLImpressImportOOO, 2160*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLImporter", 2161*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLOasisImporter" ) 2162*cdf0e10cSrcweir OOO_IMPORTER( XMLImpressStylesImportOOO, 2163*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLStylesImporter", 2164*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLOasisStylesImporter" ) 2165*cdf0e10cSrcweir OOO_IMPORTER( XMLImpressContentImportOOO, 2166*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLContentImporter", 2167*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLOasisContentImporter" ) 2168*cdf0e10cSrcweir OOO_IMPORTER( XMLImpressMetaImportOOO, 2169*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLMetaImporter", 2170*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLOasisMetaImporter" ) 2171*cdf0e10cSrcweir OOO_IMPORTER( XMLImpressSettingsImportOOO, 2172*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLSettingsImporter", 2173*cdf0e10cSrcweir "com.sun.star.comp.Impress.XMLOasisSettingsImporter" ) 2174*cdf0e10cSrcweir 2175*cdf0e10cSrcweir OOO_IMPORTER( XMLDrawImportOOO, 2176*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLImporter", 2177*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLOasisImporter" ) 2178*cdf0e10cSrcweir OOO_IMPORTER( XMLDrawStylesImportOOO, 2179*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLStylesImporter", 2180*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLOasisStylesImporter" ) 2181*cdf0e10cSrcweir OOO_IMPORTER( XMLDrawContentImportOOO, 2182*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLContentImporter", 2183*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLOasisContentImporter" ) 2184*cdf0e10cSrcweir OOO_IMPORTER( XMLDrawMetaImportOOO, 2185*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLMetaImporter", 2186*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLOasisMetaImporter" ) 2187*cdf0e10cSrcweir OOO_IMPORTER( XMLDrawSettingsImportOOO, 2188*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLSettingsImporter", 2189*cdf0e10cSrcweir "com.sun.star.comp.Draw.XMLOasisSettingsImporter" ) 2190*cdf0e10cSrcweir 2191*cdf0e10cSrcweir OOO_IMPORTER( XMLCalcImportOOO, 2192*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLImporter", 2193*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLOasisImporter" ) 2194*cdf0e10cSrcweir OOO_IMPORTER( XMLCalcStylesImportOOO, 2195*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLStylesImporter", 2196*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLOasisStylesImporter" ) 2197*cdf0e10cSrcweir OOO_IMPORTER( XMLCalcContentImportOOO, 2198*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLContentImporter", 2199*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLOasisContentImporter" ) 2200*cdf0e10cSrcweir OOO_IMPORTER( XMLCalcMetaImportOOO, 2201*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLMetaImporter", 2202*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLOasisMetaImporter" ) 2203*cdf0e10cSrcweir OOO_IMPORTER( XMLCalcSettingsImportOOO, 2204*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLSettingsImporter", 2205*cdf0e10cSrcweir "com.sun.star.comp.Calc.XMLOasisSettingsImporter" ) 2206*cdf0e10cSrcweir 2207*cdf0e10cSrcweir OOO_IMPORTER( XMLChartImportOOO, 2208*cdf0e10cSrcweir "com.sun.star.comp.Chart.XMLImporter", 2209*cdf0e10cSrcweir "com.sun.star.comp.Chart.XMLOasisImporter" ) 2210*cdf0e10cSrcweir OOO_IMPORTER( XMLChartStylesImportOOO, 2211*cdf0e10cSrcweir "com.sun.star.comp.Chart.XMLStylesImporter", 2212*cdf0e10cSrcweir "com.sun.star.comp.Chart.XMLOasisStylesImporter" ) 2213*cdf0e10cSrcweir OOO_IMPORTER( XMLChartContentImportOOO, 2214*cdf0e10cSrcweir "com.sun.star.comp.Chart.XMLContentImporter", 2215*cdf0e10cSrcweir "com.sun.star.comp.Chart.XMLOasisContentImporter" ) 2216*cdf0e10cSrcweir 2217*cdf0e10cSrcweir OOO_IMPORTER( XMLMathMetaImportOOO, 2218*cdf0e10cSrcweir "com.sun.star.comp.Math.XMLMetaImporter", 2219*cdf0e10cSrcweir "com.sun.star.comp.Math.XMLOasisMetaImporter" ) 2220*cdf0e10cSrcweir OOO_IMPORTER( XMLMathSettingsImportOOO, 2221*cdf0e10cSrcweir "com.sun.star.comp.Math.XMLSettingsImporter", 2222*cdf0e10cSrcweir "com.sun.star.comp.Math.XMLOasisSettingsImporter" ) 2223*cdf0e10cSrcweir 2224*cdf0e10cSrcweir OOO_IMPORTER( XMLMetaImportOOO, 2225*cdf0e10cSrcweir "com.sun.star.document.XMLMetaImporter", 2226*cdf0e10cSrcweir "com.sun.star.document.XMLOasisMetaImporter" ) 2227*cdf0e10cSrcweir 2228*cdf0e10cSrcweir OOO_IMPORTER( XMLAutoTextEventImportOOO, 2229*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLAutotextEventsImporter", 2230*cdf0e10cSrcweir "com.sun.star.comp.Writer.XMLOasisAutotextEventsImporter" ) 2231