odf2uof_presentation.xsl 239 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. * This file is part of the LibreOffice project.
  4. *
  5. * This Source Code Form is subject to the terms of the Mozilla Public
  6. * License, v. 2.0. If a copy of the MPL was not distributed with this
  7. * file, You can obtain one at http://mozilla.org/MPL/2.0/.
  8. *
  9. * This file incorporates work covered by the following license notice:
  10. *
  11. * Licensed to the Apache Software Foundation (ASF) under one or more
  12. * contributor license agreements. See the NOTICE file distributed
  13. * with this work for additional information regarding copyright
  14. * ownership. The ASF licenses this file to you under the Apache
  15. * License, Version 2.0 (the "License"); you may not use this file
  16. * except in compliance with the License. You may obtain a copy of
  17. * the License at http://www.apache.org/licenses/LICENSE-2.0 .
  18. -->
  19. <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:smil="urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0" xmlns:anim="urn:oasis:names:tc:opendocument:xmlns:animation:1.0" xmlns:uof="http://schemas.uof.org/cn/2003/uof" xmlns:表="http://schemas.uof.org/cn/2003/uof-spreadsheet" xmlns:演="http://schemas.uof.org/cn/2003/uof-slideshow" xmlns:字="http://schemas.uof.org/cn/2003/uof-wordproc" xmlns:数="http://www.w3.org/1998/Math/MathML" xmlns:图="http://schemas.uof.org/cn/2003/graph" exclude-result-prefixes="office style text table draw fo xlink dc meta number presentation svg chart dr3d math form script config ooo ooow oooc dom xforms smil anim">
  20. <xsl:output method="xml" indent="no" encoding="UTF-8" version="1.0" standalone="no" omit-xml-declaration="no"/>
  21. <xsl:variable name="impresswithUnit">
  22. <xsl:value-of select="/office:document/office:styles/style:style[@style:family='graphic']/style:graphic-properties/@svg:stroke-width"/>
  23. </xsl:variable>
  24. <xsl:variable name="uofUnit">
  25. <xsl:choose>
  26. <xsl:when test="contains($impresswithUnit,'inch')">inch</xsl:when>
  27. <xsl:when test="contains($impresswithUnit,'cm')">cm</xsl:when>
  28. <xsl:when test="contains($impresswithUnit,'mm')">mm</xsl:when>
  29. <xsl:when test="contains($impresswithUnit,'pt')">pt</xsl:when>
  30. <xsl:otherwise>cm</xsl:otherwise>
  31. </xsl:choose>
  32. </xsl:variable>
  33. <xsl:variable name="cm-to-other">
  34. <xsl:choose>
  35. <xsl:when test="$uofUnit='cm'">1</xsl:when>
  36. <xsl:when test="$uofUnit='inch'">0.394</xsl:when>
  37. <xsl:when test="$uofUnit='pt'">28.346</xsl:when>
  38. <xsl:when test="$uofUnit='mm'">10</xsl:when>
  39. <xsl:when test="$uofUnit='pica'">2.364</xsl:when>
  40. <xsl:otherwise>1</xsl:otherwise>
  41. </xsl:choose>
  42. </xsl:variable>
  43. <xsl:key match="/office:document/office:automatic-styles/style:style | /office:document/office:styles/style:style" name="graphicset" use="@style:name"/>
  44. <xsl:template match="/">
  45. <xsl:apply-templates select="office:document"/>
  46. </xsl:template>
  47. <xsl:template match="office:document">
  48. <uof:UOF xmlns:uof="http://schemas.uof.org/cn/2003/uof" xmlns:图="http://schemas.uof.org/cn/2003/graph" xmlns:数="http://www.w3.org/1998/Math/MathML" xmlns:字="http://schemas.uof.org/cn/2003/uof-wordproc" xmlns:演="http://schemas.uof.org/cn/2003/uof-slideshow" xmlns:表="http://schemas.uof.org/cn/2003/uof-spreadsheet" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" uof:language="cn" uof:version="1.0" uof:locID="u0000" uof:mimetype="vnd.uof.presentation">
  49. <xsl:apply-templates select="office:meta"/>
  50. <xsl:if test="//text:bookmark|//text:bookmark-start">
  51. <uof:书签集 uof:locID="u0027">
  52. <xsl:for-each select="//text:bookmark|//text:bookmark-start">
  53. <uof:书签 uof:名称="{@text:name}" uof:locID="u0028" uof:attrList="名称">
  54. <uof:文本位置 uof:区域引用="{generate-id(.)}" uof:locID="u0029" uof:attrList="区域引用"/>
  55. </uof:书签>
  56. </xsl:for-each>
  57. </uof:书签集>
  58. </xsl:if>
  59. <xsl:if test="/office:document/office:body/text:p/text:a | /office:document/office:body/text:p/draw:a">
  60. <uof:链接集 uof:locID="u0031">
  61. <xsl:for-each select="/office:document/office:body/text:p/text:a | /office:document/office:body/text:p/draw:a">
  62. <xsl:variable name="hyperStr" select="@xlink:href"/>
  63. <uof:超级链接 uof:locID="u0032" uof:attrList="标识符 目标 书签 式样引用 已访问式样引用 提示 链源">
  64. <xsl:if test="contains($hyperStr,'#')">
  65. <xsl:attribute name="uof:书签"><xsl:value-of select="substring-after($hyperStr,'#')"/></xsl:attribute>
  66. <xsl:attribute name="uof:提示"><xsl:value-of select="."/></xsl:attribute>
  67. </xsl:if>
  68. <xsl:variable name="num">
  69. <xsl:number from="/office:document/office:body" level="any" count="text:p[text:a]"/>
  70. </xsl:variable>
  71. <xsl:attribute name="uof:链源"><xsl:value-of select="concat('hlnk',$num)"/></xsl:attribute>
  72. <xsl:attribute name="uof:标识符"><xsl:value-of select="concat('hyk_','hlnk',$num)"/></xsl:attribute>
  73. <xsl:if test="not(contains($hyperStr,'#'))">
  74. <xsl:attribute name="uof:目标"><xsl:value-of select="$hyperStr"/></xsl:attribute>
  75. <xsl:choose>
  76. <xsl:when test="contains($hyperStr,'@')">
  77. <xsl:attribute name="uof:提示">链接到邮件地址</xsl:attribute>
  78. </xsl:when>
  79. <xsl:otherwise>
  80. <xsl:attribute name="uof:提示">链接文件</xsl:attribute>
  81. </xsl:otherwise>
  82. </xsl:choose>
  83. </xsl:if>
  84. <xsl:if test="@text:style-name">
  85. <xsl:attribute name="uof:式样引用"><xsl:value-of select="@text:style-name"/></xsl:attribute>
  86. </xsl:if>
  87. <xsl:if test="@text:visited-style-name">
  88. <xsl:attribute name="uof:已访问式样引用"><xsl:value-of select="@text:visited-style-name"/></xsl:attribute>
  89. </xsl:if>
  90. </uof:超级链接>
  91. </xsl:for-each>
  92. </uof:链接集>
  93. </xsl:if>
  94. <uof:对象集 uof:locID="u0033">
  95. <xsl:apply-templates select="office:master-styles/style:handout-master" mode="styles"/>
  96. <xsl:apply-templates select="office:master-styles/style:master-page" mode="styles"/>
  97. <xsl:apply-templates select="office:body/office:presentation/draw:page" mode="styles"/>
  98. <xsl:apply-templates select="office:styles/style:presentation-page-layout/presentation:placeholder" mode="graphic"/>
  99. <xsl:apply-templates select="office:body/office:presentation/draw:page/presentation:notes" mode="styles"/>
  100. <xsl:for-each select="(/office:document/office:styles/draw:fill-image) | (/office:document/office:automatic-styles/draw:fill-image)">
  101. <uof:其他对象 uof:locID="u0036" uof:attrList="标识符 内嵌 公共类型 私有类型">
  102. <xsl:attribute name="uof:标识符"><xsl:value-of select="@draw:name"/></xsl:attribute>
  103. <xsl:attribute name="uof:公共类型">jpg</xsl:attribute>
  104. <xsl:attribute name="uof:内嵌">true</xsl:attribute>
  105. <uof:数据 uof:locID="u0037">
  106. <xsl:value-of select="office:binary-data"/>
  107. </uof:数据>
  108. </uof:其他对象>
  109. </xsl:for-each>
  110. <xsl:for-each select="(/office:document/office:styles/style:style/style:graphic-properties/text:list-style/text:list-level-style-image) | (/office:document/office:automatic-styles/style:style/style:graphic-properties/text:list-style/text:list-level-style-image)">
  111. <uof:其他对象 uof:locID="u0036" uof:attrList="标识符 内嵌 公共类型 私有类型">
  112. <xsl:attribute name="uof:标识符"><xsl:value-of select="concat('image_numbering_',count(preceding::text:list-level-style-image))"/></xsl:attribute>
  113. <xsl:attribute name="uof:公共类型">jpg</xsl:attribute>
  114. <xsl:attribute name="uof:内嵌">true</xsl:attribute>
  115. <uof:数据 uof:locID="u0037">
  116. <xsl:value-of select="office:binary-data"/>
  117. </uof:数据>
  118. </uof:其他对象>
  119. </xsl:for-each>
  120. </uof:对象集>
  121. <uof:式样集 uof:locID="u0039">
  122. <xsl:apply-templates select="office:font-face-decls"/>
  123. <xsl:element name="uof:自动编号集">
  124. <xsl:attribute name="uof:locID">u0042</xsl:attribute>
  125. <xsl:for-each select="/office:document//text:list-style">
  126. <xsl:element name="字:自动编号">
  127. <xsl:attribute name="uof:locID">t0169</xsl:attribute>
  128. <xsl:attribute name="uof:attrList">标识符 名称 父编号引用 多级编号</xsl:attribute>
  129. <xsl:attribute name="字:标识符">
  130. <xsl:variable name="count1" select="count(preceding::text:list-style)"/>
  131. <xsl:choose><xsl:when test="@style:name"><xsl:value-of select="concat(@style:name,$count1)"/></xsl:when><xsl:otherwise><xsl:value-of select="concat(../../@style:name,$count1)"/></xsl:otherwise></xsl:choose></xsl:attribute>
  132. <xsl:attribute name="字:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  133. <xsl:attribute name="字:多级编号">true</xsl:attribute>
  134. <xsl:for-each select="./* ">
  135. <xsl:if test="number(@text:level) &lt; 10">
  136. <xsl:element name="字:级别">
  137. <xsl:attribute name="uof:locID">t0159</xsl:attribute>
  138. <xsl:attribute name="uof:attrList">级别值 编号对齐方式 尾随字符</xsl:attribute>
  139. <xsl:attribute name="字:级别值"><xsl:value-of select="number(@text:level)"/></xsl:attribute>
  140. <xsl:if test="style:list-level-properties/@fo:text-align">
  141. <xsl:attribute name="字:编号对齐方式"><xsl:value-of select="style:list-level-properties/@fo:text-align"/></xsl:attribute>
  142. </xsl:if>
  143. <xsl:variable name="level">
  144. <xsl:value-of select="@text:level"/>
  145. </xsl:variable>
  146. <xsl:if test="office:binary-data">
  147. <xsl:element name="字:图片符号引用" uof:locID="t0164" uof:attrList="宽度 高度">
  148. <xsl:attribute name="字:宽度"><xsl:value-of select="substring-before(style:list-level-properties/@fo:width,$uofUnit)"/></xsl:attribute>
  149. <xsl:attribute name="字:高度"><xsl:value-of select="substring-before(style:list-level-properties/@fo:height,$uofUnit)"/></xsl:attribute>
  150. <xsl:value-of select="concat('image_numbering_',count(preceding::text:list-level-style-image))"/>
  151. </xsl:element>
  152. </xsl:if>
  153. <xsl:if test="@text:bullet-char">
  154. <xsl:element name="字:项目符号">
  155. <xsl:attribute name="uof:locID">t0171</xsl:attribute>
  156. <xsl:value-of select="@text:bullet-char"/>
  157. </xsl:element>
  158. </xsl:if>
  159. <xsl:element name="字:符号字体">
  160. <xsl:attribute name="uof:locID">t0160</xsl:attribute>
  161. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  162. <xsl:call-template name="字:句属性"/>
  163. </xsl:element>
  164. <xsl:if test="@style:num-format">
  165. <xsl:choose>
  166. <xsl:when test="string(@style:num-format)='a'">
  167. <xsl:element name="字:编号格式" uof:locID="t0162">lower-letter</xsl:element>
  168. </xsl:when>
  169. <xsl:when test="string(@style:num-format)='A'">
  170. <xsl:element name="字:编号格式" uof:locID="t0162">upper-letter</xsl:element>
  171. </xsl:when>
  172. <xsl:when test="string(@style:num-format)='i'">
  173. <xsl:element name="字:编号格式" uof:locID="t0162">lower-roman</xsl:element>
  174. </xsl:when>
  175. <xsl:when test="string(@style:num-format)='I'">
  176. <xsl:element name="字:编号格式" uof:locID="t0162">upper-roman</xsl:element>
  177. </xsl:when>
  178. <xsl:when test="string(@style:num-format)='①, ②, ③, ...'">
  179. <xsl:element name="字:编号格式" uof:locID="t0162">decimal-enclosed-circle</xsl:element>
  180. </xsl:when>
  181. <xsl:when test="string(@style:num-format)='甲, 乙, 丙, ...'">
  182. <xsl:element name="字:编号格式" uof:locID="t0162">ideograph-traditional</xsl:element>
  183. </xsl:when>
  184. <xsl:when test="string(@style:num-format)='子, 丑, 寅, ...'">
  185. <xsl:element name="字:编号格式" uof:locID="t0162">ideograph-zodiac</xsl:element>
  186. </xsl:when>
  187. <xsl:when test="string(@style:num-format)='一, 二, 三, ...'">
  188. <xsl:element name="字:编号格式" uof:locID="t0162">chinese-counting</xsl:element>
  189. </xsl:when>
  190. <xsl:when test="string(@style:num-format)='壹, 贰, 叁, ...'">
  191. <xsl:element name="字:编号格式" uof:locID="t0162">chinese-legal-simplified</xsl:element>
  192. </xsl:when>
  193. <xsl:otherwise>
  194. <xsl:element name="字:编号格式" uof:locID="t0162">decimal</xsl:element>
  195. </xsl:otherwise>
  196. </xsl:choose>
  197. </xsl:if>
  198. <xsl:variable name="jibie">
  199. <xsl:value-of select="position()"/>
  200. </xsl:variable>
  201. <xsl:variable name="xianshijibie">
  202. <xsl:choose>
  203. <xsl:when test="@text:display-levels">
  204. <xsl:value-of select="@text:display-levels"/>
  205. </xsl:when>
  206. <xsl:otherwise>1</xsl:otherwise>
  207. </xsl:choose>
  208. </xsl:variable>
  209. <字:编号格式表示 uof:locID="t0163">
  210. <xsl:call-template name="字:编号格式表示">
  211. <xsl:with-param name="bubianjibie" select="$jibie"/>
  212. <xsl:with-param name="jibie" select="$jibie"/>
  213. <xsl:with-param name="xianshijibie" select="$xianshijibie"/>
  214. <xsl:with-param name="biaoshi" select="concat(string(@style:num-prefix),'%',$jibie,string(@style:num-suffix))"/>
  215. </xsl:call-template>
  216. </字:编号格式表示>
  217. <xsl:element name="字:缩进">
  218. <xsl:attribute name="uof:locID">t0165</xsl:attribute>
  219. <xsl:call-template name="字:缩进类型"/>
  220. </xsl:element>
  221. <xsl:element name="字:制表符位置">
  222. <xsl:attribute name="uof:locID">t0166</xsl:attribute>
  223. <xsl:value-of select="substring-before(style:list-level-properties/@text:min-label-width,$uofUnit)"/>
  224. </xsl:element>
  225. <xsl:if test="@text:start-value">
  226. <xsl:element name="字:起始编号">
  227. <xsl:value-of select="@text:start-value"/>
  228. </xsl:element>
  229. </xsl:if>
  230. <xsl:if test="@text:num-regular-exp">
  231. <xsl:element name="字:正规格式" uof:locID="t0168" uof:attrList="值">
  232. <xsl:attribute name="值"><xsl:value-of select="@text:num-regular-exp"/></xsl:attribute>
  233. </xsl:element>
  234. </xsl:if>
  235. </xsl:element>
  236. </xsl:if>
  237. </xsl:for-each>
  238. </xsl:element>
  239. </xsl:for-each>
  240. </xsl:element>
  241. <xsl:for-each select="/office:document//text:list-style/*">
  242. <xsl:if test="style:text-properties/@fo:font-family">
  243. <xsl:element name="uof:句式样">
  244. <xsl:attribute name="uof:locID">u0043</xsl:attribute>
  245. <xsl:attribute name="uof:attrList">标识符 名称 类型 别名 基式样引用</xsl:attribute>
  246. <xsl:variable name="count"><xsl:value-of select="count(preceding::node())"/></xsl:variable>
  247. <xsl:attribute name="字:标识符"><xsl:value-of select="concat('ID',$count)"/></xsl:attribute>
  248. <xsl:attribute name="字:名称"><xsl:value-of select="concat(ancestor::style:style/@style:name,@text:level)"/></xsl:attribute>
  249. <xsl:attribute name="字:类型">auto</xsl:attribute>
  250. <xsl:if test="ancestor::style:style/@style:parent-style-name">
  251. <xsl:attribute name="字:基式样引用"><xsl:value-of select="ancestor::style:style/@style:parent-style-name"/></xsl:attribute>
  252. </xsl:if>
  253. <xsl:call-template name="字:句属性"/>
  254. </xsl:element>
  255. </xsl:if>
  256. </xsl:for-each>
  257. <xsl:apply-templates select="office:styles | office:automatic-styles" mode="style"/>
  258. <xsl:for-each select="/office:document/office:master-styles/style:master-page">
  259. <xsl:for-each select="child::draw:frame">
  260. <xsl:variable name="stylename" select="@presentation:style-name"/>
  261. <xsl:variable name="parent" select="/office:document/office:automatic-styles/style:style[@style:name=$stylename]/@style:parent-style-name"/>
  262. <xsl:for-each select="/office:document/*/style:style[@style:name=$parent]">
  263. <xsl:if test="not(contains(@style:name,'outline'))">
  264. <xsl:call-template name="段落式样"/>
  265. </xsl:if>
  266. </xsl:for-each>
  267. </xsl:for-each>
  268. </xsl:for-each>
  269. <xsl:for-each select="/office:document/office:styles/style:style[contains(@style:name,'outline')]">
  270. <xsl:call-template name="段落式样"/>
  271. </xsl:for-each>
  272. </uof:式样集>
  273. <uof:演示文稿 uof:locID="u0048">
  274. <演:公用处理规则 uof:locID="p0000">
  275. <xsl:element name="演:度量单位">
  276. <xsl:attribute name="uof:locID">p0055</xsl:attribute>
  277. <xsl:value-of select="$uofUnit"/>
  278. </xsl:element>
  279. <演:页面设置集 uof:locID="p0001">
  280. <xsl:apply-templates select="office:automatic-styles/style:page-layout"/>
  281. </演:页面设置集>
  282. <演:配色方案集 uof:locID="p0007">
  283. <xsl:for-each select="/office:document/office:master-styles/*[@draw:style-name]">
  284. <xsl:call-template name="配色方案"/>
  285. </xsl:for-each>
  286. <xsl:for-each select="/office:document/office:body/office:presentation/draw:page">
  287. <xsl:call-template name="配色方案"/>
  288. </xsl:for-each>
  289. </演:配色方案集>
  290. <演:页面版式集 uof:locID="p0017">
  291. <xsl:apply-templates select="office:styles/style:presentation-page-layout" mode="pagestyle"/>
  292. </演:页面版式集>
  293. <xsl:if test="office:styles/style:style='标准-title' or office:styles/style:style='标准-outline'" >
  294. <演:文本式样集 uof:locID="p0131">
  295. <xsl:for-each select="office:styles/style:style">
  296. <xsl:variable name="name"><xsl:value-of select="@style:name"/></xsl:variable>
  297. <xsl:if test="$name='标准-title' or contains($name,'标准-outline')">
  298. <演:文本式样 uof:locID="p0132" uof:attrList="标识符 名称">
  299. <xsl:attribute name="演:标识符">text-style</xsl:attribute>
  300. <xsl:attribute name="演:名称">文本式样</xsl:attribute>
  301. <xsl:element name="演:段落式样">
  302. <xsl:attribute name="字:标识符"><xsl:value-of select="@style:name"/></xsl:attribute>
  303. <xsl:attribute name="字:类型">auto</xsl:attribute>
  304. <xsl:if test="@style:parent-style-name">
  305. <xsl:attribute name="字:基式样引用"><xsl:value-of select="@style:parent-style-name"/></xsl:attribute>
  306. </xsl:if>
  307. <xsl:attribute name="字:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  308. <xsl:attribute name="字:别名"><xsl:value-of select="@style:class"/></xsl:attribute>
  309. <xsl:call-template name="ParaAttribute">
  310. <xsl:with-param name="text-style-name" select="@text:style-name"/>
  311. </xsl:call-template>
  312. <xsl:call-template name="字:句属性"/>
  313. </xsl:element>
  314. </演:文本式样>
  315. </xsl:if>
  316. </xsl:for-each>
  317. </演:文本式样集>
  318. </xsl:if>
  319. <演:显示比例 uof:locID="p0020">
  320. <xsl:variable name="VisibleAreaWidth">
  321. <xsl:value-of select="/office:document/office:settings/config:config-item-set/config:config-item-map-indexed/config:config-item-map-entry/config:config-item[@config:name='VisibleAreaWidth']"/>
  322. </xsl:variable>
  323. <xsl:value-of select="substring-before((13997 div $VisibleAreaWidth)*100,'.')"/>
  324. </演:显示比例>
  325. <演:放映设置 uof:locID="p0021">
  326. <演:幻灯片序列 uof:locID="p0022" uof:attrList="标识符 名称 自定义">
  327. <xsl:attribute name="演:标识符">customList</xsl:attribute>
  328. <xsl:attribute name="演:名称">幻灯片序列</xsl:attribute>
  329. <xsl:attribute name="演:自定义">true</xsl:attribute>
  330. <xsl:choose>
  331. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:start-page">
  332. <xsl:variable name="start-page">
  333. <xsl:value-of select="office:body/office:presentation/presentation:settings/@presentation:start-page"/>
  334. </xsl:variable>
  335. <xsl:variable name="before-slides">
  336. <xsl:call-template name="幻灯片序列">
  337. <xsl:with-param name="start-node" select="office:body/office:presentation/draw:page[@draw:name=$start-page]"/>
  338. <xsl:with-param name="end-node" select="office:body/office:presentation/draw:page[last()]"/>
  339. <xsl:with-param name="value"/>
  340. </xsl:call-template>
  341. </xsl:variable>
  342. <xsl:variable name="after-slides">
  343. <xsl:for-each select="office:body/office:presentation/draw:page[@draw:name=$start-page]">
  344. <xsl:call-template name="幻灯片序列">
  345. <xsl:with-param name="start-node" select="/office:document/office:body/office:presentation/draw:page[1]"/>
  346. <xsl:with-param name="end-node" select="preceding-sibling::node()[1]"/>
  347. <xsl:with-param name="value"/>
  348. </xsl:call-template>
  349. </xsl:for-each>
  350. </xsl:variable>
  351. <xsl:value-of select="concat($before-slides,' ',$after-slides)"/>
  352. </xsl:when>
  353. <xsl:otherwise>
  354. <xsl:call-template name="幻灯片序列">
  355. <xsl:with-param name="start-node" select="office:body/office:presentation/draw:page[1]"/>
  356. <xsl:with-param name="end-node" select="office:body/office:presentation/draw:page[last()]"/>
  357. <xsl:with-param name="value"/>
  358. </xsl:call-template>
  359. </xsl:otherwise>
  360. </xsl:choose>
  361. </演:幻灯片序列>
  362. <演:放映顺序 uof:locID="p0023" uof:attrList="名称 序列引用">
  363. <xsl:attribute name="演:名称">放映顺序</xsl:attribute>
  364. <xsl:attribute name="演:序列引用">customList</xsl:attribute>
  365. </演:放映顺序>
  366. <演:全屏放映 uof:locID="p0024">
  367. <xsl:choose>
  368. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:full-screen='false'">false</xsl:when>
  369. <xsl:otherwise>true</xsl:otherwise>
  370. </xsl:choose>
  371. </演:全屏放映>
  372. <演:循环放映 uof:locID="p0025">
  373. <xsl:choose>
  374. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:endless='true'">true</xsl:when>
  375. <xsl:otherwise>false</xsl:otherwise>
  376. </xsl:choose>
  377. </演:循环放映>
  378. <xsl:if test="office:body/office:presentation/presentation:settings/@presentation:pause">
  379. <演:放映间隔 uof:locID="p0026">
  380. <xsl:variable name="hms">
  381. <xsl:value-of select="substring-after(office:body/office:presentation/presentation:settings/@presentation:pause,'PT')"/>
  382. </xsl:variable>
  383. <xsl:value-of select="concat('P0Y0M0DT',$hms)"/>
  384. </演:放映间隔>
  385. </xsl:if>
  386. <演:手动方式 uof:locID="p0027">
  387. <xsl:choose>
  388. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:force-manual='true'">true</xsl:when>
  389. <xsl:otherwise>false</xsl:otherwise>
  390. </xsl:choose>
  391. </演:手动方式>
  392. <演:导航帮助 uof:locID="p0029">
  393. <xsl:choose>
  394. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:start-with-navigator='true'">true</xsl:when>
  395. <xsl:otherwise>false</xsl:otherwise>
  396. </xsl:choose>
  397. </演:导航帮助>
  398. <演:放映动画 uof:locID="p0030">
  399. <xsl:choose>
  400. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:animations='disabled'">false</xsl:when>
  401. <xsl:otherwise>true</xsl:otherwise>
  402. </xsl:choose>
  403. </演:放映动画>
  404. <演:前端显示 uof:locID="p0031">
  405. <xsl:choose>
  406. <xsl:when test="office:body/office:presentation/presentation:settings/@presentation:stay-on-top='true'">true</xsl:when>
  407. <xsl:otherwise>false</xsl:otherwise>
  408. </xsl:choose>
  409. </演:前端显示>
  410. </演:放映设置>
  411. </演:公用处理规则>
  412. <演:主体 uof:locID="p0034">
  413. <演:母版集 uof:locID="p0035">
  414. <xsl:apply-templates select="office:master-styles"/>
  415. </演:母版集>
  416. <演:幻灯片集 uof:locID="p0039">
  417. <xsl:apply-templates select="office:body/office:presentation/draw:page"/>
  418. </演:幻灯片集>
  419. </演:主体>
  420. </uof:演示文稿>
  421. </uof:UOF>
  422. </xsl:template>
  423. <xsl:template name="配色方案">
  424. <xsl:variable name="page-name"><xsl:value-of select="@draw:style-name"/></xsl:variable>
  425. <演:配色方案 uof:locID="p0008" uof:attrList="标识符 名称 类型">
  426. <xsl:attribute name="演:标识符">
  427. <xsl:choose>
  428. <xsl:when test="@draw:name"><xsl:value-of select="@draw:name"/></xsl:when>
  429. <xsl:otherwise><xsl:value-of select="@draw:style-name"/></xsl:otherwise>
  430. </xsl:choose>
  431. </xsl:attribute>
  432. <xsl:for-each select="/office:document/office:automatic-styles/style:style[@style:name = $page-name]">
  433. <xsl:attribute name="演:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  434. <xsl:attribute name="演:类型"><xsl:choose><xsl:when test="not(contains(@style:name,'color'))">custom</xsl:when><xsl:otherwise>standard</xsl:otherwise></xsl:choose></xsl:attribute>
  435. <xsl:if test="style:drawing-page-properties/@draw:fill-color">
  436. <演:背景色 uof:locID="p0009">
  437. <xsl:value-of select="style:drawing-page-properties/@draw:fill-color"/>
  438. </演:背景色>
  439. </xsl:if>
  440. <xsl:if test="style:drawing-page-properties/@svg:stroke-color">
  441. <演:文本和线条 uof:locID="p0010">
  442. <xsl:value-of select="style:drawing-page-properties/@svg:stroke-color"/>
  443. </演:文本和线条>
  444. </xsl:if>
  445. <xsl:if test="style:drawing-page-properties/@draw:shadow-color">
  446. <演:阴影 uof:locID="p0011">
  447. <xsl:value-of select="style:drawing-page-properties/@draw:shadow-color"/>
  448. </演:阴影>
  449. </xsl:if>
  450. <xsl:if test="style:drawing-page-properties/@svg:stroke-color">
  451. <演:标题文本 uof:locID="p0012">
  452. <xsl:value-of select="style:drawing-page-properties/@svg:stroke-color"/>
  453. </演:标题文本>
  454. </xsl:if>
  455. <xsl:if test="style:drawing-page-properties/@draw:fill-color">
  456. <演:填充 uof:locID="p0013">
  457. <xsl:value-of select="style:drawing-page-properties/@draw:fill-color"/>
  458. </演:填充>
  459. </xsl:if>
  460. <演:强调 uof:locID="p0014">#FFFFFF</演:强调>
  461. <演:强调和超级链接 uof:locID="p0015">#FF0000</演:强调和超级链接>
  462. <演:强调和尾随超级链接 uof:locID="p0016">#FF00FF</演:强调和尾随超级链接>
  463. </xsl:for-each>
  464. </演:配色方案>
  465. </xsl:template>
  466. <xsl:template name="幻灯片序列">
  467. <xsl:param name="start-node"/>
  468. <xsl:param name="end-node"/>
  469. <xsl:param name="value"/>
  470. <xsl:choose>
  471. <xsl:when test="not($start-node/@draw:name = $end-node/@draw:name)">
  472. <xsl:for-each select="$start-node">
  473. <xsl:variable name="value1">
  474. <xsl:value-of select="concat($value,@draw:name,'_',@draw:style-name,' ')"/>
  475. </xsl:variable>
  476. <xsl:call-template name="幻灯片序列">
  477. <xsl:with-param name="start-node" select="following-sibling::node()[1]"/>
  478. <xsl:with-param name="end-node" select="$end-node"/>
  479. <xsl:with-param name="value" select="$value1"/>
  480. </xsl:call-template>
  481. </xsl:for-each>
  482. </xsl:when>
  483. <xsl:otherwise>
  484. <xsl:value-of select="concat($value,$start-node/@draw:name)"/>
  485. </xsl:otherwise>
  486. </xsl:choose>
  487. </xsl:template>
  488. <xsl:template name="字:编号格式表示">
  489. <xsl:param name="bubianjibie"/>
  490. <xsl:param name="jibie"/>
  491. <xsl:param name="xianshijibie"/>
  492. <xsl:param name="biaoshi"/>
  493. <xsl:choose>
  494. <xsl:when test="number($xianshijibie)= 1">
  495. <xsl:value-of select="$biaoshi"/>
  496. </xsl:when>
  497. <xsl:otherwise>
  498. <xsl:variable name="num-prefix">
  499. <xsl:value-of select="preceding-sibling::*[number($bubianjibie -$jibie +1)]/@style:num-prefix"/>
  500. </xsl:variable>
  501. <xsl:variable name="num-suffix">
  502. <xsl:value-of select="preceding-sibling::*[number($bubianjibie -$jibie +1)]/@style:num-suffix"/>
  503. </xsl:variable>
  504. <xsl:call-template name="字:编号格式表示">
  505. <xsl:with-param name="bubianjibie" select="$bubianjibie"/>
  506. <xsl:with-param name="jibie" select="$jibie -1"/>
  507. <xsl:with-param name="xianshijibie" select="$xianshijibie -1"/>
  508. <xsl:with-param name="biaoshi" select="concat($num-prefix,'%',number($jibie -1),$num-suffix,'.',$biaoshi)"/>
  509. </xsl:call-template>
  510. </xsl:otherwise>
  511. </xsl:choose>
  512. </xsl:template>
  513. <xsl:template name="字:句属性">
  514. <xsl:element name="字:字体">
  515. <xsl:attribute name="uof:locID">t0088</xsl:attribute>
  516. <xsl:attribute name="uof:attrList">西文字体引用 中文字体引用 特殊字体引用 西文绘制 字号 相对字号 颜色</xsl:attribute>
  517. <xsl:if test=".//@fo:font-size or .//@style:font-size-asian or .//@style:font-size-complex">
  518. <xsl:choose>
  519. <xsl:when test="contains(.//@fo:font-size,'%') or contains(.//@style:font-size-asian,'%')">
  520. <xsl:attribute name="字:相对字号"><xsl:choose><xsl:when test=".//@fo:font-size"><xsl:value-of select="substring-before(.//@fo:font-size,'%')"/></xsl:when><xsl:when test=".//@style:font-size-asian"><xsl:value-of select="substring-before(.//@style:font-size-asian,'%')"/></xsl:when></xsl:choose></xsl:attribute>
  521. </xsl:when>
  522. <xsl:otherwise>
  523. <xsl:attribute name="字:字号"><xsl:choose><xsl:when test=".//@fo:font-size"><xsl:value-of select="substring-before(.//@fo:font-size,'pt')"/></xsl:when><xsl:when test=".//@style:font-size-asian"><xsl:value-of select="substring-before(.//@style:font-size-asian,'pt')"/></xsl:when><xsl:when test=".//@style:font-size-complex"><xsl:value-of select="substring-before(.//@style:font-size-complex,'pt')"/></xsl:when></xsl:choose></xsl:attribute>
  524. </xsl:otherwise>
  525. </xsl:choose>
  526. </xsl:if>
  527. <xsl:if test=".//@style:font-name">
  528. <xsl:attribute name="字:西文字体引用"><xsl:value-of select=".//@style:font-name"/></xsl:attribute>
  529. </xsl:if>
  530. <xsl:if test=".//@style:font-name-asian">
  531. <xsl:attribute name="字:中文字体引用"><xsl:value-of select=".//@style:font-name-asian"/></xsl:attribute>
  532. </xsl:if>
  533. <xsl:if test=".//@fo:color">
  534. <xsl:attribute name="字:颜色"><xsl:value-of select=".//@fo:color"/></xsl:attribute>
  535. </xsl:if>
  536. </xsl:element>
  537. <xsl:if test=".//@style:text-background-color and not(.//@style:text-background-color='transparent')">
  538. <xsl:element name="字:填充">
  539. <xsl:element name="图:图案">
  540. <xsl:attribute name="uof:locID">g0036</xsl:attribute>
  541. <xsl:attribute name="uof:attrList">类型 图形引用 前景色 背景色</xsl:attribute>
  542. <xsl:if test=".//@style:text-background-color">
  543. <xsl:attribute name="图:前景色"><xsl:value-of select=".//@style:text-background-color"/></xsl:attribute>
  544. </xsl:if>
  545. </xsl:element>
  546. </xsl:element>
  547. </xsl:if>
  548. <xsl:if test=".//@fo:font-weight or .//@style:font-weight-asian">
  549. <xsl:element name="字:粗体">
  550. <xsl:attribute name="uof:locID">t0089</xsl:attribute>
  551. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  552. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@style:font-weight-asian='bold' or .//@fo:font-weight='bold'">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  553. </xsl:element>
  554. </xsl:if>
  555. <xsl:if test=".//@fo:font-style or .//@style:font-style-asian">
  556. <xsl:element name="字:斜体">
  557. <xsl:attribute name="uof:locID">t0090</xsl:attribute>
  558. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  559. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@fo:font-style='italic' or .//@style:font-style-asian='italic'">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  560. </xsl:element>
  561. </xsl:if>
  562. <xsl:if test=".//@style:text-crossing-out">
  563. <xsl:element name="字:删除线">
  564. <xsl:attribute name="uof:locID">t0094</xsl:attribute>
  565. <xsl:attribute name="uof:attrList">类型</xsl:attribute>
  566. <xsl:attribute name="字:类型"><xsl:call-template name="uof:线型类型"><xsl:with-param name="lineType" select=".//@style:text-crossing-out"/></xsl:call-template></xsl:attribute>
  567. </xsl:element>
  568. </xsl:if>
  569. <xsl:if test=".//@style:text-underline">
  570. <xsl:element name="字:下划线">
  571. <xsl:attribute name="字:类型"><xsl:call-template name="uof:线型类型"><xsl:with-param name="lineType" select=".//@style:text-underline"/></xsl:call-template></xsl:attribute>
  572. <xsl:attribute name="uof:locID">t0095</xsl:attribute>
  573. <xsl:attribute name="uof:attrList">类型</xsl:attribute>
  574. <xsl:if test=".//@style:text-underline-color">
  575. <xsl:attribute name="字:颜色"><xsl:value-of select=".//@style:text-underline-color"/></xsl:attribute>
  576. </xsl:if>
  577. </xsl:element>
  578. </xsl:if>
  579. <xsl:if test=".//@fo:text-shadow and not(.//@fo:text-shadow='none')">
  580. <xsl:element name="字:阴影">
  581. <xsl:attribute name="uof:locID">t0100</xsl:attribute>
  582. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  583. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@fo:text-shadow='none'">false</xsl:when><xsl:otherwise>true</xsl:otherwise></xsl:choose></xsl:attribute>
  584. </xsl:element>
  585. </xsl:if>
  586. <xsl:if test=".//@style:text-emphasize">
  587. <xsl:element name="字:着重号">
  588. <xsl:attribute name="uof:locID">t0096</xsl:attribute>
  589. <xsl:attribute name="uof:attrList">类型 颜色 字着重号</xsl:attribute>
  590. <xsl:choose>
  591. <xsl:when test=".//@style:text-emphasize='none'">
  592. <xsl:attribute name="字:字着重号">false</xsl:attribute>
  593. <xsl:attribute name="字:类型">none</xsl:attribute>
  594. </xsl:when>
  595. <xsl:otherwise>
  596. <xsl:attribute name="字:字着重号">true</xsl:attribute>
  597. <xsl:attribute name="字:类型">dot</xsl:attribute>
  598. </xsl:otherwise>
  599. </xsl:choose>
  600. <xsl:if test=".//@fo:color">
  601. <xsl:attribute name="字:颜色"><xsl:value-of select=".//@fo:color"/></xsl:attribute>
  602. </xsl:if>
  603. </xsl:element>
  604. </xsl:if>
  605. <xsl:if test=".//@text:display and not(.//@text:display='none')">
  606. <xsl:element name="字:隐藏文字">
  607. <xsl:attribute name="uof:locID">t0097</xsl:attribute>
  608. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  609. <xsl:attribute name="字:值">true</xsl:attribute>
  610. </xsl:element>
  611. </xsl:if>
  612. <xsl:if test=".//@style:text-outline and not(.//@style:text-outline='none')">
  613. <xsl:element name="字:空心">
  614. <xsl:attribute name="uof:locID">t0098</xsl:attribute>
  615. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  616. <xsl:attribute name="字:值"><xsl:value-of select=".//@style:text-outline"/></xsl:attribute>
  617. </xsl:element>
  618. </xsl:if>
  619. <xsl:if test=".//@style:font-relief and not(.//@style:font-relief='none')">
  620. <xsl:element name="字:浮雕">
  621. <xsl:attribute name="uof:locID">t0099</xsl:attribute>
  622. <xsl:attribute name="uof:attrList">类型</xsl:attribute>
  623. <xsl:attribute name="字:类型"><xsl:choose><xsl:when test=".//@style:font-relief='embossed'">emboss</xsl:when><xsl:when test=".//@style:font-relief='engraved'">engrave</xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:attribute>
  624. </xsl:element>
  625. </xsl:if>
  626. <xsl:if test=".//@fo:text-transform or .//@fo:font-variant">
  627. <xsl:element name="字:醒目字体">
  628. <xsl:attribute name="uof:locID">t0101</xsl:attribute>
  629. <xsl:attribute name="uof:attrList">类型</xsl:attribute>
  630. <xsl:attribute name="字:类型"><xsl:choose><xsl:when test=".//@fo:text-transform='uppercase'">uppercase</xsl:when><xsl:when test=".//@fo:text-transform='lowercase'">lowercase</xsl:when><xsl:when test=".//@fo:text-transform='capitalize'">capital</xsl:when><xsl:when test=".//@fo:font-variant='small-caps'">small-caps</xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:attribute>
  631. </xsl:element>
  632. </xsl:if>
  633. <xsl:if test=".//@style:text-position">
  634. <xsl:element name="字:位置">
  635. <xsl:attribute name="uof:locID">t0102</xsl:attribute>
  636. <xsl:value-of select=".//@style:text-position"/>
  637. </xsl:element>
  638. <字:上下标 uof:locID="t0205" uof:attrList="值">
  639. <xsl:attribute name="字:值">none</xsl:attribute>
  640. </字:上下标>
  641. </xsl:if>
  642. <xsl:if test=".//@style:text-scale">
  643. <xsl:element name="字:缩放">
  644. <xsl:attribute name="uof:locID">t0103</xsl:attribute>
  645. <xsl:value-of select=".//@style:text-scale"/>
  646. </xsl:element>
  647. </xsl:if>
  648. <xsl:if test=".//@fo:letter-spacing">
  649. <xsl:element name="字:字符间距">
  650. <xsl:attribute name="uof:locID">t0104</xsl:attribute>
  651. <xsl:value-of select=".//@fo:letter-spacing"/>
  652. </xsl:element>
  653. </xsl:if>
  654. <xsl:if test=".//@style:letter-kerning">
  655. <xsl:element name="字:调整字间距">
  656. <xsl:attribute name="uof:locID">t015</xsl:attribute>
  657. <xsl:value-of select=".//@style:letter-kerning"/>
  658. </xsl:element>
  659. </xsl:if>
  660. <xsl:element name="字:字符对齐网格">
  661. <xsl:attribute name="字:值">false</xsl:attribute>
  662. <xsl:attribute name="uof:locID">t0106</xsl:attribute>
  663. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  664. </xsl:element>
  665. </xsl:template>
  666. <xsl:template match="style:presentation-page-layout" mode="pagestyle">
  667. <演:页面版式 uof:locID="p0018" uof:attrList="标识符 名称">
  668. <xsl:attribute name="演:标识符"><xsl:value-of select="@style:name"/></xsl:attribute>
  669. <xsl:attribute name="演:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  670. <演:布局 uof:locID="p0129" uof:attrList="类型">
  671. <xsl:attribute name="演:类型">
  672. <xsl:variable name="layout" select="substring-after(@style:name,'T')"/>
  673. <xsl:choose>
  674. <xsl:when test="$layout='0'">title-subtitle</xsl:when><xsl:when test="$layout='1'">title-body</xsl:when><xsl:when test="$layout='19'">title-only</xsl:when><xsl:when test="$layout='12'">column-2-rows</xsl:when><xsl:when test="$layout='15'">2-rows-column</xsl:when><xsl:when test="$layout='16'">2-columns-row</xsl:when><xsl:when test="$layout='17'">2-rows</xsl:when><xsl:when test="$layout='18'">4-objects</xsl:when><xsl:when test="$layout='27'">v-2-rows</xsl:when><xsl:when test="$layout='28'">v-title-body</xsl:when><xsl:when test="$layout='29'">big-object</xsl:when><xsl:when test="$layout='30'">2-columns</xsl:when>
  675. <xsl:otherwise>title-only</xsl:otherwise>
  676. </xsl:choose></xsl:attribute>
  677. </演:布局>
  678. <xsl:apply-templates select="presentation:placeholder" mode="anchor"/>
  679. </演:页面版式>
  680. </xsl:template>
  681. <xsl:template match="presentation:placeholder" mode="anchor">
  682. <演:占位符 uof:locID="p0130" uof:attrList="类型">
  683. <xsl:attribute name="演:类型"><xsl:choose><xsl:when test="@presentation:object = 'vertical_outline'">vertical_text</xsl:when><xsl:when test="@presentation:object = 'date-time'">date</xsl:when><xsl:when test="@presentation:object = 'page_number'">number</xsl:when><xsl:otherwise><xsl:value-of select="@presentation:object"/></xsl:otherwise></xsl:choose></xsl:attribute>
  684. <uof:锚点 uof:locID="u0064" uof:attrList="x坐标 y坐标 宽度 高度 图形引用 随动方式 缩略图 占位符">
  685. <xsl:attribute name="uof:x坐标"><xsl:value-of select="substring-before(@svg:x,$uofUnit)"/></xsl:attribute>
  686. <xsl:attribute name="uof:y坐标"><xsl:value-of select="substring-before(@svg:y,$uofUnit)"/></xsl:attribute>
  687. <xsl:attribute name="uof:宽度"><xsl:value-of select="substring-before(@svg:width,$uofUnit)"/></xsl:attribute>
  688. <xsl:attribute name="uof:高度"><xsl:value-of select="substring-before(@svg:height,$uofUnit)"/></xsl:attribute>
  689. <xsl:attribute name="uof:图形引用"><xsl:variable name="number"><xsl:value-of select="concat('_',count(preceding-sibling::presentation:placeholder))"/></xsl:variable><xsl:value-of select="concat(parent::style:presentation-page-layout/@style:name,$number)"/></xsl:attribute>
  690. </uof:锚点>
  691. </演:占位符>
  692. </xsl:template>
  693. <xsl:template match="presentation:placeholder" mode="graphic">
  694. <图:图形 uof:locID="g0000" uof:attrList="层次 标识符 组合列表 其他对象" 图:层次="3">
  695. <xsl:attribute name="图:标识符"><xsl:variable name="number"><xsl:value-of select="concat('_',count(preceding-sibling::presentation:placeholder))"/></xsl:variable><xsl:value-of select="concat(parent::style:presentation-page-layout/@style:name,$number)"/></xsl:attribute>
  696. </图:图形>
  697. </xsl:template>
  698. <xsl:template match="office:master-styles">
  699. <xsl:apply-templates select="style:handout-master"/>
  700. <xsl:apply-templates select="style:master-page"/>
  701. <xsl:if test="style:master-page/presentation:notes">
  702. <xsl:apply-templates select="style:master-page/presentation:notes"/>
  703. </xsl:if>
  704. </xsl:template>
  705. <xsl:template match="style:handout-master">
  706. <演:母版 uof:locID="p0036" uof:attrList="标识符 名称 类型 页面设置引用 配色方案引用 页面版式引用 文本式样引用" 演:名称="handout母版" 演:类型="handout">
  707. <xsl:attribute name="演:页面设置引用"><xsl:value-of select="@style:page-layout-name"/></xsl:attribute>
  708. <xsl:if test="@draw:style-name">
  709. <xsl:attribute name="演:配色方案引用"><xsl:value-of select="@draw:style-name"/></xsl:attribute>
  710. </xsl:if>
  711. <xsl:if test="@presentation:presentation-page-layout-name">
  712. <xsl:attribute name="演:页面版式引用"><xsl:value-of select="@presentation:presentation-page-layout-name"/></xsl:attribute>
  713. </xsl:if>
  714. <xsl:call-template name="产生锚点"/>
  715. </演:母版>
  716. </xsl:template>
  717. <xsl:template match="style:master-page">
  718. <演:母版 uof:locID="p0036" uof:attrList="标识符 名称 类型 页面设置引用 配色方案引用 页面版式引用 文本式样引用" 演:名称="slide母版" 演:类型="slide">
  719. <xsl:attribute name="演:标识符"><xsl:value-of select="@style:name"/></xsl:attribute>
  720. <xsl:attribute name="演:页面设置引用"><xsl:value-of select="@style:page-layout-name"/></xsl:attribute>
  721. <xsl:if test="@draw:style-name">
  722. <xsl:attribute name="演:配色方案引用"><xsl:value-of select="@draw:style-name"/></xsl:attribute>
  723. </xsl:if>
  724. <xsl:if test="@presentation:presentation-page-layout-name">
  725. <xsl:attribute name="演:页面版式引用"><xsl:value-of select="@presentation:presentation-page-layout-name"/></xsl:attribute>
  726. </xsl:if>
  727. <xsl:call-template name="产生锚点"/>
  728. <xsl:variable name="stylename">
  729. <xsl:value-of select="@draw:style-name"/>
  730. </xsl:variable>
  731. <xsl:variable name="name">
  732. <xsl:value-of select="name(.)"/>
  733. </xsl:variable>
  734. <xsl:for-each select="/office:document/*/style:style[@style:name=$stylename]/style:drawing-page-properties">
  735. <xsl:if test="@draw:fill and not(@draw:fill='none')">
  736. <演:背景 uof:locID="p0057">
  737. <xsl:call-template name="填充">
  738. <xsl:with-param name="picname" select="$stylename"/>
  739. <xsl:with-param name="nodename" select="$name"/>
  740. </xsl:call-template>
  741. </演:背景>
  742. </xsl:if>
  743. </xsl:for-each>
  744. </演:母版>
  745. </xsl:template>
  746. <xsl:template match="presentation:notes">
  747. <演:母版 uof:locID="p0036" uof:attrList="标识符 名称 类型 页面设置引用 配色方案引用 页面版式引用 文本式样引用" 演:名称="notes母版" 演:类型="notes">
  748. <xsl:attribute name="演:标识符"><xsl:value-of select="concat('note-',parent::style:master-page/@style:name)"/></xsl:attribute>
  749. <xsl:attribute name="演:页面设置引用"><xsl:value-of select="@style:page-layout-name"/></xsl:attribute>
  750. <xsl:if test="@draw:style-name">
  751. <xsl:attribute name="演:配色方案引用"><xsl:value-of select="@draw:style-name"/></xsl:attribute>
  752. </xsl:if>
  753. <xsl:if test="@presentation:presentation-page-layout-name">
  754. <xsl:attribute name="演:页面版式引用"><xsl:value-of select="@presentation:presentation-page-layout-name"/></xsl:attribute>
  755. </xsl:if>
  756. <xsl:call-template name="产生锚点"/>
  757. </演:母版>
  758. </xsl:template>
  759. <xsl:template match="draw:page">
  760. <演:幻灯片 uof:locID="p0040" uof:attrList="名称 标识符 母版引用 配色方案引用 页面版式引用 显示 显示背景 显示背景对象">
  761. <xsl:attribute name="演:标识符"><xsl:value-of select="concat(@draw:name,'_',@draw:style-name)"/></xsl:attribute>
  762. <xsl:attribute name="演:名称"><xsl:value-of select="@draw:name"/></xsl:attribute>
  763. <xsl:attribute name="演:母版引用"><xsl:value-of select="@draw:master-page-name"/></xsl:attribute>
  764. <xsl:if test="@presentation:presentation-page-layout-name">
  765. <xsl:attribute name="演:页面版式引用"><xsl:value-of select="@presentation:presentation-page-layout-name"/></xsl:attribute>
  766. </xsl:if>
  767. <xsl:call-template name="产生锚点"/>
  768. <xsl:apply-templates select="presentation:notes" mode="page"/>
  769. <xsl:variable name="stylename">
  770. <xsl:value-of select="@draw:style-name"/>
  771. </xsl:variable>
  772. <xsl:variable name="name">
  773. <xsl:value-of select="name(.)"/>
  774. </xsl:variable>
  775. <xsl:for-each select="/office:document/*/style:style[@style:name=$stylename]/style:drawing-page-properties">
  776. <xsl:if test="@draw:fill and not(@draw:fill='none')">
  777. <演:背景 uof:locID="p0057">
  778. <xsl:call-template name="填充">
  779. <xsl:with-param name="picname" select="$stylename"/>
  780. <xsl:with-param name="nodename" select="$name"/>
  781. </xsl:call-template>
  782. </演:背景>
  783. </xsl:if>
  784. </xsl:for-each>
  785. <演:切换 uof:locID="p0058" uof:attrList="效果 速度">
  786. <xsl:for-each select="key('graphicset',$stylename)/style:drawing-page-properties">
  787. <xsl:attribute name="演:速度"><xsl:choose><xsl:when test="@presentation:transition-speed='slow'">slow</xsl:when><xsl:otherwise>fast</xsl:otherwise></xsl:choose></xsl:attribute>
  788. <xsl:attribute name="演:效果"><xsl:variable name="type"><xsl:value-of select="@smil:type"/></xsl:variable><xsl:variable name="subtype"><xsl:value-of select="@smil:subtype"/></xsl:variable><xsl:choose><xsl:when test="$type='irisWipe' and $subtype='rectangle' and @smil:direction='reverse'">box in</xsl:when><xsl:when test="$type='irisWipe' and $subtype='rectangle'">box out</xsl:when><xsl:when test="$type='checkerBoardWipe' and $subtype='across'">checkerboard across</xsl:when><xsl:when test="$type='checkerBoardWipe' and $subtype='down'">checkerboard down</xsl:when><xsl:when test="$type='pushWipe' and $subtype='combHorizontal'">comb horizontal</xsl:when><xsl:when test="$type='pushWipe' and $subtype='combVertical'">comb vertical</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromTop' and @smil:direction='reverse'">uncover down</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromRight' and @smil:direction='reverse'">uncover left</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromLeft' and @smil:direction='reverse'">uncover right</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromBottom' and @smil:direction='reverse'">uncover up</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromTopRight' and @smil:direction='reverse'">uncover left-down</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromBottomRight' and @smil:direction='reverse'">uncover left-up</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromTopLeft' and @smil:direction='reverse'">uncover right-down</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromBottomLeft' and @smil:direction='reverse'">uncover right-up</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromTop'">cover down</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromRight'">cover left</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromLeft'">cover right</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromBottom'">cover up</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromTopRight'">cover left-down</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromBottomRight'">cover left-up</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromTopLeft'">cover right-down</xsl:when><xsl:when test="$type='slideWipe' and $subtype='fromBottomLeft'">cover right-up</xsl:when><xsl:when test="$type='fade' and $subtype='fadeOverColor'">fade through black</xsl:when><xsl:when test="$type='pushWipe' and $subtype='fromTop'">push down</xsl:when><xsl:when test="$type='pushWipe' and $subtype='fromRight'">push left</xsl:when><xsl:when test="$type='pushWipe' and $subtype='fromLeft'">push right</xsl:when><xsl:when test="$type='pushWipe' and $subtype='fromBottom'">push up</xsl:when><xsl:when test="$type='randomBarWipe' and $subtype='horizontal'">random bars horizontal</xsl:when><xsl:when test="$type='randomBarWipe' and $subtype='vertical'">random bars vertical</xsl:when><xsl:when test="$type='ellipseWipe' and $subtype='circle'">shape circle</xsl:when><xsl:when test="$type='irisWipe' and $subtype='diamond'">shape diamond</xsl:when><xsl:when test="$type='fourBoxWipe' and $subtype='cornersOut'">shape plus</xsl:when><xsl:when test="$type='barnDoorWipe' and $subtype='horizontal' and @smil:direction='reverse'">split horizontal in</xsl:when><xsl:when test="$type='barnDoorWipe' and $subtype='horizontal'">split horizontal out</xsl:when><xsl:when test="$type='barnDoorWipe' and $subtype='vertical' and @smil:direction='reverse'">split vertical in</xsl:when><xsl:when test="$type='barnDoorWipe' and $subtype='vertical'">split vertical out</xsl:when><xsl:when test="$type='fanWipe' and $subtype='centerTop'">wedge</xsl:when><xsl:when test="$type='pinWheelWipe' and $subtype='oneBlade'">wheel clockwise – 1 spoke</xsl:when><xsl:when test="$type='pinWheelWipe' and $subtype='twoBladeVertical'">wheel clockwise – 2 spoke</xsl:when><xsl:when test="$type='pinWheelWipe' and $subtype='threeBlade'">wheel clockwise – 3 spoke</xsl:when><xsl:when test="$type='pinWheelWipe' and $subtype='fourBlade'">wheel clockwise – 4 spoke</xsl:when><xsl:when test="$type='pinWheelWipe' and $subtype='eightBlade'">wheel clockwise – 8 spoke</xsl:when><xsl:when test="$type='barWipe' and $subtype='leftToRight' and @smil:direction='reverse'">wipe left</xsl:when><xsl:when test="$type='barWipe' and $subtype='leftToRight'">wipe right</xsl:when><xsl:when test="$type='barWipe' and $subtype='topToBottom' and @smil:direction='reverse'">wipe up</xsl:when><xsl:when test="$type='barWipe' and $subtype='topToBottom'">wipe down</xsl:when><xsl:when test="$type='blindsWipe' and $subtype='vertical'">blinds vertical</xsl:when><xsl:when test="$type='blindsWipe' and $subtype='horizontal'">blinds horizontal</xsl:when><xsl:when test="$type='dissolve'">dissolve</xsl:when><xsl:when test="$type='random'">random transition</xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:attribute>
  789. <演:声音 uof:locID="p0061" uof:attrList="预定义声音 自定义声音">
  790. <xsl:choose>
  791. <xsl:when test="not(presentation:sound)">
  792. <xsl:attribute name="演:预定义声音">none</xsl:attribute>
  793. </xsl:when>
  794. <xsl:otherwise>
  795. <xsl:variable name="lujing">
  796. <xsl:value-of select="substring-after(presentation:sound/@xlink:href,'share/gallery/sounds/')"/>
  797. </xsl:variable>
  798. <xsl:variable name="ming">
  799. <xsl:value-of select="substring-before($lujing,'.wav')"/>
  800. </xsl:variable>
  801. <xsl:choose>
  802. <xsl:when test="$ming='applause'">
  803. <xsl:attribute name="演:预定义声音">applause</xsl:attribute>
  804. </xsl:when>
  805. <xsl:when test="$ming='explos'">
  806. <xsl:attribute name="演:预定义声音">explosion</xsl:attribute>
  807. </xsl:when>
  808. <xsl:when test="$ming='laser'">
  809. <xsl:attribute name="演:预定义声音">laser</xsl:attribute>
  810. </xsl:when>
  811. <xsl:otherwise>
  812. <xsl:attribute name="演:自定义声音"><xsl:value-of select="presentation:sound/@xlink:href"/></xsl:attribute>
  813. </xsl:otherwise>
  814. </xsl:choose>
  815. </xsl:otherwise>
  816. </xsl:choose>
  817. </演:声音>
  818. <演:方式 uof:locID="p0062">
  819. <演:单击鼠标 uof:locID="p0065">
  820. <xsl:choose>
  821. <xsl:when test="@presentation:transition-type='automatic'">false</xsl:when>
  822. <xsl:otherwise>true</xsl:otherwise>
  823. </xsl:choose>
  824. </演:单击鼠标>
  825. <xsl:if test="@presentation:duration">
  826. <演:时间间隔 uof:locID="p0066">
  827. <xsl:variable name="hms">
  828. <xsl:value-of select="substring-after(@presentation:duration,'PT')"/>
  829. </xsl:variable>
  830. <xsl:variable name="h">
  831. <xsl:value-of select="number(substring-before($hms,'H'))"/>
  832. </xsl:variable>
  833. <xsl:variable name="ms">
  834. <xsl:value-of select="substring-after($hms,'H')"/>
  835. </xsl:variable>
  836. <xsl:variable name="m">
  837. <xsl:value-of select="number(substring-before($ms,'M'))"/>
  838. </xsl:variable>
  839. <xsl:variable name="s">
  840. <xsl:value-of select="number(substring-before(substring-after($ms,'M'),'S'))"/>
  841. </xsl:variable>
  842. <xsl:value-of select="$h *3600 + $m * 60 + $s"/>
  843. </演:时间间隔>
  844. </xsl:if>
  845. </演:方式>
  846. </xsl:for-each>
  847. </演:切换>
  848. </演:幻灯片>
  849. </xsl:template>
  850. <xsl:template match="presentation:notes" mode="page">
  851. <演:幻灯片备注 uof:locID="p0054" uof:attrList="备注母版引用">
  852. <xsl:attribute name="演:备注母版引用"><xsl:variable name="cute"><xsl:value-of select="parent::node()/@draw:master-page-name"/></xsl:variable><xsl:value-of select="concat('note-',$cute)"/></xsl:attribute>
  853. <xsl:call-template name="产生锚点"/>
  854. <演:背景 uof:locID="p0057">
  855. <图:颜色 uof:locID="g0034">#ffffff</图:颜色>
  856. </演:背景>
  857. </演:幻灯片备注>
  858. </xsl:template>
  859. <xsl:template name="产生锚点">
  860. <xsl:for-each select="child::node( )">
  861. <xsl:choose>
  862. <xsl:when test="substring-before(name(),':')='draw'">
  863. <uof:锚点 uof:locID="u0064" uof:attrList="x坐标 y坐标 宽度 高度 图形引用 随动方式 缩略图 占位符">
  864. <xsl:variable name="nodename">
  865. <xsl:value-of select="name(.)"/>
  866. </xsl:variable>
  867. <xsl:variable name="refpicname">
  868. <xsl:choose>
  869. <xsl:when test="@draw:style-name">
  870. <xsl:value-of select="@draw:style-name"/>
  871. </xsl:when>
  872. <xsl:otherwise>
  873. <xsl:value-of select="@presentation:style-name"/>
  874. </xsl:otherwise>
  875. </xsl:choose>
  876. </xsl:variable>
  877. <xsl:variable name="picnumber">
  878. <xsl:choose>
  879. <xsl:when test="@draw:style-name">
  880. <xsl:value-of select="count(preceding::*[@draw:style-name=$refpicname])"/>
  881. </xsl:when>
  882. <xsl:otherwise>
  883. <xsl:value-of select="count(preceding::*[@presentation:style-name=$refpicname])"/>
  884. </xsl:otherwise>
  885. </xsl:choose>
  886. </xsl:variable>
  887. <xsl:attribute name="uof:x坐标"><xsl:choose><xsl:when test="name(.)='draw:g'"><xsl:call-template name="groupminx"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:x][1]/@svg:x,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:when><xsl:otherwise><xsl:choose><xsl:when test="@svg:x"><xsl:value-of select="substring-before(@svg:x,$uofUnit)"/></xsl:when><xsl:when test="@svg:x1"><xsl:value-of select="substring-before(@svg:x1,$uofUnit)"/></xsl:when></xsl:choose></xsl:otherwise></xsl:choose></xsl:attribute>
  888. <xsl:attribute name="uof:y坐标"><xsl:choose><xsl:when test="name(.)='draw:g'"><xsl:call-template name="groupminx"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:y][1]/@svg:y,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:when><xsl:otherwise><xsl:choose><xsl:when test="@svg:y"><xsl:value-of select="substring-before(@svg:y,$uofUnit)"/></xsl:when><xsl:when test="@svg:y1"><xsl:value-of select="substring-before(@svg:y1,$uofUnit)"/></xsl:when></xsl:choose></xsl:otherwise></xsl:choose></xsl:attribute>
  889. <xsl:attribute name="uof:宽度"><xsl:choose><xsl:when test="@svg:width"><xsl:value-of select="substring-before(@svg:width,$uofUnit)"/></xsl:when><xsl:when test="@svg:x1"><xsl:value-of select="substring-before(@svg:x2,$uofUnit) - substring-before(@svg:x1,$uofUnit)"/></xsl:when><xsl:when test="name(.)='draw:g'"><xsl:variable name="minx"><xsl:call-template name="groupminx"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:x][1]/@svg:x,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:variable><xsl:variable name="svgx"><xsl:value-of select="number(substring-before(descendant::node()[@svg:x][1]/@svg:x,$uofUnit))"/></xsl:variable><xsl:variable name="width"><xsl:value-of select="number(substring-before(descendant::node()[@svg:x][1]/@svg:width,$uofUnit))"/></xsl:variable><xsl:variable name="maxx"><xsl:call-template name="groupmaxx"><xsl:with-param name="value" select="$svgx + $width"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:variable><xsl:value-of select="$maxx - $minx"/></xsl:when></xsl:choose></xsl:attribute>
  890. <xsl:attribute name="uof:高度"><xsl:choose><xsl:when test="@svg:height"><xsl:value-of select="substring-before(@svg:height,$uofUnit)"/></xsl:when><xsl:when test="@svg:x1"><xsl:value-of select="substring-before(@svg:y2,$uofUnit) - substring-before(@svg:y1,$uofUnit)"/></xsl:when><xsl:when test="name(.)='draw:g'"><xsl:variable name="miny"><xsl:call-template name="groupminy"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:y][1]/@svg:y,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:variable><xsl:variable name="svgy"><xsl:value-of select="number(substring-before(descendant::node()[@svg:y][1]/@svg:y,$uofUnit))"/></xsl:variable><xsl:variable name="height"><xsl:value-of select="number(substring-before(descendant::node()[@svg:y][1]/@svg:height,$uofUnit))"/></xsl:variable><xsl:variable name="maxy"><xsl:call-template name="groupmaxy"><xsl:with-param name="value" select="$svgy + $height"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:variable><xsl:value-of select="$maxy - $miny"/></xsl:when></xsl:choose></xsl:attribute>
  891. <xsl:attribute name="uof:图形引用"><xsl:choose><xsl:when test="@draw:id"><xsl:value-of select="@draw:id"/></xsl:when><xsl:when test="not(@draw:style-name) and name()='draw:g'"><xsl:value-of select="concat(child::node()[1]/@draw:style-name,'_',$picnumber)"/></xsl:when><xsl:otherwise><xsl:value-of select="concat($refpicname,'_',$picnumber)"/></xsl:otherwise></xsl:choose></xsl:attribute>
  892. <xsl:attribute name="uof:随动方式"><xsl:choose><xsl:when test="key('graphicset',$refpicname)/node()/@style:protect"><xsl:for-each select="key('graphicset',$refpicname)/node()"><xsl:choose><xsl:when test="@style:protect='size'">move</xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:for-each></xsl:when><xsl:otherwise>movesize</xsl:otherwise></xsl:choose></xsl:attribute>
  893. <xsl:if test="name(.)='draw:page-thumbnail'">
  894. <xsl:attribute name="uof:缩略图">true</xsl:attribute>
  895. </xsl:if>
  896. <xsl:if test="not(name(parent::node())='style:handout-master')">
  897. <xsl:attribute name="uof:占位符"><xsl:choose><xsl:when test="@presentation:object"><xsl:value-of select="@presentation:object"/></xsl:when><xsl:when test=".//draw:image">graphic</xsl:when></xsl:choose></xsl:attribute>
  898. <xsl:if test="@presentation:class">
  899. <xsl:attribute name="uof:占位符"><xsl:value-of select="@presentation:class"/></xsl:attribute>
  900. </xsl:if>
  901. </xsl:if>
  902. </uof:锚点>
  903. </xsl:when>
  904. <xsl:when test="name()= 'anim:par'">
  905. <演:动画 uof:locID="p0042">
  906. <xsl:apply-templates select="anim:seq"/>
  907. </演:动画>
  908. </xsl:when>
  909. </xsl:choose>
  910. </xsl:for-each>
  911. </xsl:template>
  912. <xsl:template match="anim:seq">
  913. <xsl:apply-templates select="anim:par/anim:par/anim:par"/>
  914. <xsl:apply-templates select="anim:par/anim:par/anim:iterate"/>
  915. </xsl:template>
  916. <xsl:template match="anim:par | anim:iterate">
  917. <演:序列 uof:locID="p0043" uof:attrList="段落引用 动画对象">
  918. <xsl:attribute name="演:动画对象"><xsl:choose>
  919. <xsl:when test=".//@smil:targetElement"><xsl:value-of select=".//@smil:targetElement"/></xsl:when><xsl:when test="@anim:id"><xsl:value-of select="@anim:id"/></xsl:when><xsl:otherwise><xsl:value-of select="../@smil:targetElement"/></xsl:otherwise></xsl:choose></xsl:attribute>
  920. <演:定时 uof:locID="p0067" uof:attrList="事件 延时 速度 重复 回卷">
  921. <xsl:attribute name="演:事件">
  922. <xsl:choose>
  923. <xsl:when test="@presentation:node-type='on-click'">on click</xsl:when>
  924. <xsl:when test="@presentation:node-type='with-previous'">with previous</xsl:when>
  925. <xsl:otherwise><xsl:value-of select="@presentation:node-type"/></xsl:otherwise>
  926. </xsl:choose>
  927. </xsl:attribute>
  928. <xsl:attribute name="演:延时"><xsl:value-of select="substring-before(@smil:begin,'s')"/></xsl:attribute>
  929. <xsl:attribute name="演:速度"><xsl:choose><xsl:when test="anim:animate/@smil:dur='0.5s'">very fast</xsl:when><xsl:when test="anim:animate/@smil:dur='1s'">fast</xsl:when><xsl:when test="anim:animate/@smil:dur='2s'">medium</xsl:when><xsl:when test="anim:animate/@smil:dur='3s'">slow</xsl:when><xsl:when test="anim:animate/@smil:dur='5s'">very slow</xsl:when><xsl:otherwise>medium</xsl:otherwise></xsl:choose></xsl:attribute>
  930. <xsl:attribute name="演:重复"><xsl:choose><xsl:when test="@smil:repeatCount = 'indefinite' "><xsl:choose><xsl:when test="@smil:end='next'">until next click</xsl:when><xsl:otherwise>until next slide</xsl:otherwise></xsl:choose></xsl:when><xsl:when test="@smil:repeatCount ='2' or @smil:repeatCount ='3' or @smil:repeatCount ='4' or @smil:repeatCount ='5' or @smil:repeatCount ='10' "><xsl:value-of select="@smil:repeatCount"/></xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:attribute>
  931. <xsl:attribute name="演:回卷"><xsl:choose><xsl:when test="@smil:fill='remove'">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  932. </演:定时>
  933. <演:增强 uof:locID="p0068">
  934. <演:动画播放后 uof:locID="p0070" uof:attrList="颜色 变暗 播放后隐藏 单击后隐藏">
  935. <xsl:if test="../anim:animateColor">
  936. <xsl:attribute name="演:颜色"><xsl:value-of select="../anim:animateColor/@smil:to"/></xsl:attribute>
  937. </xsl:if>
  938. <xsl:choose>
  939. <xsl:when test="../anim:animateColor">
  940. <xsl:attribute name="演:变暗">true</xsl:attribute>
  941. </xsl:when>
  942. <xsl:otherwise>
  943. <xsl:attribute name="演:变暗">false</xsl:attribute>
  944. </xsl:otherwise>
  945. </xsl:choose>
  946. <xsl:choose>
  947. <xsl:when test="@presentation:preset-property='Direction;Accelerate;Decelerate' ">
  948. <xsl:attribute name="演:播放后隐藏">true</xsl:attribute>
  949. </xsl:when>
  950. <xsl:otherwise>
  951. <xsl:attribute name="演:播放后隐藏">false</xsl:attribute>
  952. </xsl:otherwise>
  953. </xsl:choose>
  954. <xsl:choose>
  955. <xsl:when test="../anim:set/@smil:to">
  956. <xsl:attribute name="演:单击后隐藏">true</xsl:attribute>
  957. </xsl:when>
  958. <xsl:otherwise>
  959. <xsl:attribute name="演:单击后隐藏">false</xsl:attribute>
  960. </xsl:otherwise>
  961. </xsl:choose>
  962. </演:动画播放后>
  963. <演:动画文本 uof:locID="p0071" uof:attrList="发送 间隔 动画形状 相反顺序">
  964. <xsl:attribute name="演:发送"><xsl:choose><xsl:when test="@anim:iterate-type = 'by-word' ">by word</xsl:when><xsl:when test="@anim:iterate-type = 'by-letter' ">by letter</xsl:when><xsl:otherwise>all at once</xsl:otherwise></xsl:choose></xsl:attribute>
  965. <xsl:attribute name="演:间隔"><xsl:choose><xsl:when test="@anim:iterate-interval"><xsl:value-of select="substring-before(@anim:iterate-interval,'s')"/>
  966. </xsl:when><xsl:otherwise>0</xsl:otherwise></xsl:choose></xsl:attribute>
  967. <xsl:attribute name="演:动画形状">false</xsl:attribute>
  968. <xsl:attribute name="演:相反顺序">false</xsl:attribute>
  969. </演:动画文本>
  970. <xsl:if test="anim:audio">
  971. <演:声音 uof:locID="p0061" uof:attrList="预定义声音 自定义声音">
  972. <xsl:variable name="audioname">
  973. <xsl:value-of select="substring-after(anim:audio/@xlink:href,'gallery/sounds/')"/>
  974. </xsl:variable>
  975. <xsl:choose>
  976. <xsl:when test="not($audioname='')">
  977. <xsl:attribute name="演:预定义声音"><xsl:choose><xsl:when test="anim:audio/@xlink:href"><xsl:value-of select="anim:audio/@xlink:href"/></xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:attribute>
  978. </xsl:when>
  979. <xsl:otherwise>
  980. <xsl:attribute name="演:自定义声音"><xsl:value-of select="anim:audio/@xlink:href"/></xsl:attribute>
  981. </xsl:otherwise>
  982. </xsl:choose>
  983. </演:声音>
  984. </xsl:if>
  985. </演:增强>
  986. <演:效果 uof:locID="p0069">
  987. <xsl:choose>
  988. <xsl:when test="./@presentation:preset-class = 'entrance'">
  989. <演:进入 uof:locID="p0073">
  990. <xsl:apply-templates select="@presentation:preset-id"/>
  991. </演:进入>
  992. </xsl:when>
  993. <xsl:when test="./@presentation:preset-class = 'exit'">
  994. <演:退出 uof:locID="p0074">
  995. <xsl:apply-templates select="@presentation:preset-id"/>
  996. </演:退出>
  997. </xsl:when>
  998. <xsl:when test="./@presentation:preset-class = 'emphasis' ">
  999. <演:强调 uof:locID="p0075">
  1000. <xsl:apply-templates select="@presentation:preset-id"/>
  1001. </演:强调>
  1002. </xsl:when>
  1003. <xsl:otherwise>
  1004. <演:动作路径 uof:locID="p0133" uof:attrList="路径">
  1005. <xsl:attribute name="演:路径">
  1006. <xsl:value-of select="anim:animateMotion/@svg:path"/>
  1007. </xsl:attribute>
  1008. </演:动作路径>
  1009. </xsl:otherwise>
  1010. </xsl:choose>
  1011. </演:效果>
  1012. </演:序列>
  1013. </xsl:template>
  1014. <xsl:template name="anim_speed">
  1015. <xsl:param name="speed"/>
  1016. <xsl:choose>
  1017. <xsl:when test="$speed='0.5s' or $speed='0.25s'">very fast</xsl:when>
  1018. <xsl:when test="$speed='1s'">fast</xsl:when>
  1019. <xsl:when test="$speed='2s'">medium</xsl:when>
  1020. <xsl:when test="$speed='3s'">slow</xsl:when>
  1021. <xsl:when test="$speed='5s'">very slow</xsl:when>
  1022. <xsl:otherwise>medium</xsl:otherwise>
  1023. </xsl:choose>
  1024. </xsl:template>
  1025. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-venetian-blinds']">
  1026. <演:百叶窗 uof:locID="p0080" uof:attrList="速度 方向">
  1027. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1028. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1029. </演:百叶窗>
  1030. </xsl:template>
  1031. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-appear']">
  1032. <演:出现 uof:locID="p0081">
  1033. </演:出现>
  1034. </xsl:template>
  1035. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-box']">
  1036. <演:盒状 uof:locID="p0082" uof:attrList="速度 方向">
  1037. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1038. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1039. </演:盒状>
  1040. </xsl:template>
  1041. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-diagonal-squares']">
  1042. <演:阶梯状 uof:locID="p0083" uof:attrList="速度 方向">
  1043. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1044. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'left-to-bottom' ">left down</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'left-to-top' ">left up</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'right-to-bottom' ">right down</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'right-to-top' ">right up</xsl:when></xsl:choose></xsl:attribute>
  1045. </演:阶梯状>
  1046. </xsl:template>
  1047. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-wheel']">
  1048. <演:轮子 uof:locID="p0084" uof:attrList="速度 辐射状">
  1049. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1050. <xsl:attribute name="演:辐射状"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1051. </演:轮子>
  1052. </xsl:template>
  1053. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-checkerboard']">
  1054. <演:棋盘 uof:locID="p0085" uof:attrList="速度 方向">
  1055. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1056. <xsl:attribute name="演:方向"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:subtype"/></xsl:attribute>
  1057. </演:棋盘>
  1058. </xsl:template>
  1059. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-flash-once']">
  1060. <演:闪烁一次 uof:locID="p0086" uof:attrList="速度">
  1061. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:set/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1062. </演:闪烁一次>
  1063. </xsl:template>
  1064. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-plus']">
  1065. <演:十字形扩展 uof:locID="p0087" uof:attrList="速度 方向">
  1066. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1067. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1068. </演:十字形扩展>
  1069. </xsl:template>
  1070. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-random']">
  1071. <演:随机效果 uof:locID="p0088">
  1072. </演:随机效果>
  1073. </xsl:template>
  1074. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-circle']">
  1075. <演:圆形扩展 uof:locID="p0089" uof:attrList="速度 方向">
  1076. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1077. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1078. </演:圆形扩展>
  1079. </xsl:template>
  1080. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-wipe']">
  1081. <演:擦除 uof:locID="p0090" uof:attrList="速度 方向">
  1082. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1083. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-right'">from right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">from left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">from top</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">from bottom</xsl:when></xsl:choose></xsl:attribute>
  1084. </演:擦除>
  1085. </xsl:template>
  1086. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-fly-in']">
  1087. <演:飞入 uof:locID="p0091" uof:attrList="速度 方向">
  1088. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:animate/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1089. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">from bottom</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top-right'">from top-right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top-left'">from top-left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom-left'">from bottom-left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom-right'">from bottom-right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-right'">from right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">from left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">from top</xsl:when></xsl:choose></xsl:attribute>
  1090. </演:飞入>
  1091. </xsl:template>
  1092. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-fly-in-slow']">
  1093. <演:缓慢飞入 uof:locID="p0092" uof:attrList="速度 方向">
  1094. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:animate/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1095. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-right'">from right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">from left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">from top</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">from bottom</xsl:when></xsl:choose></xsl:attribute>
  1096. </演:缓慢飞入>
  1097. </xsl:template>
  1098. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-diamond']">
  1099. <演:菱形 uof:locID="p0093" uof:attrList="速度 方向">
  1100. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1101. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1102. </演:菱形>
  1103. </xsl:template>
  1104. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-split']">
  1105. <演:劈裂 uof:locID="p0094" uof:attrList="速度 方向">
  1106. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1107. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'horizontal-out'">horizontal out</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'horizontal-in'">horizontal in</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'vertical-in'">vertical in</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'vertical-out'">vertical out</xsl:when></xsl:choose></xsl:attribute>
  1108. </演:劈裂>
  1109. </xsl:template>
  1110. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-peek-in']">
  1111. <演:切入 uof:locID="p0095" uof:attrList="速度 方向">
  1112. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1113. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-right'">from right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">from left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">from top</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">from bottom</xsl:when></xsl:choose></xsl:attribute>
  1114. </演:切入>
  1115. </xsl:template>
  1116. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-wedge']">
  1117. <演:扇形展开 uof:locID="p0096" uof:attrList="速度">
  1118. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1119. </演:扇形展开>
  1120. </xsl:template>
  1121. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-random-bars']">
  1122. <演:随机线条 uof:locID="p0097" uof:attrList="速度 方向">
  1123. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1124. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1125. </演:随机线条>
  1126. </xsl:template>
  1127. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-dissolve-in']">
  1128. <演:向内溶解 uof:locID="p0098" uof:attrList="速度">
  1129. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1130. </演:向内溶解>
  1131. </xsl:template>
  1132. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-boomerang']">
  1133. <演:其他 uof:locID="p0099">
  1134. <xsl:copy-of select="parent::node()"/>
  1135. </演:其他>
  1136. </xsl:template>
  1137. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-bounce']">
  1138. <演:其他 uof:locID="p0099">
  1139. <xsl:copy-of select="parent::node()"/>
  1140. </演:其他>
  1141. </xsl:template>
  1142. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-curve-up']">
  1143. <演:其他 uof:locID="p0099">
  1144. <xsl:copy-of select="parent::node()"/>
  1145. </演:其他>
  1146. </xsl:template>
  1147. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-falling-in']">
  1148. <演:其他 uof:locID="p0099">
  1149. <xsl:copy-of select="parent::node()"/>
  1150. </演:其他>
  1151. </xsl:template>
  1152. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-flip']">
  1153. <演:其他 uof:locID="p0099">
  1154. <xsl:copy-of select="parent::node()"/>
  1155. </演:其他>
  1156. </xsl:template>
  1157. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-float']">
  1158. <演:其他 uof:locID="p0099">
  1159. <xsl:copy-of select="parent::node()"/>
  1160. </演:其他>
  1161. </xsl:template>
  1162. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-fold']">
  1163. <演:其他 uof:locID="p0099">
  1164. <xsl:copy-of select="parent::node()"/>
  1165. </演:其他>
  1166. </xsl:template>
  1167. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-glide']">
  1168. <演:其他 uof:locID="p0099">
  1169. <xsl:copy-of select="parent::node()"/>
  1170. </演:其他>
  1171. </xsl:template>
  1172. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-magnify']">
  1173. <演:其他 uof:locID="p0099">
  1174. <xsl:copy-of select="parent::node()"/>
  1175. </演:其他>
  1176. </xsl:template>
  1177. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-movie-credits']">
  1178. <演:其他 uof:locID="p0099">
  1179. <xsl:copy-of select="parent::node()"/>
  1180. </演:其他>
  1181. </xsl:template>
  1182. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-pinwheel']">
  1183. <演:其他 uof:locID="p0099">
  1184. <xsl:copy-of select="parent::node()"/>
  1185. </演:其他>
  1186. </xsl:template>
  1187. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-breaks']">
  1188. <演:其他 uof:locID="p0099">
  1189. <xsl:copy-of select="parent::node()"/>
  1190. </演:其他>
  1191. </xsl:template>
  1192. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-sling']">
  1193. <演:其他 uof:locID="p0099">
  1194. <xsl:copy-of select="parent::node()"/>
  1195. </演:其他>
  1196. </xsl:template>
  1197. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-spiral-in']">
  1198. <演:其他 uof:locID="p0099">
  1199. <xsl:copy-of select="parent::node()"/>
  1200. </演:其他>
  1201. </xsl:template>
  1202. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-swivel']">
  1203. <演:其他 uof:locID="p0099">
  1204. <xsl:copy-of select="parent::node()"/>
  1205. </演:其他>
  1206. </xsl:template>
  1207. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-thread']">
  1208. <演:其他 uof:locID="p0099">
  1209. <xsl:copy-of select="parent::node()"/>
  1210. </演:其他>
  1211. </xsl:template>
  1212. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-whip']">
  1213. <演:其他 uof:locID="p0099">
  1214. <xsl:copy-of select="parent::node()"/>
  1215. </演:其他>
  1216. </xsl:template>
  1217. <xsl:template match="@presentation:preset-id[. = 'oooo-entrance-ascend']">
  1218. <演:其他 uof:locID="p0099">
  1219. <xsl:copy-of select="parent::node()"/>
  1220. </演:其他>
  1221. </xsl:template>
  1222. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-center-revolve']">
  1223. <演:其他 uof:locID="p0099">
  1224. <xsl:copy-of select="parent::node()"/>
  1225. </演:其他>
  1226. </xsl:template>
  1227. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-colored-lettering']">
  1228. <演:其他 uof:locID="p0099">
  1229. <xsl:copy-of select="parent::node()"/>
  1230. </演:其他>
  1231. </xsl:template>
  1232. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-compress']">
  1233. <演:其他 uof:locID="p0099">
  1234. <xsl:copy-of select="parent::node()"/>
  1235. </演:其他>
  1236. </xsl:template>
  1237. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-descend']">
  1238. <演:其他 uof:locID="p0099">
  1239. <xsl:copy-of select="parent::node()"/>
  1240. </演:其他>
  1241. </xsl:template>
  1242. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-ease-in']">
  1243. <演:其他 uof:locID="p0099">
  1244. <xsl:copy-of select="parent::node()"/>
  1245. </演:其他>
  1246. </xsl:template>
  1247. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-rise-up']">
  1248. <演:其他 uof:locID="p0099">
  1249. <xsl:copy-of select="parent::node()"/>
  1250. </演:其他>
  1251. </xsl:template>
  1252. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-spin-in']">
  1253. <演:其他 uof:locID="p0099">
  1254. <xsl:copy-of select="parent::node()"/>
  1255. </演:其他>
  1256. </xsl:template>
  1257. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-stretchy']">
  1258. <演:其他 uof:locID="p0099">
  1259. <xsl:copy-of select="parent::node()"/>
  1260. </演:其他>
  1261. </xsl:template>
  1262. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-turn-and-grow']">
  1263. <演:其他 uof:locID="p0099">
  1264. <xsl:copy-of select="parent::node()"/>
  1265. </演:其他>
  1266. </xsl:template>
  1267. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-unfold']">
  1268. <演:其他 uof:locID="p0099">
  1269. <xsl:copy-of select="parent::node()"/>
  1270. </演:其他>
  1271. </xsl:template>
  1272. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-colored-lettering']">
  1273. <演:其他 uof:locID="p0099">
  1274. <xsl:copy-of select="parent::node()"/>
  1275. </演:其他>
  1276. </xsl:template>
  1277. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-expand']">
  1278. <演:其他 uof:locID="p0099">
  1279. <xsl:copy-of select="parent::node()"/>
  1280. </演:其他>
  1281. </xsl:template>
  1282. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-fade-in']">
  1283. <演:其他 uof:locID="p0099">
  1284. <xsl:copy-of select="parent::node()"/>
  1285. </演:其他>
  1286. </xsl:template>
  1287. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-fade-in-and-swivel']">
  1288. <演:其他 uof:locID="p0099">
  1289. <xsl:copy-of select="parent::node()"/>
  1290. </演:其他>
  1291. </xsl:template>
  1292. <xsl:template match="@presentation:preset-id[. = 'ooo-entrance-fade-in-and-zoom']">
  1293. <演:其他 uof:locID="p0099">
  1294. <xsl:copy-of select="parent::node()"/>
  1295. </演:其他>
  1296. </xsl:template>
  1297. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-fill-color']">
  1298. <演:更改填充颜色 uof:locID="p0124" uof:attrList="速度 颜色">
  1299. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animateColor/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1300. <xsl:attribute name="演:颜色"><xsl:value-of select="../anim:animateColor/@smil:to"/></xsl:attribute>
  1301. </演:更改填充颜色>
  1302. </xsl:template>
  1303. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-font-color']">
  1304. <演:更改字体颜色 uof:locID="p0126" uof:attrList="速度 颜色">
  1305. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animateColor/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1306. <xsl:attribute name="演:颜色"><xsl:value-of select="../anim:animateColor/@smil:to"/></xsl:attribute>
  1307. </演:更改字体颜色>
  1308. </xsl:template>
  1309. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-grow-and-shrink']">
  1310. <演:缩放 uof:locID="p0120" uof:attrList="速度 方向 预定义尺寸 自定义尺寸">
  1311. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animateTransform/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1312. <xsl:attribute name="演:方向">horizontal</xsl:attribute>
  1313. <xsl:choose>
  1314. <xsl:when test="../anim:animateTransform/@smil:to='0.25,1' ">
  1315. <xsl:attribute name="演:预定义尺寸">tiny</xsl:attribute>
  1316. </xsl:when>
  1317. <xsl:when test="../anim:animateTransform/@smil:to='0.5,1' ">
  1318. <xsl:attribute name="演:预定义尺寸">smaller</xsl:attribute>
  1319. </xsl:when>
  1320. <xsl:when test="../anim:animateTransform/@smil:to='1.5,1' ">
  1321. <xsl:attribute name="演:预定义尺寸">larger</xsl:attribute>
  1322. </xsl:when>
  1323. <xsl:when test="../anim:animateTransform/@smil:to='4,1' ">
  1324. <xsl:attribute name="演:预定义尺寸">huge</xsl:attribute>
  1325. </xsl:when>
  1326. <xsl:otherwise>
  1327. <xsl:attribute name="演:自定义尺寸"><xsl:choose><xsl:when test="../anim:animateTransform/@smil:to"><xsl:value-of select="../anim:animateTransform/@smil:to"/></xsl:when><xsl:otherwise>1</xsl:otherwise></xsl:choose></xsl:attribute>
  1328. </xsl:otherwise>
  1329. </xsl:choose>
  1330. </演:缩放>
  1331. </xsl:template>
  1332. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-font-size']">
  1333. <演:更改字号 uof:locID="p0125" uof:attrList="速度 预定义尺寸 自定义尺寸">
  1334. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animate/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1335. <xsl:choose>
  1336. <xsl:when test="parent::anim:par/anim:animate/@smil:to='0.25,1' ">
  1337. <xsl:attribute name="演:预定义尺寸">tiny</xsl:attribute>
  1338. </xsl:when>
  1339. <xsl:when test="parent::anim:par/anim:animate/@smil:to='0.5,1' ">
  1340. <xsl:attribute name="演:预定义尺寸">smaller</xsl:attribute>
  1341. </xsl:when>
  1342. <xsl:when test="parent::anim:par/anim:animate/@smil:to='1.5,1' ">
  1343. <xsl:attribute name="演:预定义尺寸">larger</xsl:attribute>
  1344. </xsl:when>
  1345. <xsl:when test="parent::anim:par/anim:animate/@smil:to='4,1' ">
  1346. <xsl:attribute name="演:预定义尺寸">huge</xsl:attribute>
  1347. </xsl:when>
  1348. <xsl:otherwise>
  1349. <xsl:attribute name="演:自定义尺寸"><xsl:choose><xsl:when test="parent::anim:par/anim:animate/@smil:to"><xsl:value-of select="parent::anim:par/anim:animate/@smil:to"/></xsl:when><xsl:otherwise>1</xsl:otherwise></xsl:choose></xsl:attribute>
  1350. </xsl:otherwise>
  1351. </xsl:choose>
  1352. </演:更改字号>
  1353. </xsl:template>
  1354. <xsl:template name="getfontstyle_emphasis">
  1355. <xsl:value-of select="concat(@smil:to,' ')"/>
  1356. </xsl:template>
  1357. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-font-style']">
  1358. <演:更改字形 uof:locID="p0122" uof:attrList="字形 期间">
  1359. <xsl:attribute name="演:字形"><xsl:variable name="fontstyle"><xsl:for-each select="../anim:set"><xsl:call-template name="getfontstyle_emphasis"/></xsl:for-each></xsl:variable><xsl:value-of select="$fontstyle"/></xsl:attribute>
  1360. <xsl:attribute name="演:期间"><xsl:choose><xsl:when test="../@smil:repeatCount = 'indefinite' "><xsl:choose><xsl:when test="../@smil:end='next'">until next click</xsl:when><xsl:otherwise>until next slide</xsl:otherwise></xsl:choose></xsl:when><xsl:when test="../@smil:repeatCount ='2' or ../@smil:repeatCount ='3' or ../@smil:repeatCount ='4' or ../@smil:repeatCount ='5' or ../@smil:repeatCount ='10'"><xsl:value-of select="../@smil:repeatCount"/></xsl:when><xsl:otherwise>none</xsl:otherwise></xsl:choose></xsl:attribute>
  1361. </演:更改字形>
  1362. </xsl:template>
  1363. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-line-color']">
  1364. <演:更改线条颜色 uof:locID="p0121" uof:attrList="速度 颜色">
  1365. <xsl:attribute name="演:速度">medium</xsl:attribute>
  1366. <xsl:attribute name="演:颜色"><xsl:value-of select="../anim:animateColor/@smil:to"/></xsl:attribute>
  1367. </演:更改线条颜色>
  1368. </xsl:template>
  1369. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-spin']">
  1370. <演:陀螺旋 uof:locID="p0123" uof:attrList="速度 顺时针方向 预定义角度 自定义角度">
  1371. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:animateTransform/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1372. <xsl:attribute name="演:顺时针方向">true</xsl:attribute>
  1373. <xsl:choose>
  1374. <xsl:when test="parent::anim:par/anim:animateTransform/@smil:by='90'">
  1375. <xsl:attribute name="演:预定义角度">quarter spin</xsl:attribute>
  1376. </xsl:when>
  1377. <xsl:when test="parent::anim:par/anim:animateTransform/@smil:by='180'">
  1378. <xsl:attribute name="演:预定义角度">half spin</xsl:attribute>
  1379. </xsl:when>
  1380. <xsl:when test="parent::anim:par/anim:animateTransform/@smil:by='360'">
  1381. <xsl:attribute name="演:预定义角度">full spin</xsl:attribute>
  1382. </xsl:when>
  1383. <xsl:when test="parent::anim:par/anim:animateTransform/@smil:by='720'">
  1384. <xsl:attribute name="演:预定义角度">two spins</xsl:attribute>
  1385. </xsl:when>
  1386. <xsl:otherwise>
  1387. <xsl:attribute name="演:自定义角度"><xsl:value-of select="parent::anim:par/anim:animateTransform/@smil:by"/></xsl:attribute>
  1388. </xsl:otherwise>
  1389. </xsl:choose>
  1390. </演:陀螺旋>
  1391. </xsl:template>
  1392. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-transparency']">
  1393. <演:透明 uof:locID="p0127" uof:attrList="预定义透明度 自定义透明度 期间">
  1394. <xsl:choose>
  1395. <xsl:when test="../anim:set/@smil:to='0.25' ">
  1396. <xsl:attribute name="演:预定义透明度">25</xsl:attribute>
  1397. </xsl:when>
  1398. <xsl:when test="../anim:set/@smil:to='0.5' ">
  1399. <xsl:attribute name="演:预定义透明度">50</xsl:attribute>
  1400. </xsl:when>
  1401. <xsl:when test="../anim:set/@smil:to='0.75' ">
  1402. <xsl:attribute name="演:预定义透明度">75</xsl:attribute>
  1403. </xsl:when>
  1404. <xsl:when test="../anim:set/@smil:to='1' ">
  1405. <xsl:attribute name="演:预定义透明度">100</xsl:attribute>
  1406. </xsl:when>
  1407. <xsl:otherwise>
  1408. <xsl:attribute name="演:自定义透明度"><xsl:value-of select="../anim:set/@smil:to"/></xsl:attribute>
  1409. </xsl:otherwise>
  1410. </xsl:choose>
  1411. <xsl:attribute name="演:期间"><xsl:choose><xsl:when test="../@smil:repeatCount = 'indefinite' "><xsl:choose><xsl:when test="../@smil:end='next'">until next click</xsl:when><xsl:otherwise>until next slide</xsl:otherwise></xsl:choose></xsl:when><xsl:when test="../@smil:repeatCount ='2' or ../@smil:repeatCount ='3' or ../@smil:repeatCount ='4' or ../@smil:repeatCount ='5' or ../@smil:repeatCount ='10'"><xsl:value-of select="../@smil:repeatCount"/></xsl:when><xsl:otherwise>until next click</xsl:otherwise></xsl:choose></xsl:attribute>
  1412. </演:透明>
  1413. </xsl:template>
  1414. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-font']">
  1415. <演:其他 uof:locID="p0128">
  1416. <xsl:copy-of select="parent::node()"/>
  1417. </演:其他>
  1418. </xsl:template>
  1419. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-blast']">
  1420. <演:其他 uof:locID="p0128">
  1421. <xsl:copy-of select="parent::node()"/>
  1422. </演:其他>
  1423. </xsl:template>
  1424. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-blink']">
  1425. <演:其他 uof:locID="p0128">
  1426. <xsl:copy-of select="parent::node()"/>
  1427. </演:其他>
  1428. </xsl:template>
  1429. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-bold-reveal']">
  1430. <演:其他 uof:locID="p0128">
  1431. <xsl:copy-of select="parent::node()"/>
  1432. </演:其他>
  1433. </xsl:template>
  1434. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-style-emphasis']">
  1435. <演:其他 uof:locID="p0128">
  1436. <xsl:copy-of select="parent::node()"/>
  1437. </演:其他>
  1438. </xsl:template>
  1439. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-wave']">
  1440. <演:其他 uof:locID="p0128">
  1441. <xsl:copy-of select="parent::node()"/>
  1442. </演:其他>
  1443. </xsl:template>
  1444. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-flicker']">
  1445. <演:其他 uof:locID="p0128">
  1446. <xsl:copy-of select="parent::node()"/>
  1447. </演:其他>
  1448. </xsl:template>
  1449. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-grow-with-color']">
  1450. <演:其他 uof:locID="p0128">
  1451. <xsl:copy-of select="parent::node()"/>
  1452. </演:其他>
  1453. </xsl:template>
  1454. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-shimmer']">
  1455. <演:其他 uof:locID="p0128">
  1456. <xsl:copy-of select="parent::node()"/>
  1457. </演:其他>
  1458. </xsl:template>
  1459. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-teeter']">
  1460. <演:其他 uof:locID="p0128">
  1461. <xsl:copy-of select="parent::node()"/>
  1462. </演:其他>
  1463. </xsl:template>
  1464. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-bold-flash']">
  1465. <演:其他 uof:locID="p0128">
  1466. <xsl:copy-of select="parent::node()"/>
  1467. </演:其他>
  1468. </xsl:template>
  1469. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-color-blend']">
  1470. <演:其他 uof:locID="p0128">
  1471. <xsl:copy-of select="parent::node()"/>
  1472. </演:其他>
  1473. </xsl:template>
  1474. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-color-over-by-letter']">
  1475. <演:其他 uof:locID="p0128">
  1476. <xsl:copy-of select="parent::node()"/>
  1477. </演:其他>
  1478. </xsl:template>
  1479. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-color-over-by-word']">
  1480. <演:其他 uof:locID="p0128">
  1481. <xsl:copy-of select="parent::node()"/>
  1482. </演:其他>
  1483. </xsl:template>
  1484. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-complementary-color']">
  1485. <演:其他 uof:locID="p0128">
  1486. <xsl:copy-of select="parent::node()"/>
  1487. </演:其他>
  1488. </xsl:template>
  1489. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-complementary-color-2']">
  1490. <演:其他 uof:locID="p0128">
  1491. <xsl:copy-of select="parent::node()"/>
  1492. </演:其他>
  1493. </xsl:template>
  1494. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-contrasting-color']">
  1495. <演:其他 uof:locID="p0128">
  1496. <xsl:copy-of select="parent::node()"/>
  1497. </演:其他>
  1498. </xsl:template>
  1499. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-darken']">
  1500. <演:其他 uof:locID="p0128">
  1501. <xsl:copy-of select="parent::node()"/>
  1502. </演:其他>
  1503. </xsl:template>
  1504. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-desaturate']">
  1505. <演:其他 uof:locID="p0128">
  1506. <xsl:copy-of select="parent::node()"/>
  1507. </演:其他>
  1508. </xsl:template>
  1509. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-flash-bulb']">
  1510. <演:其他 uof:locID="p0128">
  1511. <xsl:copy-of select="parent::node()"/>
  1512. </演:其他>
  1513. </xsl:template>
  1514. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-lighten']">
  1515. <演:其他 uof:locID="p0128">
  1516. <xsl:copy-of select="parent::node()"/>
  1517. </演:其他>
  1518. </xsl:template>
  1519. <xsl:template match="@presentation:preset-id[. = 'ooo-emphasis-reveal-underline']">
  1520. <演:其他 uof:locID="p0128">
  1521. <xsl:copy-of select="parent::node()"/>
  1522. </演:其他>
  1523. </xsl:template>
  1524. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-box']">
  1525. <演:盒状 uof:locID="p0111" uof:attrList="速度 方向">
  1526. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1527. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1528. </演:盒状>
  1529. </xsl:template>
  1530. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-checkerboard']">
  1531. <演:棋盘 uof:locID="p0114" uof:attrList="速度 方向">
  1532. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1533. <xsl:attribute name="演:方向"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:subtype"/></xsl:attribute>
  1534. </演:棋盘>
  1535. </xsl:template>
  1536. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-circle']">
  1537. <演:圆形扩展 uof:locID="p0109" uof:attrList="速度 方向">
  1538. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1539. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1540. </演:圆形扩展>
  1541. </xsl:template>
  1542. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-crawl-out']">
  1543. <演:缓慢移出 uof:locID="p0102" uof:attrList="速度 方向">
  1544. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animate/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1545. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-right'">to right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">to left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">to top</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">to bottom</xsl:when></xsl:choose></xsl:attribute>
  1546. </演:缓慢移出>
  1547. </xsl:template>
  1548. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-diagonal-squares']">
  1549. <演:阶梯状 uof:locID="p0112" uof:attrList="速度 方向">
  1550. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1551. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'left-to-bottom' ">left down</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'left-to-top' ">left up</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'right-to-bottom' ">right down</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'right-to-top' ">right up</xsl:when></xsl:choose></xsl:attribute>
  1552. </演:阶梯状>
  1553. </xsl:template>
  1554. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-diamond']">
  1555. <演:菱形 uof:locID="p0103" uof:attrList="速度 方向">
  1556. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1557. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1558. </演:菱形>
  1559. </xsl:template>
  1560. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-disappear']">
  1561. <演:消失 uof:locID="p0118">
  1562. </演:消失>
  1563. </xsl:template>
  1564. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-dissolve']">
  1565. <演:向外溶解 uof:locID="p0108" uof:attrList="速度">
  1566. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1567. </演:向外溶解>
  1568. </xsl:template>
  1569. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-flash-once']">
  1570. <演:闪烁一次 uof:locID="p0115" uof:attrList="速度 方向">
  1571. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animate/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1572. </演:闪烁一次>
  1573. </xsl:template>
  1574. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-fly-out']">
  1575. <演:飞出 uof:locID="p0101" uof:attrList="速度 方向">
  1576. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="../anim:animate/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1577. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">to bottom</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top-right'">to top-right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top-left'">to top-left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom-left'">to bottom-left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom-right'">to bottom-right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-right'">to right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">to left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">to top</xsl:when></xsl:choose></xsl:attribute>
  1578. </演:飞出>
  1579. </xsl:template>
  1580. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-peek-out']">
  1581. <演:切出 uof:locID="p0105" uof:attrList="速度 方向">
  1582. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1583. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-right'">to right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">to left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">to top</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">to bottom</xsl:when></xsl:choose></xsl:attribute>
  1584. </演:切出>
  1585. </xsl:template>
  1586. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-plus']">
  1587. <演:十字形扩展 uof:locID="p0116" uof:attrList="速度 方向">
  1588. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1589. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1590. </演:十字形扩展>
  1591. </xsl:template>
  1592. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-random-bars']">
  1593. <演:随机线条 uof:locID="p0107" uof:attrList="速度 方向">
  1594. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1595. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1596. </演:随机线条>
  1597. </xsl:template>
  1598. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-random']">
  1599. <演:随机效果 uof:locID="p0117">
  1600. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:choose><xsl:when test="parent::anim:par/anim:transitionFilter/@smil:dur"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:when><xsl:otherwise><xsl:value-of select="../anim:animate/@smil:dur"/></xsl:otherwise></xsl:choose></xsl:with-param></xsl:call-template></xsl:attribute>
  1601. </演:随机效果>
  1602. </xsl:template>
  1603. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-split']">
  1604. <演:劈裂 uof:locID="p0104" uof:attrList="速度 方向">
  1605. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1606. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'horizontal-out'">horizontal out</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'horizontal-in'">horizontal in</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'vertical-in'">vertical in</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'vertical-out'">vertical out</xsl:when></xsl:choose></xsl:attribute>
  1607. </演:劈裂>
  1608. </xsl:template>
  1609. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-venetian-blinds']">
  1610. <演:百叶窗 uof:locID="p0100" uof:attrList="速度 方向">
  1611. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1612. <xsl:attribute name="演:方向"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1613. </演:百叶窗>
  1614. </xsl:template>
  1615. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-wedge']">
  1616. <演:扇形展开 uof:locID="p0106" uof:attrList="速度">
  1617. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1618. </演:扇形展开>
  1619. </xsl:template>
  1620. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-wheel']">
  1621. <演:轮子 uof:locID="p0113" uof:attrList="速度 轮辐">
  1622. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1623. <xsl:attribute name="演:轮辐"><xsl:value-of select="../@presentation:preset-sub-type"/></xsl:attribute>
  1624. </演:轮子>
  1625. </xsl:template>
  1626. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-wipe']">
  1627. <演:擦除 uof:locID="p0110" uof:attrList="速度 方向">
  1628. <xsl:attribute name="演:速度"><xsl:call-template name="anim_speed"><xsl:with-param name="speed"><xsl:value-of select="parent::anim:par/anim:transitionFilter/@smil:dur"/></xsl:with-param></xsl:call-template></xsl:attribute>
  1629. <xsl:attribute name="演:方向"><xsl:choose><xsl:when test="../@presentation:preset-sub-type = 'from-right'">from right</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-left'">from left</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-top'">from top</xsl:when><xsl:when test="../@presentation:preset-sub-type = 'from-bottom'">from bottom</xsl:when></xsl:choose></xsl:attribute>
  1630. </演:擦除>
  1631. </xsl:template>
  1632. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-boomerang']">
  1633. <演:其他 uof:locID="p0119">
  1634. <xsl:copy-of select="parent::node()"/>
  1635. </演:其他>
  1636. </xsl:template>
  1637. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-bounce']">
  1638. <演:其他 uof:locID="p0119">
  1639. <xsl:copy-of select="parent::node()"/>
  1640. </演:其他>
  1641. </xsl:template>
  1642. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-curve-down']">
  1643. <演:其他 uof:locID="p0119">
  1644. <xsl:copy-of select="parent::node()"/>
  1645. </演:其他>
  1646. </xsl:template>
  1647. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-flip']">
  1648. <演:其他 uof:locID="p0119">
  1649. <xsl:copy-of select="parent::node()"/>
  1650. </演:其他>
  1651. </xsl:template>
  1652. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-float']">
  1653. <演:其他 uof:locID="p0119">
  1654. <xsl:copy-of select="parent::node()"/>
  1655. </演:其他>
  1656. </xsl:template>
  1657. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-fold']">
  1658. <演:其他 uof:locID="p0119">
  1659. <xsl:copy-of select="parent::node()"/>
  1660. </演:其他>
  1661. </xsl:template>
  1662. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-glide']">
  1663. <演:其他 uof:locID="p0119">
  1664. <xsl:copy-of select="parent::node()"/>
  1665. </演:其他>
  1666. </xsl:template>
  1667. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-magnify']">
  1668. <演:其他 uof:locID="p0119">
  1669. <xsl:copy-of select="parent::node()"/>
  1670. </演:其他>
  1671. </xsl:template>
  1672. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-movie-credits']">
  1673. <演:其他 uof:locID="p0119">
  1674. <xsl:copy-of select="parent::node()"/>
  1675. </演:其他>
  1676. </xsl:template>
  1677. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-pinwheel']">
  1678. <演:其他 uof:locID="p0119">
  1679. <xsl:copy-of select="parent::node()"/>
  1680. </演:其他>
  1681. </xsl:template>
  1682. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-breaks']">
  1683. <演:其他 uof:locID="p0119">
  1684. <xsl:copy-of select="parent::node()"/>
  1685. </演:其他>
  1686. </xsl:template>
  1687. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-sling']">
  1688. <演:其他 uof:locID="p0119">
  1689. <xsl:copy-of select="parent::node()"/>
  1690. </演:其他>
  1691. </xsl:template>
  1692. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-swish']">
  1693. <演:其他 uof:locID="p0119">
  1694. <xsl:copy-of select="parent::node()"/>
  1695. </演:其他>
  1696. </xsl:template>
  1697. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-swivel']">
  1698. <演:其他 uof:locID="p0119">
  1699. <xsl:copy-of select="parent::node()"/>
  1700. </演:其他>
  1701. </xsl:template>
  1702. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-thread']">
  1703. <演:其他 uof:locID="p0119">
  1704. <xsl:copy-of select="parent::node()"/>
  1705. </演:其他>
  1706. </xsl:template>
  1707. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-whip']">
  1708. <演:其他 uof:locID="p0119">
  1709. <xsl:copy-of select="parent::node()"/>
  1710. </演:其他>
  1711. </xsl:template>
  1712. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-ascend']">
  1713. <演:其他 uof:locID="p0119">
  1714. <xsl:copy-of select="parent::node()"/>
  1715. </演:其他>
  1716. </xsl:template>
  1717. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-center-revolve']">
  1718. <演:其他 uof:locID="p0119">
  1719. <xsl:copy-of select="parent::node()"/>
  1720. </演:其他>
  1721. </xsl:template>
  1722. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-collapse']">
  1723. <演:其他 uof:locID="p0119">
  1724. <xsl:copy-of select="parent::node()"/>
  1725. </演:其他>
  1726. </xsl:template>
  1727. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-colored-lettering']">
  1728. <演:其他 uof:locID="p0119">
  1729. <xsl:copy-of select="parent::node()"/>
  1730. </演:其他>
  1731. </xsl:template>
  1732. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-descend']">
  1733. <演:其他 uof:locID="p0119">
  1734. <xsl:copy-of select="parent::node()"/>
  1735. </演:其他>
  1736. </xsl:template>
  1737. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-ease-out']">
  1738. <演:其他 uof:locID="p0119">
  1739. <xsl:copy-of select="parent::node()"/>
  1740. </演:其他>
  1741. </xsl:template>
  1742. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-sink-down']">
  1743. <演:其他 uof:locID="p0119">
  1744. <xsl:copy-of select="parent::node()"/>
  1745. </演:其他>
  1746. </xsl:template>
  1747. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-spin-out']">
  1748. <演:其他 uof:locID="p0119">
  1749. <xsl:copy-of select="parent::node()"/>
  1750. </演:其他>
  1751. </xsl:template>
  1752. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-stretchy']">
  1753. <演:其他 uof:locID="p0119">
  1754. <xsl:copy-of select="parent::node()"/>
  1755. </演:其他>
  1756. </xsl:template>
  1757. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-turn-and-grow ']">
  1758. <演:其他 uof:locID="p0119">
  1759. <xsl:copy-of select="parent::node()"/>
  1760. </演:其他>
  1761. </xsl:template>
  1762. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-unfold']">
  1763. <演:其他 uof:locID="p0119">
  1764. <xsl:copy-of select="parent::node()"/>
  1765. </演:其他>
  1766. </xsl:template>
  1767. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-zoom']">
  1768. <演:其他 uof:locID="p0119">
  1769. <xsl:copy-of select="parent::node()"/>
  1770. </演:其他>
  1771. </xsl:template>
  1772. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-contract']">
  1773. <演:其他 uof:locID="p0119">
  1774. <xsl:copy-of select="parent::node()"/>
  1775. </演:其他>
  1776. </xsl:template>
  1777. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-fade-out']">
  1778. <演:其他 uof:locID="p0119">
  1779. <xsl:copy-of select="parent::node()"/>
  1780. </演:其他>
  1781. </xsl:template>
  1782. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-fade-out-and-swivel']">
  1783. <演:其他 uof:locID="p0119">
  1784. <xsl:copy-of select="parent::node()"/>
  1785. </演:其他>
  1786. </xsl:template>
  1787. <xsl:template match="@presentation:preset-id[. = 'ooo-exit-fade-out-and-zoom']">
  1788. <演:其他 uof:locID="p0119">
  1789. <xsl:copy-of select="parent::node()"/>
  1790. </演:其他>
  1791. </xsl:template>
  1792. <xsl:template match="draw:page" mode="styles">
  1793. <xsl:call-template name="creategraphicstyles"/>
  1794. </xsl:template>
  1795. <xsl:template match="style:handout-master" mode="styles">
  1796. <xsl:call-template name="creategraphicstyles"/>
  1797. </xsl:template>
  1798. <xsl:template match="style:master-page" mode="styles">
  1799. <xsl:apply-templates select="presentation:notes" mode="styles"/>
  1800. <xsl:call-template name="creategraphicstyles"/>
  1801. </xsl:template>
  1802. <xsl:template match="presentation:notes" mode="styles">
  1803. <xsl:call-template name="creategraphicstyles"/>
  1804. </xsl:template>
  1805. <xsl:template name="creategraphicstyles">
  1806. <xsl:for-each select="node()">
  1807. <xsl:variable name="nodename1">
  1808. <xsl:value-of select="name()"/>
  1809. </xsl:variable>
  1810. <xsl:if test="(substring-before($nodename1,':') = 'draw')">
  1811. <xsl:call-template name="draw">
  1812. <xsl:with-param name="nodename1" select="$nodename1"/>
  1813. </xsl:call-template>
  1814. </xsl:if>
  1815. </xsl:for-each>
  1816. </xsl:template>
  1817. <xsl:template name="draw">
  1818. <xsl:param name="nodename1"/>
  1819. <xsl:choose>
  1820. <xsl:when test="substring-after($nodename1,':') = 'a'">
  1821. <xsl:for-each select="child::*">
  1822. <xsl:call-template name="draw">
  1823. <xsl:with-param name="nodename">
  1824. <xsl:value-of select="name()"/>
  1825. </xsl:with-param>
  1826. </xsl:call-template>
  1827. </xsl:for-each>
  1828. </xsl:when>
  1829. <xsl:when test="substring-after($nodename1,':') = 'g'">
  1830. <xsl:call-template name="draw:g"/>
  1831. </xsl:when>
  1832. <xsl:otherwise>
  1833. <xsl:call-template name="creategraphic"/>
  1834. </xsl:otherwise>
  1835. </xsl:choose>
  1836. </xsl:template>
  1837. <xsl:template name="draw:g">
  1838. <xsl:for-each select="child::*">
  1839. <xsl:choose>
  1840. <xsl:when test="name()='draw:g'">
  1841. <xsl:call-template name="draw:g"/>
  1842. </xsl:when>
  1843. <xsl:otherwise>
  1844. <xsl:call-template name="creategraphic"/>
  1845. </xsl:otherwise>
  1846. </xsl:choose>
  1847. </xsl:for-each>
  1848. <xsl:call-template name="creategraphic"/>
  1849. </xsl:template>
  1850. <xsl:template name="zuheliebiao">
  1851. <xsl:param name="allnode"/>
  1852. <xsl:param name="pos"/>
  1853. <xsl:choose>
  1854. <xsl:when test="../child::*[$pos]">
  1855. <xsl:for-each select="../child::*[$pos]">
  1856. <xsl:variable name="nodepos">
  1857. <xsl:value-of select="@draw:style-name"/>
  1858. </xsl:variable>
  1859. <xsl:variable name="picnumber1">
  1860. <xsl:value-of select="count(preceding::*[@draw:style-name=$nodepos])"/>
  1861. </xsl:variable>
  1862. <xsl:variable name="pic-name1">
  1863. <xsl:value-of select="concat($nodepos,'_',$picnumber1)"/>
  1864. </xsl:variable>
  1865. <xsl:variable name="allnode1">
  1866. <xsl:value-of select="concat($allnode,',',$pic-name1)"/>
  1867. </xsl:variable>
  1868. <xsl:call-template name="zuheliebiao">
  1869. <xsl:with-param name="allnode" select="$allnode1"/>
  1870. <xsl:with-param name="pos" select="$pos+1"/>
  1871. </xsl:call-template>
  1872. </xsl:for-each>
  1873. </xsl:when>
  1874. <xsl:otherwise>
  1875. <xsl:value-of select="$allnode"/>
  1876. </xsl:otherwise>
  1877. </xsl:choose>
  1878. </xsl:template>
  1879. <xsl:template name="creategraphic">
  1880. <xsl:variable name="nodename">
  1881. <xsl:value-of select="name()"/>
  1882. </xsl:variable>
  1883. <xsl:choose>
  1884. <xsl:when test="@draw:style-name or name()='draw:g'">
  1885. <xsl:variable name="pic-name">
  1886. <xsl:value-of select="@draw:style-name"/>
  1887. </xsl:variable>
  1888. <xsl:variable name="pic-num">
  1889. <xsl:value-of select="count(/descendant::*[@draw:style-name=$pic-name])"/>
  1890. </xsl:variable>
  1891. <xsl:variable name="picnumber">
  1892. <xsl:value-of select="count(preceding::*[@draw:style-name=$pic-name])"/>
  1893. </xsl:variable>
  1894. <xsl:call-template name="pic-process">
  1895. <xsl:with-param name="pic-name" select="$pic-name"/>
  1896. <xsl:with-param name="nodename" select="$nodename"/>
  1897. <xsl:with-param name="picnumber" select="$picnumber"/>
  1898. </xsl:call-template>
  1899. </xsl:when>
  1900. <xsl:when test="@presentation:style-name">
  1901. <xsl:variable name="pic-name">
  1902. <xsl:value-of select="@presentation:style-name"/>
  1903. </xsl:variable>
  1904. <xsl:variable name="pic-num">
  1905. <xsl:value-of select="count(/descendant::*[@presentation:style-name=$pic-name])"/>
  1906. </xsl:variable>
  1907. <xsl:variable name="picnumber">
  1908. <xsl:value-of select="count(preceding::*[@presentation:style-name=$pic-name])"/>
  1909. </xsl:variable>
  1910. <xsl:call-template name="pic-process">
  1911. <xsl:with-param name="pic-name" select="$pic-name"/>
  1912. <xsl:with-param name="picnumber" select="$picnumber"/>
  1913. <xsl:with-param name="nodename" select="$nodename"/>
  1914. </xsl:call-template>
  1915. </xsl:when>
  1916. </xsl:choose>
  1917. </xsl:template>
  1918. <xsl:template name="pic-process">
  1919. <xsl:param name="pic-name"/>
  1920. <xsl:param name="nodename"/>
  1921. <xsl:param name="picnumber"/>
  1922. <图:图形 uof:locID="g0000" uof:attrList="层次 标识符 组合列表 其他对象">
  1923. <xsl:attribute name="图:标识符"><xsl:choose><xsl:when test="@draw:id"><xsl:value-of select="@draw:id"/></xsl:when><xsl:when test="not(@draw:style-name) and name()='draw:g'"><xsl:value-of select="concat(child::node()[1]/@draw:style-name,'-',$picnumber)"/></xsl:when><xsl:otherwise><xsl:value-of select="concat($pic-name,'_',$picnumber)"/></xsl:otherwise></xsl:choose></xsl:attribute>
  1924. <xsl:attribute name="图:层次"><xsl:choose><xsl:when test="name(parent::node())='draw:g'"><xsl:value-of select="position()"/></xsl:when><xsl:when test="@draw:z-index"><xsl:value-of select="@draw:z-index"/></xsl:when>
  1925. <xsl:otherwise><xsl:value-of select="position()"/></xsl:otherwise>
  1926. </xsl:choose></xsl:attribute>
  1927. <xsl:if test="$nodename='draw:g'">
  1928. <xsl:attribute name="图:组合列表"><xsl:for-each select="child::*[1]"><xsl:variable name="node1"><xsl:value-of select="@draw:style-name"/></xsl:variable><xsl:variable name="picnumber2"><xsl:value-of select="count(preceding::*[@draw:style-name=$node1])"/></xsl:variable><xsl:call-template name="zuheliebiao"><xsl:with-param name="allnode"><xsl:value-of select="concat($node1,'_',$picnumber2)"/></xsl:with-param><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:for-each></xsl:attribute>
  1929. </xsl:if>
  1930. <xsl:if test=".//office:binary-data">
  1931. <xsl:attribute name="图:其他对象"><xsl:choose><xsl:when test="@draw:name"><xsl:value-of select="@draw:name"/></xsl:when><xsl:otherwise><xsl:value-of select="concat($pic-name,'_b1')"/></xsl:otherwise></xsl:choose></xsl:attribute>
  1932. </xsl:if>
  1933. <xsl:variable name="arrow-sign">
  1934. <xsl:choose>
  1935. <xsl:when test="key('graphicset',$pic-name)/style:graphic-properties/@draw:marker-start or key('graphicset',$pic-name)/style:graphic-properties/@draw:marker-end">
  1936. <xsl:value-of select="'1'"/>
  1937. </xsl:when>
  1938. <xsl:otherwise>0</xsl:otherwise>
  1939. </xsl:choose>
  1940. </xsl:variable>
  1941. <xsl:choose>
  1942. <xsl:when test="$nodename='draw:line' or $nodename='draw:rect' or $nodename='draw:circle' or $nodename='draw:polygon' or $nodename='draw:polyline' or $nodename='draw:ellipse' or $nodename='draw:page-thumbnail' or $nodename='draw:frame' or $nodename='draw:path'or $nodename='draw:g'">
  1943. <图:预定义图形 uof:locID="g0005">
  1944. <图:类别 uof:locID="g0006">
  1945. <xsl:choose>
  1946. <xsl:when test="$nodename='draw:rect'">11</xsl:when>
  1947. <xsl:when test="$nodename='draw:line'">61</xsl:when>
  1948. <xsl:when test="$nodename='draw:circle'">19</xsl:when>
  1949. <xsl:when test="$nodename='draw:polygon'">65</xsl:when>
  1950. <xsl:when test="$nodename='draw:polyline'">66</xsl:when>
  1951. <xsl:when test="$nodename='draw:ellipse'">19</xsl:when>
  1952. <xsl:when test="$nodename='draw:page-thumbnail'">67</xsl:when>
  1953. <xsl:when test="$nodename='draw:frame'">3</xsl:when>
  1954. <xsl:when test="$nodename='draw:path'">64</xsl:when>
  1955. <xsl:when test="$nodename='draw:g'">4</xsl:when>
  1956. </xsl:choose>
  1957. </图:类别>
  1958. <图:名称 uof:locID="g0007">
  1959. <xsl:choose>
  1960. <xsl:when test="$nodename='draw:rect'">Rectangle</xsl:when>
  1961. <xsl:when test="$nodename='draw:line'">Line</xsl:when>
  1962. <xsl:when test="$nodename='draw:circle'">Oval</xsl:when>
  1963. <xsl:when test="$nodename='draw:polygon'">Freeform</xsl:when>
  1964. <xsl:when test="$nodename='draw:polyline'">Scribble</xsl:when>
  1965. <xsl:when test="$nodename='draw:ellipse'">Oval</xsl:when>
  1966. <xsl:when test="$nodename='draw:page-thumbnail'">缩略图</xsl:when>
  1967. <xsl:when test="$nodename='draw:frame'">文本框</xsl:when>
  1968. <xsl:when test="$nodename='draw:path'">Curve</xsl:when>
  1969. <xsl:when test="$nodename='draw:g'">group</xsl:when>
  1970. </xsl:choose>
  1971. </图:名称>
  1972. <图:生成软件 uof:locID="g0008">PNG</图:生成软件>
  1973. <xsl:if test="./@draw:points or ./@svg:d">
  1974. <图:关键点坐标 uof:locID="g0009" uofattrList="路径">
  1975. <xsl:attribute name="图:路径"><xsl:choose><xsl:when test="@svg:d"><xsl:value-of select="@svg:d"/></xsl:when><xsl:when test="@draw:points"><xsl:call-template name="draw:points"><xsl:with-param name="point" select="@draw:points"/><xsl:with-param name="lujing"/></xsl:call-template></xsl:when></xsl:choose></xsl:attribute>
  1976. </图:关键点坐标>
  1977. </xsl:if>
  1978. <图:属性 uof:locID="g0011">
  1979. <xsl:for-each select="(/office:document/office:styles/descendant::*[@style:name=$pic-name]) | (/office:document/*/style:style[@style:name=$pic-name]) ">
  1980. <xsl:for-each select="style:graphic-properties">
  1981. <xsl:if test="not(@draw:fill='none')">
  1982. <图:填充 uof:locID="g0012">
  1983. <xsl:call-template name="填充">
  1984. <xsl:with-param name="nodename" select="$nodename"/>
  1985. <xsl:with-param name="picname" select="$pic-name"/>
  1986. </xsl:call-template>
  1987. </图:填充>
  1988. </xsl:if>
  1989. </xsl:for-each>
  1990. <xsl:if test="style:graphic-properties/@svg:stroke-color">
  1991. <图:线颜色 uof:locID="g0013">
  1992. <xsl:value-of select="style:graphic-properties/@svg:stroke-color"/>
  1993. </图:线颜色>
  1994. </xsl:if>
  1995. <图:线型 uof:locID="g0014">
  1996. <xsl:variable name="linetype" select="style:graphic-properties/@draw:stroke-dash"/>
  1997. <xsl:choose>
  1998. <xsl:when test="not(style:graphic-properties/@draw:stroke)">
  1999. <xsl:choose>
  2000. <xsl:when test="not(style:graphic-properties/@svg:stroke-width)">single</xsl:when>
  2001. <xsl:otherwise>thick</xsl:otherwise>
  2002. </xsl:choose>
  2003. </xsl:when>
  2004. <xsl:otherwise>
  2005. <xsl:choose>
  2006. <xsl:when test="style:graphic-properties/@draw:stroke = 'none'">none</xsl:when>
  2007. <xsl:otherwise>
  2008. <xsl:choose>
  2009. <xsl:when test="$linetype='Fine_20_Dashed' and style:graphic-properties/@svg:stroke-width">dash-long-heavy</xsl:when>
  2010. <xsl:when test="$linetype='Fine_20_Dashed'">dash-long</xsl:when>
  2011. <xsl:when test="$linetype='_32__20_Dots_20_1_20_Dash' and style:graphic-properties/@svg:stroke-width">dash-dot-dot-heavy</xsl:when>
  2012. <xsl:when test="$linetype='_32__20_Dots_20_1_20_Dash'">dot-dot-dash</xsl:when>
  2013. <xsl:when test="$linetype='Ultrafine_20_Dashed' and style:graphic-properties/@svg:stroke-width">dashed-heavy</xsl:when>
  2014. <xsl:when test="$linetype='Ultrafine_20_Dotted_20__28_var_29_'and style:graphic-properties/@svg:stroke-width">dotted-heavy</xsl:when>
  2015. <xsl:when test="$linetype='Ultrafine_20_Dotted_20__28_var_29_'">dotted</xsl:when>
  2016. <xsl:when test="$linetype='Line_20_with_20_Fine_20_Dots'">double</xsl:when>
  2017. <xsl:when test="$linetype='_33__20_Dashes_20_3_20_Dots_20__28_var_29_' and style:graphic-properties/@svg:stroke-width">dash-dot-heavy</xsl:when>
  2018. <xsl:when test="$linetype='_33__20_Dashes_20_3_20_Dots_20__28_var_29_'">dot-dash</xsl:when>
  2019. <xsl:when test="$linetype='Ultrafine_20_2_20_Dots_20_3_20_Dashes'and style:graphic-properties/@svg:stroke-width">wavy-heavy</xsl:when>
  2020. <xsl:when test="$linetype='Ultrafine_20_2_20_Dots_20_3_20_Dashes'">wave</xsl:when>
  2021. <xsl:when test="$linetype='Fine_20_Dashed_20__28_var_29_'">wavy-double</xsl:when>
  2022. <xsl:otherwise>dash</xsl:otherwise>
  2023. </xsl:choose>
  2024. </xsl:otherwise>
  2025. </xsl:choose>
  2026. </xsl:otherwise>
  2027. </xsl:choose>
  2028. </图:线型>
  2029. <xsl:if test="style:graphic-properties/@svg:stroke-width">
  2030. <图:线粗细 uof:locID="g0016">
  2031. <xsl:value-of select="substring-before(style:graphic-properties/@svg:stroke-width,$uofUnit)"/>
  2032. </图:线粗细>
  2033. </xsl:if>
  2034. <xsl:if test="style:graphic-properties/@draw:marker-start and string-length(style:graphic-properties/@draw:marker-start)&gt;0">
  2035. <图:前端箭头 uof:locID="g0017">
  2036. <图:式样 uof:locID="g0018">
  2037. <xsl:choose>
  2038. <xsl:when test="style:graphic-properties/@draw:marker-start='Arrow'">normal</xsl:when>
  2039. <xsl:when test="style:graphic-properties/@draw:marker-start='Line_20_Arrow'">open</xsl:when>
  2040. <xsl:when test="style:graphic-properties/@draw:marker-start='Arrow_20_concave'">stealth</xsl:when>
  2041. <xsl:when test="style:graphic-properties/@draw:marker-start='Circle'">oval</xsl:when>
  2042. <xsl:when test="style:graphic-properties/@draw:marker-start='Square_20_45'">diamond</xsl:when>
  2043. <xsl:otherwise>normal</xsl:otherwise>
  2044. </xsl:choose>
  2045. </图:式样>
  2046. <xsl:if test="style:graphic-properties/@draw:marker-start-width">
  2047. <图:大小 uof:locID="g0019">
  2048. <xsl:variable name="width">
  2049. <xsl:value-of select="substring-before(style:graphic-properties/@draw:marker-start-width,$uofUnit)"/>
  2050. </xsl:variable>
  2051. <xsl:choose>
  2052. <xsl:when test="($width&lt;0.05 and 0&lt;$width) or $width=0.05">1</xsl:when>
  2053. <xsl:when test="($width&lt;0.10 and 0.05&lt;$width) or $width=0.10">2</xsl:when>
  2054. <xsl:when test="($width&lt;0.15 and 0.10&lt;$width) or $width=0.15">3</xsl:when>
  2055. <xsl:when test="($width&lt;0.20 and 0.15&lt;$width) or $width=0.20">4</xsl:when>
  2056. <xsl:when test="($width&lt;0.25 and 0.20&lt;$width) or $width=0.25">5</xsl:when>
  2057. <xsl:when test="($width&lt;0.30 and 0.25&lt;$width) or $width=0.30">6</xsl:when>
  2058. <xsl:when test="($width&lt;0.35 and 0.30&lt;$width) or $width=0.35">7</xsl:when>
  2059. <xsl:when test="($width&lt;0.40 and 0.35&lt;$width) or $width=0.40">8</xsl:when>
  2060. <xsl:otherwise>9</xsl:otherwise>
  2061. </xsl:choose>
  2062. </图:大小>
  2063. </xsl:if>
  2064. </图:前端箭头>
  2065. </xsl:if>
  2066. <xsl:if test="style:graphic-properties/@draw:marker-end">
  2067. <图:后端箭头 uof:locID="g0020">
  2068. <图:式样 uof:locID="g0021">
  2069. <xsl:choose>
  2070. <xsl:when test="style:graphic-properties/@draw:marker-end='Arrow'">normal</xsl:when>
  2071. <xsl:when test="style:graphic-properties/@draw:marker-end='Line_20_Arrow'">open</xsl:when>
  2072. <xsl:when test="style:graphic-properties/@draw:marker-end='Arrow_20_concave'">stealth</xsl:when>
  2073. <xsl:when test="style:graphic-properties/@draw:marker-end='Circle'">oval</xsl:when>
  2074. <xsl:when test="style:graphic-properties/@draw:marker-end='Square_20_45'">diamond</xsl:when>
  2075. <xsl:otherwise>normal</xsl:otherwise>
  2076. </xsl:choose>
  2077. </图:式样>
  2078. <xsl:if test="style:graphic-properties/@draw:marker-end-width">
  2079. <图:大小 uof:locID="g0022">
  2080. <xsl:variable name="width">
  2081. <xsl:value-of select="number(substring-before(style:graphic-properties/@draw:marker-end-width,$uofUnit))"/>
  2082. </xsl:variable>
  2083. <xsl:choose>
  2084. <xsl:when test="($width&lt;0.05 and 0&lt;$width) or $width=0.05">1</xsl:when>
  2085. <xsl:when test="($width&lt;0.10 and 0.05&lt;$width) or $width=0.10">2</xsl:when>
  2086. <xsl:when test="($width&lt;0.15 and 0.10&lt;$width) or $width=0.15">3</xsl:when>
  2087. <xsl:when test="($width&lt;0.20 and 0.15&lt;$width) or $width=0.20">4</xsl:when>
  2088. <xsl:when test="($width&lt;0.25 and 0.20&lt;$width) or $width=0.25">5</xsl:when>
  2089. <xsl:when test="($width&lt;0.30 and 0.25&lt;$width) or $width=0.30">6</xsl:when>
  2090. <xsl:when test="($width&lt;0.35 and 0.30&lt;$width) or $width=0.35">7</xsl:when>
  2091. <xsl:when test="($width&lt;0.40 and 0.35&lt;$width) or $width=0.40">8</xsl:when>
  2092. <xsl:otherwise>9</xsl:otherwise>
  2093. </xsl:choose>
  2094. </图:大小>
  2095. </xsl:if>
  2096. </图:后端箭头>
  2097. </xsl:if>
  2098. <xsl:if test="style:graphic-properties/@draw:opacity or style:graphic-properties/@svg:stroke-opacity or style:graphic-properties/@svg:stroke-opacity">
  2099. <图:透明度 uof:locID="g0038">
  2100. <xsl:choose>
  2101. <xsl:when test="style:graphic-properties/@draw:opacity">
  2102. <xsl:variable name="transparency">
  2103. <xsl:value-of select="substring-before(style:graphic-properties/@draw:opacity,'%')"/>
  2104. </xsl:variable>
  2105. <xsl:value-of select="(100 - $transparency) div 100"/>
  2106. </xsl:when>
  2107. <xsl:when test="style:graphic-properties/@svg:stroke-opacity">
  2108. <xsl:variable name="transparency">
  2109. <xsl:value-of select="substring-before(style:graphic-properties/@svg:stroke-opacity,'%')"/>
  2110. </xsl:variable>
  2111. <xsl:value-of select="(100 - $transparency) div 100"/>
  2112. </xsl:when>
  2113. <xsl:when test="style:properties/@svg:stroke-opacity">
  2114. <xsl:value-of select="substring-before(style:properties/@svg:stroke-opacity,'%')"/>
  2115. </xsl:when>
  2116. </xsl:choose>
  2117. </图:透明度>
  2118. </xsl:if>
  2119. </xsl:for-each>
  2120. <xsl:choose>
  2121. <xsl:when test="@svg:x1">
  2122. <图:宽度 uof:locID="g0023">
  2123. <xsl:value-of select="substring-before(@svg:x2,$uofUnit) - substring-before(@svg:x1,$uofUnit)"/>
  2124. </图:宽度>
  2125. <图:高度 uof:locID="g0024">
  2126. <xsl:value-of select="substring-before(@svg:y2,$uofUnit) - substring-before(@svg:y1,$uofUnit)"/>
  2127. </图:高度>
  2128. </xsl:when>
  2129. <xsl:when test="@svg:x">
  2130. <图:宽度 uof:locID="g0023">
  2131. <xsl:value-of select="substring-before(@svg:width,$uofUnit)"/>
  2132. </图:宽度>
  2133. <图:高度 uof:locID="g0024">
  2134. <xsl:value-of select="substring-before(@svg:height,$uofUnit)"/>
  2135. </图:高度>
  2136. </xsl:when>
  2137. <xsl:when test="@svg:width">
  2138. <图:宽度 uof:locID="g0023">
  2139. <xsl:value-of select="substring-before(@svg:width,$uofUnit)"/>
  2140. </图:宽度>
  2141. <图:高度 uof:locID="g0024">
  2142. <xsl:value-of select="substring-before(@svg:height,$uofUnit)"/>
  2143. </图:高度>
  2144. </xsl:when>
  2145. </xsl:choose>
  2146. <图:旋转角度 uof:locID="g0025">
  2147. <xsl:choose>
  2148. <xsl:when test="@draw:transform">
  2149. <xsl:variable name="rotate-angle">
  2150. <xsl:value-of select="@draw:transform"/>
  2151. </xsl:variable>
  2152. <xsl:variable name="rotate-temp">
  2153. <xsl:value-of select="substring-before(substring-after($rotate-angle,'rotate ('),')')"/>
  2154. </xsl:variable>
  2155. <xsl:value-of select="($rotate-temp * 360) div (2 * 3.14159265)"/>
  2156. </xsl:when>
  2157. <xsl:otherwise>0.0</xsl:otherwise>
  2158. </xsl:choose>
  2159. </图:旋转角度>
  2160. <图:X-缩放比例 uof:locID="g0026">1</图:X-缩放比例>
  2161. <图:Y-缩放比例 uof:locID="g0027">1</图:Y-缩放比例>
  2162. <图:锁定纵横比 uof:locID="g0028">0</图:锁定纵横比>
  2163. <图:相对原始比例 uof:locID="g0029">1</图:相对原始比例>
  2164. <图:打印对象 uof:locID="g0032">true</图:打印对象>
  2165. <图:Web文字 uof:locID="g0033"/>
  2166. </图:属性>
  2167. </图:预定义图形>
  2168. </xsl:when>
  2169. </xsl:choose>
  2170. <xsl:if test="./text:p or ./draw:text-box">
  2171. <图:文本内容 uof:locID="g0002" uof:attrList="文本框 左边距 右边距 上边距 下边距 水平对齐 垂直对齐 文字排列方向 自动换行 大小适应文字 前一链接 后一链接">
  2172. <xsl:if test="$nodename='draw:text-box'">
  2173. <xsl:attribute name="图:文本框">true</xsl:attribute>
  2174. <xsl:if test="./@draw:name = /office:document/office:body
  2175. //draw:text-box/@draw:chain-next-name">
  2176. <xsl:attribute name="图:前一链接"><xsl:variable name="drawname"><xsl:value-of select="./@draw:name"/></xsl:variable><xsl:variable name="befor-link-name"><xsl:value-of select="/office:document/office:body
  2177. //draw:text-box[@draw:name=$drawname]/@draw:style-name"/></xsl:variable><xsl:value-of select="concat($befor-link-name,'_',$picnumber)"/></xsl:attribute>
  2178. </xsl:if>
  2179. <xsl:if test="./@draw:chain-next-name">
  2180. <xsl:attribute name="图:后一链接"><xsl:variable name="next-link"><xsl:value-of select="./@draw:chain-next-name"/></xsl:variable><xsl:variable name="link-name"><xsl:value-of select="/office:document/office:body
  2181. //draw:text-box[@draw:name=$next-link]/@draw:style-name"/></xsl:variable><xsl:value-of select="concat($link-name,'_',$picnumber)"/></xsl:attribute>
  2182. </xsl:if>
  2183. </xsl:if>
  2184. <xsl:for-each select="(/office:document/office:styles/descendant::*[@style:name=$pic-name]) | (/office:document/office:automatic-styles/descendant::*[@style:name=$pic-name]) ">
  2185. <xsl:if test="style:graphic-properties/@fo:padding-left">
  2186. <xsl:attribute name="图:左边距"><xsl:value-of select="substring-before(style:graphic-properties/@fo:padding-left,$uofUnit)"/></xsl:attribute>
  2187. <xsl:attribute name="图:右边距"><xsl:value-of select="substring-before(style:graphic-properties/@fo:padding-right,$uofUnit)"/></xsl:attribute>
  2188. <xsl:attribute name="图:上边距"><xsl:value-of select="substring-before(style:graphic-properties/@fo:padding-top,$uofUnit)"/></xsl:attribute>
  2189. <xsl:attribute name="图:下边距"><xsl:value-of select="substring-before(style:graphic-properties/@fo:padding-bottom,$uofUnit)"/></xsl:attribute>
  2190. </xsl:if>
  2191. <xsl:attribute name="图:文字排列方向">
  2192. <xsl:choose>
  2193. <xsl:when test="style:paragraph-properties/@style:writing-mode">
  2194. <xsl:choose>
  2195. <xsl:when test="style:paragraph-properties/@style:writing-mode='tb-rl' and style:graphic-properties/@draw:textarea-vertical-align='bottom'">vert-l2r</xsl:when>
  2196. <xsl:when test="style:paragraph-properties/@style:writing-mode='tb-rl'">vert-r2l</xsl:when>
  2197. </xsl:choose>
  2198. </xsl:when>
  2199. <xsl:when test="style:graphic-properties/@draw:textarea-horizontal-align='right'">hori-r2l</xsl:when>
  2200. <xsl:otherwise>hori-l2r</xsl:otherwise>
  2201. </xsl:choose>
  2202. </xsl:attribute>
  2203. <xsl:if test="style:graphic-properties/@fo:wrap-option">
  2204. <xsl:attribute name="图:自动换行">true</xsl:attribute>
  2205. </xsl:if>
  2206. <xsl:if test="style:graphic-properties/@draw:auto-grow-width='true'">
  2207. <xsl:attribute name="图:大小适应文字">true</xsl:attribute>
  2208. </xsl:if>
  2209. </xsl:for-each>
  2210. <xsl:if test="./draw:text-box">
  2211. <xsl:for-each select="draw:text-box/node( )">
  2212. <xsl:choose>
  2213. <xsl:when test="name()='text:list'">
  2214. <xsl:call-template name="unordered-ordered-list">
  2215. <xsl:with-param name="currlistlvl" select="number('1')"/>
  2216. <xsl:with-param name="liststylename" select="@text:style-name"/>
  2217. </xsl:call-template>
  2218. </xsl:when>
  2219. <xsl:when test="name()='text:p'or name()='text:h'">
  2220. <xsl:call-template name="execParagraph">
  2221. <xsl:with-param name="currlistlvl" select="number('0')"/>
  2222. <xsl:with-param name="liststylename" select="string('00000')"/>
  2223. </xsl:call-template>
  2224. </xsl:when>
  2225. </xsl:choose>
  2226. </xsl:for-each>
  2227. </xsl:if>
  2228. <xsl:if test="./text:p">
  2229. <xsl:call-template name="execParagraph">
  2230. <xsl:with-param name="currlistlvl" select="number('0')"/>
  2231. <xsl:with-param name="liststylename" select="string('00000')"/>
  2232. </xsl:call-template>
  2233. </xsl:if>
  2234. </图:文本内容>
  2235. </xsl:if>
  2236. <图:控制点 uof:locID="g0003" uof:attrList="x坐标 y坐标">
  2237. <xsl:attribute name="图:x坐标"><xsl:value-of select="substring-before(@svg:x,$uofUnit)"/></xsl:attribute>
  2238. <xsl:attribute name="图:y坐标"><xsl:value-of select="substring-before(@svg:y,$uofUnit)"/></xsl:attribute>
  2239. </图:控制点>
  2240. <图:翻转 uof:locID="g0040" uof:attrList="方向" 图:方向="x"/>
  2241. </图:图形>
  2242. <xsl:if test="name(..)='draw:g'">
  2243. <图:组合位置 uof:locID="g0041" uof:attrList="x坐标 y坐标">
  2244. <xsl:attribute name="图:x坐标"><xsl:variable name="minx"><xsl:for-each select="parent::node()"><xsl:call-template name="groupminx"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:x][1]/@svg:x,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:for-each></xsl:variable><xsl:choose><xsl:when test="name(.)='draw:g'"><xsl:variable name="current-minx"><xsl:call-template name="groupminx"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:x][1]/@svg:x,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:variable><xsl:value-of select="$current-minx - $minx"/></xsl:when><xsl:otherwise><xsl:variable name="current-x" select="number(substring-before(@svg:x,$uofUnit))"/><xsl:value-of select="$current-x - $minx"/></xsl:otherwise></xsl:choose></xsl:attribute>
  2245. <xsl:attribute name="图:y坐标"><xsl:variable name="miny"><xsl:for-each select="parent::node()"><xsl:call-template name="groupminy"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:y][1]/@svg:y,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:for-each></xsl:variable><xsl:choose><xsl:when test="name(.)='draw:g'"><xsl:variable name="current-miny"><xsl:call-template name="groupminy"><xsl:with-param name="value" select="number(substring-before(descendant::node()[@svg:y][1]/@svg:y,$uofUnit))"/><xsl:with-param name="pos" select="2"/></xsl:call-template></xsl:variable><xsl:value-of select="$current-miny - $miny"/></xsl:when><xsl:otherwise><xsl:variable name="current-y" select="number(substring-before(@svg:y,$uofUnit))"/><xsl:value-of select="$current-y - $miny"/></xsl:otherwise></xsl:choose></xsl:attribute>
  2246. </图:组合位置>
  2247. </xsl:if>
  2248. <xsl:if test="name()='draw:frame' and ./draw:image">
  2249. <uof:其他对象 uof:locID="u0036" uof:attrList="标识符 内嵌 公共类型 私有类型">
  2250. <xsl:attribute name="uof:标识符"><xsl:choose><xsl:when test="@draw:id"><xsl:value-of select="@draw:id"/></xsl:when><xsl:otherwise><xsl:value-of select="concat($pic-name,'_',$picnumber)"/></xsl:otherwise></xsl:choose></xsl:attribute>
  2251. <xsl:attribute name="uof:内嵌">true</xsl:attribute>
  2252. <xsl:attribute name="uof:公共类型">jpg</xsl:attribute>
  2253. <xsl:if test="./draw:image/office:binary-data">
  2254. <uof:数据 uof:locID="u0037">
  2255. <xsl:value-of select="./draw:image/office:binary-data"/>
  2256. </uof:数据>
  2257. </xsl:if>
  2258. <xsl:if test="./draw:image/@xlink:href">
  2259. <uof:路径 uof:locID="u0038">
  2260. <xsl:value-of select="./draw:image/@xlink:href"/>
  2261. </uof:路径>
  2262. </xsl:if>
  2263. </uof:其他对象>
  2264. </xsl:if>
  2265. <xsl:for-each select="(/office:document/office:styles/descendant::*[@style:name=$pic-name]) | (/office:document/office:automatic-styles/descendant::*[@style:name=$pic-name]) ">
  2266. <xsl:if test="style:graphic-properties/@draw:fill-image-name and @draw:fill='bitmap'">
  2267. <uof:其他对象 uof:locID="u0036" uof:attrList="标识符 内嵌 公共类型 私有类型">
  2268. <xsl:attribute name="uof:标识符"><xsl:choose><xsl:when test="@draw:id"><xsl:value-of select="@draw:id"/></xsl:when><xsl:otherwise><xsl:value-of select="concat($pic-name,'_',$picnumber)"/></xsl:otherwise></xsl:choose></xsl:attribute>
  2269. <xsl:attribute name="uof:公共类型">jpg</xsl:attribute>
  2270. <xsl:attribute name="uof:内嵌">true</xsl:attribute>
  2271. <xsl:variable name="fill-name">
  2272. <xsl:value-of select="style:graphic-properties/@draw:fill-image-name"/>
  2273. </xsl:variable>
  2274. <uof:数据 uof:locID="u0037">
  2275. <xsl:for-each select="/office:document/office:styles/draw:fill-image[@draw:name=$fill-name]">
  2276. <xsl:value-of select="office:binary-data"/>
  2277. </xsl:for-each>
  2278. </uof:数据>
  2279. <uof:路径 uof:locID="u0038">
  2280. <xsl:value-of select="@xlink:href"/>
  2281. </uof:路径>
  2282. </uof:其他对象>
  2283. </xsl:if>
  2284. </xsl:for-each>
  2285. </xsl:template>
  2286. <xsl:template name="unordered-ordered-list">
  2287. <xsl:param name="currlistlvl"/>
  2288. <xsl:param name="liststylename"/>
  2289. <xsl:for-each select="text:list-item">
  2290. <xsl:if test="text:p">
  2291. <xsl:for-each select="text:p">
  2292. <xsl:call-template name="execParagraph">
  2293. <xsl:with-param name="currlistlvl" select="$currlistlvl"/>
  2294. <xsl:with-param name="liststylename" select="$liststylename"/>
  2295. </xsl:call-template>
  2296. </xsl:for-each>
  2297. </xsl:if>
  2298. <xsl:for-each select="node( )">
  2299. <xsl:if test="name()='text:list'">
  2300. <xsl:call-template name="unordered-ordered-list">
  2301. <xsl:with-param name="currlistlvl" select="$currlistlvl +1"/>
  2302. <xsl:with-param name="liststylename" select="$liststylename"/>
  2303. </xsl:call-template>
  2304. </xsl:if>
  2305. </xsl:for-each>
  2306. </xsl:for-each>
  2307. </xsl:template>
  2308. <xsl:template name="groupminx">
  2309. <xsl:param name="value"/>
  2310. <xsl:param name="pos"/>
  2311. <xsl:choose>
  2312. <xsl:when test="descendant::node()[@svg:x][position()=$pos]">
  2313. <xsl:variable name="othervalue" select="number(substring-before(descendant::node()[@svg:x][position()=$pos]/@svg:x,$uofUnit))"/>
  2314. <xsl:call-template name="groupminx">
  2315. <xsl:with-param name="value">
  2316. <xsl:choose>
  2317. <xsl:when test="$value&gt;$othervalue">
  2318. <xsl:value-of select="$othervalue"/>
  2319. </xsl:when>
  2320. <xsl:otherwise>
  2321. <xsl:value-of select="$value"/>
  2322. </xsl:otherwise>
  2323. </xsl:choose>
  2324. </xsl:with-param>
  2325. <xsl:with-param name="pos" select="$pos+1"/>
  2326. </xsl:call-template>
  2327. </xsl:when>
  2328. <xsl:otherwise>
  2329. <xsl:value-of select="$value"/>
  2330. </xsl:otherwise>
  2331. </xsl:choose>
  2332. </xsl:template>
  2333. <xsl:template name="groupminy">
  2334. <xsl:param name="value"/>
  2335. <xsl:param name="pos"/>
  2336. <xsl:choose>
  2337. <xsl:when test="descendant::node()[@svg:y][position()=$pos]">
  2338. <xsl:variable name="othervalue" select="number(substring-before(descendant::node()[@svg:y][position()=$pos]/@svg:y,$uofUnit))"/>
  2339. <xsl:call-template name="groupminy">
  2340. <xsl:with-param name="value">
  2341. <xsl:choose>
  2342. <xsl:when test="$value&gt;$othervalue">
  2343. <xsl:value-of select="$othervalue"/>
  2344. </xsl:when>
  2345. <xsl:otherwise>
  2346. <xsl:value-of select="$value"/>
  2347. </xsl:otherwise>
  2348. </xsl:choose>
  2349. </xsl:with-param>
  2350. <xsl:with-param name="pos" select="$pos+1"/>
  2351. </xsl:call-template>
  2352. </xsl:when>
  2353. <xsl:otherwise>
  2354. <xsl:value-of select="$value"/>
  2355. </xsl:otherwise>
  2356. </xsl:choose>
  2357. </xsl:template>
  2358. <xsl:template name="groupmaxx">
  2359. <xsl:param name="value"/>
  2360. <xsl:param name="pos"/>
  2361. <xsl:choose>
  2362. <xsl:when test="descendant::node()[@svg:x][position()=$pos]">
  2363. <xsl:variable name="svgx">
  2364. <xsl:value-of select="number(substring-before(descendant::node()[@svg:x][position()=$pos]/@svg:x,$uofUnit))"/>
  2365. </xsl:variable>
  2366. <xsl:variable name="width">
  2367. <xsl:value-of select="number(substring-before(descendant::node()[@svg:x][position()=$pos]/@svg:width,$uofUnit))"/>
  2368. </xsl:variable>
  2369. <xsl:variable name="othervalue" select="$svgx + $width"/>
  2370. <xsl:call-template name="groupminx">
  2371. <xsl:with-param name="value">
  2372. <xsl:choose>
  2373. <xsl:when test="$value&gt;$othervalue">
  2374. <xsl:value-of select="$value"/>
  2375. </xsl:when>
  2376. <xsl:otherwise>
  2377. <xsl:value-of select="$othervalue"/>
  2378. </xsl:otherwise>
  2379. </xsl:choose>
  2380. </xsl:with-param>
  2381. <xsl:with-param name="pos" select="$pos+1"/>
  2382. </xsl:call-template>
  2383. </xsl:when>
  2384. <xsl:otherwise>
  2385. <xsl:value-of select="$value"/>
  2386. </xsl:otherwise>
  2387. </xsl:choose>
  2388. </xsl:template>
  2389. <xsl:template name="groupmaxy">
  2390. <xsl:param name="value"/>
  2391. <xsl:param name="pos"/>
  2392. <xsl:choose>
  2393. <xsl:when test="descendant::node()[@svg:y][position()=$pos]">
  2394. <xsl:variable name="svgy">
  2395. <xsl:value-of select="number(substring-before(descendant::node()[@svg:y][position()=$pos]/@svg:y,$uofUnit))"/>
  2396. </xsl:variable>
  2397. <xsl:variable name="height">
  2398. <xsl:value-of select="number(substring-before(descendant::node()[@svg:y][position()=$pos]/@svg:height,$uofUnit))"/>
  2399. </xsl:variable>
  2400. <xsl:variable name="othervalue" select="$svgy + $height"/>
  2401. <xsl:call-template name="groupminy">
  2402. <xsl:with-param name="value">
  2403. <xsl:choose>
  2404. <xsl:when test="$value&gt;$othervalue">
  2405. <xsl:value-of select="$value"/>
  2406. </xsl:when>
  2407. <xsl:otherwise>
  2408. <xsl:value-of select="$othervalue"/>
  2409. </xsl:otherwise>
  2410. </xsl:choose>
  2411. </xsl:with-param>
  2412. <xsl:with-param name="pos" select="$pos+1"/>
  2413. </xsl:call-template>
  2414. </xsl:when>
  2415. <xsl:otherwise>
  2416. <xsl:value-of select="$value"/>
  2417. </xsl:otherwise>
  2418. </xsl:choose>
  2419. </xsl:template>
  2420. <xsl:template name="draw:points">
  2421. <xsl:param name="point"/>
  2422. <xsl:param name="lujing"/>
  2423. <xsl:choose>
  2424. <xsl:when test="contains($point,' ' )">
  2425. <xsl:variable name="first-point" select="substring-before($point,' ')"/>
  2426. <xsl:variable name="other-point" select="substring-after($point,' ')"/>
  2427. <xsl:variable name="xzuobiao">
  2428. <xsl:value-of select="substring-before($first-point,',') div 1000"/>
  2429. </xsl:variable>
  2430. <xsl:variable name="yzuobiao">
  2431. <xsl:value-of select="substring-after($first-point,',') div 1000"/>
  2432. </xsl:variable>
  2433. <xsl:call-template name="draw:points">
  2434. <xsl:with-param name="point" select="$other-point"/>
  2435. <xsl:with-param name="lujing" select="concat($lujing,$xzuobiao,' ',$yzuobiao,'lineto')"/>
  2436. </xsl:call-template>
  2437. </xsl:when>
  2438. <xsl:otherwise>
  2439. <xsl:variable name="xzuobiao">
  2440. <xsl:value-of select="substring-before($point,',') div 1000"/>
  2441. </xsl:variable>
  2442. <xsl:variable name="yzuobiao">
  2443. <xsl:value-of select="substring-after($point,',') div 1000"/>
  2444. </xsl:variable>
  2445. <xsl:value-of select="concat($lujing,$xzuobiao,' ',$yzuobiao)"/>
  2446. </xsl:otherwise>
  2447. </xsl:choose>
  2448. </xsl:template>
  2449. <xsl:template name="execParagraph">
  2450. <xsl:param name="currlistlvl"/>
  2451. <xsl:param name="liststylename"/>
  2452. <字:段落 uof:locID="t0051" uof:attrList="标识符">
  2453. <xsl:if test="@text:id">
  2454. <xsl:attribute name="字:动画标识"><xsl:value-of select="@text:id"/></xsl:attribute>
  2455. </xsl:if>
  2456. <xsl:element name="字:段落属性">
  2457. <xsl:attribute name="uof:locID">t0052</xsl:attribute>
  2458. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  2459. <xsl:attribute name="字:式样引用"><xsl:choose><xsl:when test="@text:id"><xsl:value-of select="@text:id"/></xsl:when><xsl:otherwise><xsl:value-of select="@text:style-name"/></xsl:otherwise></xsl:choose></xsl:attribute>
  2460. <xsl:if test="not(number($currlistlvl) =number('0'))">
  2461. <xsl:variable name="parent-position">
  2462. <xsl:number from="/office:document/office:body/text:ordered-list" level="any" count="text:list-item/text:p" format="1"/>
  2463. </xsl:variable>
  2464. <xsl:element name="字:自动编号信息">
  2465. <xsl:attribute name="uof:locID">t0059</xsl:attribute>
  2466. <xsl:attribute name="uof:attrList">编号引用 编号级别 重新编号 起始编号</xsl:attribute>
  2467. <xsl:attribute name="字:编号引用"><xsl:value-of select="$liststylename"/></xsl:attribute>
  2468. <xsl:attribute name="字:编号级别"><xsl:value-of select="$currlistlvl"/></xsl:attribute>
  2469. <xsl:attribute name="字:重新编号"><xsl:choose><xsl:when test="number($parent-position)=number('1')">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  2470. <xsl:attribute name="字:起始编号"><xsl:for-each select="//text:list-style[$liststylename=@style:name]/*[number($currlistlvl)=number(@text:level)]"><xsl:choose><xsl:when test="@text:start-value"><xsl:value-of select="@text:start-value"/></xsl:when><xsl:otherwise>1</xsl:otherwise></xsl:choose></xsl:for-each></xsl:attribute>
  2471. </xsl:element>
  2472. </xsl:if>
  2473. <xsl:variable name="stylename">
  2474. <xsl:value-of select="@text:style-name"/>
  2475. </xsl:variable>
  2476. <xsl:for-each select="(//style:style[@style:name=$stylename])">
  2477. <xsl:call-template name="ParaAttribute">
  2478. <xsl:with-param name="text-style-name" select="@text:style-name"/>
  2479. </xsl:call-template>
  2480. </xsl:for-each>
  2481. </xsl:element>
  2482. <xsl:for-each select="node( )">
  2483. <xsl:choose>
  2484. <xsl:when test="self::node( )[name(.)='text:span']">
  2485. <xsl:call-template name="textspan"/>
  2486. </xsl:when>
  2487. <xsl:when test="self::node()[name(.)='text:time']">
  2488. <xsl:apply-templates select="."/>
  2489. </xsl:when>
  2490. <xsl:when test="self::node()[name(.)='text:s']">
  2491. <xsl:apply-templates select="."/>
  2492. </xsl:when>
  2493. <xsl:when test="substring-before(name(.),':')='draw' and not(name(.)='draw:a')">
  2494. </xsl:when>
  2495. <xsl:when test="name(.)='text:a'">
  2496. <字:句 uof:locID="t0085">
  2497. <xsl:element name="字:句属性">
  2498. <xsl:attribute name="uof:locID">t0086</xsl:attribute>
  2499. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  2500. <字:字体 uof:locID="t0088" uof:attrList="西文字体引用 中文字体引用 字号 颜色" 字:颜色="#0000ff"/>
  2501. <字:下划线 uof:locID="t0095" 字:类型="single" 字:颜色="#0000ff" uof:attrList="类型 颜色 字下划线"/>
  2502. </xsl:element>
  2503. <xsl:element name="字:区域开始">
  2504. <xsl:attribute name="字:标识符">hlnk<xsl:number from="/office:document/office:body" level="any" count="text:p[text:a]"/></xsl:attribute>
  2505. <xsl:attribute name="字:名称">Hyperlink</xsl:attribute>
  2506. <xsl:attribute name="字:类型">hyperlink</xsl:attribute>
  2507. <xsl:attribute name="uof:locID">t0121</xsl:attribute>
  2508. <xsl:attribute name="uof:attrList">标识符 名称 类型</xsl:attribute>
  2509. </xsl:element>
  2510. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2511. <xsl:value-of select="."/>
  2512. </字:文本串>
  2513. <xsl:element name="字:区域结束">
  2514. <xsl:attribute name="字:标识符引用">hlnk<xsl:number from="/office:document/office:body" level="any" count="text:p[text:a]"/></xsl:attribute>
  2515. <xsl:attribute name="uof:locID">t0122</xsl:attribute>
  2516. <xsl:attribute name="uof:attrList">标识符引用</xsl:attribute>
  2517. </xsl:element>
  2518. </字:句>
  2519. </xsl:when>
  2520. <xsl:otherwise>
  2521. <xsl:call-template name="字:句"/>
  2522. </xsl:otherwise>
  2523. </xsl:choose>
  2524. </xsl:for-each>
  2525. </字:段落>
  2526. </xsl:template>
  2527. <xsl:template name="字:句">
  2528. <xsl:if test="not(name(.)='text:bookmark-start' or name(.)='text:bookmark-end' or name(.)='draw:image' or name(.)='office:binary-data')">
  2529. <字:句 uof:locID="t0085">
  2530. <字:句属性 uof:locID="t0086" uof:attrList="式样引用">
  2531. <xsl:choose>
  2532. <xsl:when test="@text:style-name">
  2533. <xsl:attribute name="字:式样引用"><xsl:value-of select="@text:style-name"/></xsl:attribute>
  2534. </xsl:when>
  2535. <xsl:otherwise>
  2536. <xsl:attribute name="字:式样引用"><xsl:value-of select="parent::node( )/@text:style-name"/></xsl:attribute>
  2537. </xsl:otherwise>
  2538. </xsl:choose>
  2539. </字:句属性>
  2540. <xsl:choose>
  2541. <xsl:when test="(preceding-sibling::text:bookmark-start) and (following-sibling::text:bookmark-end)">
  2542. <字:区域开始 uof:locID="t0121" uof:attrList="标识符 名称 类型">
  2543. <xsl:attribute name="字:标识符"><xsl:value-of select="preceding-sibling::text:bookmark-start/@text:name"/></xsl:attribute>
  2544. <xsl:attribute name="字:名称">Bookmark</xsl:attribute>
  2545. <xsl:attribute name="字:类型">bookmark</xsl:attribute>
  2546. </字:区域开始>
  2547. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2548. <xsl:value-of select="string(.)"/>
  2549. </字:文本串>
  2550. <字:区域结束 uof:locID="t0122" uof:attrList="标识符引用">
  2551. <xsl:attribute name="字:标识符引用"><xsl:value-of select="following-sibling::text:bookmark-end/@text:name"/></xsl:attribute>
  2552. </字:区域结束>
  2553. </xsl:when>
  2554. <xsl:when test="preceding-sibling::text:bookmark">
  2555. <字:区域开始 uof:locID="t0121" uof:attrList="标识符 名称 类型">
  2556. <xsl:attribute name="字:标识符"><xsl:value-of select="preceding-sibling::text:bookmark/@text:name"/></xsl:attribute>
  2557. <xsl:attribute name="字:名称">Bookmark</xsl:attribute>
  2558. <xsl:attribute name="字:类型">bookmark</xsl:attribute>
  2559. </字:区域开始>
  2560. <字:区域结束 uof:locID="t0122" uof:attrList="标识符引用">
  2561. <xsl:attribute name="字:标识符引用"><xsl:value-of select="preceding-sibling::text:bookmark/@text:name"/></xsl:attribute>
  2562. </字:区域结束>
  2563. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2564. <xsl:value-of select="string(.)"/>
  2565. </字:文本串>
  2566. </xsl:when>
  2567. <xsl:when test="name(.)='draw:a'">
  2568. <xsl:variable name="link-name">
  2569. <xsl:value-of select="substring-after(@xlink:href,'#')"/>
  2570. </xsl:variable>
  2571. <字:区域开始 uof:locID="t0121" uof:attrList="标识符 名称 类型">
  2572. <xsl:attribute name="字:标识符"><xsl:value-of select="$link-name"/></xsl:attribute>
  2573. <xsl:attribute name="字:名称">Bookmark</xsl:attribute>
  2574. <xsl:attribute name="字:类型">bookmark</xsl:attribute>
  2575. </字:区域开始>
  2576. <字:区域结束 uof:locID="t0122" uof:attrList="标识符引用">
  2577. <xsl:attribute name="字:标识符引用"><xsl:value-of select="$link-name"/></xsl:attribute>
  2578. </字:区域结束>
  2579. </xsl:when>
  2580. <xsl:when test="self::node( )[name(.)='text:tab-stop']">
  2581. <xsl:element name="字:制表符">
  2582. <xsl:attribute name="uof:locID">t0123</xsl:attribute>
  2583. </xsl:element>
  2584. </xsl:when>
  2585. <xsl:when test="name(.)='text:bookmark-start' or name(.)='text:bookmark-end' or name(.)='draw:image' or name(.)='office:binary-data'">
  2586. </xsl:when>
  2587. <xsl:otherwise>
  2588. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2589. <xsl:value-of select="string(.)"/>
  2590. </字:文本串>
  2591. </xsl:otherwise>
  2592. </xsl:choose>
  2593. </字:句>
  2594. </xsl:if>
  2595. </xsl:template>
  2596. <xsl:template name="jiaozhu">
  2597. <字:脚注 uof:locID="t0107" uof:attrList="引文体">
  2598. <xsl:call-template name="execParagraph">
  2599. <xsl:with-param name="currlistlvl" select="number('0')"/>
  2600. <xsl:with-param name="liststylename" select="string('00000')"/>
  2601. </xsl:call-template>
  2602. </字:脚注>
  2603. </xsl:template>
  2604. <xsl:template match="text:s">
  2605. <xsl:param name="bText"/>
  2606. <xsl:choose>
  2607. <xsl:when test="$bText='0'">
  2608. <xsl:variable name="count">
  2609. <xsl:choose>
  2610. <xsl:when test="not(@text:c)">1</xsl:when>
  2611. <xsl:otherwise>
  2612. <xsl:value-of select="@text:c+1"/>
  2613. </xsl:otherwise>
  2614. </xsl:choose>
  2615. </xsl:variable>
  2616. <字:句 uof:locID="t0085">
  2617. <字:空格符 uof:locID="t0126" uof:attrList="个数" 字:个数="{$count}"/>
  2618. </字:句>
  2619. </xsl:when>
  2620. <xsl:otherwise>
  2621. <字:空格符 uof:locID="t0126" uof:attrList="个数" 字:个数="{@text:c}"/>
  2622. </xsl:otherwise>
  2623. </xsl:choose>
  2624. </xsl:template>
  2625. <xsl:template name="weizhu">
  2626. <字:尾注 uof:locID="t0108" uof:attrList="引文体">
  2627. <xsl:call-template name="execParagraph">
  2628. <xsl:with-param name="currlistlvl" select="number('0')"/>
  2629. <xsl:with-param name="liststylename" select="string('00000')"/>
  2630. </xsl:call-template>
  2631. </字:尾注>
  2632. </xsl:template>
  2633. <xsl:template match="text:time">
  2634. <xsl:element name="字:域开始">
  2635. <xsl:attribute name="字:类型"><xsl:value-of select="'TIME'"/></xsl:attribute>
  2636. <xsl:choose>
  2637. <xsl:when test="text:fixed='1'">
  2638. <xsl:attribute name="字:锁定">true</xsl:attribute>
  2639. </xsl:when>
  2640. <xsl:otherwise>
  2641. <xsl:attribute name="字:锁定">false</xsl:attribute>
  2642. </xsl:otherwise>
  2643. </xsl:choose>
  2644. <xsl:attribute name="uof:locID">t0079</xsl:attribute>
  2645. <xsl:attribute name="uof:attrList">类型 锁定</xsl:attribute>
  2646. </xsl:element>
  2647. <xsl:element name="字:域代码">
  2648. <字:段落 uof:locID="t0051">
  2649. <字:句 uof:locID="t0085">
  2650. <字:句属性 uof:locID="t0086" uof:attrList="式样引用"/>
  2651. <xsl:variable name="timefmt">
  2652. <xsl:variable name="aa" select="@style:data-style-name"/>
  2653. <xsl:for-each select="key('geshi',$aa)/number:hours | key('geshi',$aa)/number:minutes | key('geshi',$aa)/number:am-pm | key('geshi',$aa)/number:seconds | key('geshi',$aa)/number:text">
  2654. <xsl:choose>
  2655. <xsl:when test="@number:style='long' ">
  2656. <xsl:if test="self::node( )[name(.)='number:hours']">HH</xsl:if>
  2657. <xsl:if test="self::node( )[name(.)='number:minutes']">MM</xsl:if>
  2658. <xsl:if test="self::node( )[name(.)='number:seconds']">SS</xsl:if>
  2659. </xsl:when>
  2660. <xsl:otherwise>
  2661. <xsl:if test="self::node( )[name(.)='number:text']">
  2662. <xsl:value-of select="."/>
  2663. </xsl:if>
  2664. <xsl:if test="self::node( )[name(.)='number:hours']">H</xsl:if>
  2665. <xsl:if test="self::node( )[name(.)='number:minutes']">M</xsl:if>
  2666. <xsl:if test="self::node( )[name(.)='number:seconds']">S</xsl:if>
  2667. <xsl:if test="self::node( )[name(.)='number:am-pm']">AMPM</xsl:if>
  2668. </xsl:otherwise>
  2669. </xsl:choose>
  2670. </xsl:for-each>
  2671. </xsl:variable>
  2672. <xsl:variable name="quote">"</xsl:variable>
  2673. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2674. <xsl:value-of select="concat('TIME \@ ',$quote,$timefmt,$quote,' \* MERGEFORMAT ')"/>
  2675. </字:文本串>
  2676. </字:句>
  2677. </字:段落>
  2678. </xsl:element>
  2679. <字:句 uof:locID="t0085">
  2680. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2681. <xsl:value-of select="."/>
  2682. </字:文本串>
  2683. </字:句>
  2684. <xsl:element name="字:域结束">
  2685. <xsl:attribute name="uof:locID">t0081</xsl:attribute>
  2686. </xsl:element>
  2687. </xsl:template>
  2688. <xsl:template name="ParaAttribute">
  2689. <xsl:param name="text-style-name"/>
  2690. <xsl:for-each select="/office:document/office:styles/style:style">
  2691. <xsl:if test="@style:name=$text-style-name and not($text-style-name='Standard')">
  2692. <xsl:element name="字:格式修订">
  2693. <xsl:attribute name="uof:locID">t0053</xsl:attribute>
  2694. <xsl:attribute name="uof:attrList">修订信息引用</xsl:attribute>
  2695. <xsl:attribute name="字:修订信息引用"><xsl:value-of select="@style:name"/></xsl:attribute>
  2696. <xsl:element name="字:段落属性">
  2697. <xsl:attribute name="uof:locID">t0052</xsl:attribute>
  2698. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  2699. <xsl:attribute name="字:式样引用"><xsl:value-of select="@style:name"/></xsl:attribute>
  2700. </xsl:element>
  2701. </xsl:element>
  2702. </xsl:if>
  2703. </xsl:for-each>
  2704. <xsl:if test="@style:name='Heading'">
  2705. <xsl:element name="字:大纲级别">
  2706. <xsl:attribute name="uof:locID">t0054</xsl:attribute>
  2707. <xsl:value-of select="substring-after(@style:name,'Heading')"/>
  2708. </xsl:element>
  2709. </xsl:if>
  2710. <xsl:if test=".//@fo:text-align or .//@style:vertical-align">
  2711. <xsl:element name="字:对齐">
  2712. <xsl:attribute name="uof:locID">t0055</xsl:attribute>
  2713. <xsl:attribute name="uof:attrList">水平对齐 文字对齐</xsl:attribute>
  2714. <xsl:attribute name="字:水平对齐"><xsl:choose><xsl:when test=".//@fo:text-align='end'">right</xsl:when><xsl:when test=".//@fo:text-align='center'">center</xsl:when><xsl:when test=".//@fo:text-align='justify' and not(.//@fo:text-align-last='justify')">justified</xsl:when><xsl:when test=".//@fo:text-align='justify' and .//@fo:text-align-last='justify'">distributed</xsl:when><xsl:otherwise>left</xsl:otherwise></xsl:choose></xsl:attribute>
  2715. <xsl:attribute name="字:文字对齐"><xsl:choose><xsl:when test=".//@style:vertical-align='baseline'">base</xsl:when><xsl:when test=".//@style:vertical-align='top'">top</xsl:when><xsl:when test=".//@style:vertical-align='middle'">center</xsl:when><xsl:when test=".//@style:vertical-align='bottom'">bottom</xsl:when><xsl:otherwise>auto</xsl:otherwise></xsl:choose></xsl:attribute>
  2716. </xsl:element>
  2717. </xsl:if>
  2718. <xsl:if test=".//@fo:margin-left or .//@fo:margin-right or .//@fo:text-indent">
  2719. <xsl:element name="字:缩进">
  2720. <xsl:attribute name="uof:locID">t0056</xsl:attribute>
  2721. <xsl:call-template name="字:缩进类型"/>
  2722. </xsl:element>
  2723. </xsl:if>
  2724. <xsl:element name="字:行距">
  2725. <xsl:attribute name="uof:locID">t0057</xsl:attribute>
  2726. <xsl:attribute name="uof:attrList">类型 值</xsl:attribute>
  2727. <xsl:choose>
  2728. <xsl:when test="contains(.//@fo:line-height,$uofUnit)">
  2729. <xsl:attribute name="字:类型">fixed</xsl:attribute>
  2730. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(.//@fo:line-height,$uofUnit)"/></xsl:attribute>
  2731. </xsl:when>
  2732. <xsl:when test="contains(.//@fo:line-height,'%')">
  2733. <xsl:attribute name="字:类型">multi-lines</xsl:attribute>
  2734. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(.//@fo:line-height,'%') div 100"/></xsl:attribute>
  2735. </xsl:when>
  2736. <xsl:when test=".//@style:line-height-at-least">
  2737. <xsl:attribute name="字:类型">at-least</xsl:attribute>
  2738. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(.//@style:line-height-at-least,$uofUnit)"/></xsl:attribute>
  2739. </xsl:when>
  2740. <xsl:when test=".//@style:line-spacing">
  2741. <xsl:attribute name="字:类型">line-space</xsl:attribute>
  2742. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(.//@style:line-spacing,$uofUnit)"/></xsl:attribute>
  2743. </xsl:when>
  2744. <xsl:otherwise>
  2745. <xsl:attribute name="字:类型">multi-lines</xsl:attribute>
  2746. <xsl:attribute name="字:值">1.0</xsl:attribute>
  2747. </xsl:otherwise>
  2748. </xsl:choose>
  2749. </xsl:element>
  2750. <xsl:if test=".//@fo:orphans">
  2751. <xsl:element name="字:孤行控制">
  2752. <xsl:attribute name="uof:locID">t0060</xsl:attribute>
  2753. <xsl:value-of select=".//@fo:orphans"/>
  2754. </xsl:element>
  2755. </xsl:if>
  2756. <xsl:if test=".//@fo:widows">
  2757. <xsl:element name="字:寡行控制">
  2758. <xsl:attribute name="uof:locID">t0061</xsl:attribute>
  2759. <xsl:value-of select=".//@fo:widows"/>
  2760. </xsl:element>
  2761. </xsl:if>
  2762. <xsl:if test=".//@style:break-inside">
  2763. <xsl:element name="字:段中不分页">
  2764. <xsl:attribute name="uof:locID">t0062</xsl:attribute>
  2765. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2766. <xsl:attribute name="字:值">true</xsl:attribute>
  2767. </xsl:element>
  2768. </xsl:if>
  2769. <xsl:if test=".//@fo:keep-with-next">
  2770. <xsl:element name="字:与下段同页">
  2771. <xsl:attribute name="uof:locID">t0063</xsl:attribute>
  2772. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2773. <xsl:attribute name="字:值">true</xsl:attribute>
  2774. </xsl:element>
  2775. </xsl:if>
  2776. <xsl:if test=".//@fo:break-before">
  2777. <xsl:element name="字:段前分页">
  2778. <xsl:attribute name="uof:locID">t0064</xsl:attribute>
  2779. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2780. <xsl:attribute name="字:值">true</xsl:attribute>
  2781. </xsl:element>
  2782. </xsl:if>
  2783. <xsl:if test=".//@style:snap-to-layout-grid">
  2784. <xsl:element name="字:对齐网格">
  2785. <xsl:attribute name="uof:locID">t0069</xsl:attribute>
  2786. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2787. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@style:snap-to-layout-grid='true'">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  2788. </xsl:element>
  2789. </xsl:if>
  2790. <xsl:if test=".//style:drop-cap">
  2791. <xsl:element name="字:首字下沉">
  2792. <xsl:attribute name="uof:locID">t0070</xsl:attribute>
  2793. <xsl:attribute name="uof:attrList">类型 字体引用 字符数 行数 间距</xsl:attribute>
  2794. <xsl:attribute name="字:类型">dropped</xsl:attribute>
  2795. <xsl:if test=".//style:drop-cap/@style:style-name">
  2796. <xsl:attribute name="字:字体引用"><xsl:value-of select=".//style:drop-cap/@style:style-name"/></xsl:attribute>
  2797. </xsl:if>
  2798. <xsl:if test=".//style:drop-cap/@style:distance">
  2799. <xsl:attribute name="字:间距"><xsl:value-of select="substring-before(.//style:drop-cap/@style:distance,$uofUnit)"/></xsl:attribute>
  2800. </xsl:if>
  2801. <xsl:if test=".//style:drop-cap/@style:length">
  2802. <xsl:attribute name="字:字符数"><xsl:value-of select=".//style:drop-cap/@style:length"/></xsl:attribute>
  2803. </xsl:if>
  2804. <xsl:if test=".//style:drop-cap/@style:lines">
  2805. <xsl:attribute name="字:行数"><xsl:value-of select=".//style:drop-cap/@style:lines"/></xsl:attribute>
  2806. </xsl:if>
  2807. </xsl:element>
  2808. </xsl:if>
  2809. <xsl:if test=".//@fo:hyphenate">
  2810. <xsl:element name="字:取消断字">
  2811. <xsl:attribute name="uof:locID">t0071</xsl:attribute>
  2812. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2813. <xsl:attribute name="字:值"><xsl:value-of select=".//@fo:hyphenate"/></xsl:attribute>
  2814. </xsl:element>
  2815. </xsl:if>
  2816. <xsl:if test=".//@text:number-lines">
  2817. <xsl:element name="字:取消行号">
  2818. <xsl:attribute name="字:值"><xsl:value-of select=".//@text:number-lines"/></xsl:attribute>
  2819. <xsl:attribute name="uof:locID">t0072</xsl:attribute>
  2820. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2821. </xsl:element>
  2822. </xsl:if>
  2823. <xsl:element name="字:允许单词断字">
  2824. <xsl:attribute name="字:值">true</xsl:attribute>
  2825. <xsl:attribute name="uof:locID">t0073</xsl:attribute>
  2826. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2827. </xsl:element>
  2828. <xsl:if test=".//@style:punctuation-wrap">
  2829. <xsl:element name="字:行首尾标点控制">
  2830. <xsl:attribute name="uof:locID">t0074</xsl:attribute>
  2831. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2832. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@style:punctuation-wrap='hanging'">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  2833. </xsl:element>
  2834. </xsl:if>
  2835. <xsl:element name="字:是否行首标点压缩">
  2836. <xsl:attribute name="uof:locID">t0075</xsl:attribute>
  2837. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2838. <xsl:attribute name="字:值">false</xsl:attribute>
  2839. </xsl:element>
  2840. <xsl:if test=".//@style:line-break ">
  2841. <xsl:element name="字:中文习惯首尾字符">
  2842. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@style:line-break='strict'">true</xsl:when><xsl:when test=".//@style:line-break='normal'">false</xsl:when></xsl:choose></xsl:attribute>
  2843. <xsl:attribute name="uof:locID">t0076</xsl:attribute>
  2844. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2845. </xsl:element>
  2846. </xsl:if>
  2847. <xsl:if test=".//@style:text-autospace">
  2848. <xsl:element name="字:自动调整中英文字符间距">
  2849. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@style:text-autospace='ideograph-alpha'">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  2850. <xsl:attribute name="uof:locID">t0077</xsl:attribute>
  2851. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2852. </xsl:element>
  2853. </xsl:if>
  2854. <xsl:if test=".//@style:text-autospace">
  2855. <xsl:element name="字:自动调整中文与数字间距">
  2856. <xsl:attribute name="字:值"><xsl:choose><xsl:when test=".//@style:text-autospace='ideograph-alpha'">true </xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:attribute>
  2857. <xsl:attribute name="uof:locID">t0078</xsl:attribute>
  2858. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2859. </xsl:element>
  2860. </xsl:if>
  2861. <xsl:element name="字:有网格自动调整右缩进">
  2862. <xsl:attribute name="字:值">false</xsl:attribute>
  2863. <xsl:attribute name="uof:locID">t0195</xsl:attribute>
  2864. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  2865. </xsl:element>
  2866. <xsl:if test=".//@fo:border or .//@fo:border-top or .//@fo:border-bottom or .//@fo:border-left or .//@fo:border-right or .//@style:shadow[.!='none']">
  2867. <xsl:element name="字:边框">
  2868. <xsl:attribute name="uof:locID">t0065</xsl:attribute>
  2869. </xsl:element>
  2870. </xsl:if>
  2871. <xsl:if test=".//@fo:background-color">
  2872. <xsl:element name="字:填充">
  2873. <xsl:attribute name="uof:locID">t0066</xsl:attribute>
  2874. </xsl:element>
  2875. </xsl:if>
  2876. <xsl:if test=".//@fo:margin-top or .//@fo:margin-bottom">
  2877. <字:段间距 uof:locID="t0058">
  2878. <xsl:if test=".//@fo:margin-top">
  2879. <字:段前距 uof:locID="t0196">
  2880. <字:绝对值 uof:locID="t0199" uof:attrList="值">
  2881. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(.//@fo:margin-top,$uofUnit)"/></xsl:attribute>
  2882. </字:绝对值>
  2883. </字:段前距>
  2884. </xsl:if>
  2885. <xsl:if test=".//@fo:margin-bottom">
  2886. <字:段后距 uof:locID="t0196">
  2887. <字:绝对值 uof:locID="t0202" uof:attrList="值">
  2888. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(.//@fo:margin-bottom,$uofUnit)"/></xsl:attribute>
  2889. </字:绝对值>
  2890. </字:段后距>
  2891. </xsl:if>
  2892. </字:段间距>
  2893. </xsl:if>
  2894. <xsl:if test=".//style:tab-stops">
  2895. <xsl:element name="字:制表位设置">
  2896. <xsl:attribute name="uof:locID">t0067</xsl:attribute>
  2897. <xsl:for-each select=".//style:tab-stops/style:tab-stop">
  2898. <xsl:element name="字:制表位">
  2899. <xsl:attribute name="uof:locID">t0068</xsl:attribute>
  2900. <xsl:attribute name="uof:attrList">位置 类型 前导符</xsl:attribute>
  2901. <xsl:attribute name="字:位置"><xsl:value-of select="@style:position"/></xsl:attribute>
  2902. <xsl:variable name="aa">
  2903. <xsl:value-of select="@style:type"/>
  2904. </xsl:variable>
  2905. <xsl:variable name="zbflx">
  2906. <xsl:choose>
  2907. <xsl:when test="$aa='right'">right</xsl:when>
  2908. <xsl:when test="$aa='center'">center</xsl:when>
  2909. <xsl:when test="$aa='char'and @style:char!=''">decimal</xsl:when>
  2910. <xsl:otherwise>left</xsl:otherwise>
  2911. </xsl:choose>
  2912. </xsl:variable>
  2913. <xsl:attribute name="字:类型"><xsl:value-of select="$zbflx"/></xsl:attribute>
  2914. <xsl:if test="$zbflx='decimal'">
  2915. <xsl:attribute name="字:制表位字符"><xsl:value-of select="@style:char"/></xsl:attribute>
  2916. </xsl:if>
  2917. <xsl:if test="@style:leader-char">
  2918. <xsl:attribute name="字:前导符"><xsl:value-of select="@style:leader-char"/></xsl:attribute>
  2919. </xsl:if>
  2920. </xsl:element>
  2921. </xsl:for-each>
  2922. </xsl:element>
  2923. </xsl:if>
  2924. </xsl:template>
  2925. <xsl:template name="textspan">
  2926. <字:句 uof:locID="t0085">
  2927. <xsl:choose>
  2928. <xsl:when test="./text:footnote">
  2929. <xsl:call-template name="jiaozhu"/>
  2930. </xsl:when>
  2931. <xsl:when test="./text:endnote">
  2932. <xsl:call-template name="weizhu"/>
  2933. </xsl:when>
  2934. <xsl:otherwise>
  2935. <xsl:element name="字:句属性">
  2936. <xsl:attribute name="uof:locID">t0086</xsl:attribute>
  2937. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  2938. <xsl:variable name="textstyle">
  2939. <xsl:value-of select="@text:style-name"/>
  2940. </xsl:variable>
  2941. <xsl:attribute name="字:式样引用"><xsl:value-of select="@text:style-name"/></xsl:attribute>
  2942. <xsl:for-each select="/office:document/office:automatic-styles//style:style[@style:family='text']">
  2943. <xsl:if test="@style:name=$textstyle and not(@style:parent-style-name='Standard')">
  2944. <xsl:if test="@style:parent-style-name=/office:document/office:styles/style:style/@style:name">
  2945. <xsl:call-template name="SentenceXD">
  2946. <xsl:with-param name="Sentencestyle" select="@style:parent-style-name"/>
  2947. </xsl:call-template>
  2948. </xsl:if>
  2949. </xsl:if>
  2950. </xsl:for-each>
  2951. <xsl:for-each select="/office:document/office:styles//style:style[@style:family='text']">
  2952. <xsl:if test="@style:name=$textstyle">
  2953. <xsl:call-template name="SentenceXD">
  2954. <xsl:with-param name="Sentencestyle" select="@style:name"/>
  2955. </xsl:call-template>
  2956. </xsl:if>
  2957. </xsl:for-each>
  2958. </xsl:element>
  2959. <字:文本串 uof:locID="t0109" uof:attrList="udsPath">
  2960. <xsl:value-of select="string(.)"/>
  2961. </字:文本串>
  2962. </xsl:otherwise>
  2963. </xsl:choose>
  2964. </字:句>
  2965. </xsl:template>
  2966. <xsl:template name="SentenceXD">
  2967. <xsl:param name="Sentencestyle"/>
  2968. <xsl:element name="字:格式修订">
  2969. <xsl:attribute name="uof:locID">t0087</xsl:attribute>
  2970. <xsl:attribute name="uof:attrList">修订信息引用</xsl:attribute>
  2971. <xsl:attribute name="字:修订信息引用"><xsl:value-of select="$Sentencestyle"/></xsl:attribute>
  2972. <xsl:element name="字:句属性">
  2973. <xsl:attribute name="uof:locID">t0086</xsl:attribute>
  2974. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  2975. <xsl:attribute name="字:式样引用"><xsl:value-of select="$Sentencestyle"/></xsl:attribute>
  2976. </xsl:element>
  2977. </xsl:element>
  2978. </xsl:template>
  2979. <xsl:template name="add-space">
  2980. <xsl:param name="number"/>
  2981. <xsl:if test="$number &gt; 1">
  2982. <xsl:call-template name="add-space">
  2983. <xsl:with-param name="number" select="$number - 1"/>
  2984. </xsl:call-template>
  2985. <xsl:text> </xsl:text>
  2986. </xsl:if>
  2987. </xsl:template>
  2988. <xsl:template match="office:styles | office:automatic-styles" mode="style">
  2989. <xsl:for-each select="style:style[@style:family= 'paragraph' or @style:family= 'text']">
  2990. <xsl:choose>
  2991. <xsl:when test="@style:family = 'text'">
  2992. <xsl:call-template name="句式样"/>
  2993. </xsl:when>
  2994. <xsl:when test="@style:family = 'paragraph'">
  2995. <xsl:call-template name="段落式样"/>
  2996. </xsl:when>
  2997. </xsl:choose>
  2998. </xsl:for-each>
  2999. </xsl:template>
  3000. <xsl:template name="段落式样">
  3001. <xsl:element name="uof:段落式样">
  3002. <xsl:attribute name="uof:locID">u0044</xsl:attribute>
  3003. <xsl:attribute name="uof:attrList">标识符 名称 类型 别名 基式样引用</xsl:attribute>
  3004. <xsl:variable name="count"><xsl:value-of select="count(preceding::style:style)"/></xsl:variable>
  3005. <xsl:attribute name="字:标识符"><xsl:value-of select="concat(@style:name,$count)"/></xsl:attribute>
  3006. <xsl:attribute name="字:类型">default</xsl:attribute>
  3007. <xsl:attribute name="字:基式样引用"><xsl:variable name="stylename" select="@style:name"/><xsl:variable name="frame-parent"><xsl:choose><xsl:when test="/office:document/office:master-styles/style:master-page/draw:frame[draw:text-box//text:p/@text:style-name = $stylename]"><xsl:for-each select="/office:document/office:master-styles/style:master-page/draw:frame[draw:text-box//text:p/@text:style-name = $stylename][1]"><xsl:variable name="frame-style" select="@presentation:style-name"/><xsl:value-of select="/office:document/*/style:style[@style:name=$frame-style]/@style:parent-style-name"/></xsl:for-each></xsl:when><xsl:otherwise>not-master</xsl:otherwise></xsl:choose></xsl:variable><xsl:choose><xsl:when test="@style:parent-style-name"><xsl:value-of select="@style:parent-style-name"/></xsl:when><xsl:when test="not($frame-parent='not-master')"><xsl:value-of select="$frame-parent"/></xsl:when></xsl:choose></xsl:attribute>
  3008. <xsl:attribute name="字:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  3009. <xsl:apply-templates select="style:paragraph-properties"/>
  3010. <xsl:for-each select="style:text-properties">
  3011. <xsl:element name="字:句属性">
  3012. <xsl:attribute name="uof:locID">t0086</xsl:attribute>
  3013. <xsl:attribute name="uof:attrList">式样引用</xsl:attribute>
  3014. <xsl:call-template name="字:句属性"/>
  3015. </xsl:element>
  3016. </xsl:for-each>
  3017. </xsl:element>
  3018. </xsl:template>
  3019. <xsl:template match="style:paragraph-properties">
  3020. <xsl:element name="字:缩进">
  3021. <xsl:attribute name="uof:locID">t0056</xsl:attribute>
  3022. <xsl:call-template name="字:缩进类型"/>
  3023. </xsl:element>
  3024. <xsl:if test="@fo:text-align | @fotext-align-last">
  3025. <xsl:element name="字:对齐">
  3026. <xsl:attribute name="uof:locID">t0055</xsl:attribute>
  3027. <xsl:if test="@fo:text-align">
  3028. <xsl:attribute name="字:水平对齐"><xsl:choose><xsl:when test=".//@fo:text-align='end'">right</xsl:when><xsl:when test=".//@fo:text-align='center'">center</xsl:when><xsl:when test=".//@fo:text-align='justify' and not(.//@fo:text-align-last='justify')">justified</xsl:when><xsl:when test=".//@fo:text-align='justify' and .//@fo:text-align-last='justify'">distributed</xsl:when><xsl:otherwise>left</xsl:otherwise></xsl:choose></xsl:attribute>
  3029. </xsl:if>
  3030. <xsl:if test="@style:vertical-align">
  3031. <xsl:attribute name="字:文字对齐"><xsl:choose><xsl:when test=".//@style:vertical-align='baseline'">base</xsl:when><xsl:when test=".//@style:vertical-align='top'">top</xsl:when><xsl:when test=".//@style:vertical-align='middle'">center</xsl:when><xsl:when test=".//@style:vertical-align='bottom'">bottom</xsl:when><xsl:otherwise>auto</xsl:otherwise></xsl:choose></xsl:attribute>
  3032. </xsl:if>
  3033. <xsl:attribute name="uof:attrList">水平对齐 文字对齐</xsl:attribute>
  3034. </xsl:element>
  3035. </xsl:if>
  3036. </xsl:template>
  3037. <xsl:template name="句式样">
  3038. <xsl:element name="uof:句式样">
  3039. <xsl:attribute name="uof:locID">u0043</xsl:attribute>
  3040. <xsl:attribute name="uof:attrList">标识符 名称 类型 别名 基式样引用</xsl:attribute>
  3041. <xsl:attribute name="字:标识符"><xsl:value-of select="@style:name"/></xsl:attribute>
  3042. <xsl:attribute name="字:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  3043. <xsl:attribute name="字:类型">auto</xsl:attribute>
  3044. <xsl:call-template name="字:句属性"/>
  3045. </xsl:element>
  3046. </xsl:template>
  3047. <xsl:template match="style:text-properties">
  3048. <xsl:element name="字:字体">
  3049. <xsl:attribute name="uof:locID">t0088</xsl:attribute>
  3050. <xsl:attribute name="uof:attrList">西文字体引用 中文字体引用 特殊字体引用 西文绘制 字号 相对字号 颜色</xsl:attribute>
  3051. <xsl:if test=".//@fo:font-size or .//@style:font-size-asian or .//@style:font-size-complex">
  3052. <xsl:choose>
  3053. <xsl:when test="contains(.//@fo:font-size,'%') or contains(.//@style:font-size-asian,'%')">
  3054. <xsl:attribute name="字:相对字号"><xsl:choose><xsl:when test=".//@fo:font-size"><xsl:value-of select="substring-before(.//@fo:font-size,'%')"/></xsl:when><xsl:when test=".//@style:font-size-asian"><xsl:value-of select="substring-before(.//@style:font-size-asian,'%')"/></xsl:when></xsl:choose></xsl:attribute>
  3055. </xsl:when>
  3056. <xsl:otherwise>
  3057. <xsl:attribute name="字:字号"><xsl:choose><xsl:when test=".//@fo:font-size"><xsl:value-of select="substring-before(.//@fo:font-size,'pt')"/></xsl:when><xsl:when test=".//@style:font-size-asian"><xsl:value-of select="substring-before(.//@style:font-size-asian,'pt')"/></xsl:when><xsl:when test=".//@style:font-size-complex"><xsl:value-of select="substring-before(.//@style:font-size-complex,'pt')"/></xsl:when></xsl:choose></xsl:attribute>
  3058. </xsl:otherwise>
  3059. </xsl:choose>
  3060. </xsl:if>
  3061. <xsl:if test=".//@style:font-name">
  3062. <xsl:attribute name="字:西文字体引用"><xsl:value-of select=".//@style:font-name"/></xsl:attribute>
  3063. </xsl:if>
  3064. <xsl:if test=".//@style:font-name-asian">
  3065. <xsl:attribute name="字:中文字体引用"><xsl:value-of select=".//@style:font-name-asian"/></xsl:attribute>
  3066. </xsl:if>
  3067. <xsl:if test=".//@fo:color">
  3068. <xsl:attribute name="字:颜色"><xsl:value-of select=".//@fo:color"/></xsl:attribute>
  3069. </xsl:if>
  3070. </xsl:element>
  3071. <xsl:if test="(@fo:font-weight='bold') or (@fo:font-weight-asian='bold') or (@style:font-weight-asian='bold') or (@style:font-weight-complex='bold')">
  3072. <xsl:element name="字:粗体">
  3073. <xsl:attribute name="字:值">1</xsl:attribute>
  3074. <xsl:attribute name="uof:locID">t0089</xsl:attribute>
  3075. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  3076. </xsl:element>
  3077. </xsl:if>
  3078. <xsl:if test="(@style:font-style-asian='italic') or (@style:font-style-complex='italic') or (@fo:font-style-asian='italic') or (@fo:font-style='italic')">
  3079. <xsl:element name="字:斜体">
  3080. <xsl:attribute name="字:值">1</xsl:attribute>
  3081. <xsl:attribute name="uof:locID">t0090</xsl:attribute>
  3082. <xsl:attribute name="uof:attrList">值</xsl:attribute>
  3083. </xsl:element>
  3084. </xsl:if>
  3085. </xsl:template>
  3086. <xsl:template match="style:page-layout">
  3087. <xsl:element name="演:页面设置">
  3088. <xsl:attribute name="uof:locID">p0002</xsl:attribute>
  3089. <xsl:attribute name="uof:attrList">标识符 名称</xsl:attribute>
  3090. <xsl:attribute name="演:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  3091. <xsl:attribute name="演:标识符"><xsl:value-of select="@style:name"/></xsl:attribute>
  3092. <xsl:attribute name="演:名称">页面设置</xsl:attribute>
  3093. <xsl:element name="演:纸张">
  3094. <xsl:attribute name="uof:locID">p0003</xsl:attribute>
  3095. <xsl:attribute name="uof:attrList">宽度 高度 纸型</xsl:attribute>
  3096. <xsl:attribute name="uof:宽度"><xsl:value-of select="substring-before(style:page-layout-properties/@fo:page-width,$uofUnit)"/></xsl:attribute>
  3097. <xsl:attribute name="uof:高度"><xsl:value-of select="substring-before(style:page-layout-properties/@fo:page-height,$uofUnit)"/></xsl:attribute>
  3098. <xsl:attribute name="uof:纸型"><xsl:variable name="height"><xsl:value-of select="style:page-layout-properties/@fo:page-height"/></xsl:variable><xsl:variable name="width"><xsl:value-of select="style:page-layout-properties/@fo:page-width"/></xsl:variable><xsl:choose><xsl:when test="$height='29.7cm' and $width='42cm'">A3</xsl:when><xsl:when test="$height='21cm' and $width='29.7cm'">A4</xsl:when><xsl:when test="$height='14.8cm' and $width='21cm'">A5</xsl:when><xsl:when test="$height='25cm' and $width='35.3cm'">B4</xsl:when><xsl:when test="$height='17.6cm' and $width='25cm'">B5</xsl:when><xsl:when test="$height='12.5cm' and $width='17.6cm'">B6</xsl:when><xsl:otherwise>使用者</xsl:otherwise></xsl:choose></xsl:attribute>
  3099. </xsl:element>
  3100. <xsl:element name="演:页边距">
  3101. <xsl:attribute name="uof:locID">p0004</xsl:attribute>
  3102. <xsl:attribute name="uof:attrList">左 上 右 下</xsl:attribute>
  3103. <xsl:attribute name="uof:左"><xsl:value-of select="substring-before(style:page-layout-properties/@fo:margin-left,$uofUnit)"/></xsl:attribute>
  3104. <xsl:attribute name="uof:上"><xsl:value-of select="substring-before(style:page-layout-properties/@fo:margin-top,$uofUnit)"/></xsl:attribute>
  3105. <xsl:attribute name="uof:右"><xsl:value-of select="substring-before(style:page-layout-properties/@fo:margin-right,$uofUnit)"/></xsl:attribute>
  3106. <xsl:attribute name="uof:下"><xsl:value-of select="substring-before(style:page-layout-properties/@fo:margin-bottom,$uofUnit)"/></xsl:attribute>
  3107. </xsl:element>
  3108. <xsl:variable name="PageNumberFormat">
  3109. <xsl:value-of select="/office:document/office:settings/config:config-item-set/config:config-item[@config:name='PageNumberFormat']"/>
  3110. </xsl:variable>
  3111. <xsl:if test="not($PageNumberFormat='5')">
  3112. <xsl:element name="演:页码格式">
  3113. <xsl:attribute name="uof:locID">p0005</xsl:attribute>
  3114. <xsl:choose>
  3115. <xsl:when test="$PageNumberFormat='0'">upper-letter</xsl:when>
  3116. <xsl:when test="$PageNumberFormat='1'">lower-letter</xsl:when>
  3117. <xsl:when test="$PageNumberFormat='2'">upper-roman</xsl:when>
  3118. <xsl:when test="$PageNumberFormat='3'">lower-letter</xsl:when>
  3119. <xsl:when test="$PageNumberFormat='4'">decimal</xsl:when>
  3120. </xsl:choose>
  3121. </xsl:element>
  3122. </xsl:if>
  3123. <xsl:element name="演:纸张方向">
  3124. <xsl:attribute name="uof:locID">p0006</xsl:attribute>
  3125. <xsl:choose>
  3126. <xsl:when test="style:page-layout-properties/@style:print-orientation">
  3127. <xsl:value-of select="style:page-layout-properties/@style:print-orientation"/>
  3128. </xsl:when>
  3129. <xsl:otherwise>portrait</xsl:otherwise>
  3130. </xsl:choose>
  3131. </xsl:element>
  3132. </xsl:element>
  3133. </xsl:template>
  3134. <xsl:template name="obtain_anim_type">
  3135. <xsl:param name="flytype"/>
  3136. <xsl:variable name="flytypestr" select="substring-after($flytype,'from-')"/>
  3137. <xsl:choose>
  3138. <xsl:when test="contains($flytypestr,'-')">
  3139. <xsl:value-of select="concat(substring-before($flytypestr,'-'),substring-after($flytypestr,'-'))"/>
  3140. </xsl:when>
  3141. <xsl:otherwise>
  3142. <xsl:value-of select="$flytypestr"/>
  3143. </xsl:otherwise>
  3144. </xsl:choose>
  3145. </xsl:template>
  3146. <xsl:template name="cm2pt">
  3147. <xsl:param name="cmval"/>
  3148. <xsl:value-of select="substring-before($cmval,$uofUnit)* $cm-to-other "/>
  3149. </xsl:template>
  3150. <xsl:template match="office:font-face-decls">
  3151. <uof:字体集 uof:locID="u0040">
  3152. <uof:默认字体 uof:ascii="Times New Roman" uof:fareast="宋体" uof:h-ansi="宋体" uof:cs="宋体"/>
  3153. <xsl:for-each select="style:font-face">
  3154. <xsl:element name="uof:字体声明">
  3155. <xsl:attribute name="uof:attrList">标识符 名称 字体族</xsl:attribute>
  3156. <xsl:attribute name="uof:locID">u0041</xsl:attribute>
  3157. <xsl:attribute name="uof:名称"><xsl:value-of select="@style:name"/></xsl:attribute>
  3158. <xsl:attribute name="uof:字体族"><xsl:value-of select="@svg:font-family"/></xsl:attribute>
  3159. <xsl:if test="@style:font-charset= '02'">
  3160. <xsl:attribute name="uof:字符集">x-symbol</xsl:attribute>
  3161. </xsl:if>
  3162. <xsl:if test="@style:font-family-generic">
  3163. <xsl:choose>
  3164. <xsl:when test="@style:font-family-generic = 'swiss'">
  3165. <xsl:attribute name="uof:字体族">Swiss</xsl:attribute>
  3166. </xsl:when>
  3167. <xsl:when test="@style:font-family-generic ='modern'">
  3168. <xsl:attribute name="uof:字符集">Modern</xsl:attribute>
  3169. </xsl:when>
  3170. <xsl:when test="@style:font-family-generic='roman'">
  3171. <xsl:attribute name="uof:字符集">Roman</xsl:attribute>
  3172. </xsl:when>
  3173. <xsl:when test="@style:font-family-generic ='script'">
  3174. <xsl:attribute name="uof:字符集">Script</xsl:attribute>
  3175. </xsl:when>
  3176. <xsl:when test="@style:font-family-generic ='decorative'">
  3177. <xsl:attribute name="uof:字符集">Decorative</xsl:attribute>
  3178. </xsl:when>
  3179. <xsl:when test="@style:font-family-generic ='system'">
  3180. <xsl:attribute name="uof:字符集">System</xsl:attribute>
  3181. </xsl:when>
  3182. <xsl:otherwise>
  3183. <xsl:attribute name="uof:字符集">System</xsl:attribute>
  3184. </xsl:otherwise>
  3185. </xsl:choose>
  3186. </xsl:if>
  3187. </xsl:element>
  3188. </xsl:for-each>
  3189. <xsl:apply-templates select="style:font-decl"/>
  3190. </uof:字体集>
  3191. </xsl:template>
  3192. <xsl:template match="office:meta">
  3193. <uof:元数据 uof:locID="u0001">
  3194. <uof:标题 uof:locID="u0002">
  3195. <xsl:value-of select="dc:title"/>
  3196. </uof:标题>
  3197. <uof:创建应用程序 uof:locID="u0011">
  3198. <xsl:value-of select="meta:generator"/>
  3199. </uof:创建应用程序>
  3200. <uof:摘要 uof:locID="u0007">
  3201. <xsl:value-of select="dc:description"/>
  3202. </uof:摘要>
  3203. <uof:主题 uof:locID="u0003">
  3204. <xsl:value-of select="dc:subject"/>
  3205. </uof:主题>
  3206. <uof:创建者 uof:locID="u0004"/>
  3207. <uof:作者 uof:locID="u0005">
  3208. <xsl:value-of select="meta:initial-creator"/>
  3209. </uof:作者>
  3210. <uof:创建日期 uof:locID="u0008">
  3211. <xsl:value-of select="meta:creation-date"/>
  3212. </uof:创建日期>
  3213. <uof:最后作者 uof:locID="u0006">
  3214. <xsl:value-of select="dc:creator"/>
  3215. </uof:最后作者>
  3216. <uof:关键字集 uof:locID="u0014">
  3217. <xsl:for-each select=".">
  3218. <uof:关键字 uof:locID="u0015">
  3219. <xsl:value-of select="meta:keywords/@meta:keyword"/>
  3220. </uof:关键字>
  3221. </xsl:for-each>
  3222. </uof:关键字集>
  3223. <uof:编辑次数 uof:locID="u0009">
  3224. <xsl:value-of select="meta:editing-cycles"/>
  3225. </uof:编辑次数>
  3226. <xsl:if test="meta:editing-duration">
  3227. <uof:编辑时间 uof:locID="u0010">
  3228. <xsl:value-of select="meta:editing-duration"/>
  3229. </uof:编辑时间>
  3230. </xsl:if>
  3231. <xsl:if test="meta:template/@xlink:href">
  3232. <uof:文档模板 uof:locID="u0013">
  3233. <xsl:value-of select="meta:template/@xlink:href"/>
  3234. </uof:文档模板>
  3235. </xsl:if>
  3236. <xsl:if test="meta:user-defined/@meta:name">
  3237. <uof:用户自定义元数据集 uof:locID="u0016">
  3238. <xsl:for-each select="meta:user-defined">
  3239. <uof:用户自定义元数据 uof:locID="u0017" uof:attrList="名称 类型">
  3240. <xsl:attribute name="uof:名称"><xsl:value-of select="@meta:name"/></xsl:attribute>
  3241. <xsl:attribute name="uof:类型"><xsl:value-of select="'string'"/></xsl:attribute>
  3242. </uof:用户自定义元数据>
  3243. </xsl:for-each>
  3244. </uof:用户自定义元数据集>
  3245. </xsl:if>
  3246. <xsl:if test="meta:document-statistic/@meta:page-count">
  3247. <uof:页数 uof:locID="u0020">
  3248. <xsl:value-of select="meta:document-statistic/@meta:page-count"/>
  3249. </uof:页数>
  3250. </xsl:if>
  3251. <xsl:if test="meta:document-statistic/@meta:paragraph-count">
  3252. <uof:段落数 uof:locID="u0025">
  3253. <xsl:value-of select="meta:document-statistic/@meta:paragraph-count"/>
  3254. </uof:段落数>
  3255. </xsl:if>
  3256. <xsl:if test="meta:document-statistic/@meta:object-count">
  3257. <uof:对象数 uof:locID="u0026">
  3258. <xsl:value-of select="meta:document-statistic/@meta:object-count"/>
  3259. </uof:对象数>
  3260. </xsl:if>
  3261. <xsl:if test="meta:document-statistic/@meta:character-count">
  3262. <uof:字数 uof:locID="u0021">
  3263. <xsl:value-of select="meta:document-statistic/@meta:character-count"/>
  3264. </uof:字数>
  3265. </xsl:if>
  3266. <xsl:if test="meta:document-statistic/@meta:word-count">
  3267. <uof:中文字符数 uof:locID="u0023">
  3268. <xsl:value-of select="meta:document-statistic/@meta:word-count"/>
  3269. </uof:中文字符数>
  3270. </xsl:if>
  3271. </uof:元数据>
  3272. </xsl:template>
  3273. <xsl:template name="填充">
  3274. <xsl:param name="picname"/>
  3275. <xsl:param name="nodename"/>
  3276. <xsl:choose>
  3277. <xsl:when test="@draw:fill='gradient'">
  3278. <xsl:variable name="gradient-name">
  3279. <xsl:value-of select="@draw:fill-gradient-name"/>
  3280. </xsl:variable>
  3281. <xsl:for-each select="/descendant::draw:gradient[@draw:name=$gradient-name]">
  3282. <图:渐变 uof:locID="g0037" uof:attrList="起始色 终止色 种子类型 起始浓度 终止浓度 渐变方向 边界 种子X位置 种子Y位置 类型">
  3283. <xsl:attribute name="图:起始色"><xsl:value-of select="@draw:start-color"/></xsl:attribute>
  3284. <xsl:attribute name="图:终止色"><xsl:value-of select="@draw:end-color"/></xsl:attribute>
  3285. <xsl:attribute name="图:种子类型"><xsl:choose><xsl:when test="@draw:style='linear' or @draw:style='axial'">linear</xsl:when><xsl:when test="@draw:style='radial'">radar</xsl:when><xsl:when test="@draw:style='ellipsoid'">oval</xsl:when><xsl:when test="@draw:style='square'">square</xsl:when><xsl:when test="@draw:style='rectangular'">rectangle</xsl:when></xsl:choose></xsl:attribute>
  3286. <xsl:attribute name="图:起始浓度"><xsl:value-of select="substring-before(@draw:start-intensity,'%')"/></xsl:attribute>
  3287. <xsl:attribute name="图:终止浓度"><xsl:value-of select="substring-before(@draw:end-intensity,'%')"/></xsl:attribute>
  3288. <xsl:variable name="angle">
  3289. <xsl:value-of select="@draw:angle div 10"/>
  3290. </xsl:variable>
  3291. <xsl:attribute name="图:渐变方向"><xsl:choose><xsl:when test="0&lt;$angle and $angle&lt;25">0</xsl:when><xsl:when test="25&lt;$angle and $angle&lt;70">45</xsl:when><xsl:when test="70&lt;$angle and $angle&lt;115">90</xsl:when><xsl:when test="115&lt;$angle and $angle&lt;160">135</xsl:when><xsl:when test="160&lt;$angle and $angle&lt;205">180</xsl:when><xsl:when test="205&lt;$angle and $angle&lt;250">225</xsl:when><xsl:when test="250&lt;$angle and $angle&lt;295">270</xsl:when><xsl:when test="295&lt;$angle and $angle&lt;340">315</xsl:when><xsl:when test="340&lt;$angle and $angle&lt;360">360</xsl:when></xsl:choose></xsl:attribute>
  3292. <xsl:attribute name="图:边界"><xsl:value-of select="substring-before(@draw:border,'%')"/></xsl:attribute>
  3293. <xsl:if test="@draw:cx">
  3294. <xsl:attribute name="图:种子X位置"><xsl:value-of select="substring-before(@draw:cx,'%')"/></xsl:attribute>
  3295. </xsl:if>
  3296. <xsl:if test="@draw:cy">
  3297. <xsl:attribute name="图:种子Y位置"><xsl:value-of select="substring-before(@draw:cy,'%')"/></xsl:attribute>
  3298. </xsl:if>
  3299. <xsl:attribute name="图:类型">-2</xsl:attribute>
  3300. </图:渐变>
  3301. </xsl:for-each>
  3302. </xsl:when>
  3303. <xsl:when test="@draw:fill='bitmap'">
  3304. <图:图片 uof:locID="g0035" uof:attrList="位置 图形引用 类型 名称">
  3305. <xsl:attribute name="图:位置"><xsl:choose><xsl:when test="not(@style:repeat)">title</xsl:when><xsl:otherwise><xsl:choose><xsl:when test="@style:repeat = 'stretch'">stretch</xsl:when><xsl:when test="@style:repeat = 'repeat'">title</xsl:when><xsl:when test="@style:repeat = 'no-repeat'">center</xsl:when></xsl:choose></xsl:otherwise></xsl:choose></xsl:attribute>
  3306. <xsl:attribute name="图:图形引用"><xsl:value-of select="@draw:fill-image-name"/></xsl:attribute>
  3307. <xsl:attribute name="图:类型">png</xsl:attribute>
  3308. <xsl:attribute name="图:名称"><xsl:value-of select="concat($picname,'_b1')"/></xsl:attribute>
  3309. </图:图片>
  3310. </xsl:when>
  3311. <xsl:when test="@draw:fill='hatch'">
  3312. <图:图案 uof:locID="g0036" uof:attrList="类型 图形引用 前景色 背景色">
  3313. <xsl:attribute name="图:类型"><xsl:value-of select="/office:document/office:styles/draw:hatch/@draw:name"/></xsl:attribute>
  3314. <xsl:attribute name="图:图形引用"/>
  3315. <xsl:attribute name="图:前景色"><xsl:value-of select="/office:document/office:styles/draw:hatch/@draw:color"/></xsl:attribute>
  3316. <xsl:attribute name="图:背景色"><xsl:choose><xsl:when test="@draw:fill-color"><xsl:value-of select="@draw:fill-color"/></xsl:when><xsl:otherwise>#ffffff</xsl:otherwise></xsl:choose></xsl:attribute>
  3317. </图:图案>
  3318. </xsl:when>
  3319. <xsl:otherwise>
  3320. <xsl:choose>
  3321. <xsl:when test="$nodename='draw:frame'">
  3322. <xsl:if test="@draw:fill='solid'">
  3323. <图:颜色 uof:locID="g0034">
  3324. <xsl:value-of select="@draw:fill-color"/>
  3325. </图:颜色>
  3326. </xsl:if>
  3327. </xsl:when>
  3328. <xsl:otherwise>
  3329. <图:颜色 uof:locID="g0034">
  3330. <xsl:choose>
  3331. <xsl:when test="@draw:fill-color">
  3332. <xsl:value-of select="@draw:fill-color"/>
  3333. </xsl:when>
  3334. <xsl:otherwise>#99ccff</xsl:otherwise>
  3335. </xsl:choose>
  3336. </图:颜色>
  3337. </xsl:otherwise>
  3338. </xsl:choose>
  3339. </xsl:otherwise>
  3340. </xsl:choose>
  3341. </xsl:template>
  3342. <xsl:template name="字:缩进类型">
  3343. <xsl:if test="style:list-level-properties/@text:space-before">
  3344. <字:左 uof:locID="t0182">
  3345. <字:绝对 uof:locID="t0185" uof:attrList="值">
  3346. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(style:list-level-properties/@text:space-before,$uofUnit)"/></xsl:attribute>
  3347. </字:绝对>
  3348. </字:左>
  3349. </xsl:if>
  3350. <xsl:if test="style:list-level-properties/@text:min-label-width">
  3351. <字:右 uof:locID="t0183">
  3352. <字:绝对 uof:locID="t0187" uof:attrList="值">
  3353. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(style:list-level-properties/@text:min-label-width,$uofUnit)"/></xsl:attribute>
  3354. </字:绝对>
  3355. </字:右>
  3356. </xsl:if>
  3357. <xsl:if test="style:list-level-properties/@text:min-label-distance">
  3358. <字:首行 uof:locID="t0184">
  3359. <字:绝对 uof:locID="t0189" uof:attrList="值">
  3360. <xsl:attribute name="字:值"><xsl:value-of select="substring-before(style:list-level-properties/@text:min-label-distance,$uofUnit)"/></xsl:attribute>
  3361. </字:绝对>
  3362. </字:首行>
  3363. </xsl:if>
  3364. </xsl:template>
  3365. <xsl:template name="uof:线型类型">
  3366. <xsl:param name="lineType"/>
  3367. <xsl:choose>
  3368. <xsl:when test="$lineType='single-line'">single</xsl:when>
  3369. <xsl:when test="$lineType='double-line'">double</xsl:when>
  3370. <xsl:when test="$lineType='single'">single</xsl:when>
  3371. <xsl:when test="$lineType='double'">double</xsl:when>
  3372. <xsl:when test="$lineType='dash'">dash</xsl:when>
  3373. <xsl:when test="$lineType='long-dash'">dash-long</xsl:when>
  3374. <xsl:when test="$lineType='dot-dash'">dot-dash</xsl:when>
  3375. <xsl:when test="$lineType='dot-dot-dash'">dot-dot-dash</xsl:when>
  3376. <xsl:when test="$lineType='wave'">wave</xsl:when>
  3377. <xsl:when test="$lineType='bold-dotted'">dotted-heavy</xsl:when>
  3378. <xsl:when test="$lineType='bold-dash'">dashed-heavy</xsl:when>
  3379. <xsl:when test="$lineType='bold-long-dash'">dash-long-heavy</xsl:when>
  3380. <xsl:when test="$lineType='bold-dot-dash'">dash-dot-heavy</xsl:when>
  3381. <xsl:when test="$lineType='bold-dot-dot-dash'">dash-dot-dot-heavy</xsl:when>
  3382. <xsl:when test="$lineType='bold-wave'">wavy-heavy</xsl:when>
  3383. <xsl:when test="$lineType='double-wave'">wavy-double</xsl:when>
  3384. <xsl:when test="$lineType='bold'">bold</xsl:when>
  3385. <xsl:when test="$lineType='small-wave'">wave</xsl:when>
  3386. <xsl:when test="$lineType='dotted'">dotted</xsl:when>
  3387. <xsl:when test="$lineType='none'">none</xsl:when>
  3388. </xsl:choose>
  3389. </xsl:template>
  3390. </xsl:stylesheet>