Produced by Araxis Merge on Thu Oct 16 22:30:07 2008 UTC. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a reasonably standards compliant browser such as the latest version of Firefox or Internet Explorer. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.
# | Location | File | Last Modified |
---|---|---|---|
1 | Thu Oct 16 22:30:07 2008 UTC | ||
2 | C:\Documents and Settings\lauren\Desktop\ww-version-snapshots\ww-version-snapshots\2008.3\WebWorks\ePublisher Pro\Formats\Wiki - MoinMoin\Transforms | content.xsl | Mon Oct 13 05:51:50 2008 UTC |
Description | Between Files 1 and 2 |
|
---|---|---|
Text Blocks | Lines | |
Unchanged | 0 | 0 |
Changed | 0 | 0 |
Inserted | 1 | 3151 |
Removed | 0 | 0 |
Whitespace | All differences in whitespace within lines are ignored |
---|---|
Character case | Differences in character case are significant |
Line endings | Differences in line endings (CR and LF characters) are ignored |
CR/LF characters | Not shown in the comparison detail |
No regular expressions were active.
1 | <?xml vers ion="1.0" encoding=" UTF-8"?> | |||||
2 | <xsl:style sheet vers ion="1.0" xmlns="urn :WebWorks- Wiki-Page- Schema" | |||||
3 | xmlns:wwwi ki="urn:We bWorks-Wik i-Page-Sch ema" | |||||
4 | xmlns:xsl= "http://ww w.w3.org/1 999/XSL/Tr ansform" | |||||
5 | xmlns:msxs l="urn:sch emas-micro soft-com:x slt" | |||||
6 | xmlns:wwmo de="urn:We bWorks-Eng ine-Mode" | |||||
7 | xmlns:wwli nks="urn:W ebWorks-En gine-Links -Schema" | |||||
8 | xmlns:wwfi les="urn:W ebWorks-En gine-Files -Schema" | |||||
9 | xmlns:wwdo c="urn:Web Works-Docu ment-Schem a" | |||||
10 | xmlns:wwsp lits="urn: WebWorks-E ngine-Spli ts-Schema" | |||||
11 | xmlns:wwto c="urn:Web Works-Engi ne-TOC-Sch ema" | |||||
12 | xmlns:wwbe haviors="u rn:WebWork s-Behavior s-Schema" | |||||
13 | xmlns:wwno tes="urn:W ebWorks-Fo otnote-Sch ema" | |||||
14 | xmlns:wwpr oject="urn :WebWorks- Publish-Pr oject" | |||||
15 | xmlns:wwpa ge="urn:We bWorks-Pag e-Template -Schema" | |||||
16 | xmlns:wwlo cale="urn: WebWorks-L ocale-Sche ma" | |||||
17 | xmlns:wwpr ogress="ur n:WebWorks -XSLT-Exte nsion-Prog ress" | |||||
18 | xmlns:wwlo g="urn:Web Works-XSLT -Extension -Log" | |||||
19 | xmlns:wwfi lesystem=" urn:WebWor ks-XSLT-Ex tension-Fi leSystem" | |||||
20 | xmlns:wwur i="urn:Web Works-XSLT -Extension -URI" | |||||
21 | xmlns:wwst ring="urn: WebWorks-X SLT-Extens ion-String Utilities" | |||||
22 | xmlns:wwun its="urn:W ebWorks-XS LT-Extensi on-Units" | |||||
23 | xmlns:wwfi lesext="ur n:WebWorks -XSLT-Exte nsion-File s" | |||||
24 | xmlns:wwpr ojext="urn :WebWorks- XSLT-Exten sion-Proje ct" | |||||
25 | xmlns:wwim aging="urn :WebWorks- XSLT-Exten sion-Imagi ng" | |||||
26 | xmlns:wwex sldoc="urn :WebWorks- XSLT-Exten sion-Docum ent" | |||||
27 | exclude-re sult-prefi xes="xsl m sxsl wwmod e wwlinks wwfiles ww doc wwspli ts wwtoc w wbehaviors wwnotes w wproject w wpage wwlo cale wwpro gress wwlo g wwfilesy stem wwuri wwstring wwunits ww filesext w wprojext w wimaging w wexsldoc" | |||||
28 | > | |||||
29 | <xsl:key name="wwsp lits-files -by-groupi d-type" ma tch="wwspl its:File" use="conca t(@groupID , ':', @ty pe)" /> | |||||
30 | <xsl:key name="wwsp lits-frame s-by-id" m atch="wwsp lits:Frame " use="@id " /> | |||||
31 | <xsl:key name="wwto c-entry-by -id" match ="wwtoc:En try" use=" @id" /> | |||||
32 | <xsl:key name="wwbe haviors-pa ragraphs-b y-id" matc h="wwbehav iors:Parag raph" use= "@id" /> | |||||
33 | <xsl:key name="wwbe haviors-pa ragraphs-b y-relatedt opic" matc h="wwbehav iors:Parag raph" use= "@relatedt opic" /> | |||||
34 | <xsl:key name="wwbe haviors-fr ames-by-id " match="w wbehaviors :Frame" us e="@id" /> | |||||
35 | <xsl:key name="wwbe haviors-ta bles-by-id " match="w wbehaviors :Table" us e="@id" /> | |||||
36 | <xsl:key name="wwdo c-paragrap hs-by-id" match="wwd oc:Paragra ph" use="@ id" /> | |||||
37 | <xsl:key name="wwno tes-notes- by-id" mat ch="wwnote s:Note" us e="@id" /> | |||||
38 | <xsl:key name="wwfi les-files- by-path" m atch="wwfi les:File" use="@path " /> | |||||
39 | <xsl:key name="wwpr oject-prop erty-by-na me" match= "wwproject :Property" use="@Nam e"/> | |||||
40 | ||||||
41 | ||||||
42 | <xsl:vari able name= "GlobalPro cessAsPage Extensions " select=" concat(' ' , wwprojex t:GetForma tSetting(' wiki-proce ss-as-page -extension s'), ' ')" /> | |||||
43 | ||||||
44 | ||||||
45 | <xsl:temp late name= "Breadcrum bs"> | |||||
46 | <xsl:par am name="P aramPageRu le" /> | |||||
47 | <xsl:par am name="P aramSplit" /> | |||||
48 | <xsl:par am name="P aramBreadc rumbTOCEnt ry" /> | |||||
49 | ||||||
50 | <xsl:for -each sele ct="$Param Breadcrumb TOCEntry/. ./ancestor -or-self:: wwtoc:Entr y"> | |||||
51 | <xsl:va riable nam e="VarTOCE ntry" sele ct="." /> | |||||
52 | ||||||
53 | <!-- Em it entry - -> | |||||
54 | <!-- - -> | |||||
55 | <xsl:ch oose> | |||||
56 | <xsl:w hen test=" string-len gth($VarTO CEntry/@pa th) > 0 "> | |||||
57 | <!-- Entry with link --> | |||||
58 | <!-- --> | |||||
59 | <xsl: variable n ame="VarRe lativePath "> | |||||
60 | <xsl :call-temp late name= "MoinMoin- RelativePa geLink"> | |||||
61 | <xs l:with-par am name="P aramSource " select=" $ParamSpli t/@path" / > | |||||
62 | <xs l:with-par am name="P aramTarget " select=" $VarTOCEnt ry/@path" /> | |||||
63 | </xs l:call-tem plate> | |||||
64 | </xsl :variable> | |||||
65 | ||||||
66 | <xsl: text>[[</x sl:text> | |||||
67 | <xsl: if test="$ VarRelativ ePath != ' ../'"> | |||||
68 | <xs l:value-of select="$ VarRelativ ePath" /> | |||||
69 | </xsl :if> | |||||
70 | <xsl: if test="s tring-leng th($ParamB readcrumbT OCEntry/@l inkid) > ; 0"> | |||||
71 | <xsl :text>#</x sl:text> | |||||
72 | <xsl :value-of select="$P aramBreadc rumbTOCEnt ry/@linkid " /> | |||||
73 | </xsl :if> | |||||
74 | <xsl: text>|</xs l:text> | |||||
75 | <xsl: call-templ ate name=" Breadcrumb Entry"> | |||||
76 | <xsl :with-para m name="Pa ramTOCEntr y" select= "$VarTOCEn try" /> | |||||
77 | </xsl :call-temp late> | |||||
78 | <xsl: text>]]</x sl:text> | |||||
79 | </xsl: when> | |||||
80 | ||||||
81 | <xsl:o therwise> | |||||
82 | <!-- Entry with out link - -> | |||||
83 | <!-- - -> | |||||
84 | <xsl: call-templ ate name=" Breadcrumb Entry"> | |||||
85 | <xsl :with-para m name="Pa ramTOCEntr y" select= "$VarTOCEn try" /> | |||||
86 | </xsl :call-temp late> | |||||
87 | </xsl: otherwise> | |||||
88 | </xsl:c hoose> | |||||
89 | ||||||
90 | <!-- Em it separat or --> | |||||
91 | <!-- --> | |||||
92 | <xsl:va riable nam e="VarBrea dcrumbsSep arator" se lect="$Par amPageRule /wwproject :Propertie s/wwprojec t:Property [@Name = ' breadcrumb s-separato r']/@Value " /> | |||||
93 | <xsl:ch oose> | |||||
94 | <xsl:w hen test=" string-len gth($VarBr eadcrumbsS eparator) > 0"> | |||||
95 | <xsl: value-of s elect="$Va rBreadcrum bsSeparato r" /> | |||||
96 | </xsl: when> | |||||
97 | ||||||
98 | <xsl:o therwise> | |||||
99 | <xsl: text> : </ xsl:text> | |||||
100 | </xsl: otherwise> | |||||
101 | </xsl:c hoose> | |||||
102 | </xsl:fo r-each> | |||||
103 | ||||||
104 | <!-- Col lect up te xt --> | |||||
105 | <!-- --> | |||||
106 | <xsl:var iable name ="VarParag raphText"> | |||||
107 | <xsl:ca ll-templat e name="Br eadcrumbEn try"> | |||||
108 | <xsl:w ith-param name="Para mTOCEntry" select="$ ParamBread crumbTOCEn try" /> | |||||
109 | </xsl:c all-templa te> | |||||
110 | </xsl:va riable> | |||||
111 | ||||||
112 | <!-- Esc ape for di splay --> | |||||
113 | <!-- --> | |||||
114 | <xsl:cal l-template name="Moi nMoin-Esca peParagrap hText"> | |||||
115 | <xsl:wi th-param n ame="Param Text" sele ct="$VarPa ragraphTex t" /> | |||||
116 | </xsl:ca ll-templat e> | |||||
117 | </xsl:tem plate> | |||||
118 | ||||||
119 | ||||||
120 | <xsl:temp late name= "Breadcrum bEntry"> | |||||
121 | <xsl:par am name="P aramTOCEnt ry" /> | |||||
122 | ||||||
123 | <xsl:for -each sele ct="$Param TOCEntry/w wdoc:Parag raph/wwdoc :Number/ww doc:Text | $ParamTOC Entry/wwdo c:Paragrap h/wwdoc:Te xtRun/wwdo c:Text"> | |||||
124 | <xsl:va riable nam e="VarText " select=" ." /> | |||||
125 | ||||||
126 | <xsl:va lue-of sel ect="$VarT ext/@value " /> | |||||
127 | </xsl:fo r-each> | |||||
128 | </xsl:tem plate> | |||||
129 | ||||||
130 | ||||||
131 | <xsl:temp late name= "Content-C ontent"> | |||||
132 | <xsl:par am name="P aramConten t" /> | |||||
133 | <xsl:par am name="P aramSplits " /> | |||||
134 | <xsl:par am name="P aramCargo" /> | |||||
135 | <xsl:par am name="P aramLinks" /> | |||||
136 | <xsl:par am name="P aramTOCDat a" /> | |||||
137 | <xsl:par am name="P aramSplit" /> | |||||
138 | ||||||
139 | <!-- Con tent --> | |||||
140 | <!-- --> | |||||
141 | <xsl:app ly-templat es select= "$ParamCon tent" mode ="wwmode:c ontent"> | |||||
142 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
143 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
144 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
145 | <xsl:wi th-param n ame="Param TOCData" s elect="$Pa ramTOCData " /> | |||||
146 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
147 | </xsl:ap ply-templa tes> | |||||
148 | ||||||
149 | <!-- Rel ated Topic s --> | |||||
150 | <!-- --> | |||||
151 | <xsl:cal l-template name="Rel atedTopics "> | |||||
152 | <xsl:wi th-param n ame="Param Content" s elect="$Pa ramContent " /> | |||||
153 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
154 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
155 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
156 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
157 | </xsl:ca ll-templat e> | |||||
158 | </xsl:tem plate> | |||||
159 | ||||||
160 | ||||||
161 | <xsl:temp late name= "RelatedTo pics"> | |||||
162 | <xsl:par am name="P aramConten t" /> | |||||
163 | <xsl:par am name="P aramSplits " /> | |||||
164 | <xsl:par am name="P aramCargo" /> | |||||
165 | <xsl:par am name="P aramLinks" /> | |||||
166 | <xsl:par am name="P aramSplit" /> | |||||
167 | ||||||
168 | <xsl:var iable name ="VarRelat edTopicPar agraphsAsX ML"> | |||||
169 | <xsl:ca ll-templat e name="Re latedTopic Paragraphs "> | |||||
170 | <xsl:w ith-param name="Para mContent" select="$P aramConten t" /> | |||||
171 | <xsl:w ith-param name="Para mCargo" se lect="$Par amCargo" / > | |||||
172 | <xsl:w ith-param name="Para mSplit" se lect="$Par amSplit" / > | |||||
173 | </xsl:c all-templa te> | |||||
174 | </xsl:va riable> | |||||
175 | <xsl:var iable name ="VarRelat edTopicPar agraphs" s elect="msx sl:node-se t($VarRela tedTopicPa ragraphsAs XML)/wwdoc :Paragraph " /> | |||||
176 | ||||||
177 | <xsl:if test="coun t($VarRela tedTopicPa ragraphs) > 0"> | |||||
178 | <xsl:te xt><< ;BR>> ; | |||||
179 | </xsl:text > | |||||
180 | <xsl:te xt>---- | |||||
181 | </xsl:text > | |||||
182 | ||||||
183 | <!-- Ti tle --> | |||||
184 | <!-- --> | |||||
185 | <xsl:te xt> ::</xs l:text> | |||||
186 | <xsl:va lue-of sel ect="$Glob alLocale/w wlocale:Lo cale/wwloc ale:String s/wwlocale :String[@n ame = 'Rel atedTopics ']/@value" /> | |||||
187 | <xsl:te xt> | |||||
188 | </xsl:text > | |||||
189 | ||||||
190 | <!-- Re lated Topi c Entries --> | |||||
191 | <!-- --> | |||||
192 | <xsl:fo r-each sel ect="$VarR elatedTopi cParagraph s"> | |||||
193 | <xsl:v ariable na me="VarRel atedTopicP aragraph" select="." /> | |||||
194 | ||||||
195 | <xsl:v ariable na me="VarCon textRule" select="ww projext:Ge tContextRu le('Paragr aph', $Var RelatedTop icParagrap h/@stylena me, $Param Split/@doc umentID, $ VarRelated TopicParag raph/@id)" /> | |||||
196 | <xsl:v ariable na me="VarPar agraphBeha vior" sele ct="$Param Cargo/wwbe haviors:Be haviors[1] " /> | |||||
197 | ||||||
198 | <!-- R elated Top ic Paragra ph --> | |||||
199 | <!-- --> | |||||
200 | <xsl:t ext> :: </ xsl:text> | |||||
201 | <xsl:c all-templa te name="P aragraph-N ormal-Cont ent"> | |||||
202 | <xsl: with-param name="Par amSplits" select="$P aramSplits " /> | |||||
203 | <xsl: with-param name="Par amCargo" s elect="$Pa ramCargo" /> | |||||
204 | <xsl: with-param name="Par amLinks" s elect="$Pa ramLinks" /> | |||||
205 | <xsl: with-param name="Par amSplit" s elect="$Pa ramSplit" /> | |||||
206 | <xsl: with-param name="Par amParagrap h" select= "$VarRelat edTopicPar agraph" /> | |||||
207 | <xsl: with-param name="Par amStyleNam e" select= "$VarRelat edTopicPar agraph/@st ylename" / > | |||||
208 | <xsl: with-param name="Par amContextR ule" selec t="$VarCon textRule" /> | |||||
209 | <xsl: with-param name="Par amParagrap hBehavior" select="$ VarParagra phBehavior " /> | |||||
210 | </xsl: call-templ ate> | |||||
211 | <xsl:t ext> | |||||
212 | </xsl:text > | |||||
213 | </xsl:f or-each> | |||||
214 | </xsl:if > | |||||
215 | </xsl:tem plate> | |||||
216 | ||||||
217 | ||||||
218 | <xsl:temp late name= "RelatedTo picParagra phs"> | |||||
219 | <xsl:par am name="P aramConten t" /> | |||||
220 | <xsl:par am name="P aramCargo" /> | |||||
221 | <xsl:par am name="P aramSplit" /> | |||||
222 | ||||||
223 | <xsl:for -each sele ct="$Param Cargo/wwbe haviors:Be haviors[1] "> | |||||
224 | <xsl:va riable nam e="VarRela tedTopicBe haviorPara graphs" se lect="key( 'wwbehavio rs-paragra phs-by-rel atedtopic' , 'define' ) | key('w wbehaviors -paragraph s-by-relat edtopic', 'define-no -output')" /> | |||||
225 | ||||||
226 | <xsl:fo r-each sel ect="$VarR elatedTopi cBehaviorP aragraphs[ (@document position & gt;= $Para mSplit/@do cumentstar tposition) and (@doc umentposit ion <= $ParamSpli t/@documen tendpositi on)]"> | |||||
227 | <xsl:v ariable na me="VarBeh aviorParag raph" sele ct="." /> | |||||
228 | ||||||
229 | <xsl:f or-each se lect="$Par amContent[ 1]"> | |||||
230 | <xsl: for-each s elect="key ('wwdoc-pa ragraphs-b y-id', $Va rBehaviorP aragraph/@ id)[1]"> | |||||
231 | <xsl :variable name="VarP aragraph" select="." /> | |||||
232 | ||||||
233 | <!-- Paragraph has link? --> | |||||
234 | <!-- --> | |||||
235 | <xsl :variable name="VarC hildLinks" select="$ VarParagra ph//wwdoc: Link[count ($VarParag raph | anc estor::wwd oc:Paragra ph[1]) = 1 ]" /> | |||||
236 | <xsl :variable name="VarC hildLinksC ount" sele ct="count( $VarChildL inks)" /> | |||||
237 | <xsl :if test=" $VarChildL inksCount > 0"> | |||||
238 | <!- - Emit par agraph --> | |||||
239 | <!- - --> | |||||
240 | <ww doc:Paragr aph> | |||||
241 | <x sl:copy-of select="$ VarParagra ph/@*" /> | |||||
242 | ||||||
243 | <! -- Insure link is de fined --> | |||||
244 | <! -- --> | |||||
245 | <x sl:if test ="count($V arParagrap h/wwdoc:Li nk) = 0"> | |||||
246 | < xsl:copy-o f select=" $VarChildL inks[1]" / > | |||||
247 | </ xsl:if> | |||||
248 | ||||||
249 | <x sl:copy-of select="$ VarParagra ph/*" /> | |||||
250 | </w wdoc:Parag raph> | |||||
251 | </xs l:if> | |||||
252 | </xsl :for-each> | |||||
253 | </xsl: for-each> | |||||
254 | </xsl:f or-each> | |||||
255 | </xsl:fo r-each> | |||||
256 | </xsl:tem plate> | |||||
257 | ||||||
258 | ||||||
259 | <xsl:temp late name= "Content-N otes"> | |||||
260 | <xsl:par am name="P aramNotes" /> | |||||
261 | <xsl:par am name="P aramSplits " /> | |||||
262 | <xsl:par am name="P aramCargo" /> | |||||
263 | <xsl:par am name="P aramLinks" /> | |||||
264 | <xsl:par am name="P aramTOCDat a" /> | |||||
265 | <xsl:par am name="P aramSplit" /> | |||||
266 | ||||||
267 | <xsl:if test="coun t($ParamNo tes[1]) = 1"> | |||||
268 | <xsl:te xt>---- | |||||
269 | </xsl:text > | |||||
270 | ||||||
271 | <xsl:fo r-each sel ect="$Para mNotes"> | |||||
272 | <xsl:v ariable na me="VarNot e" select= "." /> | |||||
273 | ||||||
274 | <xsl:v ariable na me="VarNot eNumber" s elect="$Pa ramCargo/w wnotes:Not eNumbering /wwnotes:N ote[@id = $VarNote/@ id]/@numbe r" /> | |||||
275 | ||||||
276 | <xsl:i f test="st ring-lengt h($VarNote Number) &g t; 0"> | |||||
277 | <!-- Footnote n umber --> | |||||
278 | <!-- --> | |||||
279 | <wwex sldoc:Text disable-o utput-esca ping="yes" ><<A nchor(<xsl :value-of select="$V arNote/@id " />)>& gt;</wwexs ldoc:Text> | |||||
280 | <xsl: text>[[#</ xsl:text> | |||||
281 | <xsl: text>wwfoo tnote_inli ne_</xsl:t ext> | |||||
282 | <xsl: value-of s elect="$Va rNote/@id" /> | |||||
283 | <xsl: text>|</xs l:text> | |||||
284 | <xsl: value-of s elect="$Va rNoteNumbe r" /> | |||||
285 | <xsl: text>]] </ xsl:text> | |||||
286 | ||||||
287 | <!-- Footnote t ext --> | |||||
288 | <!-- --> | |||||
289 | <xsl: apply-temp lates sele ct="$VarNo te/*" mode ="wwmode:c ontent"> | |||||
290 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
291 | <xsl :with-para m name="Pa ramCargo" select="$P aramCargo" /> | |||||
292 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
293 | <xsl :with-para m name="Pa ramTOCData " select=" $ParamTOCD ata" /> | |||||
294 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
295 | </xsl :apply-tem plates> | |||||
296 | </xsl: if> | |||||
297 | </xsl:f or-each> | |||||
298 | </xsl:if > | |||||
299 | </xsl:tem plate> | |||||
300 | ||||||
301 | ||||||
302 | <xsl:temp late name= "Notes-Num ber"> | |||||
303 | <xsl:par am name="P aramNotes" /> | |||||
304 | ||||||
305 | <wwnotes :NoteNumbe ring versi on="1.0"> | |||||
306 | <xsl:fo r-each sel ect="$Para mNotes"> | |||||
307 | <xsl:v ariable na me="VarNot e" select= "." /> | |||||
308 | ||||||
309 | <wwnot es:Note id ="{$VarNot e/@id}" nu mber="{pos ition()}" /> | |||||
310 | </xsl:f or-each> | |||||
311 | </wwnote s:NoteNumb ering> | |||||
312 | </xsl:tem plate> | |||||
313 | ||||||
314 | ||||||
315 | <xsl:temp late match ="wwdoc:Pa ragraph" m ode="wwmod e:content" > | |||||
316 | <xsl:par am name="P aramSplits " /> | |||||
317 | <xsl:par am name="P aramCargo" /> | |||||
318 | <xsl:par am name="P aramLinks" /> | |||||
319 | <xsl:par am name="P aramTOCDat a" /> | |||||
320 | <xsl:par am name="P aramSplit" /> | |||||
321 | ||||||
322 | <xsl:var iable name ="VarParag raph" sele ct="." /> | |||||
323 | ||||||
324 | <!-- Abo rted? --> | |||||
325 | <!-- --> | |||||
326 | <xsl:if test="not( wwprogress :Abort())" > | |||||
327 | <xsl:va riable nam e="VarCont extRule" s elect="wwp rojext:Get ContextRul e('Paragra ph', $VarP aragraph/@ stylename, $ParamSpl it/@docume ntID, $Var Paragraph/ @id)" /> | |||||
328 | <xsl:va riable nam e="VarGene rateOutput Option" se lect="$Var ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'gene rate-outpu t']/@Value " /> | |||||
329 | <xsl:va riable nam e="VarGene rateOutput " select=" (string-le ngth($VarG enerateOut putOption) = 0) or ( $VarGenera teOutputOp tion != 'f alse')" /> | |||||
330 | <xsl:if test="$Va rGenerateO utput"> | |||||
331 | <!-- R elated Top ic Only or Popup Onl y? --> | |||||
332 | <!-- --> | |||||
333 | <xsl:f or-each se lect="$Par amCargo/ww behaviors: Behaviors[ 1]"> | |||||
334 | <xsl: variable n ame="VarPa ragraphBeh avior" sel ect="key(' wwbehavior s-paragrap hs-by-id', $VarParag raph/@id)[ 1]" /> | |||||
335 | <xsl: variable n ame="VarIn PopupPage" select="c ount($Para mCargo/wwb ehaviors:P opupPage) > 0" /> | |||||
336 | <xsl: variable n ame="VarPo pupOnly" s elect="($V arParagrap hBehavior/ @popup = ' define-no- output') o r ($VarPar agraphBeha vior/@popu p = 'appen d-no-outpu t')" /> | |||||
337 | <xsl: variable n ame="VarRe latedTopic Only" sele ct="$VarPa ragraphBeh avior/@rel atedtopic = 'define- no-output' " /> | |||||
338 | ||||||
339 | <xsl: if test="$ VarInPopup Page or (n ot($VarPop upOnly) an d not($Var RelatedTop icOnly))"> | |||||
340 | <!-- Paragraph --> | |||||
341 | <!-- --> | |||||
342 | <xsl :call-temp late name= "Paragraph "> | |||||
343 | <xs l:with-par am name="P aramSplits " select=" $ParamSpli ts" /> | |||||
344 | <xs l:with-par am name="P aramCargo" select="$ ParamCargo " /> | |||||
345 | <xs l:with-par am name="P aramLinks" select="$ ParamLinks " /> | |||||
346 | <xs l:with-par am name="P aramSplit" select="$ ParamSplit " /> | |||||
347 | <xs l:with-par am name="P aramParagr aph" selec t="$VarPar agraph" /> | |||||
348 | <xs l:with-par am name="P aramStyleN ame" selec t="$VarPar agraph/@st ylename" / > | |||||
349 | <xs l:with-par am name="P aramContex tRule" sel ect="$VarC ontextRule " /> | |||||
350 | <xs l:with-par am name="P aramParagr aphBehavio r" select= "$VarParag raphBehavi or" /> | |||||
351 | </xs l:call-tem plate> | |||||
352 | ||||||
353 | <!-- MiniTOC - -> | |||||
354 | <!-- - -> | |||||
355 | <xsl :if test=" not($VarIn PopupPage) "> | |||||
356 | <xs l:variable name="Var MiniTOCSub Levels" se lect="$Var ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'mini toc-sublev els']/@Val ue" /> | |||||
357 | <xs l:variable name="Var MiniTOCSub LevelsNume ricPrefix" select="w wunits:Num ericPrefix ($VarMiniT OCSubLevel s)" /> | |||||
358 | <xs l:variable name="Var MiniTOCSub LevelsGrea terThanZer o" select= "(string-l ength($Var MiniTOCSub LevelsNume ricPrefix) > 0) a nd (number ($VarMiniT OCSubLevel sNumericPr efix) > 0)" /> | |||||
359 | <xs l:if test= "($VarMini TOCSubLeve lsGreaterT hanZero) o r ($VarMin iTOCSubLev els = 'all ')"> | |||||
360 | <x sl:for-eac h select=" $ParamTOCD ata[1]"> | |||||
361 | < xsl:variab le name="V arTOCEntry " select=" key('wwtoc -entry-by- id', $VarP aragraph/@ id)[@docum entID = $P aramSplit/ @documentI D]" /> | |||||
362 | < xsl:for-ea ch select= "$VarTOCEn try[1]"> | |||||
363 | <xsl:call- template n ame="MiniT OC"> | |||||
364 | <xsl:with -param nam e="ParamSp lit" selec t="$ParamS plit" /> | |||||
365 | <xsl:with -param nam e="ParamTO CEntry" se lect="$Var TOCEntry[1 ]" /> | |||||
366 | <xsl:with -param nam e="ParamEm itTOCEntry " select=" false()" / > | |||||
367 | <xsl:with -param nam e="ParamMi niTOCSubLe vels" sele ct="$VarMi niTOCSubLe vels" /> | |||||
368 | </xsl:call -template> | |||||
369 | < /xsl:for-e ach> | |||||
370 | </ xsl:for-ea ch> | |||||
371 | </x sl:if> | |||||
372 | </xs l:if> | |||||
373 | </xsl :if> | |||||
374 | </xsl: for-each> | |||||
375 | </xsl:i f> | |||||
376 | </xsl:if > | |||||
377 | </xsl:tem plate> | |||||
378 | ||||||
379 | ||||||
380 | <xsl:temp late name= "MiniTOC"> | |||||
381 | <xsl:par am name="P aramSplit" /> | |||||
382 | <xsl:par am name="P aramTOCEnt ry" /> | |||||
383 | <xsl:par am name="P aramEmitTO CEntry" /> | |||||
384 | <xsl:par am name="P aramMiniTO CSubLevels " /> | |||||
385 | ||||||
386 | <xsl:if test="($Pa ramEmitTOC Entry = tr ue()) or ( count($Par amTOCEntry /wwtoc:Ent ry[1]) = 1 )"> | |||||
387 | <!-- Wr ap inside a block -- > | |||||
388 | <!-- -- > | |||||
389 | <xsl:te xt>{{{{{#! wiki | |||||
390 | </xsl:text > | |||||
391 | <!-- E mit top-le vel entry? --> | |||||
392 | <!-- --> | |||||
393 | <xsl:c hoose> | |||||
394 | <xsl: when test= "$ParamEmi tTOCEntry = true()"> | |||||
395 | <!-- Paragraph --> | |||||
396 | <!-- --> | |||||
397 | <xsl :text> . < /xsl:text> | |||||
398 | <xsl :variable name="VarP aragraphTe xt"> | |||||
399 | <xs l:call-tem plate name ="MiniTOCP aragraph"> | |||||
400 | <x sl:with-pa ram name=" ParamParag raph" sele ct="$Param TOCEntry/w wdoc:Parag raph" /> | |||||
401 | </x sl:call-te mplate> | |||||
402 | </xs l:variable > | |||||
403 | <xsl :call-temp late name= "MoinMoin- EscapePara graphText" > | |||||
404 | <xs l:with-par am name="P aramText" select="$V arParagrap hText" /> | |||||
405 | </xs l:call-tem plate> | |||||
406 | <xsl :text> | |||||
407 | </xsl:text > | |||||
408 | ||||||
409 | <!-- Children --> | |||||
410 | <!-- --> | |||||
411 | <xsl :call-temp late name= "MiniTOCEn tries"> | |||||
412 | <xs l:with-par am name="P aramRefere ncePath" s elect="$Pa ramSplit/@ path" /> | |||||
413 | <xs l:with-par am name="P aramParent " select=" $ParamTOCE ntry" /> | |||||
414 | <xs l:with-par am name="P aramMiniTO CSubLevels " select=" $ParamMini TOCSubLeve ls" /> | |||||
415 | <xs l:with-par am name="P aramLevel" select="2 " /> | |||||
416 | </xs l:call-tem plate> | |||||
417 | </xsl :when> | |||||
418 | ||||||
419 | <xsl: otherwise> | |||||
420 | <!-- Children --> | |||||
421 | <!-- --> | |||||
422 | <xsl :call-temp late name= "MiniTOCEn tries"> | |||||
423 | <xs l:with-par am name="P aramRefere ncePath" s elect="$Pa ramSplit/@ path" /> | |||||
424 | <xs l:with-par am name="P aramParent " select=" $ParamTOCE ntry" /> | |||||
425 | <xs l:with-par am name="P aramMiniTO CSubLevels " select=" $ParamMini TOCSubLeve ls" /> | |||||
426 | <xs l:with-par am name="P aramLevel" select="1 " /> | |||||
427 | </xs l:call-tem plate> | |||||
428 | </xsl :otherwise > | |||||
429 | </xsl: choose> | |||||
430 | <xsl:te xt>}}}}} | |||||
431 | ||||||
432 | </xsl:text > | |||||
433 | </xsl:if > | |||||
434 | </xsl:tem plate> | |||||
435 | ||||||
436 | ||||||
437 | <xsl:temp late name= "MiniTOCEn tries"> | |||||
438 | <xsl:par am name="P aramRefere ncePath" / > | |||||
439 | <xsl:par am name="P aramParent " /> | |||||
440 | <xsl:par am name="P aramMiniTO CSubLevels " /> | |||||
441 | <xsl:par am name="P aramLevel" /> | |||||
442 | ||||||
443 | <xsl:var iable name ="VarSubEn tries" sel ect="$Para mParent/ww toc:Entry" /> | |||||
444 | ||||||
445 | <xsl:for -each sele ct="$VarSu bEntries[1 ]"> | |||||
446 | <xsl:fo r-each sel ect="$VarS ubEntries" > | |||||
447 | <xsl:v ariable na me="VarEnt ry" select ="." /> | |||||
448 | ||||||
449 | <!-- E mit on lin e --> | |||||
450 | <!-- --> | |||||
451 | <xsl:c all-templa te name="S paces"> | |||||
452 | <xsl: with-param name="Par amSpacesTo Emit" sele ct="$Param Level" /> | |||||
453 | </xsl: call-templ ate> | |||||
454 | <xsl:t ext>. </xs l:text> | |||||
455 | ||||||
456 | <xsl:c hoose> | |||||
457 | <xsl: when test= "string-le ngth($VarE ntry/@path ) > 0"> | |||||
458 | <!-- Get link --> | |||||
459 | <!-- --> | |||||
460 | <xsl :variable name="VarR elativeLin kPath"> | |||||
461 | <xs l:call-tem plate name ="MoinMoin -RelativeP ageLink"> | |||||
462 | <x sl:with-pa ram name=" ParamSourc e" select= "$ParamRef erencePath " /> | |||||
463 | <x sl:with-pa ram name=" ParamTarge t" select= "$VarEntry /@path" /> | |||||
464 | </x sl:call-te mplate> | |||||
465 | </xs l:variable > | |||||
466 | ||||||
467 | <xsl :text>[[</ xsl:text> | |||||
468 | <xsl :if test=" $VarRelati veLinkPath != '../'" > | |||||
469 | <xs l:value-of select="$ VarRelativ eLinkPath" /> | |||||
470 | </xs l:if> | |||||
471 | <xsl :if test=" string-len gth($VarEn try/@linki d) > 0" > | |||||
472 | <xs l:text>#</ xsl:text> | |||||
473 | <xs l:value-of select="$ VarEntry/@ linkid" /> | |||||
474 | </xs l:if> | |||||
475 | <xsl :text>|</x sl:text> | |||||
476 | <xsl :call-temp late name= "MiniTOCPa ragraph"> | |||||
477 | <xs l:with-par am name="P aramParagr aph" selec t="$VarEnt ry/wwdoc:P aragraph" /> | |||||
478 | </xs l:call-tem plate> | |||||
479 | <xsl :text>]]</ xsl:text> | |||||
480 | </xsl :when> | |||||
481 | ||||||
482 | <xsl: otherwise> | |||||
483 | <xsl :variable name="VarP aragraphTe xt"> | |||||
484 | <xs l:call-tem plate name ="MiniTOCP aragraph"> | |||||
485 | <x sl:with-pa ram name=" ParamParag raph" sele ct="$VarEn try/wwdoc: Paragraph" /> | |||||
486 | </x sl:call-te mplate> | |||||
487 | </xs l:variable > | |||||
488 | <xsl :call-temp late name= "MoinMoin- EscapePara graphText" > | |||||
489 | <xs l:with-par am name="P aramText" select="$V arParagrap hText" /> | |||||
490 | </xs l:call-tem plate> | |||||
491 | </xsl :otherwise > | |||||
492 | </xsl: choose> | |||||
493 | <xsl:t ext> | |||||
494 | </xsl:text > | |||||
495 | ||||||
496 | <!-- R ecurse --> | |||||
497 | <!-- --> | |||||
498 | <xsl:c hoose> | |||||
499 | <xsl: when test= "$ParamMin iTOCSubLev els = 'all '"> | |||||
500 | <xsl :call-temp late name= "MiniTOCEn tries"> | |||||
501 | <xs l:with-par am name="P aramRefere ncePath" s elect="$Pa ramReferen cePath" /> | |||||
502 | <xs l:with-par am name="P aramParent " select=" $VarEntry" /> | |||||
503 | <xs l:with-par am name="P aramMiniTO CSubLevels " select=" $ParamMini TOCSubLeve ls" /> | |||||
504 | <xs l:with-par am name="P aramLevel" select="$ ParamLevel + 1" /> | |||||
505 | </xs l:call-tem plate> | |||||
506 | </xsl :when> | |||||
507 | ||||||
508 | <xsl: when test= "($ParamMi niTOCSubLe vels - 1) > 0"> | |||||
509 | <xsl :call-temp late name= "MiniTOCEn tries"> | |||||
510 | <xs l:with-par am name="P aramRefere ncePath" s elect="$Pa ramReferen cePath" /> | |||||
511 | <xs l:with-par am name="P aramParent " select=" $VarEntry" /> | |||||
512 | <xs l:with-par am name="P aramMiniTO CSubLevels " select=" $ParamMini TOCSubLeve ls - 1" /> | |||||
513 | <xs l:with-par am name="P aramLevel" select="$ ParamLevel + 1" /> | |||||
514 | </xs l:call-tem plate> | |||||
515 | </xsl :when> | |||||
516 | </xsl: choose> | |||||
517 | </xsl:f or-each> | |||||
518 | </xsl:fo r-each> | |||||
519 | </xsl:tem plate> | |||||
520 | ||||||
521 | ||||||
522 | <xsl:temp late name= "MiniTOCPa ragraph"> | |||||
523 | <xsl:par am name="P aramParagr aph" /> | |||||
524 | ||||||
525 | <xsl:for -each sele ct="$Param Paragraph/ wwdoc:Numb er/wwdoc:T ext | $Par amParagrap h/wwdoc:Te xtRun/wwdo c:Text"> | |||||
526 | <xsl:va lue-of sel ect="@valu e" /> | |||||
527 | </xsl:fo r-each> | |||||
528 | </xsl:tem plate> | |||||
529 | ||||||
530 | ||||||
531 | <xsl:temp late name= "Paragraph "> | |||||
532 | <xsl:par am name="P aramSplits " /> | |||||
533 | <xsl:par am name="P aramCargo" /> | |||||
534 | <xsl:par am name="P aramLinks" /> | |||||
535 | <xsl:par am name="P aramSplit" /> | |||||
536 | <xsl:par am name="P aramParagr aph" /> | |||||
537 | <xsl:par am name="P aramStyleN ame" /> | |||||
538 | <xsl:par am name="P aramContex tRule" /> | |||||
539 | <xsl:par am name="P aramParagr aphBehavio r" /> | |||||
540 | ||||||
541 | <!-- Pre serve empt y? --> | |||||
542 | <!-- --> | |||||
543 | <xsl:var iable name ="VarPrese rveEmptyOp tion" sele ct="$Param ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'pres erve-empty ']/@Value" /> | |||||
544 | <xsl:var iable name ="VarPrese rveEmpty" select="(s tring-leng th($VarPre serveEmpty Option) = 0) or ($Va rPreserveE mptyOption = 'true') " /> | |||||
545 | ||||||
546 | <!-- Non -empty tex t runs --> | |||||
547 | <!-- --> | |||||
548 | <xsl:var iable name ="VarTextR uns" selec t="$ParamP aragraph/w wdoc:TextR un[count(c hild::wwdo c:Text[1] | child::w wdoc:Frame [1] | chil d::wwdoc:N ote[1] | c hild::wwdo c:LineBrea k[1]) > 0]" /> | |||||
549 | ||||||
550 | <!-- Pro cess this paragraph at all? -- > | |||||
551 | <!-- -- > | |||||
552 | <xsl:if test="($Va rPreserveE mpty) or ( count($Var TextRuns[1 ]) = 1)"> | |||||
553 | <!-- Pa ss-through ? --> | |||||
554 | <!-- --> | |||||
555 | <xsl:va riable nam e="VarPass Through"> | |||||
556 | <xsl:c all-templa te name="C onditions- PassThroug h"> | |||||
557 | <xsl: with-param name="Par amConditio ns" select ="$ParamPa ragraph/ww doc:Condit ions" /> | |||||
558 | </xsl: call-templ ate> | |||||
559 | </xsl:v ariable> | |||||
560 | ||||||
561 | <xsl:ch oose> | |||||
562 | <!-- P ass-throug h --> | |||||
563 | <!-- --> | |||||
564 | <xsl:w hen test=" $VarPassTh rough = 't rue'"> | |||||
565 | <!-- Use number ing? --> | |||||
566 | <!-- --> | |||||
567 | <xsl: variable n ame="VarUs eNumbering Option" se lect="$Par amContextR ule/wwproj ect:Option s/wwprojec t:Option[@ Name = 'us e-numberin g']/@Value " /> | |||||
568 | <xsl: variable n ame="VarUs eNumbering " select=" (string-le ngth($VarU seNumberin gOption) = 0) or ($V arUseNumbe ringOption = 'true') " /> | |||||
569 | <xsl: choose> | |||||
570 | <xsl :when test ="$VarUseN umbering"> | |||||
571 | <xs l:apply-te mplates se lect="$Par amParagrap h" mode="w wmode:pass through-wi th-numberi ng" /> | |||||
572 | </xs l:when> | |||||
573 | ||||||
574 | <xsl :otherwise > | |||||
575 | <xs l:apply-te mplates se lect="$Par amParagrap h" mode="w wmode:pass through" / > | |||||
576 | </xs l:otherwis e> | |||||
577 | </xsl :choose> | |||||
578 | </xsl: when> | |||||
579 | ||||||
580 | <!-- O ther parag raph behav ior --> | |||||
581 | <!-- --> | |||||
582 | <xsl:o therwise> | |||||
583 | <!-- Parser blo ck? --> | |||||
584 | <!-- --> | |||||
585 | <xsl: variable n ame="VarWi kiParserBl ockOption" select="$ ParamConte xtRule/wwp roject:Opt ions/wwpro ject:Optio n[@Name = 'wiki-pars er-block'] /@Value" / > | |||||
586 | <xsl: variable n ame="VarWi kiParserBl ock" selec t="$VarWik iParserBlo ckOption = 'true'" / > | |||||
587 | ||||||
588 | <xsl: choose> | |||||
589 | <!-- Parser bl ock --> | |||||
590 | <!-- --> | |||||
591 | <xsl :when test ="$VarWiki ParserBloc k"> | |||||
592 | <xs l:call-tem plate name ="Paragrap h-ParserBl ock"> | |||||
593 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
594 | <x sl:with-pa ram name=" ParamCargo " select=" $ParamCarg o" /> | |||||
595 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
596 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
597 | <x sl:with-pa ram name=" ParamParag raph" sele ct="$Param Paragraph" /> | |||||
598 | <x sl:with-pa ram name=" ParamStyle Name" sele ct="$Param StyleName" /> | |||||
599 | <x sl:with-pa ram name=" ParamConte xtRule" se lect="$Par amContextR ule" /> | |||||
600 | <x sl:with-pa ram name=" ParamParag raphBehavi or" select ="$ParamPa ragraphBeh avior" /> | |||||
601 | </x sl:call-te mplate> | |||||
602 | </xs l:when> | |||||
603 | ||||||
604 | <!-- Other par agraph beh avior --> | |||||
605 | <!-- --> | |||||
606 | <xsl :otherwise > | |||||
607 | <!- - Comment? --> | |||||
608 | <!- - --> | |||||
609 | <xs l:variable name="Var WikiCommen tOption" s elect="$Pa ramContext Rule/wwpro ject:Optio ns/wwproje ct:Option[ @Name = 'w iki-commen t']/@Value " /> | |||||
610 | <xs l:variable name="Var WikiCommen t" select= "$VarWikiC ommentOpti on = 'true '" /> | |||||
611 | ||||||
612 | <xs l:choose> | |||||
613 | <! -- Comment --> | |||||
614 | <! -- --> | |||||
615 | <x sl:when te st="$VarWi kiComment" > | |||||
616 | < xsl:call-t emplate na me="Paragr aph-Commen t"> | |||||
617 | <xsl:with- param name ="ParamSpl its" selec t="$ParamS plits" /> | |||||
618 | <xsl:with- param name ="ParamCar go" select ="$ParamCa rgo" /> | |||||
619 | <xsl:with- param name ="ParamLin ks" select ="$ParamLi nks" /> | |||||
620 | <xsl:with- param name ="ParamSpl it" select ="$ParamSp lit" /> | |||||
621 | <xsl:with- param name ="ParamPar agraph" se lect="$Par amParagrap h" /> | |||||
622 | <xsl:with- param name ="ParamSty leName" se lect="$Par amStyleNam e" /> | |||||
623 | <xsl:with- param name ="ParamCon textRule" select="$P aramContex tRule" /> | |||||
624 | <xsl:with- param name ="ParamPar agraphBeha vior" sele ct="$Param ParagraphB ehavior" / > | |||||
625 | < /xsl:call- template> | |||||
626 | </ xsl:when> | |||||
627 | ||||||
628 | <! -- Other p aragraph b ehavior -- > | |||||
629 | <! -- -- > | |||||
630 | <x sl:otherwi se> | |||||
631 | < !-- Headin g level? - -> | |||||
632 | < !-- - -> | |||||
633 | < xsl:variab le name="V arWikiHead ingLevelOp tion" sele ct="$Param ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'wiki -heading-l evel']/@Va lue" /> | |||||
634 | < xsl:variab le name="V arWikiHead ingLevelAs Text"> | |||||
635 | <xsl:choos e> | |||||
636 | <xsl:when test="$Va rWikiHeadi ngLevelOpt ion = 'non e'"> | |||||
637 | <xsl:val ue-of sele ct="0" /> | |||||
638 | </xsl:whe n> | |||||
639 | ||||||
640 | <xsl:when test="num ber($VarWi kiHeadingL evelOption ) > 0"> | |||||
641 | <xsl:val ue-of sele ct="$VarWi kiHeadingL evelOption " /> | |||||
642 | </xsl:whe n> | |||||
643 | ||||||
644 | <xsl:othe rwise> | |||||
645 | <xsl:val ue-of sele ct="0" /> | |||||
646 | </xsl:oth erwise> | |||||
647 | </xsl:choo se> | |||||
648 | < /xsl:varia ble> | |||||
649 | < xsl:variab le name="V arWikiHead ingLevel" select="nu mber($VarW ikiHeading LevelAsTex t)" /> | |||||
650 | ||||||
651 | < xsl:choose > | |||||
652 | <!-- Headi ng level - -> | |||||
653 | <!-- - -> | |||||
654 | <xsl:when test="$Var WikiHeadin gLevel > ; 0"> | |||||
655 | <xsl:call -template name="Para graph-Head ing"> | |||||
656 | <xsl:wit h-param na me="ParamS plits" sel ect="$Para mSplits" / > | |||||
657 | <xsl:wit h-param na me="ParamC argo" sele ct="$Param Cargo" /> | |||||
658 | <xsl:wit h-param na me="ParamL inks" sele ct="$Param Links" /> | |||||
659 | <xsl:wit h-param na me="ParamS plit" sele ct="$Param Split" /> | |||||
660 | <xsl:wit h-param na me="ParamP aragraph" select="$P aramParagr aph" /> | |||||
661 | <xsl:wit h-param na me="ParamS tyleName" select="$P aramStyleN ame" /> | |||||
662 | <xsl:wit h-param na me="ParamC ontextRule " select=" $ParamCont extRule" / > | |||||
663 | <xsl:wit h-param na me="ParamP aragraphBe havior" se lect="$Par amParagrap hBehavior" /> | |||||
664 | <xsl:wit h-param na me="ParamW ikiHeading Level" sel ect="$VarW ikiHeading Level" /> | |||||
665 | </xsl:cal l-template > | |||||
666 | </xsl:when > | |||||
667 | ||||||
668 | <!-- Body paragraph --> | |||||
669 | <!-- --> | |||||
670 | <xsl:other wise> | |||||
671 | <xsl:call -template name="Para graph-Norm al"> | |||||
672 | <xsl:wit h-param na me="ParamS plits" sel ect="$Para mSplits" / > | |||||
673 | <xsl:wit h-param na me="ParamC argo" sele ct="$Param Cargo" /> | |||||
674 | <xsl:wit h-param na me="ParamL inks" sele ct="$Param Links" /> | |||||
675 | <xsl:wit h-param na me="ParamS plit" sele ct="$Param Split" /> | |||||
676 | <xsl:wit h-param na me="ParamP aragraph" select="$P aramParagr aph" /> | |||||
677 | <xsl:wit h-param na me="ParamS tyleName" select="$P aramStyleN ame" /> | |||||
678 | <xsl:wit h-param na me="ParamC ontextRule " select=" $ParamCont extRule" / > | |||||
679 | <xsl:wit h-param na me="ParamP aragraphBe havior" se lect="$Par amParagrap hBehavior" /> | |||||
680 | </xsl:cal l-template > | |||||
681 | </xsl:othe rwise> | |||||
682 | < /xsl:choos e> | |||||
683 | </ xsl:otherw ise> | |||||
684 | </x sl:choose> | |||||
685 | </xs l:otherwis e> | |||||
686 | </xsl :choose> | |||||
687 | </xsl: otherwise> | |||||
688 | </xsl:c hoose> | |||||
689 | </xsl:if > | |||||
690 | </xsl:tem plate> | |||||
691 | ||||||
692 | ||||||
693 | <xsl:temp late name= "Paragraph -ParserBlo ck"> | |||||
694 | <xsl:par am name="P aramSplits " /> | |||||
695 | <xsl:par am name="P aramCargo" /> | |||||
696 | <xsl:par am name="P aramLinks" /> | |||||
697 | <xsl:par am name="P aramSplit" /> | |||||
698 | <xsl:par am name="P aramParagr aph" /> | |||||
699 | <xsl:par am name="P aramStyleN ame" /> | |||||
700 | <xsl:par am name="P aramContex tRule" /> | |||||
701 | <xsl:par am name="P aramParagr aphBehavio r" /> | |||||
702 | ||||||
703 | <!-- Par ser block type and o ptions --> | |||||
704 | <!-- --> | |||||
705 | <xsl:var iable name ="VarWikiP arserBlock Format" se lect="$Par amContextR ule/wwproj ect:Option s/wwprojec t:Option[@ Name = 'wi ki-parser- block-form at']/@Valu e" /> | |||||
706 | <xsl:var iable name ="VarWikiP arserBlock Options" s elect="$Pa ramContext Rule/wwpro ject:Optio ns/wwproje ct:Option[ @Name = 'w iki-parser -block-opt ions']/@Va lue" /> | |||||
707 | ||||||
708 | <!-- Par ser block prefix --> | |||||
709 | <!-- --> | |||||
710 | <xsl:tex t>{{{{{</x sl:text> | |||||
711 | <xsl:if test="(str ing-length ($VarWikiP arserBlock Format) &g t; 0) and (($VarWiki ParserBloc kFormat != 'plain') or (string -length($V arWikiPars erBlockOpt ions) > 0))"> | |||||
712 | <xsl:te xt>#!</xsl :text> | |||||
713 | <xsl:va lue-of sel ect="$VarW ikiParserB lockFormat " /> | |||||
714 | </xsl:if > | |||||
715 | <xsl:if test="stri ng-length( $VarWikiPa rserBlockO ptions) &g t; 0"> | |||||
716 | <xsl:te xt> </xsl: text> | |||||
717 | <xsl:va lue-of sel ect="$VarW ikiParserB lockOption s" /> | |||||
718 | </xsl:if > | |||||
719 | <xsl:tex t> | |||||
720 | </xsl:text > | |||||
721 | ||||||
722 | <!-- Par agraph --> | |||||
723 | <!-- --> | |||||
724 | ||||||
725 | <!-- Use numbering ? --> | |||||
726 | <!-- --> | |||||
727 | <xsl:var iable name ="VarUseNu mberingOpt ion" selec t="$ParamC ontextRule /wwproject :Options/w wproject:O ption[@Nam e = 'use-n umbering'] /@Value" / > | |||||
728 | <xsl:var iable name ="VarUseNu mbering" s elect="(st ring-lengt h($VarUseN umberingOp tion) = 0) or ($VarU seNumberin gOption = 'true')" / > | |||||
729 | <xsl:cho ose> | |||||
730 | <xsl:wh en test="$ VarUseNumb ering"> | |||||
731 | <xsl:a pply-templ ates selec t="$ParamP aragraph" mode="wwmo de:passthr ough-with- numbering" /> | |||||
732 | </xsl:w hen> | |||||
733 | ||||||
734 | <xsl:ot herwise> | |||||
735 | <xsl:a pply-templ ates selec t="$ParamP aragraph" mode="wwmo de:passthr ough" /> | |||||
736 | </xsl:o therwise> | |||||
737 | </xsl:ch oose> | |||||
738 | ||||||
739 | <!-- Par ser block suffix --> | |||||
740 | <!-- --> | |||||
741 | <xsl:tex t> | |||||
742 | </xsl:text > | |||||
743 | <xsl:tex t>}}}}}</x sl:text> | |||||
744 | <xsl:tex t> | |||||
745 | ||||||
746 | </xsl:text > | |||||
747 | </xsl:tem plate> | |||||
748 | ||||||
749 | ||||||
750 | <xsl:temp late name= "Paragraph -Comment"> | |||||
751 | <xsl:par am name="P aramSplits " /> | |||||
752 | <xsl:par am name="P aramCargo" /> | |||||
753 | <xsl:par am name="P aramLinks" /> | |||||
754 | <xsl:par am name="P aramSplit" /> | |||||
755 | <xsl:par am name="P aramParagr aph" /> | |||||
756 | <xsl:par am name="P aramStyleN ame" /> | |||||
757 | <xsl:par am name="P aramContex tRule" /> | |||||
758 | <xsl:par am name="P aramParagr aphBehavio r" /> | |||||
759 | ||||||
760 | <!-- Com ment prefi x --> | |||||
761 | <!-- --> | |||||
762 | <xsl:tex t>/* </xsl :text> | |||||
763 | ||||||
764 | <!-- Par agraph --> | |||||
765 | <!-- --> | |||||
766 | <xsl:cal l-template name="Par agraph-Nor mal-Conten t"> | |||||
767 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
768 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
769 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
770 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
771 | <xsl:wi th-param n ame="Param Paragraph" select="$ ParamParag raph" /> | |||||
772 | <xsl:wi th-param n ame="Param StyleName" select="$ ParamStyle Name" /> | |||||
773 | <xsl:wi th-param n ame="Param ContextRul e" select= "$ParamCon textRule" /> | |||||
774 | <xsl:wi th-param n ame="Param ParagraphB ehavior" s elect="$Pa ramParagra phBehavior " /> | |||||
775 | </xsl:ca ll-templat e> | |||||
776 | ||||||
777 | <!-- Com ment suffi x --> | |||||
778 | <!-- --> | |||||
779 | <xsl:tex t> */</xsl :text> | |||||
780 | ||||||
781 | <!-- End paragraph --> | |||||
782 | <!-- --> | |||||
783 | <xsl:tex t> | |||||
784 | ||||||
785 | </xsl:text > | |||||
786 | </xsl:tem plate> | |||||
787 | ||||||
788 | ||||||
789 | <xsl:temp late name= "Paragraph -Heading"> | |||||
790 | <xsl:par am name="P aramSplits " /> | |||||
791 | <xsl:par am name="P aramCargo" /> | |||||
792 | <xsl:par am name="P aramLinks" /> | |||||
793 | <xsl:par am name="P aramSplit" /> | |||||
794 | <xsl:par am name="P aramParagr aph" /> | |||||
795 | <xsl:par am name="P aramStyleN ame" /> | |||||
796 | <xsl:par am name="P aramContex tRule" /> | |||||
797 | <xsl:par am name="P aramParagr aphBehavio r" /> | |||||
798 | <xsl:par am name="P aramWikiHe adingLevel " /> | |||||
799 | ||||||
800 | <!-- Det ermine pre fix/suffix --> | |||||
801 | <!-- --> | |||||
802 | <xsl:var iable name ="VarHeadi ngPrefixSu ffix"> | |||||
803 | <xsl:ca ll-templat e name="Mo inMoin-Rep eatString" > | |||||
804 | <xsl:w ith-param name="Para mStringToR eport" sel ect="'='" /> | |||||
805 | <xsl:w ith-param name="Para mCount" se lect="$Par amWikiHead ingLevel" /> | |||||
806 | </xsl:c all-templa te> | |||||
807 | </xsl:va riable> | |||||
808 | ||||||
809 | <!-- Anc hor destin ation --> | |||||
810 | <!-- --> | |||||
811 | <wwexsld oc:Text di sable-outp ut-escapin g="yes">&l t;<Anch or(<xsl:va lue-of sel ect="$Para mParagraph /@id" />)& gt;></w wexsldoc:T ext> | |||||
812 | <xsl:tex t> | |||||
813 | </xsl:text > | |||||
814 | ||||||
815 | <!-- Hea ding prefi x --> | |||||
816 | <!-- --> | |||||
817 | <xsl:val ue-of sele ct="$VarHe adingPrefi xSuffix" / > | |||||
818 | <xsl:tex t> </xsl:t ext> | |||||
819 | ||||||
820 | <!-- Par agraph --> | |||||
821 | <!-- --> | |||||
822 | ||||||
823 | <!-- Use numbering ? --> | |||||
824 | <!-- --> | |||||
825 | <xsl:var iable name ="VarUseNu mberingOpt ion" selec t="$ParamC ontextRule /wwproject :Options/w wproject:O ption[@Nam e = 'use-n umbering'] /@Value" / > | |||||
826 | <xsl:var iable name ="VarUseNu mbering" s elect="(st ring-lengt h($VarUseN umberingOp tion) = 0) or ($VarU seNumberin gOption = 'true')" / > | |||||
827 | <xsl:cho ose> | |||||
828 | <xsl:wh en test="$ VarUseNumb ering"> | |||||
829 | <xsl:a pply-templ ates selec t="$ParamP aragraph" mode="wwmo de:passthr ough-with- numbering" /> | |||||
830 | </xsl:w hen> | |||||
831 | ||||||
832 | <xsl:ot herwise> | |||||
833 | <xsl:a pply-templ ates selec t="$ParamP aragraph" mode="wwmo de:passthr ough" /> | |||||
834 | </xsl:o therwise> | |||||
835 | </xsl:ch oose> | |||||
836 | ||||||
837 | <!-- Hea ding suffi x --> | |||||
838 | <!-- --> | |||||
839 | <xsl:tex t> </xsl:t ext> | |||||
840 | <xsl:val ue-of sele ct="$VarHe adingPrefi xSuffix" / > | |||||
841 | <xsl:tex t> | |||||
842 | ||||||
843 | </xsl:text > | |||||
844 | </xsl:tem plate> | |||||
845 | ||||||
846 | ||||||
847 | <xsl:temp late name= "Paragraph -Normal"> | |||||
848 | <xsl:par am name="P aramSplits " /> | |||||
849 | <xsl:par am name="P aramCargo" /> | |||||
850 | <xsl:par am name="P aramLinks" /> | |||||
851 | <xsl:par am name="P aramSplit" /> | |||||
852 | <xsl:par am name="P aramParagr aph" /> | |||||
853 | <xsl:par am name="P aramStyleN ame" /> | |||||
854 | <xsl:par am name="P aramContex tRule" /> | |||||
855 | <xsl:par am name="P aramParagr aphBehavio r" /> | |||||
856 | ||||||
857 | <!-- Par agraph con tent --> | |||||
858 | <!-- --> | |||||
859 | <xsl:cal l-template name="Par agraph-Nor mal-Conten t"> | |||||
860 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
861 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
862 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
863 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
864 | <xsl:wi th-param n ame="Param Paragraph" select="$ ParamParag raph" /> | |||||
865 | <xsl:wi th-param n ame="Param StyleName" select="$ ParamStyle Name" /> | |||||
866 | <xsl:wi th-param n ame="Param ContextRul e" select= "$ParamCon textRule" /> | |||||
867 | <xsl:wi th-param n ame="Param ParagraphB ehavior" s elect="$Pa ramParagra phBehavior " /> | |||||
868 | </xsl:ca ll-templat e> | |||||
869 | ||||||
870 | <!-- End paragraph --> | |||||
871 | <!-- --> | |||||
872 | <xsl:tex t> | |||||
873 | ||||||
874 | </xsl:text > | |||||
875 | </xsl:tem plate> | |||||
876 | ||||||
877 | ||||||
878 | <xsl:temp late name= "Paragraph -Normal-Co ntent"> | |||||
879 | <xsl:par am name="P aramSplits " /> | |||||
880 | <xsl:par am name="P aramCargo" /> | |||||
881 | <xsl:par am name="P aramLinks" /> | |||||
882 | <xsl:par am name="P aramSplit" /> | |||||
883 | <xsl:par am name="P aramParagr aph" /> | |||||
884 | <xsl:par am name="P aramStyleN ame" /> | |||||
885 | <xsl:par am name="P aramContex tRule" /> | |||||
886 | <xsl:par am name="P aramParagr aphBehavio r" /> | |||||
887 | ||||||
888 | <!-- Use character styles? - -> | |||||
889 | <!-- - -> | |||||
890 | <xsl:var iable name ="VarUseCh aracterSty lesOption" select="$ ParamConte xtRule/wwp roject:Opt ions/wwpro ject:Optio n[@Name = 'use-chara cter-style s']/@Value " /> | |||||
891 | <xsl:var iable name ="VarUseCh aracterSty les" selec t="(string -length($V arUseChara cterStyles Option) = 0) or ($Va rUseCharac terStylesO ption = 't rue')" /> | |||||
892 | ||||||
893 | <!-- Pre serve empt y? --> | |||||
894 | <!-- --> | |||||
895 | <xsl:var iable name ="VarPrese rveEmptyOp tion" sele ct="$Param ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'pres erve-empty ']/@Value" /> | |||||
896 | <xsl:var iable name ="VarPrese rveEmpty" select="(s tring-leng th($VarPre serveEmpty Option) = 0) or ($Va rPreserveE mptyOption = 'true') " /> | |||||
897 | ||||||
898 | <!-- Res olve proje ct propert ies --> | |||||
899 | <!-- --> | |||||
900 | <xsl:var iable name ="VarResol vedPropert iesAsXML"> | |||||
901 | <xsl:ca ll-templat e name="Pr operties-R esolveCont extRule"> | |||||
902 | <xsl:w ith-param name="Para mDocumentC ontext" se lect="$Par amParagrap h" /> | |||||
903 | <xsl:w ith-param name="Para mPropertie s" select= "$ParamCon textRule/w wproject:P roperties/ wwproject: Property" /> | |||||
904 | <xsl:w ith-param name="Para mStyleName " select=" $ParamPara graph/@sty lename" /> | |||||
905 | <xsl:w ith-param name="Para mStyleType " select=" 'Paragraph '" /> | |||||
906 | <xsl:w ith-param name="Para mContextSt yle" selec t="$ParamP aragraph/w wdoc:Style " /> | |||||
907 | </xsl:c all-templa te> | |||||
908 | </xsl:va riable> | |||||
909 | <xsl:var iable name ="VarResol vedPropert ies" selec t="msxsl:n ode-set($V arResolved Properties AsXML)/wwp roject:Pro perty" /> | |||||
910 | ||||||
911 | <!-- Emi t indent o r numberin g --> | |||||
912 | <!-- --> | |||||
913 | <xsl:cal l-template name="Par agraph-Ind entOrNumbe r"> | |||||
914 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
915 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
916 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
917 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
918 | <xsl:wi th-param n ame="Param Paragraph" select="$ ParamParag raph" /> | |||||
919 | <xsl:wi th-param n ame="Param ContextRul e" select= "$ParamCon textRule" /> | |||||
920 | </xsl:ca ll-templat e> | |||||
921 | ||||||
922 | <!-- Tex t Runs --> | |||||
923 | <!-- --> | |||||
924 | <xsl:cal l-template name="Par agraphText Runs"> | |||||
925 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
926 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
927 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
928 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
929 | <xsl:wi th-param n ame="Param PreserveEm pty" selec t="$VarPre serveEmpty " /> | |||||
930 | <xsl:wi th-param n ame="Param UseCharact erStyles" select="$V arUseChara cterStyles " /> | |||||
931 | <xsl:wi th-param n ame="Param Paragraph" select="$ ParamParag raph" /> | |||||
932 | <xsl:wi th-param n ame="Param ParagraphP roperties" select="$ VarResolve dPropertie s" /> | |||||
933 | </xsl:ca ll-templat e> | |||||
934 | </xsl:tem plate> | |||||
935 | ||||||
936 | ||||||
937 | <xsl:temp late name= "Paragraph -IndentOrN umber"> | |||||
938 | <xsl:par am name="P aramSplits " /> | |||||
939 | <xsl:par am name="P aramCargo" /> | |||||
940 | <xsl:par am name="P aramLinks" /> | |||||
941 | <xsl:par am name="P aramSplit" /> | |||||
942 | <xsl:par am name="P aramParagr aph" /> | |||||
943 | <xsl:par am name="P aramContex tRule" /> | |||||
944 | ||||||
945 | <!-- Use numbering ? --> | |||||
946 | <!-- --> | |||||
947 | <xsl:var iable name ="VarUseNu mberingOpt ion" selec t="$ParamC ontextRule /wwproject :Options/w wproject:O ption[@Nam e = 'use-n umbering'] /@Value" / > | |||||
948 | <xsl:var iable name ="VarUseNu mbering" s elect="(st ring-lengt h($VarUseN umberingOp tion) = 0) or ($VarU seNumberin gOption = 'true')" / > | |||||
949 | ||||||
950 | <!-- Wik i Indent - -> | |||||
951 | <!-- - -> | |||||
952 | <xsl:var iable name ="VarWikiI ndent"> | |||||
953 | <xsl:va riable nam e="VarWiki IndentOpti on" select ="$ParamCo ntextRule/ wwproject: Options/ww project:Op tion[@Name = 'wiki-i ndent']/@V alue" /> | |||||
954 | ||||||
955 | <xsl:ch oose> | |||||
956 | <xsl:w hen test=" $VarWikiIn dentOption = 'none'" > | |||||
957 | <xsl: value-of s elect="0" /> | |||||
958 | </xsl: when> | |||||
959 | ||||||
960 | <xsl:w hen test=" number($Va rWikiInden tOption) & gt; 0"> | |||||
961 | <xsl: value-of s elect="num ber($VarWi kiIndentOp tion)" /> | |||||
962 | </xsl: when> | |||||
963 | ||||||
964 | <xsl:o therwise> | |||||
965 | <xsl: value-of s elect="0" /> | |||||
966 | </xsl: otherwise> | |||||
967 | </xsl:c hoose> | |||||
968 | </xsl:va riable> | |||||
969 | ||||||
970 | <!-- Wik i List Lev el --> | |||||
971 | <!-- --> | |||||
972 | <xsl:var iable name ="VarWikiL istLevel"> | |||||
973 | <xsl:va riable nam e="VarWiki ListLevelO ption" sel ect="$Para mContextRu le/wwproje ct:Options /wwproject :Option[@N ame = 'wik i-list-lev el']/@Valu e" /> | |||||
974 | ||||||
975 | <xsl:ch oose> | |||||
976 | <xsl:w hen test=" $VarWikiLi stLevelOpt ion = 'aut o'"> | |||||
977 | <xsl: variable n ame="VarPa ragraphLis tLevel" se lect="$Par amParagrap h/wwdoc:Nu mber/wwdoc :Style/wwd oc:Attribu te[@name = 'wwdoc-li st-level'] /@value" / > | |||||
978 | ||||||
979 | <xsl: choose> | |||||
980 | <xsl :when test ="(string- length($Va rParagraph ListLevel) > 0) a nd (number ($VarParag raphListLe vel) > 0)"> | |||||
981 | <xs l:value-of select="n umber($Var ParagraphL istLevel)" /> | |||||
982 | </xs l:when> | |||||
983 | ||||||
984 | <xsl :otherwise > | |||||
985 | <xs l:value-of select="0 " /> | |||||
986 | </xs l:otherwis e> | |||||
987 | </xsl :choose> | |||||
988 | </xsl: when> | |||||
989 | ||||||
990 | <xsl:w hen test=" number($Va rWikiListL evelOption ) > 0"> | |||||
991 | <xsl: value-of s elect="num ber($VarWi kiListLeve lOption)" /> | |||||
992 | </xsl: when> | |||||
993 | ||||||
994 | <xsl:o therwise> | |||||
995 | <xsl: value-of s elect="0" /> | |||||
996 | </xsl: otherwise> | |||||
997 | </xsl:c hoose> | |||||
998 | </xsl:va riable> | |||||
999 | ||||||
1000 | <!-- Wik i List Typ e --> | |||||
1001 | <!-- --> | |||||
1002 | <xsl:var iable name ="VarWikiL istType"> | |||||
1003 | <xsl:va riable nam e="VarWiki ListTypeOp tion" sele ct="$Param ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'wiki -list-type ']/@Value" /> | |||||
1004 | ||||||
1005 | <xsl:ch oose> | |||||
1006 | <xsl:w hen test=" $VarWikiLi stTypeOpti on = 'auto '"> | |||||
1007 | <xsl: variable n ame="VarPa ragraphLis tType" sel ect="$Para mParagraph /wwdoc:Num ber/wwdoc: Style/wwdo c:Attribut e[@name = 'list-styl e-type']/@ value" /> | |||||
1008 | ||||||
1009 | <xsl: choose> | |||||
1010 | <xsl :when test ="string-l ength($Var ParagraphL istType) & gt; 0"> | |||||
1011 | <xs l:value-of select="$ VarParagra phListType " /> | |||||
1012 | </xs l:when> | |||||
1013 | ||||||
1014 | <xsl :otherwise > | |||||
1015 | <xs l:value-of select="' '" /> | |||||
1016 | </xs l:otherwis e> | |||||
1017 | </xsl :choose> | |||||
1018 | </xsl: when> | |||||
1019 | ||||||
1020 | <xsl:w hen test=" string-len gth($VarWi kiListType Option) &g t; 0"> | |||||
1021 | <xsl: value-of s elect="$Va rWikiListT ypeOption" /> | |||||
1022 | </xsl: when> | |||||
1023 | ||||||
1024 | <xsl:o therwise> | |||||
1025 | <xsl: value-of s elect="''" /> | |||||
1026 | </xsl: otherwise> | |||||
1027 | </xsl:c hoose> | |||||
1028 | </xsl:va riable> | |||||
1029 | ||||||
1030 | <!-- Emi t paragrap h prefix - -> | |||||
1031 | <!-- - -> | |||||
1032 | <xsl:cho ose> | |||||
1033 | <!-- Li st entry - -> | |||||
1034 | <!-- - -> | |||||
1035 | <xsl:wh en test="( $VarUseNum bering) an d (string- length($Va rWikiListT ype) > 0)"> | |||||
1036 | <xsl:c all-templa te name="S paces"> | |||||
1037 | <xsl: with-param name="Par amSpacesTo Emit" sele ct="$VarWi kiListLeve l - 1" /> | |||||
1038 | </xsl: call-templ ate> | |||||
1039 | ||||||
1040 | <xsl:c hoose> | |||||
1041 | <xsl: when test= "$VarWikiL istType = 'bullet'"> | |||||
1042 | <xsl :text> * < /xsl:text> | |||||
1043 | </xsl :when> | |||||
1044 | ||||||
1045 | <xsl: when test= "$VarWikiL istType = 'decimal'" > | |||||
1046 | <xsl :text> 1. </xsl:text > | |||||
1047 | </xsl :when> | |||||
1048 | ||||||
1049 | <xsl: when test= "$VarWikiL istType = 'upper-alp ha'"> | |||||
1050 | <xsl :text> A. </xsl:text > | |||||
1051 | </xsl :when> | |||||
1052 | ||||||
1053 | <xsl: when test= "$VarWikiL istType = 'lower-alp ha'"> | |||||
1054 | <xsl :text> a. </xsl:text > | |||||
1055 | </xsl :when> | |||||
1056 | ||||||
1057 | <xsl: when test= "$VarWikiL istType = 'upper-rom an'"> | |||||
1058 | <xsl :text> I. </xsl:text > | |||||
1059 | </xsl :when> | |||||
1060 | ||||||
1061 | <xsl: when test= "$VarWikiL istType = 'lower-rom an'"> | |||||
1062 | <xsl :text> i. </xsl:text > | |||||
1063 | </xsl :when> | |||||
1064 | </xsl: choose> | |||||
1065 | </xsl:w hen> | |||||
1066 | ||||||
1067 | <!-- In dent --> | |||||
1068 | <!-- --> | |||||
1069 | <xsl:wh en test="$ VarWikiInd ent > 0 "> | |||||
1070 | <xsl:c all-templa te name="S paces"> | |||||
1071 | <xsl: with-param name="Par amSpacesTo Emit" sele ct="$VarWi kiIndent" /> | |||||
1072 | </xsl: call-templ ate> | |||||
1073 | </xsl:w hen> | |||||
1074 | ||||||
1075 | <!-- De fault --> | |||||
1076 | <!-- --> | |||||
1077 | <xsl:ot herwise> | |||||
1078 | <!-- N othing to do --> | |||||
1079 | <!-- --> | |||||
1080 | </xsl:o therwise> | |||||
1081 | </xsl:ch oose> | |||||
1082 | </xsl:tem plate> | |||||
1083 | ||||||
1084 | ||||||
1085 | <xsl:temp late name= "Paragraph TextRuns"> | |||||
1086 | <xsl:par am name="P aramSplits " /> | |||||
1087 | <xsl:par am name="P aramCargo" /> | |||||
1088 | <xsl:par am name="P aramLinks" /> | |||||
1089 | <xsl:par am name="P aramSplit" /> | |||||
1090 | <xsl:par am name="P aramPreser veEmpty" / > | |||||
1091 | <xsl:par am name="P aramUseCha racterStyl es" /> | |||||
1092 | <xsl:par am name="P aramParagr aph" /> | |||||
1093 | <xsl:par am name="P aramParagr aphPropert ies" /> | |||||
1094 | ||||||
1095 | <!-- Pre vent white space issu es with pr eformatted text bloc ks --> | |||||
1096 | <!-- --> | |||||
1097 | <wwexsld oc:NoBreak /> | |||||
1098 | ||||||
1099 | <!-- Non -empty tex t runs --> | |||||
1100 | <!-- --> | |||||
1101 | <xsl:var iable name ="VarTextR uns" selec t="$ParamP aragraph/w wdoc:TextR un[count(c hild::wwdo c:Text[1] | child::w wdoc:Frame [1] | chil d::wwdoc:N ote[1] | c hild::wwdo c:LineBrea k[1]) > 0]" /> | |||||
1102 | ||||||
1103 | <!-- Che ck for emp ty paragra phs --> | |||||
1104 | <!-- --> | |||||
1105 | <xsl:cho ose> | |||||
1106 | <xsl:wh en test="c ount($VarT extRuns[1] ) = 1"> | |||||
1107 | <!-- E mit anchor --> | |||||
1108 | <!-- --> | |||||
1109 | <wwexs ldoc:Text disable-ou tput-escap ing="yes"> <<An chor(<xsl: value-of s elect="$Pa ramParagra ph/@id" /> )>>< /wwexsldoc :Text> | |||||
1110 | ||||||
1111 | <!-- P aragraph h as content --> | |||||
1112 | <!-- --> | |||||
1113 | <xsl:f or-each se lect="$Var TextRuns"> | |||||
1114 | <xsl: variable n ame="VarTe xtRun" sel ect="." /> | |||||
1115 | ||||||
1116 | <xsl: call-templ ate name=" TextRun"> | |||||
1117 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
1118 | <xsl :with-para m name="Pa ramCargo" select="$P aramCargo" /> | |||||
1119 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
1120 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
1121 | <xsl :with-para m name="Pa ramParagra phID" sele ct="$Param Paragraph/ @id" /> | |||||
1122 | <xsl :with-para m name="Pa ramParagra phProperti es" select ="$ParamPa ragraphPro perties" / > | |||||
1123 | <xsl :with-para m name="Pa ramUseChar acterStyle s" select= "$ParamUse CharacterS tyles" /> | |||||
1124 | <xsl :with-para m name="Pa ramTextRun " select=" $VarTextRu n" /> | |||||
1125 | <xsl :with-para m name="Pa ramPositio n" select= "position( )" /> | |||||
1126 | </xsl :call-temp late> | |||||
1127 | </xsl: for-each> | |||||
1128 | </xsl:w hen> | |||||
1129 | ||||||
1130 | <xsl:ot herwise> | |||||
1131 | <!-- E mpty parag raph! --> | |||||
1132 | <!-- --> | |||||
1133 | <xsl:i f test="$P aramPreser veEmpty"> | |||||
1134 | <!-- Emit ancho r --> | |||||
1135 | <!-- --> | |||||
1136 | <wwex sldoc:Text disable-o utput-esca ping="yes" ><<A nchor(<xsl :value-of select="$P aramParagr aph/@id" / >)>> </wwexsldo c:Text> | |||||
1137 | <xsl: text>  ; | |||||
1138 | ||||||
1139 | </xsl:text > | |||||
1140 | </xsl: if> | |||||
1141 | </xsl:o therwise> | |||||
1142 | </xsl:ch oose> | |||||
1143 | </xsl:tem plate> | |||||
1144 | ||||||
1145 | ||||||
1146 | <xsl:temp late name= "LinkInfo" > | |||||
1147 | <xsl:par am name="P aramSplits " /> | |||||
1148 | <xsl:par am name="P aramLinks" /> | |||||
1149 | <xsl:par am name="P aramSplit" /> | |||||
1150 | <xsl:par am name="P aramDocume ntLink" /> | |||||
1151 | ||||||
1152 | <xsl:ele ment name= "LinkInfo" namespace ="urn:WebW orks-Engin e-Links-Sc hema"> | |||||
1153 | <xsl:if test="cou nt($ParamD ocumentLin k) > 0" > | |||||
1154 | <!-- R esolve lin k --> | |||||
1155 | <!-- --> | |||||
1156 | <xsl:v ariable na me="VarRes olvedLinkI nfoAsXML"> | |||||
1157 | <xsl: call-templ ate name=" Links-Reso lve"> | |||||
1158 | <xsl :with-para m name="Pa ramAllowBa ggage" sel ect="$Para meterAllow Baggage" / > | |||||
1159 | <xsl :with-para m name="Pa ramAllowGr oupToGroup " select=" $Parameter AllowGroup ToGroup" / > | |||||
1160 | <xsl :with-para m name="Pa ramAllowUR L" select= "$Paramete rAllowURL" /> | |||||
1161 | <xsl :with-para m name="Pa ramBaggage SplitFileT ype" selec t="$Parame terBaggage SplitFileT ype" /> | |||||
1162 | <xsl :with-para m name="Pa ramProject " select=" $GlobalPro ject" /> | |||||
1163 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
1164 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
1165 | <xsl :with-para m name="Pa ramSplitGr oupID" sel ect="$Para mSplit/@gr oupID" /> | |||||
1166 | <xsl :with-para m name="Pa ramSplitDo cumentID" select="$P aramSplit/ @documentI D" /> | |||||
1167 | <xsl :with-para m name="Pa ramDocumen tLink" sel ect="$Para mDocumentL ink" /> | |||||
1168 | </xsl :call-temp late> | |||||
1169 | </xsl: variable> | |||||
1170 | <xsl:v ariable na me="VarRes olvedLinkI nfo" selec t="msxsl:n ode-set($V arResolved LinkInfoAs XML)/wwlin ks:Resolve dLink" /> | |||||
1171 | ||||||
1172 | <!-- @ title --> | |||||
1173 | <!-- --> | |||||
1174 | <xsl:i f test="st ring-lengt h($VarReso lvedLinkIn fo/@title) > 0"> | |||||
1175 | <xsl: attribute name="titl e"> | |||||
1176 | <xsl :value-of select="$V arResolved LinkInfo/@ title" /> | |||||
1177 | </xsl :attribute > | |||||
1178 | </xsl: if> | |||||
1179 | ||||||
1180 | <!-- P rocess as Wiki page? --> | |||||
1181 | <!-- --> | |||||
1182 | <xsl:v ariable na me="VarPro cessBaggag eAsWikiPag e" select= "contains( $GlobalPro cessAsPage Extensions , concat(' ', wwfile system:Get Extension( VarResolve dLinkInfo/ @path), ' '))" /> | |||||
1183 | ||||||
1184 | <xsl:c hoose> | |||||
1185 | <!-- Baggage -- > | |||||
1186 | <!-- -- > | |||||
1187 | <xsl: when test= "($VarReso lvedLinkIn fo/@type = 'baggage' ) and not( $VarProces sBaggageAs WikiPage)" > | |||||
1188 | <xsl :variable name="VarR elativePat h" select= "wwuri:Get RelativeTo ($VarResol vedLinkInf o/@path, $ ParamSplit /@path)" / > | |||||
1189 | ||||||
1190 | <xsl :attribute name="hre f"> | |||||
1191 | <xs l:text>att achment:.. /</xsl:tex t> | |||||
1192 | <xs l:value-of select="$ VarRelativ ePath" /> | |||||
1193 | </xs l:attribut e> | |||||
1194 | ||||||
1195 | <xsl :variable name="VarT arget" sel ect="wwpro jext:GetFo rmatSettin g('baggage -file-targ et')" /> | |||||
1196 | ||||||
1197 | <xsl :if test=" (string-le ngth($VarT arget) > ; 0) and ( $VarTarget != 'none' )"> | |||||
1198 | <xs l:attribut e name="ta rget"> | |||||
1199 | <x sl:value-o f select=" $VarTarget " /> | |||||
1200 | </x sl:attribu te> | |||||
1201 | </xs l:if> | |||||
1202 | </xsl :when> | |||||
1203 | ||||||
1204 | <!-- Document - -> | |||||
1205 | <!-- - -> | |||||
1206 | <xsl: when test= "(($VarRes olvedLinkI nfo/@type = 'baggage ') and ($V arProcessB aggageAsWi kiPage)) o r (($VarRe solvedLink Info/@type = 'docume nt') or ($ VarResolve dLinkInfo/ @type = 'g roup') or ($VarResol vedLinkInf o/@type = 'project') )"> | |||||
1207 | <xsl :attribute name="hre f"> | |||||
1208 | <xs l:variable name="Var RelativePa th"> | |||||
1209 | <x sl:call-te mplate nam e="MoinMoi n-Relative PageLink"> | |||||
1210 | < xsl:with-p aram name= "ParamSour ce" select ="$ParamSp lit/@path" /> | |||||
1211 | < xsl:with-p aram name= "ParamTarg et" select ="$VarReso lvedLinkIn fo/@path" /> | |||||
1212 | </ xsl:call-t emplate> | |||||
1213 | </x sl:variabl e> | |||||
1214 | ||||||
1215 | <xs l:if test= "$VarRelat ivePath != '../'"> | |||||
1216 | <x sl:value-o f select=" $VarRelati vePath" /> | |||||
1217 | </x sl:if> | |||||
1218 | <xs l:if test= "string-le ngth($Para mDocumentL ink/@ancho r) > 0" > | |||||
1219 | <x sl:text>#< /xsl:text> | |||||
1220 | <x sl:value-o f select=" $VarResolv edLinkInfo /@linkid" /> | |||||
1221 | </x sl:if> | |||||
1222 | </xs l:attribut e> | |||||
1223 | </xsl :when> | |||||
1224 | ||||||
1225 | <!-- URL --> | |||||
1226 | <!-- --> | |||||
1227 | <xsl: when test= "$VarResol vedLinkInf o/@type = 'url'"> | |||||
1228 | <xsl :attribute name="hre f"> | |||||
1229 | <xs l:value-of select="$ VarResolve dLinkInfo/ @url" /> | |||||
1230 | </xs l:attribut e> | |||||
1231 | ||||||
1232 | <!-- External URL Target --> | |||||
1233 | <!-- --> | |||||
1234 | <xsl :if test=" not(wwuri: IsFile($Va rResolvedL inkInfo/@u rl))"> | |||||
1235 | <xs l:variable name="Var Target" se lect="wwpr ojext:GetF ormatSetti ng('extern al-url-tar get')" /> | |||||
1236 | ||||||
1237 | <xs l:if test= "(string-l ength($Var Target) &g t; 0) and ($VarTarge t != 'none ')"> | |||||
1238 | <x sl:attribu te name="t arget"> | |||||
1239 | < xsl:value- of select= "$VarTarge t" /> | |||||
1240 | </ xsl:attrib ute> | |||||
1241 | </x sl:if> | |||||
1242 | </xs l:if> | |||||
1243 | </xsl :when> | |||||
1244 | </xsl: choose> | |||||
1245 | </xsl:i f> | |||||
1246 | </xsl:el ement> | |||||
1247 | </xsl:tem plate> | |||||
1248 | ||||||
1249 | ||||||
1250 | <xsl:temp late name= "TextRun"> | |||||
1251 | <xsl:par am name="P aramSplits " /> | |||||
1252 | <xsl:par am name="P aramCargo" /> | |||||
1253 | <xsl:par am name="P aramLinks" /> | |||||
1254 | <xsl:par am name="P aramSplit" /> | |||||
1255 | <xsl:par am name="P aramParagr aphID" /> | |||||
1256 | <xsl:par am name="P aramParagr aphPropert ies" /> | |||||
1257 | <xsl:par am name="P aramUseCha racterStyl es" /> | |||||
1258 | <xsl:par am name="P aramTextRu n" /> | |||||
1259 | <xsl:par am name="P aramPositi on" /> | |||||
1260 | ||||||
1261 | <!-- Get rule --> | |||||
1262 | <!-- --> | |||||
1263 | <xsl:var iable name ="VarRule" select="w wprojext:G etRule('Ch aracter', $ParamText Run/@style name)" /> | |||||
1264 | ||||||
1265 | <!-- Gen erate outp ut? --> | |||||
1266 | <!--- --> | |||||
1267 | <xsl:var iable name ="VarGener ateOutputO ption" sel ect="$VarR ule/wwproj ect:Option s/wwprojec t:Option[@ Name = 'ge nerate-out put']/@Val ue" /> | |||||
1268 | <xsl:var iable name ="VarGener ateOutput" select="( string-len gth($VarGe nerateOutp utOption) = 0) or ($ VarGenerat eOutputOpt ion != 'fa lse')" /> | |||||
1269 | <xsl:if test="$Var GenerateOu tput"> | |||||
1270 | <!-- Pa ss-through ? --> | |||||
1271 | <!-- --> | |||||
1272 | <xsl:va riable nam e="VarPass Through"> | |||||
1273 | <xsl:c all-templa te name="C onditions- PassThroug h"> | |||||
1274 | <xsl: with-param name="Par amConditio ns" select ="$ParamTe xtRun/wwdo c:Conditio ns" /> | |||||
1275 | </xsl: call-templ ate> | |||||
1276 | </xsl:v ariable> | |||||
1277 | ||||||
1278 | <xsl:ch oose> | |||||
1279 | <xsl:w hen test=" $VarPassTh rough = 't rue'"> | |||||
1280 | <xsl: apply-temp lates sele ct="$Param TextRun" m ode="wwmod e:passthro ugh" /> | |||||
1281 | </xsl: when> | |||||
1282 | ||||||
1283 | <xsl:o therwise> | |||||
1284 | <!-- Comment? - -> | |||||
1285 | <!-- - -> | |||||
1286 | <xsl: variable n ame="VarWi kiCommentO ption" sel ect="$VarR ule/wwproj ect:Option s/wwprojec t:Option[@ Name = 'wi ki-comment ']/@Value" /> | |||||
1287 | <xsl: variable n ame="VarWi kiComment" select="$ VarWikiCom mentOption = 'true'" /> | |||||
1288 | ||||||
1289 | <xsl: choose> | |||||
1290 | <!-- Comment - -> | |||||
1291 | <!-- - -> | |||||
1292 | <xsl :when test ="$VarWiki Comment"> | |||||
1293 | <xs l:call-tem plate name ="TextRun- Comment"> | |||||
1294 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
1295 | <x sl:with-pa ram name=" ParamCargo " select=" $ParamCarg o" /> | |||||
1296 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
1297 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
1298 | <x sl:with-pa ram name=" ParamParag raphID" se lect="$Par amParagrap hID" /> | |||||
1299 | <x sl:with-pa ram name=" ParamParag raphProper ties" sele ct="$Param ParagraphP roperties" /> | |||||
1300 | <x sl:with-pa ram name=" ParamUseCh aracterSty les" selec t="$ParamU seCharacte rStyles" / > | |||||
1301 | <x sl:with-pa ram name=" ParamTextR un" select ="$ParamTe xtRun" /> | |||||
1302 | <x sl:with-pa ram name=" ParamRule" select="$ VarRule" / > | |||||
1303 | <x sl:with-pa ram name=" ParamPosit ion" selec t="$ParamP osition" / > | |||||
1304 | </x sl:call-te mplate> | |||||
1305 | </xs l:when> | |||||
1306 | ||||||
1307 | <!-- Normal be havior --> | |||||
1308 | <!-- --> | |||||
1309 | <xsl :otherwise > | |||||
1310 | <xs l:call-tem plate name ="TextRun- Normal"> | |||||
1311 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
1312 | <x sl:with-pa ram name=" ParamCargo " select=" $ParamCarg o" /> | |||||
1313 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
1314 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
1315 | <x sl:with-pa ram name=" ParamParag raphID" se lect="$Par amParagrap hID" /> | |||||
1316 | <x sl:with-pa ram name=" ParamParag raphProper ties" sele ct="$Param ParagraphP roperties" /> | |||||
1317 | <x sl:with-pa ram name=" ParamUseCh aracterSty les" selec t="$ParamU seCharacte rStyles" / > | |||||
1318 | <x sl:with-pa ram name=" ParamTextR un" select ="$ParamTe xtRun" /> | |||||
1319 | <x sl:with-pa ram name=" ParamRule" select="$ VarRule" / > | |||||
1320 | <x sl:with-pa ram name=" ParamPosit ion" selec t="$ParamP osition" / > | |||||
1321 | </x sl:call-te mplate> | |||||
1322 | </xs l:otherwis e> | |||||
1323 | </xsl :choose> | |||||
1324 | </xsl: otherwise> | |||||
1325 | </xsl:c hoose> | |||||
1326 | </xsl:if > | |||||
1327 | </xsl:tem plate> | |||||
1328 | ||||||
1329 | ||||||
1330 | <xsl:temp late name= "TextRun-C omment"> | |||||
1331 | <xsl:par am name="P aramSplits " /> | |||||
1332 | <xsl:par am name="P aramCargo" /> | |||||
1333 | <xsl:par am name="P aramLinks" /> | |||||
1334 | <xsl:par am name="P aramSplit" /> | |||||
1335 | <xsl:par am name="P aramParagr aphID" /> | |||||
1336 | <xsl:par am name="P aramParagr aphPropert ies" /> | |||||
1337 | <xsl:par am name="P aramUseCha racterStyl es" /> | |||||
1338 | <xsl:par am name="P aramTextRu n" /> | |||||
1339 | <xsl:par am name="P aramRule" /> | |||||
1340 | <xsl:par am name="P aramPositi on" /> | |||||
1341 | ||||||
1342 | <!-- Com ment prefi x --> | |||||
1343 | <!-- --> | |||||
1344 | <xsl:tex t>/* </xsl :text> | |||||
1345 | ||||||
1346 | <xsl:cal l-template name="Tex tRun-Norma l"> | |||||
1347 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
1348 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
1349 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
1350 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
1351 | <xsl:wi th-param n ame="Param ParagraphI D" select= "$ParamPar agraphID" /> | |||||
1352 | <xsl:wi th-param n ame="Param ParagraphP roperties" select="$ ParamParag raphProper ties" /> | |||||
1353 | <xsl:wi th-param n ame="Param UseCharact erStyles" select="$P aramUseCha racterStyl es" /> | |||||
1354 | <xsl:wi th-param n ame="Param TextRun" s elect="$Pa ramTextRun " /> | |||||
1355 | <xsl:wi th-param n ame="Param Rule" sele ct="$Param Rule" /> | |||||
1356 | <xsl:wi th-param n ame="Param Position" select="$P aramPositi on" /> | |||||
1357 | </xsl:ca ll-templat e> | |||||
1358 | ||||||
1359 | <!-- Com ment suffi x --> | |||||
1360 | <!-- --> | |||||
1361 | <xsl:tex t> */</xsl :text> | |||||
1362 | </xsl:tem plate> | |||||
1363 | ||||||
1364 | ||||||
1365 | <xsl:temp late name= "TextRun-N ormal"> | |||||
1366 | <xsl:par am name="P aramSplits " /> | |||||
1367 | <xsl:par am name="P aramCargo" /> | |||||
1368 | <xsl:par am name="P aramLinks" /> | |||||
1369 | <xsl:par am name="P aramSplit" /> | |||||
1370 | <xsl:par am name="P aramParagr aphID" /> | |||||
1371 | <xsl:par am name="P aramParagr aphPropert ies" /> | |||||
1372 | <xsl:par am name="P aramUseCha racterStyl es" /> | |||||
1373 | <xsl:par am name="P aramTextRu n" /> | |||||
1374 | <xsl:par am name="P aramRule" /> | |||||
1375 | <xsl:par am name="P aramPositi on" /> | |||||
1376 | ||||||
1377 | <!-- Det ermine pro perties -- > | |||||
1378 | <!-- -- > | |||||
1379 | <xsl:var iable name ="VarPrope rtiesAsXML "> | |||||
1380 | <xsl:ch oose> | |||||
1381 | <!-- H andle char acter styl e --> | |||||
1382 | <!-- --> | |||||
1383 | <xsl:w hen test=" ($ParamUse CharacterS tyles) and ((string- length($Pa ramTextRun /@stylenam e) > 0) or (count ($ParamTex tRun/wwdoc :Style) = 1))"> | |||||
1384 | <!-- Get overri de rule -- > | |||||
1385 | <!-- -- > | |||||
1386 | <xsl: variable n ame="VarCo ntextRule" select="w wprojext:G etContextR ule('Chara cter', $Pa ramTextRun /@stylenam e, $ParamS plit/@docu mentID, $P aramTextRu n/@id)" /> | |||||
1387 | ||||||
1388 | <!-- Resolve pr oject prop erties --> | |||||
1389 | <!-- --> | |||||
1390 | <xsl: variable n ame="VarRe solvedProp ertiesAsXM L"> | |||||
1391 | <xsl :call-temp late name= "Propertie s-ResolveC ontextRule "> | |||||
1392 | <xs l:with-par am name="P aramDocume ntContext" select="$ ParamTextR un" /> | |||||
1393 | <xs l:with-par am name="P aramProper ties" sele ct="$VarCo ntextRule/ wwproject: Properties /wwproject :Property | $ParamPa ragraphPro perties" / > | |||||
1394 | <xs l:with-par am name="P aramStyleN ame" selec t="$ParamT extRun/@st ylename" / > | |||||
1395 | <xs l:with-par am name="P aramStyleT ype" selec t="'Charac ter'" /> | |||||
1396 | <xs l:with-par am name="P aramContex tStyle" se lect="$Par amTextRun/ wwdoc:Styl e" /> | |||||
1397 | </xs l:call-tem plate> | |||||
1398 | </xsl :variable> | |||||
1399 | <xsl: variable n ame="VarRe solvedProp erties" se lect="msxs l:node-set ($VarResol vedPropert iesAsXML)/ wwproject: Property" /> | |||||
1400 | ||||||
1401 | <!-- Emit uniqu e properti es --> | |||||
1402 | <!-- --> | |||||
1403 | <xsl: for-each s elect="$Va rResolvedP roperties" > | |||||
1404 | <xsl :variable name="VarR esolvedPro perty" sel ect="." /> | |||||
1405 | ||||||
1406 | <xsl :copy-of s elect="$Va rResolvedP roperty" / > | |||||
1407 | </xsl :for-each> | |||||
1408 | <xsl: for-each s elect="$Pa ramParagra phProperti es"> | |||||
1409 | <xsl :variable name="VarP aragraphPr operty" se lect="." / > | |||||
1410 | ||||||
1411 | <xsl :if test=" count($Var ResolvedPr operties[@ Name = $Va rParagraph Property/@ Name]) = 0 "> | |||||
1412 | <xs l:copy-of select="$V arParagrap hProperty" /> | |||||
1413 | </xs l:if> | |||||
1414 | </xsl :for-each> | |||||
1415 | </xsl: when> | |||||
1416 | ||||||
1417 | <!-- H andle para graph styl e --> | |||||
1418 | <!-- --> | |||||
1419 | <xsl:w hen test=" count($Par amParagrap hPropertie s[1]) > 0"> | |||||
1420 | <xsl: for-each s elect="$Pa ramParagra phProperti es"> | |||||
1421 | <xsl :variable name="VarP aragraphPr operty" se lect="." / > | |||||
1422 | ||||||
1423 | <xsl :copy-of s elect="$Va rParagraph Property" /> | |||||
1424 | </xsl :for-each> | |||||
1425 | </xsl: when> | |||||
1426 | </xsl:c hoose> | |||||
1427 | </xsl:va riable> | |||||
1428 | <xsl:var iable name ="VarPrope rties" sel ect="msxsl :node-set( $VarProper tiesAsXML) /wwproject :Property" /> | |||||
1429 | ||||||
1430 | <xsl:cho ose> | |||||
1431 | <!-- Ha ndle prope rties --> | |||||
1432 | <!-- --> | |||||
1433 | <xsl:wh en test="c ount($VarP roperties[ 1]) > 0 "> | |||||
1434 | <!-- E mit style prefix --> | |||||
1435 | <!-- --> | |||||
1436 | <xsl:c all-templa te name="M oinMoin-St yle-Prefix "> | |||||
1437 | <xsl: with-param name="Par amProperti es" select ="$VarProp erties" /> | |||||
1438 | </xsl: call-templ ate> | |||||
1439 | ||||||
1440 | <!-- H andle pass through ca ses --> | |||||
1441 | <!-- --> | |||||
1442 | <xsl:v ariable na me="VarUse Passthroug hAsText"> | |||||
1443 | <xsl: call-templ ate name=" MoinMoin-S tyle-UsePa ssthrough" > | |||||
1444 | <xsl :with-para m name="Pa ramPropert ies" selec t="$VarPro perties" / > | |||||
1445 | </xsl :call-temp late> | |||||
1446 | </xsl: variable> | |||||
1447 | <xsl:v ariable na me="VarUse Passthroug h" select= "$VarUsePa ssthroughA sText = 't rue'" /> | |||||
1448 | <xsl:c hoose> | |||||
1449 | <!-- Passthroug h --> | |||||
1450 | <!-- --> | |||||
1451 | <xsl: when test= "$VarUsePa ssthrough" > | |||||
1452 | <xsl :apply-tem plates sel ect="$Para mTextRun" mode="wwmo de:passthr ough" /> | |||||
1453 | </xsl :when> | |||||
1454 | ||||||
1455 | <!-- Normal --> | |||||
1456 | <!-- --> | |||||
1457 | <xsl: otherwise> | |||||
1458 | <xsl :call-temp late name= "TextRunCh ildren"> | |||||
1459 | <xs l:with-par am name="P aramSplits " select=" $ParamSpli ts" /> | |||||
1460 | <xs l:with-par am name="P aramCargo" select="$ ParamCargo " /> | |||||
1461 | <xs l:with-par am name="P aramLinks" select="$ ParamLinks " /> | |||||
1462 | <xs l:with-par am name="P aramSplit" select="$ ParamSplit " /> | |||||
1463 | <xs l:with-par am name="P aramParagr aphID" sel ect="$Para mParagraph ID" /> | |||||
1464 | <xs l:with-par am name="P aramTextRu n" select= "$ParamTex tRun" /> | |||||
1465 | <xs l:with-par am name="P aramPositi on" select ="$ParamPo sition" /> | |||||
1466 | </xs l:call-tem plate> | |||||
1467 | </xsl :otherwise > | |||||
1468 | </xsl: choose> | |||||
1469 | ||||||
1470 | <!-- E mit style suffix --> | |||||
1471 | <!-- --> | |||||
1472 | <xsl:c all-templa te name="M oinMoin-St yle-Suffix "> | |||||
1473 | <xsl: with-param name="Par amProperti es" select ="$VarProp erties" /> | |||||
1474 | </xsl: call-templ ate> | |||||
1475 | </xsl:w hen> | |||||
1476 | ||||||
1477 | <!-- No style --> | |||||
1478 | <!-- --> | |||||
1479 | <xsl:ot herwise> | |||||
1480 | <xsl:c all-templa te name="T extRunChil dren"> | |||||
1481 | <xsl: with-param name="Par amSplits" select="$P aramSplits " /> | |||||
1482 | <xsl: with-param name="Par amCargo" s elect="$Pa ramCargo" /> | |||||
1483 | <xsl: with-param name="Par amLinks" s elect="$Pa ramLinks" /> | |||||
1484 | <xsl: with-param name="Par amSplit" s elect="$Pa ramSplit" /> | |||||
1485 | <xsl: with-param name="Par amParagrap hID" selec t="$ParamP aragraphID " /> | |||||
1486 | <xsl: with-param name="Par amTextRun" select="$ ParamTextR un" /> | |||||
1487 | <xsl: with-param name="Par amPosition " select=" $ParamPosi tion" /> | |||||
1488 | </xsl: call-templ ate> | |||||
1489 | </xsl:o therwise> | |||||
1490 | </xsl:ch oose> | |||||
1491 | </xsl:tem plate> | |||||
1492 | ||||||
1493 | ||||||
1494 | <xsl:temp late name= "TextRunCh ildren"> | |||||
1495 | <xsl:par am name="P aramSplits " /> | |||||
1496 | <xsl:par am name="P aramCargo" /> | |||||
1497 | <xsl:par am name="P aramLinks" /> | |||||
1498 | <xsl:par am name="P aramSplit" /> | |||||
1499 | <xsl:par am name="P aramParagr aphID" /> | |||||
1500 | <xsl:par am name="P aramTextRu n" /> | |||||
1501 | <xsl:par am name="P aramPositi on" /> | |||||
1502 | ||||||
1503 | <!-- For ce anchor on same li ne as cont aining spa n --> | |||||
1504 | <!-- --> | |||||
1505 | <wwexsld oc:NoBreak /> | |||||
1506 | ||||||
1507 | <!-- Lin k? --> | |||||
1508 | <!-- --> | |||||
1509 | <xsl:var iable name ="VarLinkI nfoAsXML"> | |||||
1510 | <xsl:ca ll-templat e name="Li nkInfo"> | |||||
1511 | <xsl:w ith-param name="Para mSplits" s elect="$Pa ramSplits" /> | |||||
1512 | <xsl:w ith-param name="Para mLinks" se lect="$Par amLinks" / > | |||||
1513 | <xsl:w ith-param name="Para mSplit" se lect="$Par amSplit" / > | |||||
1514 | <xsl:w ith-param name="Para mDocumentL ink" selec t="$ParamT extRun/wwd oc:Link" / > | |||||
1515 | </xsl:c all-templa te> | |||||
1516 | </xsl:va riable> | |||||
1517 | <xsl:var iable name ="VarLinkI nfo" selec t="msxsl:n ode-set($V arLinkInfo AsXML)/wwl inks:LinkI nfo" /> | |||||
1518 | ||||||
1519 | <!-- Han dle links and first textrun an chor --> | |||||
1520 | <!-- --> | |||||
1521 | <xsl:cho ose> | |||||
1522 | <xsl:wh en test="s tring-leng th($VarLin kInfo/@hre f) > 0" > | |||||
1523 | <xsl:t ext>[[</xs l:text> | |||||
1524 | <xsl:v alue-of se lect="$Var LinkInfo/@ href" /> | |||||
1525 | <xsl:t ext>|</xsl :text> | |||||
1526 | ||||||
1527 | <!-- L ink text - -> | |||||
1528 | <!-- - -> | |||||
1529 | <xsl:a pply-templ ates selec t="$ParamT extRun" mo de="wwmode :linktext" /> | |||||
1530 | ||||||
1531 | <!-- L ink option s --> | |||||
1532 | <!-- --> | |||||
1533 | <xsl:v ariable na me="VarLin kOptions"> | |||||
1534 | <xsl: if test="s tring-leng th($VarLin kInfo/@tit le) > 0 "> | |||||
1535 | <xsl :text>titl e="</ xsl:text> | |||||
1536 | <xsl :value-of select="$V arLinkInfo /@title" / > | |||||
1537 | <xsl :text>&quo t;,</xsl:t ext> | |||||
1538 | </xsl :if> | |||||
1539 | <xsl: if test="s tring-leng th($VarLin kInfo/@tar get) > 0"> | |||||
1540 | <xsl :text>targ et="< /xsl:text> | |||||
1541 | <xsl :value-of select="$V arLinkInfo /@target" /> | |||||
1542 | <xsl :text>&quo t;,</xsl:t ext> | |||||
1543 | </xsl :if> | |||||
1544 | </xsl: variable> | |||||
1545 | <xsl:i f test="st ring-lengt h($VarLink Options) & gt; 0"> | |||||
1546 | <xsl: text>|</xs l:text> | |||||
1547 | <xsl: value-of s elect="$Va rLinkOptio ns" /> | |||||
1548 | </xsl: if> | |||||
1549 | ||||||
1550 | <xsl:t ext>]]</xs l:text> | |||||
1551 | </xsl:w hen> | |||||
1552 | ||||||
1553 | <xsl:ot herwise> | |||||
1554 | <xsl:a pply-templ ates selec t="$ParamT extRun/*" mode="wwmo de:textrun "> | |||||
1555 | <xsl: with-param name="Par amSplits" select="$P aramSplits " /> | |||||
1556 | <xsl: with-param name="Par amCargo" s elect="$Pa ramCargo" /> | |||||
1557 | <xsl: with-param name="Par amLinks" s elect="$Pa ramLinks" /> | |||||
1558 | <xsl: with-param name="Par amSplit" s elect="$Pa ramSplit" /> | |||||
1559 | </xsl: apply-temp lates> | |||||
1560 | </xsl:o therwise> | |||||
1561 | </xsl:ch oose> | |||||
1562 | ||||||
1563 | <!-- For ce anchor on same li ne as cont aining spa n --> | |||||
1564 | <!-- --> | |||||
1565 | <wwexsld oc:NoBreak /> | |||||
1566 | </xsl:tem plate> | |||||
1567 | ||||||
1568 | ||||||
1569 | <xsl:temp late match ="wwdoc:No te" mode=" wwmode:tex trun"> | |||||
1570 | <xsl:par am name="P aramSplits " /> | |||||
1571 | <xsl:par am name="P aramCargo" /> | |||||
1572 | <xsl:par am name="P aramLinks" /> | |||||
1573 | <xsl:par am name="P aramSplit" /> | |||||
1574 | ||||||
1575 | <xsl:var iable name ="VarConte xt" select ="." /> | |||||
1576 | ||||||
1577 | <!-- Imp lement not es --> | |||||
1578 | <!-- --> | |||||
1579 | <xsl:for -each sele ct="$Param Cargo/wwno tes:NoteNu mbering[1] "> | |||||
1580 | <xsl:va riable nam e="VarNote Number" se lect="key( 'wwnotes-n otes-by-id ', $VarCon text/@id)/ @number" / > | |||||
1581 | ||||||
1582 | <!-- Fo otnote num ber --> | |||||
1583 | <!-- --> | |||||
1584 | <wwexsl doc:Text d isable-out put-escapi ng="yes">& lt;<Anc hor(wwfoot note_inlin e_<xsl:val ue-of sele ct="$VarCo ntext/@id" />)>&g t;</wwexsl doc:Text> | |||||
1585 | <xsl:te xt>[[#</xs l:text> | |||||
1586 | <xsl:va lue-of sel ect="$VarC ontext/@id " /> | |||||
1587 | <xsl:te xt>|</xsl: text> | |||||
1588 | <xsl:va lue-of sel ect="$VarN oteNumber" /> | |||||
1589 | <xsl:te xt>]]</xsl :text> | |||||
1590 | </xsl:fo r-each> | |||||
1591 | </xsl:tem plate> | |||||
1592 | ||||||
1593 | ||||||
1594 | <xsl:temp late match ="wwdoc:Li neBreak" m ode="wwmod e:textrun" > | |||||
1595 | <xsl:par am name="P aramSplits " /> | |||||
1596 | <xsl:par am name="P aramCargo" /> | |||||
1597 | <xsl:par am name="P aramLinks" /> | |||||
1598 | <xsl:par am name="P aramSplit" /> | |||||
1599 | ||||||
1600 | <xsl:tex t><< BR>> </xsl:text > | |||||
1601 | </xsl:tem plate> | |||||
1602 | ||||||
1603 | ||||||
1604 | <xsl:temp late match ="wwdoc:In dexMarker" mode="wwm ode:textru n"> | |||||
1605 | <xsl:par am name="P aramSplits " /> | |||||
1606 | <xsl:par am name="P aramCargo" /> | |||||
1607 | <xsl:par am name="P aramLinks" /> | |||||
1608 | <xsl:par am name="P aramSplit" /> | |||||
1609 | ||||||
1610 | <!-- Ign ore index markers -- > | |||||
1611 | <!-- -- > | |||||
1612 | </xsl:tem plate> | |||||
1613 | ||||||
1614 | ||||||
1615 | <xsl:temp late match ="wwdoc:Ma rker" mode ="wwmode:t extrun"> | |||||
1616 | <xsl:par am name="P aramSplits " /> | |||||
1617 | <xsl:par am name="P aramCargo" /> | |||||
1618 | <xsl:par am name="P aramLinks" /> | |||||
1619 | <xsl:par am name="P aramSplit" /> | |||||
1620 | ||||||
1621 | <!-- Ign ore marker s --> | |||||
1622 | <!-- --> | |||||
1623 | </xsl:tem plate> | |||||
1624 | ||||||
1625 | ||||||
1626 | <xsl:temp late match ="wwdoc:Te xt" mode=" wwmode:tex trun"> | |||||
1627 | <xsl:par am name="P aramText" select="." /> | |||||
1628 | <xsl:par am name="P aramSplits " /> | |||||
1629 | <xsl:par am name="P aramCargo" /> | |||||
1630 | <xsl:par am name="P aramLinks" /> | |||||
1631 | <xsl:par am name="P aramSplit" /> | |||||
1632 | ||||||
1633 | <xsl:cal l-template name="Moi nMoin-Esca peParagrap hText"> | |||||
1634 | <xsl:wi th-param n ame="Param Text" sele ct="$Param Text/@valu e" /> | |||||
1635 | </xsl:ca ll-templat e> | |||||
1636 | </xsl:tem plate> | |||||
1637 | ||||||
1638 | ||||||
1639 | <xsl:temp late match ="wwdoc:Ta ble" mode= "wwmode:co ntent"> | |||||
1640 | <xsl:par am name="P aramSplits " /> | |||||
1641 | <xsl:par am name="P aramCargo" /> | |||||
1642 | <xsl:par am name="P aramLinks" /> | |||||
1643 | <xsl:par am name="P aramTOCDat a" /> | |||||
1644 | <xsl:par am name="P aramSplit" /> | |||||
1645 | ||||||
1646 | <xsl:var iable name ="VarTable " select=" ." /> | |||||
1647 | ||||||
1648 | <!-- Abo rted? --> | |||||
1649 | <!-- --> | |||||
1650 | <xsl:if test="not( wwprogress :Abort())" > | |||||
1651 | <xsl:va riable nam e="VarCont extRule" s elect="wwp rojext:Get ContextRul e('Table', $VarTable /@stylenam e, $ParamS plit/@docu mentID, $V arTable/@i d)" /> | |||||
1652 | <xsl:va riable nam e="VarGene rateOutput Option" se lect="$Var ContextRul e/wwprojec t:Options/ wwproject: Option[@Na me = 'gene rate-outpu t']/@Value " /> | |||||
1653 | <xsl:va riable nam e="VarGene rateOutput " select=" (string-le ngth($VarG enerateOut putOption) = 0) or ( $VarGenera teOutputOp tion != 'f alse')" /> | |||||
1654 | <xsl:if test="$Va rGenerateO utput"> | |||||
1655 | ||||||
1656 | <!-- G et behavio r --> | |||||
1657 | <!-- --> | |||||
1658 | <xsl:f or-each se lect="$Par amCargo/ww behaviors: Behaviors[ 1]"> | |||||
1659 | <xsl: variable n ame="VarTa bleBehavio r" select= "key('wwbe haviors-ta bles-by-id ', $VarTab le/@id)[1] " /> | |||||
1660 | ||||||
1661 | <xsl: variable n ame="VarIn TablePage" select="c ount($Para mCargo/wwb ehaviors:T ablePage) > 0" /> | |||||
1662 | <xsl: choose> | |||||
1663 | <!-- Table Cel l Content --> | |||||
1664 | <!-- --> | |||||
1665 | <xsl :when test ="$VarInTa blePage"> | |||||
1666 | <xs l:call-tem plate name ="Table-Ce ll-Content "> | |||||
1667 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
1668 | <x sl:with-pa ram name=" ParamCargo " select=" $ParamCarg o" /> | |||||
1669 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
1670 | <x sl:with-pa ram name=" ParamTOCDa ta" select ="$ParamTO CData" /> | |||||
1671 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
1672 | <x sl:with-pa ram name=" ParamTable " select=" $VarTable" /> | |||||
1673 | <x sl:with-pa ram name=" ParamStyle Name" sele ct="$VarTa ble/@style name" /> | |||||
1674 | <x sl:with-pa ram name=" ParamConte xtRule" se lect="$Var ContextRul e" /> | |||||
1675 | <x sl:with-pa ram name=" ParamTable Behavior" select="$V arTableBeh avior" /> | |||||
1676 | </x sl:call-te mplate> | |||||
1677 | </xs l:when> | |||||
1678 | ||||||
1679 | <!-- Table Str ucture --> | |||||
1680 | <!-- --> | |||||
1681 | <xsl :otherwise > | |||||
1682 | <xs l:call-tem plate name ="Table-St ructure"> | |||||
1683 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
1684 | <x sl:with-pa ram name=" ParamCargo " select=" $ParamCarg o" /> | |||||
1685 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
1686 | <x sl:with-pa ram name=" ParamTOCDa ta" select ="$ParamTO CData" /> | |||||
1687 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
1688 | <x sl:with-pa ram name=" ParamTable " select=" $VarTable" /> | |||||
1689 | <x sl:with-pa ram name=" ParamStyle Name" sele ct="$VarTa ble/@style name" /> | |||||
1690 | <x sl:with-pa ram name=" ParamConte xtRule" se lect="$Var ContextRul e" /> | |||||
1691 | <x sl:with-pa ram name=" ParamTable Behavior" select="$V arTableBeh avior" /> | |||||
1692 | </x sl:call-te mplate> | |||||
1693 | </xs l:otherwis e> | |||||
1694 | </xsl :choose> | |||||
1695 | </xsl: for-each> | |||||
1696 | </xsl:i f> | |||||
1697 | </xsl:if > | |||||
1698 | </xsl:tem plate> | |||||
1699 | ||||||
1700 | ||||||
1701 | <xsl:temp late name= "Table-Cel l-Content" > | |||||
1702 | <xsl:par am name="P aramSplits " /> | |||||
1703 | <xsl:par am name="P aramCargo" /> | |||||
1704 | <xsl:par am name="P aramLinks" /> | |||||
1705 | <xsl:par am name="P aramTOCDat a" /> | |||||
1706 | <xsl:par am name="P aramSplit" /> | |||||
1707 | <xsl:par am name="P aramTable" /> | |||||
1708 | <xsl:par am name="P aramStyleN ame" /> | |||||
1709 | <xsl:par am name="P aramContex tRule" /> | |||||
1710 | <xsl:par am name="P aramTableB ehavior" / > | |||||
1711 | ||||||
1712 | <!-- Not es --> | |||||
1713 | <!-- --> | |||||
1714 | <xsl:var iable name ="VarNotes " select=" $ParamTabl e//wwdoc:N ote[not(an cestor::ww doc:Frame) ]" /> | |||||
1715 | ||||||
1716 | <!-- Not e numberin g --> | |||||
1717 | <!-- --> | |||||
1718 | <xsl:var iable name ="VarNoteN umberingAs XML"> | |||||
1719 | <xsl:ca ll-templat e name="No tes-Number "> | |||||
1720 | <xsl:w ith-param name="Para mNotes" se lect="$Var Notes" /> | |||||
1721 | </xsl:c all-templa te> | |||||
1722 | </xsl:va riable> | |||||
1723 | <xsl:var iable name ="VarNoteN umbering" select="ms xsl:node-s et($VarNot eNumbering AsXML)" /> | |||||
1724 | ||||||
1725 | <!-- Car go for rec ursion --> | |||||
1726 | <!-- --> | |||||
1727 | <xsl:var iable name ="VarCargo " select=" $ParamCarg o/*[local- name() != 'NoteNumbe ring']/.. | $VarNote Numbering" /> | |||||
1728 | ||||||
1729 | <!-- Pro cess table sections --> | |||||
1730 | <!-- --> | |||||
1731 | <xsl:for -each sele ct="$Param Table/wwdo c:TableHea d | $Param Table/wwdo c:TableBod y | $Param Table/wwdo c:TableFoo t"> | |||||
1732 | <xsl:va riable nam e="VarSect ion" selec t="." /> | |||||
1733 | ||||||
1734 | <!-- Pr ocess sect ion rows - -> | |||||
1735 | <!-- - -> | |||||
1736 | <xsl:fo r-each sel ect="$VarS ection/wwd oc:TableRo w"> | |||||
1737 | <xsl:v ariable na me="VarTab leRow" sel ect="." /> | |||||
1738 | ||||||
1739 | <!-- P rocess row cells --> | |||||
1740 | <!-- --> | |||||
1741 | <xsl:f or-each se lect="$Var TableRow/w wdoc:Table Cell"> | |||||
1742 | <xsl: variable n ame="VarTa bleCell" s elect="." /> | |||||
1743 | ||||||
1744 | <!-- Mark cell content st art --> | |||||
1745 | <!-- --> | |||||
1746 | <xsl: text>WEBWO RKS_CELL_C ONTENT_STA RT_</xsl:t ext> | |||||
1747 | <xsl: value-of s elect="$Va rTableCell /@id" /> | |||||
1748 | <xsl: text> | |||||
1749 | </xsl:text > | |||||
1750 | ||||||
1751 | <!-- Process ce ll content --> | |||||
1752 | <!-- --> | |||||
1753 | <xsl: apply-temp lates sele ct="$VarTa bleCell/*" mode="wwm ode:conten t"> | |||||
1754 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
1755 | <xsl :with-para m name="Pa ramCargo" select="$V arCargo" / > | |||||
1756 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
1757 | <xsl :with-para m name="Pa ramTOCData " select=" $ParamTOCD ata" /> | |||||
1758 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
1759 | </xsl :apply-tem plates> | |||||
1760 | ||||||
1761 | <!-- Mark cell content en d --> | |||||
1762 | <!-- --> | |||||
1763 | <xsl: text>WEBWO RKS_CELL_C ONTENT_END _</xsl:tex t> | |||||
1764 | <xsl: value-of s elect="$Va rTableCell /@id" /> | |||||
1765 | <xsl: text> | |||||
1766 | </xsl:text > | |||||
1767 | </xsl: for-each> | |||||
1768 | </xsl:f or-each> | |||||
1769 | </xsl:fo r-each> | |||||
1770 | ||||||
1771 | <!-- Tab le Footnot es --> | |||||
1772 | <!-- --> | |||||
1773 | <xsl:if test="coun t($VarNote s) > 0" > | |||||
1774 | <!-- Ma rk table f ootnotes s tart --> | |||||
1775 | <!-- --> | |||||
1776 | <xsl:te xt>WEBWORK S_TABLE_FO OTNOTES_ST ART_</xsl: text> | |||||
1777 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
1778 | <xsl:te xt> | |||||
1779 | </xsl:text > | |||||
1780 | ||||||
1781 | <xsl:ca ll-templat e name="Co ntent-Note s"> | |||||
1782 | <xsl:w ith-param name="Para mNotes" se lect="$Var Notes" /> | |||||
1783 | <xsl:w ith-param name="Para mSplits" s elect="$Pa ramSplits" /> | |||||
1784 | <xsl:w ith-param name="Para mCargo" se lect="$Var Cargo" /> | |||||
1785 | <xsl:w ith-param name="Para mLinks" se lect="$Par amLinks" / > | |||||
1786 | <xsl:w ith-param name="Para mTOCData" select="$P aramTOCDat a" /> | |||||
1787 | <xsl:w ith-param name="Para mSplit" se lect="$Par amSplit" / > | |||||
1788 | </xsl:c all-templa te> | |||||
1789 | ||||||
1790 | <!-- Ma rk table f ootnotes e nd --> | |||||
1791 | <!-- --> | |||||
1792 | <xsl:te xt>WEBWORK S_TABLE_FO OTNOTES_EN D_</xsl:te xt> | |||||
1793 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
1794 | <xsl:te xt> | |||||
1795 | </xsl:text > | |||||
1796 | </xsl:if > | |||||
1797 | ||||||
1798 | <!-- Cap tion --> | |||||
1799 | <!-- --> | |||||
1800 | <xsl:for -each sele ct="$Param Table/wwdo c:Caption[ 1]"> | |||||
1801 | <xsl:va riable nam e="VarCapt ion" selec t="." /> | |||||
1802 | ||||||
1803 | <!-- Ma rk caption content s tart --> | |||||
1804 | <!-- --> | |||||
1805 | <xsl:te xt>WEBWORK S_CAPTION_ CONTENT_ST ART_</xsl: text> | |||||
1806 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
1807 | <xsl:te xt> | |||||
1808 | </xsl:text > | |||||
1809 | ||||||
1810 | <xsl:ap ply-templa tes select ="$VarCapt ion/*" mod e="wwmode: content"> | |||||
1811 | <xsl:w ith-param name="Para mSplits" s elect="$Pa ramSplits" /> | |||||
1812 | <xsl:w ith-param name="Para mCargo" se lect="$Par amCargo" / > | |||||
1813 | <xsl:w ith-param name="Para mLinks" se lect="$Par amLinks" / > | |||||
1814 | <xsl:w ith-param name="Para mTOCData" select="$P aramTOCDat a" /> | |||||
1815 | <xsl:w ith-param name="Para mSplit" se lect="$Par amSplit" / > | |||||
1816 | </xsl:a pply-templ ates> | |||||
1817 | ||||||
1818 | <!-- Ma rk caption content e nd --> | |||||
1819 | <!-- --> | |||||
1820 | <xsl:te xt>WEBWORK S_CAPTION_ CONTENT_EN D_</xsl:te xt> | |||||
1821 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
1822 | <xsl:te xt> | |||||
1823 | </xsl:text > | |||||
1824 | </xsl:fo r-each> | |||||
1825 | </xsl:tem plate> | |||||
1826 | ||||||
1827 | ||||||
1828 | <xsl:temp late name= "Table-Str ucture"> | |||||
1829 | <xsl:par am name="P aramSplits " /> | |||||
1830 | <xsl:par am name="P aramCargo" /> | |||||
1831 | <xsl:par am name="P aramLinks" /> | |||||
1832 | <xsl:par am name="P aramTOCDat a" /> | |||||
1833 | <xsl:par am name="P aramSplit" /> | |||||
1834 | <xsl:par am name="P aramTable" /> | |||||
1835 | <xsl:par am name="P aramStyleN ame" /> | |||||
1836 | <xsl:par am name="P aramContex tRule" /> | |||||
1837 | <xsl:par am name="P aramTableB ehavior" / > | |||||
1838 | ||||||
1839 | <!-- Det ermine inc lude page path --> | |||||
1840 | <!-- --> | |||||
1841 | <xsl:var iable name ="VarInclu dePagePath "> | |||||
1842 | <xsl:va riable nam e="VarSpli tsTable" s elect="$Pa ramSplit/w wsplits:Ta ble[@id = $ParamTabl e/@id]" /> | |||||
1843 | ||||||
1844 | <xsl:ca ll-templat e name="Mo inMoin-Rel ativePageL ink"> | |||||
1845 | <xsl:w ith-param name="Para mSource" s elect="$Pa ramSplit/@ path" /> | |||||
1846 | <xsl:w ith-param name="Para mTarget" s elect="$Va rSplitsTab le/@path" /> | |||||
1847 | </xsl:c all-templa te> | |||||
1848 | </xsl:va riable> | |||||
1849 | ||||||
1850 | <!-- Not es --> | |||||
1851 | <!-- --> | |||||
1852 | <xsl:var iable name ="VarNotes " select=" $ParamTabl e//wwdoc:N ote[not(an cestor::ww doc:Frame) ]" /> | |||||
1853 | ||||||
1854 | <!-- Not e numberin g --> | |||||
1855 | <!-- --> | |||||
1856 | <xsl:var iable name ="VarNoteN umberingAs XML"> | |||||
1857 | <xsl:ca ll-templat e name="No tes-Number "> | |||||
1858 | <xsl:w ith-param name="Para mNotes" se lect="$Var Notes" /> | |||||
1859 | </xsl:c all-templa te> | |||||
1860 | </xsl:va riable> | |||||
1861 | <xsl:var iable name ="VarNoteN umbering" select="ms xsl:node-s et($VarNot eNumbering AsXML)" /> | |||||
1862 | ||||||
1863 | <!-- Car go for rec ursion --> | |||||
1864 | <!-- --> | |||||
1865 | <xsl:var iable name ="VarCargo " select=" $ParamCarg o/*[local- name() != 'NoteNumbe ring']/.. | $VarNote Numbering" /> | |||||
1866 | ||||||
1867 | <!-- Res olve proje ct propert ies --> | |||||
1868 | <!-- --> | |||||
1869 | <xsl:var iable name ="VarResol vedPropert iesAsXML"> | |||||
1870 | <xsl:ca ll-templat e name="Pr operties-R esolveCont extRule"> | |||||
1871 | <xsl:w ith-param name="Para mDocumentC ontext" se lect="$Par amTable" / > | |||||
1872 | <xsl:w ith-param name="Para mPropertie s" select= "$ParamCon textRule/w wproject:P roperties/ wwproject: Property" /> | |||||
1873 | <xsl:w ith-param name="Para mStyleName " select=" $ParamTabl e/@stylena me" /> | |||||
1874 | <xsl:w ith-param name="Para mStyleType " select=" 'Table'" / > | |||||
1875 | <xsl:w ith-param name="Para mContextSt yle" selec t="$ParamT able/wwdoc :Style" /> | |||||
1876 | </xsl:c all-templa te> | |||||
1877 | </xsl:va riable> | |||||
1878 | <xsl:var iable name ="VarResol vedPropert ies" selec t="msxsl:n ode-set($V arResolved Properties AsXML)/wwp roject:Pro perty" /> | |||||
1879 | ||||||
1880 | <!-- CSS propertie s --> | |||||
1881 | <!-- --> | |||||
1882 | <xsl:var iable name ="VarCSSPr opertiesAs XML"> | |||||
1883 | <xsl:ca ll-templat e name="CS S-Translat eProjectPr operties"> | |||||
1884 | <xsl:w ith-param name="Para mPropertie s" select= "$VarResol vedPropert ies" /> | |||||
1885 | <xsl:w ith-param name="Para mFromAbsol uteURI" se lect="$Par amSplit/@p ath" /> | |||||
1886 | <xsl:w ith-param name="Para mSplits" s elect="$Pa ramSplits" /> | |||||
1887 | </xsl:c all-templa te> | |||||
1888 | </xsl:va riable> | |||||
1889 | <xsl:var iable name ="VarCSSPr operties" select="ms xsl:node-s et($VarCSS Properties AsXML)/wwp roject:Pro perty" /> | |||||
1890 | ||||||
1891 | <!-- Tab le class - -> | |||||
1892 | <!-- - -> | |||||
1893 | <xsl:var iable name ="VarClass Attribute" > | |||||
1894 | <!-- Ad ditional C SS classes --> | |||||
1895 | <!-- --> | |||||
1896 | <xsl:va riable nam e="VarAddi tionalCSSC lassesOpti on" select ="normaliz e-space($P aramContex tRule/wwpr oject:Opti ons/wwproj ect:Option [@Name = ' additional -css-class es']/@Valu e)" /> | |||||
1897 | <xsl:if test="str ing-length ($VarAddit ionalCSSCl assesOptio n) > 0" > | |||||
1898 | <xsl:v alue-of se lect="$Var Additional CSSClasses Option" /> | |||||
1899 | </xsl:i f> | |||||
1900 | </xsl:va riable> | |||||
1901 | ||||||
1902 | <!-- Sty le attribu te --> | |||||
1903 | <!-- --> | |||||
1904 | <xsl:var iable name ="VarStyle Attribute" > | |||||
1905 | <xsl:ca ll-templat e name="CS S-InlinePr operties"> | |||||
1906 | <xsl:w ith-param name="Para mPropertie s" select= "$VarCSSPr operties[( @Name != ' vertical-a lign')]" / > | |||||
1907 | </xsl:c all-templa te> | |||||
1908 | </xsl:va riable> | |||||
1909 | ||||||
1910 | <!-- Tab le vertica l alignmen t --> | |||||
1911 | <!-- --> | |||||
1912 | <xsl:var iable name ="VarTable VerticalAl ignment"> | |||||
1913 | <xsl:va riable nam e="VarTabl eVerticalA lignmentHi nt" select ="$VarReso lvedProper ties[@Name = 'vertic al-align'] /@Value" / > | |||||
1914 | <xsl:ch oose> | |||||
1915 | <xsl:w hen test=" string-len gth($VarTa bleVertica lAlignment Hint) > 0"> | |||||
1916 | <xsl: value-of s elect="$Va rTableVert icalAlignm entHint" / > | |||||
1917 | </xsl: when> | |||||
1918 | <xsl:o therwise> | |||||
1919 | <xsl: value-of s elect="''" /> | |||||
1920 | </xsl: otherwise> | |||||
1921 | </xsl:c hoose> | |||||
1922 | </xsl:va riable> | |||||
1923 | ||||||
1924 | <!-- Cap tion Side --> | |||||
1925 | <!-- --> | |||||
1926 | <xsl:var iable name ="VarCapti onSide"> | |||||
1927 | <xsl:va lue-of sel ect="$VarR esolvedPro perties[@N ame = 'cap tion-side' ]/@Value" /> | |||||
1928 | </xsl:va riable> | |||||
1929 | ||||||
1930 | <!-- Det ermine tab le cell wi dths --> | |||||
1931 | <!-- --> | |||||
1932 | <xsl:var iable name ="VarTable CellWidths AsXML"> | |||||
1933 | <xsl:va riable nam e="VarEmit TableWidth sOption" s elect="$Pa ramContext Rule/wwpro ject:Optio ns/wwproje ct:Option[ @Name = 't able-use-d ocument-ce ll-widths' ]/@Value" /> | |||||
1934 | <xsl:va riable nam e="VarEmit TableWidth s" select= "$VarEmitT ableWidths Option = ' true'" /> | |||||
1935 | ||||||
1936 | <xsl:if test="$Va rEmitTable Widths"> | |||||
1937 | <xsl:c all-templa te name="T able-CellW idths"> | |||||
1938 | <xsl: with-param name="Par amTable" s elect="$Pa ramTable" /> | |||||
1939 | </xsl: call-templ ate> | |||||
1940 | </xsl:i f> | |||||
1941 | </xsl:va riable> | |||||
1942 | <xsl:var iable name ="VarTable CellWidths " select=" msxsl:node -set($VarT ableCellWi dthsAsXML) /*" /> | |||||
1943 | ||||||
1944 | <!-- Tab le options --> | |||||
1945 | <!-- --> | |||||
1946 | <xsl:var iable name ="VarTable Options"> | |||||
1947 | <!-- cl ass attrib ute --> | |||||
1948 | <!-- --> | |||||
1949 | <xsl:if test="str ing-length ($VarClass Attribute) > 0"> | |||||
1950 | <xsl:t ext>tablec lass="</xs l:text> | |||||
1951 | <xsl:v alue-of se lect="$Var ClassAttri bute" /> | |||||
1952 | <xsl:t ext>" </xs l:text> | |||||
1953 | </xsl:i f> | |||||
1954 | ||||||
1955 | <!-- st yle attrib ute --> | |||||
1956 | <!-- --> | |||||
1957 | <xsl:if test="str ing-length ($VarStyle Attribute) > 0"> | |||||
1958 | <xsl:t ext>tables tyle="</xs l:text> | |||||
1959 | <xsl:v alue-of se lect="$Var StyleAttri bute" /> | |||||
1960 | <xsl:t ext>" </xs l:text> | |||||
1961 | </xsl:i f> | |||||
1962 | </xsl:va riable> | |||||
1963 | ||||||
1964 | <!-- Cap tion on to p --> | |||||
1965 | <!-- --> | |||||
1966 | <xsl:if test="$Var CaptionSid e = 'top'" > | |||||
1967 | <xsl:ca ll-templat e name="Ta ble-Captio n-Include" > | |||||
1968 | <xsl:w ith-param name="Para mTable" se lect="$Par amTable" / > | |||||
1969 | <xsl:w ith-param name="Para mColumnCou nt" select ="count($V arTableCel lWidths)" /> | |||||
1970 | <xsl:w ith-param name="Para mIncludePa gePath" se lect="$Var IncludePag ePath" /> | |||||
1971 | </xsl:c all-templa te> | |||||
1972 | </xsl:if > | |||||
1973 | ||||||
1974 | <!-- Tab le Structu re --> | |||||
1975 | <!-- --> | |||||
1976 | <xsl:for -each sele ct="$Param Table/wwdo c:TableHea d | $Param Table/wwdo c:TableBod y | $Param Table/wwdo c:TableFoo t"> | |||||
1977 | <xsl:va riable nam e="VarSect ion" selec t="." /> | |||||
1978 | <xsl:va riable nam e="VarSect ionPositio n" select= "position( )" /> | |||||
1979 | ||||||
1980 | <!-- Re solve sect ion proper ties --> | |||||
1981 | <!-- --> | |||||
1982 | <xsl:va riable nam e="VarReso lvedSectio nPropertie sAsXML"> | |||||
1983 | <xsl:c all-templa te name="P roperties- Table-Sect ion-Resolv eContextRu le"> | |||||
1984 | <xsl: with-param name="Par amProperti es" select ="$ParamCo ntextRule/ wwproject: Properties /wwproject :Property" /> | |||||
1985 | <xsl: with-param name="Par amDocument Context" s elect="$Pa ramTable" /> | |||||
1986 | <xsl: with-param name="Par amTable" s elect="$Pa ramTable" /> | |||||
1987 | <xsl: with-param name="Par amSection" select="$ VarSection " /> | |||||
1988 | </xsl: call-templ ate> | |||||
1989 | </xsl:v ariable> | |||||
1990 | <xsl:va riable nam e="VarReso lvedSectio nPropertie s" select= "msxsl:nod e-set($Var ResolvedSe ctionPrope rtiesAsXML )/wwprojec t:Property " /> | |||||
1991 | ||||||
1992 | <!-- Pr ocess sect ion rows - -> | |||||
1993 | <!-- - -> | |||||
1994 | <xsl:fo r-each sel ect="$VarS ection/wwd oc:TableRo w"> | |||||
1995 | <xsl:v ariable na me="VarTab leRow" sel ect="." /> | |||||
1996 | <xsl:v ariable na me="VarRow Position" select="po sition()" /> | |||||
1997 | ||||||
1998 | <!-- R ow --> | |||||
1999 | <!-- --> | |||||
2000 | <xsl:t ext>||</xs l:text> | |||||
2001 | ||||||
2002 | <!-- H andle tabl e level ve rtical ali gn at row level --> | |||||
2003 | <!-- --> | |||||
2004 | <xsl:v ariable na me="VarRow Options"> | |||||
2005 | <xsl: if test="s tring-leng th($VarTab leVertical Alignment) > 0"> | |||||
2006 | <xsl :text>rows tyle="vert ical-align : </xsl:te xt> | |||||
2007 | <xsl :value-of select="$V arTableVer ticalAlign ment" /> | |||||
2008 | <xsl :text>;" < /xsl:text> | |||||
2009 | </xsl :if> | |||||
2010 | </xsl: variable> | |||||
2011 | ||||||
2012 | <!-- P rocess row cells --> | |||||
2013 | <!-- --> | |||||
2014 | <xsl:f or-each se lect="$Var TableRow/w wdoc:Table Cell"> | |||||
2015 | <xsl: variable n ame="VarTa bleCell" s elect="." /> | |||||
2016 | <xsl: variable n ame="VarCe llPosition " select=" position() " /> | |||||
2017 | ||||||
2018 | <!-- Resolve ce ll propert ies --> | |||||
2019 | <!-- --> | |||||
2020 | <xsl: variable n ame="VarRe solvedCell Properties AsXML"> | |||||
2021 | <xsl :call-temp late name= "Propertie s-Table-Ce ll-Resolve Properties "> | |||||
2022 | <xs l:with-par am name="P aramSectio nPropertie s" select= "$VarResol vedSection Properties " /> | |||||
2023 | <xs l:with-par am name="P aramCellSt yle" selec t="$VarTab leCell/wwd oc:Style" /> | |||||
2024 | <xs l:with-par am name="P aramRowInd ex" select ="$VarRowP osition" / > | |||||
2025 | <xs l:with-par am name="P aramColumn Index" sel ect="$VarC ellPositio n" /> | |||||
2026 | </xs l:call-tem plate> | |||||
2027 | ||||||
2028 | <!-- Width att ribute --> | |||||
2029 | <!-- --> | |||||
2030 | <xsl :for-each select="$V arTableCel lWidths[@i d = $VarTa bleCell/@i d][1]"> | |||||
2031 | <xs l:variable name="Var TableCellW idth" sele ct="." /> | |||||
2032 | ||||||
2033 | <ww project:Pr operty Nam e="width" Value="{$V arTableCel lWidth/@wi dth}" /> | |||||
2034 | </xs l:for-each > | |||||
2035 | </xsl :variable> | |||||
2036 | <xsl: variable n ame="VarRe solvedCell Properties " select=" msxsl:node -set($VarR esolvedCel lPropertie sAsXML)/ww project:Pr operty" /> | |||||
2037 | ||||||
2038 | <!-- Valid CSS properties --> | |||||
2039 | <!-- --> | |||||
2040 | <xsl: variable n ame="VarTa bleCellCSS Properties AsXML"> | |||||
2041 | <xsl :call-temp late name= "CSS-Trans lateProjec tPropertie s"> | |||||
2042 | <xs l:with-par am name="P aramProper ties" sele ct="$VarRe solvedCell Properties " /> | |||||
2043 | <xs l:with-par am name="P aramFromAb soluteURI" select="$ ParamSplit /@path" /> | |||||
2044 | <xs l:with-par am name="P aramSplits " select=" $ParamSpli ts" /> | |||||
2045 | </xs l:call-tem plate> | |||||
2046 | </xsl :variable> | |||||
2047 | <xsl: variable n ame="VarTa bleCellCSS Properties " select=" msxsl:node -set($VarT ableCellCS SPropertie sAsXML)/ww project:Pr operty" /> | |||||
2048 | ||||||
2049 | <!-- Inline CSS propertie s --> | |||||
2050 | <!-- --> | |||||
2051 | <xsl: variable n ame="VarIn lineCSSPro perties"> | |||||
2052 | <xsl :call-temp late name= "CSS-Inlin ePropertie s"> | |||||
2053 | <xs l:with-par am name="P aramProper ties" sele ct="$VarTa bleCellCSS Properties " /> | |||||
2054 | </xs l:call-tem plate> | |||||
2055 | </xsl :variable> | |||||
2056 | ||||||
2057 | <!-- Calculate row span - -> | |||||
2058 | <!-- - -> | |||||
2059 | <xsl: variable n ame="VarRo wSpan"> | |||||
2060 | <xsl :variable name="VarR owSpanHint " select=" $VarTableC ell/wwdoc: Style/wwdo c:Attribut e[@name = 'row-span' ]/@value" /> | |||||
2061 | <xsl :choose> | |||||
2062 | <xs l:when tes t="string- length($Va rRowSpanHi nt) > 0 "> | |||||
2063 | <x sl:value-o f select=" $VarRowSpa nHint" /> | |||||
2064 | </x sl:when> | |||||
2065 | <xs l:otherwis e> | |||||
2066 | <x sl:value-o f select=" '0'" /> | |||||
2067 | </x sl:otherwi se> | |||||
2068 | </xs l:choose> | |||||
2069 | </xsl :variable> | |||||
2070 | ||||||
2071 | <!-- Calculate column spa n --> | |||||
2072 | <!-- --> | |||||
2073 | <xsl: variable n ame="VarCo lumnSpan"> | |||||
2074 | <xsl :variable name="VarC olumnSpanH int" selec t="$VarTab leCell/wwd oc:Style/w wdoc:Attri bute[@name = 'column -span']/@v alue" /> | |||||
2075 | <xsl :choose> | |||||
2076 | <xs l:when tes t="string- length($Va rColumnSpa nHint) > ; 0"> | |||||
2077 | <x sl:value-o f select=" $VarColumn SpanHint" /> | |||||
2078 | </x sl:when> | |||||
2079 | <xs l:otherwis e> | |||||
2080 | <x sl:value-o f select=" '0'" /> | |||||
2081 | </x sl:otherwi se> | |||||
2082 | </xs l:choose> | |||||
2083 | </xsl :variable> | |||||
2084 | ||||||
2085 | <!-- Options ex ist? --> | |||||
2086 | <!-- --> | |||||
2087 | <xsl: variable n ame="VarCe llOptionsE xist" sele ct="(numbe r($VarRowS pan) > 0) or (num ber($VarCo lumnSpan) > 0) or (string-l ength($Var InlineCSSP roperties) > 0)" /> | |||||
2088 | <xsl: variable n ame="VarRo wOptionsEx ist" selec t="($VarRo wPosition = 1) and ( string-len gth($VarRo wOptions) > 0)" / > | |||||
2089 | <xsl: variable n ame="VarTa bleOptions Exist" sel ect="($Var SectionPos ition = 1) and ($Var RowPositio n = 1) and ($VarCell Position = 1) and (s tring-leng th($VarTab leOptions) > 0)" /> | |||||
2090 | <xsl: if test="$ VarCellOpt ionsExist or $VarRow OptionsExi st or $Var TableOptio nsExist"> | |||||
2091 | <wwe xsldoc:Tex t disable- output-esc aping="yes "><</ww exsldoc:Te xt> | |||||
2092 | ||||||
2093 | <!-- Row span --> | |||||
2094 | <!-- --> | |||||
2095 | <xsl :if test=" number($Va rRowSpan) > 0"> | |||||
2096 | <xs l:text>|</ xsl:text> | |||||
2097 | <xs l:value-of select="$ VarRowSpan " /> | |||||
2098 | <xs l:text> </ xsl:text> | |||||
2099 | </xs l:if> | |||||
2100 | ||||||
2101 | <!-- Column sp an --> | |||||
2102 | <!-- --> | |||||
2103 | <xsl :if test=" number($Va rColumnSpa n) > 0" > | |||||
2104 | <xs l:text>-</ xsl:text> | |||||
2105 | <xs l:value-of select="$ VarColumnS pan" /> | |||||
2106 | <xs l:text> </ xsl:text> | |||||
2107 | </xs l:if> | |||||
2108 | ||||||
2109 | <!-- Cell Opti ons --> | |||||
2110 | <!-- --> | |||||
2111 | <xsl :if test=" string-len gth($VarIn lineCSSPro perties) & gt; 0"> | |||||
2112 | <xs l:text>sty le="</xsl: text> | |||||
2113 | <xs l:value-of select="$ VarInlineC SSProperti es" /> | |||||
2114 | <xs l:text>" < /xsl:text> | |||||
2115 | </xs l:if> | |||||
2116 | ||||||
2117 | <!-- Row Optio ns --> | |||||
2118 | <!-- --> | |||||
2119 | <xsl :if test=" $VarRowOpt ionsExist" > | |||||
2120 | <xs l:value-of select="$ VarRowOpti ons" /> | |||||
2121 | </xs l:if> | |||||
2122 | ||||||
2123 | <!-- Table Opt ions --> | |||||
2124 | <!-- --> | |||||
2125 | <xsl :if test=" $VarTableO ptionsExis t"> | |||||
2126 | <xs l:value-of select="$ VarTableOp tions" /> | |||||
2127 | </xs l:if> | |||||
2128 | ||||||
2129 | <wwe xsldoc:Tex t disable- output-esc aping="yes ">></ww exsldoc:Te xt> | |||||
2130 | </xsl :if> | |||||
2131 | <xsl: text> </xs l:text> | |||||
2132 | ||||||
2133 | <!-- Include ce ll content --> | |||||
2134 | <!-- --> | |||||
2135 | <wwex sldoc:Text disable-o utput-esca ping="yes" ><<I nclude(</w wexsldoc:T ext> | |||||
2136 | <xsl: value-of s elect="$Va rIncludePa gePath" /> | |||||
2137 | <xsl: text>, , , from="^WE BWORKS_CEL L_CONTENT_ START_</xs l:text> | |||||
2138 | <xsl: value-of s elect="$Va rTableCell /@id" /> | |||||
2139 | <xsl: text>"</xs l:text> | |||||
2140 | <xsl: text>, to= "^WEBWORKS _CELL_CONT ENT_END_</ xsl:text> | |||||
2141 | <xsl: value-of s elect="$Va rTableCell /@id" /> | |||||
2142 | <xsl: text>"</xs l:text> | |||||
2143 | <wwex sldoc:Text disable-o utput-esca ping="yes" >)>> </wwexsldo c:Text> | |||||
2144 | ||||||
2145 | <!-- Cell compl ete --> | |||||
2146 | <!-- --> | |||||
2147 | <xsl: text> ||</ xsl:text> | |||||
2148 | </xsl: for-each> | |||||
2149 | ||||||
2150 | <!-- R ow complet e --> | |||||
2151 | <!-- --> | |||||
2152 | <xsl:t ext> | |||||
2153 | </xsl:text > | |||||
2154 | </xsl:f or-each> | |||||
2155 | </xsl:fo r-each> | |||||
2156 | ||||||
2157 | <!-- Tab le Footnot es --> | |||||
2158 | <!-- --> | |||||
2159 | <xsl:if test="coun t($VarNote s) > 0" > | |||||
2160 | <!-- Sp an table - -> | |||||
2161 | <!-- - -> | |||||
2162 | <xsl:te xt>||</xsl :text> | |||||
2163 | <xsl:if test="cou nt($VarTab leCellWidt hs) > 0 "> | |||||
2164 | <wwexs ldoc:Text disable-ou tput-escap ing="yes"> <</wwex sldoc:Text > | |||||
2165 | <xsl:t ext>-</xsl :text> | |||||
2166 | <xsl:v alue-of se lect="coun t($VarTabl eCellWidth s)" /> | |||||
2167 | <wwexs ldoc:Text disable-ou tput-escap ing="yes"> ></wwex sldoc:Text > | |||||
2168 | </xsl:i f> | |||||
2169 | <xsl:te xt> </xsl: text> | |||||
2170 | ||||||
2171 | <!-- In clude tabl e footnote s --> | |||||
2172 | <!-- --> | |||||
2173 | <wwexsl doc:Text d isable-out put-escapi ng="yes">& lt;<Inc lude(</wwe xsldoc:Tex t> | |||||
2174 | <xsl:va lue-of sel ect="$VarI ncludePage Path" /> | |||||
2175 | <xsl:te xt>, , , f rom="^WEBW ORKS_TABLE _FOOTNOTES _START_</x sl:text> | |||||
2176 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
2177 | <xsl:te xt>"</xsl: text> | |||||
2178 | <xsl:te xt>, to="^ WEBWORKS_T ABLE_FOOTN OTES_END_< /xsl:text> | |||||
2179 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
2180 | <xsl:te xt>"</xsl: text> | |||||
2181 | <wwexsl doc:Text d isable-out put-escapi ng="yes">) >></ wwexsldoc: Text> | |||||
2182 | ||||||
2183 | <!-- En d cell --> | |||||
2184 | <!-- --> | |||||
2185 | <xsl:te xt> || | |||||
2186 | </xsl:text > | |||||
2187 | </xsl:if > | |||||
2188 | ||||||
2189 | <!-- Cap tion on bo ttom --> | |||||
2190 | <!-- --> | |||||
2191 | <xsl:if test="$Var CaptionSid e = 'botto m'"> | |||||
2192 | <xsl:ca ll-templat e name="Ta ble-Captio n-Include" > | |||||
2193 | <xsl:w ith-param name="Para mTable" se lect="$Par amTable" / > | |||||
2194 | <xsl:w ith-param name="Para mColumnCou nt" select ="count($V arTableCel lWidths)" /> | |||||
2195 | <xsl:w ith-param name="Para mIncludePa gePath" se lect="$Var IncludePag ePath" /> | |||||
2196 | </xsl:c all-templa te> | |||||
2197 | </xsl:if > | |||||
2198 | </xsl:tem plate> | |||||
2199 | ||||||
2200 | ||||||
2201 | <xsl:temp late name= "Table-Cap tion-Inclu de"> | |||||
2202 | <xsl:par am name="P aramTable" /> | |||||
2203 | <xsl:par am name="P aramColumn Count" /> | |||||
2204 | <xsl:par am name="P aramInclud ePagePath" /> | |||||
2205 | ||||||
2206 | <!-- Emi t table ca ption incl ude --> | |||||
2207 | <!-- --> | |||||
2208 | <xsl:for -each sele ct="$Param Table/wwdo c:Caption[ 1]"> | |||||
2209 | <!-- Sp an table - -> | |||||
2210 | <!-- - -> | |||||
2211 | <xsl:te xt>||</xsl :text> | |||||
2212 | <xsl:if test="$Pa ramColumnC ount > 0"> | |||||
2213 | <wwexs ldoc:Text disable-ou tput-escap ing="yes"> <</wwex sldoc:Text > | |||||
2214 | <xsl:t ext>-</xsl :text> | |||||
2215 | <xsl:v alue-of se lect="$Par amColumnCo unt" /> | |||||
2216 | <wwexs ldoc:Text disable-ou tput-escap ing="yes"> ></wwex sldoc:Text > | |||||
2217 | </xsl:i f> | |||||
2218 | <xsl:te xt> </xsl: text> | |||||
2219 | ||||||
2220 | <!-- In clude tabl e caption --> | |||||
2221 | <!-- --> | |||||
2222 | <wwexsl doc:Text d isable-out put-escapi ng="yes">& lt;<Inc lude(</wwe xsldoc:Tex t> | |||||
2223 | <xsl:va lue-of sel ect="$Para mIncludePa gePath" /> | |||||
2224 | <xsl:te xt>, , , f rom="^WEBW ORKS_CAPTI ON_CONTENT _START_</x sl:text> | |||||
2225 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
2226 | <xsl:te xt>"</xsl: text> | |||||
2227 | <xsl:te xt>, to="^ WEBWORKS_C APTION_CON TENT_END_< /xsl:text> | |||||
2228 | <xsl:va lue-of sel ect="$Para mTable/@id " /> | |||||
2229 | <xsl:te xt>"</xsl: text> | |||||
2230 | <wwexsl doc:Text d isable-out put-escapi ng="yes">) >></ wwexsldoc: Text> | |||||
2231 | ||||||
2232 | <!-- En d cell --> | |||||
2233 | <!-- --> | |||||
2234 | <xsl:te xt> || | |||||
2235 | </xsl:text > | |||||
2236 | </xsl:fo r-each> | |||||
2237 | </xsl:tem plate> | |||||
2238 | ||||||
2239 | ||||||
2240 | <xsl:temp late match ="wwdoc:Fr ame" mode= "wwmode:co ntent"> | |||||
2241 | <xsl:par am name="P aramSplits " /> | |||||
2242 | <xsl:par am name="P aramCargo" /> | |||||
2243 | <xsl:par am name="P aramLinks" /> | |||||
2244 | <xsl:par am name="P aramTOCDat a" /> | |||||
2245 | <xsl:par am name="P aramSplit" /> | |||||
2246 | ||||||
2247 | <!-- Abo rted? --> | |||||
2248 | <!-- --> | |||||
2249 | <xsl:if test="not( wwprogress :Abort())" > | |||||
2250 | <xsl:ca ll-templat e name="Fr ame"> | |||||
2251 | <xsl:w ith-param name="Para mFrame" se lect="." / > | |||||
2252 | <xsl:w ith-param name="Para mSplits" s elect="$Pa ramSplits" /> | |||||
2253 | <xsl:w ith-param name="Para mCargo" se lect="$Par amCargo" / > | |||||
2254 | <xsl:w ith-param name="Para mLinks" se lect="$Par amLinks" / > | |||||
2255 | <xsl:w ith-param name="Para mSplit" se lect="$Par amSplit" / > | |||||
2256 | </xsl:c all-templa te> | |||||
2257 | </xsl:if > | |||||
2258 | </xsl:tem plate> | |||||
2259 | ||||||
2260 | ||||||
2261 | <xsl:temp late match ="wwdoc:Fr ame" mode= "wwmode:te xtrun"> | |||||
2262 | <xsl:par am name="P aramSplits " /> | |||||
2263 | <xsl:par am name="P aramCargo" /> | |||||
2264 | <xsl:par am name="P aramLinks" /> | |||||
2265 | <xsl:par am name="P aramSplit" /> | |||||
2266 | ||||||
2267 | <xsl:cal l-template name="Fra me"> | |||||
2268 | <xsl:wi th-param n ame="Param Frame" sel ect="." /> | |||||
2269 | <xsl:wi th-param n ame="Param Splits" se lect="$Par amSplits" /> | |||||
2270 | <xsl:wi th-param n ame="Param Cargo" sel ect="$Para mCargo" /> | |||||
2271 | <xsl:wi th-param n ame="Param Links" sel ect="$Para mLinks" /> | |||||
2272 | <xsl:wi th-param n ame="Param Split" sel ect="$Para mSplit" /> | |||||
2273 | </xsl:ca ll-templat e> | |||||
2274 | </xsl:tem plate> | |||||
2275 | ||||||
2276 | ||||||
2277 | <xsl:temp late name= "Frame"> | |||||
2278 | <xsl:par am name="P aramFrame" /> | |||||
2279 | <xsl:par am name="P aramSplits " /> | |||||
2280 | <xsl:par am name="P aramCargo" /> | |||||
2281 | <xsl:par am name="P aramLinks" /> | |||||
2282 | <xsl:par am name="P aramSplit" /> | |||||
2283 | ||||||
2284 | <!-- Get splits fr ame --> | |||||
2285 | <!-- --> | |||||
2286 | <xsl:for -each sele ct="$Param Splits[1]" > | |||||
2287 | <xsl:va riable nam e="VarSpli tsFrame" s elect="key ('wwsplits -frames-by -id', $Par amFrame/@i d)[@docume ntID = $Pa ramSplit/@ documentID ]" /> | |||||
2288 | ||||||
2289 | <!-- Fr ame known? --> | |||||
2290 | <!-- --> | |||||
2291 | <xsl:if test="cou nt($VarSpl itsFrame) = 1"> | |||||
2292 | <!-- T humbnail? --> | |||||
2293 | <!-- --> | |||||
2294 | <xsl:f or-each se lect="$Glo balFiles[1 ]"> | |||||
2295 | <xsl: variable n ame="VarSp litsThumbn ail" selec t="$VarSpl itsFrame/w wsplits:Th umbnail" / > | |||||
2296 | <xsl: variable n ame="VarTh umbnailDef ined" sele ct="count( key('wwfil es-files-b y-path', $ VarSplitsT humbnail/@ path)[1]) > 0" /> | |||||
2297 | ||||||
2298 | <!-- Emit image --> | |||||
2299 | <!-- --> | |||||
2300 | <xsl: choose> | |||||
2301 | <!-- Thumbnail --> | |||||
2302 | <!-- --> | |||||
2303 | <xsl :when test ="$VarThum bnailDefin ed"> | |||||
2304 | <!- - Emit mar kup --> | |||||
2305 | <!- - --> | |||||
2306 | <xs l:call-tem plate name ="Frame-Ma rkup"> | |||||
2307 | <x sl:with-pa ram name=" ParamFrame " select=" $ParamFram e" /> | |||||
2308 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
2309 | <x sl:with-pa ram name=" ParamCargo " select=" $ParamCarg o" /> | |||||
2310 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
2311 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
2312 | <x sl:with-pa ram name=" ParamSplit sFrame" se lect="$Var SplitsFram e" /> | |||||
2313 | <x sl:with-pa ram name=" ParamThumb nail" sele ct="true() " /> | |||||
2314 | </x sl:call-te mplate> | |||||
2315 | </xs l:when> | |||||
2316 | ||||||
2317 | <!-- Fullsize --> | |||||
2318 | <!-- --> | |||||
2319 | <xsl :otherwise > | |||||
2320 | <!- - Note num bering --> | |||||
2321 | <!- - --> | |||||
2322 | <xs l:variable name="Var Notes" sel ect="$Para mFrame//ww doc:Note" /> | |||||
2323 | <xs l:variable name="Var NoteNumber ingAsXML"> | |||||
2324 | <x sl:call-te mplate nam e="Notes-N umber"> | |||||
2325 | < xsl:with-p aram name= "ParamNote s" select= "$VarNotes " /> | |||||
2326 | </ xsl:call-t emplate> | |||||
2327 | </x sl:variabl e> | |||||
2328 | <xs l:variable name="Var NoteNumber ing" selec t="msxsl:n ode-set($V arNoteNumb eringAsXML )" /> | |||||
2329 | ||||||
2330 | <!- - Frame ca rgo --> | |||||
2331 | <!- - --> | |||||
2332 | <xs l:variable name="Var Cargo" sel ect="$Para mCargo/*[l ocal-name( ) != 'Note Numbering' ]/.. | $Va rNoteNumbe ring" /> | |||||
2333 | ||||||
2334 | <!- - Emit mar kup --> | |||||
2335 | <!- - --> | |||||
2336 | <xs l:call-tem plate name ="Frame-Ma rkup"> | |||||
2337 | <x sl:with-pa ram name=" ParamFrame " select=" $ParamFram e" /> | |||||
2338 | <x sl:with-pa ram name=" ParamSplit s" select= "$ParamSpl its" /> | |||||
2339 | <x sl:with-pa ram name=" ParamCargo " select=" $VarCargo" /> | |||||
2340 | <x sl:with-pa ram name=" ParamLinks " select=" $ParamLink s" /> | |||||
2341 | <x sl:with-pa ram name=" ParamSplit " select=" $ParamSpli t" /> | |||||
2342 | <x sl:with-pa ram name=" ParamSplit sFrame" se lect="$Var SplitsFram e" /> | |||||
2343 | <x sl:with-pa ram name=" ParamThumb nail" sele ct="false( )" /> | |||||
2344 | </x sl:call-te mplate> | |||||
2345 | </xs l:otherwis e> | |||||
2346 | </xsl :choose> | |||||
2347 | </xsl: for-each> | |||||
2348 | </xsl:i f> | |||||
2349 | </xsl:fo r-each> | |||||
2350 | </xsl:tem plate> | |||||
2351 | ||||||
2352 | ||||||
2353 | <xsl:temp late name= "Frame-Mar kup"> | |||||
2354 | <xsl:par am name="P aramFrame" /> | |||||
2355 | <xsl:par am name="P aramSplits " /> | |||||
2356 | <xsl:par am name="P aramCargo" /> | |||||
2357 | <xsl:par am name="P aramLinks" /> | |||||
2358 | <xsl:par am name="P aramSplit" /> | |||||
2359 | <xsl:par am name="P aramSplits Frame" /> | |||||
2360 | <xsl:par am name="P aramThumbn ail" /> | |||||
2361 | ||||||
2362 | <!-- Con text Rule --> | |||||
2363 | <!-- --> | |||||
2364 | <xsl:var iable name ="VarConte xtRule" se lect="wwpr ojext:GetC ontextRule ('Graphic' , $ParamSp litsFrame/ @stylename , $ParamSp litsFrame/ @documentI D, $ParamS plitsFrame /@id)" /> | |||||
2365 | ||||||
2366 | <!-- Gen erate? --> | |||||
2367 | <!-- --> | |||||
2368 | <xsl:var iable name ="VarGener ateOutputO ption" sel ect="$VarC ontextRule /wwproject :Options/w wproject:O ption[@Nam e = 'gener ate-output ']/@Value" /> | |||||
2369 | <xsl:var iable name ="VarGener ateOutput" select="( string-len gth($VarGe nerateOutp utOption) = 0) or ($ VarGenerat eOutputOpt ion != 'fa lse')" /> | |||||
2370 | <xsl:if test="$Var GenerateOu tput"> | |||||
2371 | <!-- De termine im age path - -> | |||||
2372 | <!-- - -> | |||||
2373 | <xsl:va riable nam e="VarImag ePath"> | |||||
2374 | <xsl:c hoose> | |||||
2375 | <xsl: when test= "$ParamThu mbnail"> | |||||
2376 | <xsl :value-of select="$P aramSplits Frame/wwsp lits:Thumb nail/@path " /> | |||||
2377 | </xsl :when> | |||||
2378 | ||||||
2379 | <xsl: otherwise> | |||||
2380 | <xsl :value-of select="$P aramSplits Frame/@pat h" /> | |||||
2381 | </xsl :otherwise > | |||||
2382 | </xsl: choose> | |||||
2383 | </xsl:v ariable> | |||||
2384 | ||||||
2385 | <!-- Ac cess image info --> | |||||
2386 | <!-- --> | |||||
2387 | <xsl:va riable nam e="VarImag eInfo" sel ect="wwima ging:GetIn fo($VarIma gePath)" / > | |||||
2388 | ||||||
2389 | <!-- De termine ty pe --> | |||||
2390 | <!-- --> | |||||
2391 | <xsl:va riable nam e="VarVect orImageAsT ext"> | |||||
2392 | <xsl:c all-templa te name="I mages-Vect orImageFor mat"> | |||||
2393 | <xsl: with-param name="Par amImageInf o" select= "$VarImage Info" /> | |||||
2394 | </xsl: call-templ ate> | |||||
2395 | </xsl:v ariable> | |||||
2396 | <xsl:va riable nam e="VarVect orImage" s elect="$Va rVectorIma geAsText = string(tr ue())" /> | |||||
2397 | <xsl:va riable nam e="VarRast erImageAsT ext"> | |||||
2398 | <xsl:c all-templa te name="I mages-Rast erImageFor mat"> | |||||
2399 | <xsl: with-param name="Par amImageInf o" select= "$VarImage Info" /> | |||||
2400 | </xsl: call-templ ate> | |||||
2401 | </xsl:v ariable> | |||||
2402 | <xsl:va riable nam e="VarRast erImage" s elect="$Va rRasterIma geAsText = string(tr ue())" /> | |||||
2403 | ||||||
2404 | <!-- Em it image - -> | |||||
2405 | <!-- - -> | |||||
2406 | <xsl:ch oose> | |||||
2407 | <!-- V ector Imag e --> | |||||
2408 | <!-- --> | |||||
2409 | <xsl:w hen test=" $VarVector Image"> | |||||
2410 | <xsl: call-templ ate name=" Frame-Mark up-Vector" > | |||||
2411 | <xsl :with-para m name="Pa ramFrame" select="$P aramFrame" /> | |||||
2412 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
2413 | <xsl :with-para m name="Pa ramCargo" select="$P aramCargo" /> | |||||
2414 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
2415 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
2416 | <xsl :with-para m name="Pa ramSplitsF rame" sele ct="$Param SplitsFram e" /> | |||||
2417 | <xsl :with-para m name="Pa ramContext Rule" sele ct="$VarCo ntextRule" /> | |||||
2418 | <xsl :with-para m name="Pa ramImageIn fo" select ="$VarImag eInfo" /> | |||||
2419 | <xsl :with-para m name="Pa ramThumbna il" select ="$ParamTh umbnail" / > | |||||
2420 | </xsl :call-temp late> | |||||
2421 | </xsl: when> | |||||
2422 | ||||||
2423 | <!-- R aster Imag e --> | |||||
2424 | <!-- --> | |||||
2425 | <xsl:w hen test=" $VarRaster Image"> | |||||
2426 | <xsl: call-templ ate name=" Frame-Mark up-Raster" > | |||||
2427 | <xsl :with-para m name="Pa ramFrame" select="$P aramFrame" /> | |||||
2428 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
2429 | <xsl :with-para m name="Pa ramCargo" select="$P aramCargo" /> | |||||
2430 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
2431 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
2432 | <xsl :with-para m name="Pa ramSplitsF rame" sele ct="$Param SplitsFram e" /> | |||||
2433 | <xsl :with-para m name="Pa ramContext Rule" sele ct="$VarCo ntextRule" /> | |||||
2434 | <xsl :with-para m name="Pa ramImageIn fo" select ="$VarImag eInfo" /> | |||||
2435 | <xsl :with-para m name="Pa ramThumbna il" select ="$ParamTh umbnail" / > | |||||
2436 | </xsl :call-temp late> | |||||
2437 | </xsl: when> | |||||
2438 | </xsl:c hoose> | |||||
2439 | </xsl:if > | |||||
2440 | </xsl:tem plate> | |||||
2441 | ||||||
2442 | ||||||
2443 | <xsl:temp late name= "Frame-Mar kup-Vector "> | |||||
2444 | <xsl:par am name="P aramFrame" /> | |||||
2445 | <xsl:par am name="P aramSplits " /> | |||||
2446 | <xsl:par am name="P aramCargo" /> | |||||
2447 | <xsl:par am name="P aramLinks" /> | |||||
2448 | <xsl:par am name="P aramSplit" /> | |||||
2449 | <xsl:par am name="P aramSplits Frame" /> | |||||
2450 | <xsl:par am name="P aramContex tRule" /> | |||||
2451 | <xsl:par am name="P aramImageI nfo" /> | |||||
2452 | <xsl:par am name="P aramThumbn ail" /> | |||||
2453 | ||||||
2454 | <xsl:cho ose> | |||||
2455 | <!-- SV G --> | |||||
2456 | <!-- --> | |||||
2457 | <xsl:wh en test="$ ParamImage Info/@form at = 'svg' "> | |||||
2458 | <xsl:c all-templa te name="F rame-Marku p-Vector-S VG"> | |||||
2459 | <xsl: with-param name="Par amFrame" s elect="$Pa ramFrame" /> | |||||
2460 | <xsl: with-param name="Par amSplits" select="$P aramSplits " /> | |||||
2461 | <xsl: with-param name="Par amCargo" s elect="$Pa ramCargo" /> | |||||
2462 | <xsl: with-param name="Par amLinks" s elect="$Pa ramLinks" /> | |||||
2463 | <xsl: with-param name="Par amSplit" s elect="$Pa ramSplit" /> | |||||
2464 | <xsl: with-param name="Par amSplitsFr ame" selec t="$ParamS plitsFrame " /> | |||||
2465 | <xsl: with-param name="Par amContextR ule" selec t="$ParamC ontextRule " /> | |||||
2466 | <xsl: with-param name="Par amImageInf o" select= "$ParamIma geInfo" /> | |||||
2467 | <xsl: with-param name="Par amThumbnai l" select= "$ParamThu mbnail" /> | |||||
2468 | </xsl: call-templ ate> | |||||
2469 | </xsl:w hen> | |||||
2470 | </xsl:ch oose> | |||||
2471 | </xsl:tem plate> | |||||
2472 | ||||||
2473 | ||||||
2474 | <xsl:temp late name= "Frame-Mar kup-Vector -SVG"> | |||||
2475 | <xsl:par am name="P aramFrame" /> | |||||
2476 | <xsl:par am name="P aramSplits " /> | |||||
2477 | <xsl:par am name="P aramCargo" /> | |||||
2478 | <xsl:par am name="P aramLinks" /> | |||||
2479 | <xsl:par am name="P aramSplit" /> | |||||
2480 | <xsl:par am name="P aramSplits Frame" /> | |||||
2481 | <xsl:par am name="P aramContex tRule" /> | |||||
2482 | <xsl:par am name="P aramImageI nfo" /> | |||||
2483 | <xsl:par am name="P aramThumbn ail" /> | |||||
2484 | ||||||
2485 | <!-- Acc ess frame behavior - -> | |||||
2486 | <!-- - -> | |||||
2487 | <xsl:for -each sele ct="$Param Cargo/wwbe haviors:Be haviors[1] "> | |||||
2488 | <xsl:va riable nam e="VarBeha viorFrame" select="k ey('wwbeha viors-fram es-by-id', $ParamFra me/@id)[1] " /> | |||||
2489 | ||||||
2490 | <!-- Re solve proj ect proper ties --> | |||||
2491 | <!-- --> | |||||
2492 | <xsl:va riable nam e="VarReso lvedProper tiesAsXML" > | |||||
2493 | <xsl:c all-templa te name="P roperties- ResolveCon textRule"> | |||||
2494 | <xsl: with-param name="Par amDocument Context" s elect="$Pa ramFrame" /> | |||||
2495 | <xsl: with-param name="Par amProperti es" select ="$ParamCo ntextRule/ wwproject: Properties /wwproject :Property" /> | |||||
2496 | <xsl: with-param name="Par amStyleNam e" select= "$ParamFra me/@stylen ame" /> | |||||
2497 | <xsl: with-param name="Par amStyleTyp e" select= "'Graphic' " /> | |||||
2498 | <xsl: with-param name="Par amContextS tyle" sele ct="$Param Frame/wwdo c:Style" / > | |||||
2499 | </xsl: call-templ ate> | |||||
2500 | </xsl:v ariable> | |||||
2501 | <xsl:va riable nam e="VarReso lvedProper ties" sele ct="msxsl: node-set($ VarResolve dPropertie sAsXML)/ww project:Pr operty" /> | |||||
2502 | ||||||
2503 | <!-- Wi dth/Height --> | |||||
2504 | <!-- --> | |||||
2505 | <xsl:va riable nam e="VarByRe ferenceGra phicsUseDo cumentDime nsionsOpti on" select ="$ParamCo ntextRule/ wwproject: Options/ww project:Op tion[@Name = 'by-ref erence-use -document- dimensions ']/@Value" /> | |||||
2506 | <xsl:va riable nam e="VarByRe ferenceGra phicsUseDo cumentDime nsions" se lect="(str ing-length ($VarByRef erenceGrap hicsUseDoc umentDimen sionsOptio n) = 0) or ($VarByRe ferenceGra phicsUseDo cumentDime nsionsOpti on = 'true ')" /> | |||||
2507 | <xsl:va riable nam e="VarWidt h"> | |||||
2508 | <xsl:c hoose> | |||||
2509 | <xsl: when test= "$ParamThu mbnail"> | |||||
2510 | <xsl :value-of select="nu mber($Para mImageInfo /@width)" /> | |||||
2511 | </xsl :when> | |||||
2512 | ||||||
2513 | <xsl: when test= "$ParamSpl itsFrame/@ byref = 't rue'"> | |||||
2514 | <xsl :choose> | |||||
2515 | <xs l:when tes t="($VarBy ReferenceG raphicsUse DocumentDi mensions) or (number ($ParamIma geInfo/@wi dth) = 0)" > | |||||
2516 | <x sl:variabl e name="Va rByReferen ceFrame" s elect="$Pa ramFrame// wwdoc:Face t[@type = 'by-refere nce'][1]/. ./.." /> | |||||
2517 | ||||||
2518 | <x sl:value-o f select=" floor(wwun its:Conver t(wwunits: NumericPre fix($VarBy ReferenceF rame/wwdoc :Attribute [@name = ' width']/@v alue), 'pt ', 'px'))" /> | |||||
2519 | </x sl:when> | |||||
2520 | ||||||
2521 | <xs l:otherwis e> | |||||
2522 | <x sl:value-o f select=" number($Pa ramImageIn fo/@width) " /> | |||||
2523 | </x sl:otherwi se> | |||||
2524 | </xs l:choose> | |||||
2525 | </xsl :when> | |||||
2526 | ||||||
2527 | <xsl: otherwise> | |||||
2528 | <xsl :value-of select="nu mber($Para mImageInfo /@width)" /> | |||||
2529 | </xsl :otherwise > | |||||
2530 | </xsl: choose> | |||||
2531 | </xsl:v ariable> | |||||
2532 | <xsl:va riable nam e="VarHeig ht"> | |||||
2533 | <xsl:c hoose> | |||||
2534 | <xsl: when test= "$ParamThu mbnail"> | |||||
2535 | <xsl :value-of select="nu mber($Para mImageInfo /@height)" /> | |||||
2536 | </xsl :when> | |||||
2537 | ||||||
2538 | <xsl: when test= "$ParamSpl itsFrame/@ byref = 't rue'"> | |||||
2539 | <xsl :choose> | |||||
2540 | <xs l:when tes t="($VarBy ReferenceG raphicsUse DocumentDi mensions) or (number ($ParamIma geInfo/@he ight) = 0) "> | |||||
2541 | <x sl:variabl e name="Va rByReferen ceFrame" s elect="$Pa ramFrame// wwdoc:Face t[@type = 'by-refere nce'][1]/. ./.." /> | |||||
2542 | ||||||
2543 | <x sl:value-o f select=" floor(wwun its:Conver t(wwunits: NumericPre fix($VarBy ReferenceF rame/wwdoc :Attribute [@name = ' height']/@ value), 'p t', 'px')) " /> | |||||
2544 | </x sl:when> | |||||
2545 | ||||||
2546 | <xs l:otherwis e> | |||||
2547 | <x sl:value-o f select=" number($Pa ramImageIn fo/@height )" /> | |||||
2548 | </x sl:otherwi se> | |||||
2549 | </xs l:choose> | |||||
2550 | </xsl :when> | |||||
2551 | ||||||
2552 | <xsl: otherwise> | |||||
2553 | <xsl :value-of select="nu mber($Para mImageInfo /@height)" /> | |||||
2554 | </xsl :otherwise > | |||||
2555 | </xsl: choose> | |||||
2556 | </xsl:v ariable> | |||||
2557 | ||||||
2558 | <!-- Sr c --> | |||||
2559 | <!-- --> | |||||
2560 | <xsl:va riable nam e="VarSrc" > | |||||
2561 | <xsl:t ext>../</x sl:text> | |||||
2562 | <xsl:v alue-of se lect="wwur i:GetRelat iveTo($Par amImageInf o/@path, $ ParamSplit /@path)" / > | |||||
2563 | </xsl:v ariable> | |||||
2564 | ||||||
2565 | <!-- Cl ass --> | |||||
2566 | <!-- --> | |||||
2567 | <xsl:va riable nam e="VarClas s"> | |||||
2568 | <!-- A dditional CSS classe s --> | |||||
2569 | <!-- --> | |||||
2570 | <xsl:v ariable na me="VarAdd itionalCSS ClassesOpt ion" selec t="normali ze-space($ ParamConte xtRule/wwp roject:Opt ions/wwpro ject:Optio n[@Name = 'additiona l-css-clas ses']/@Val ue)" /> | |||||
2571 | </xsl:v ariable> | |||||
2572 | ||||||
2573 | <!-- Al t Text --> | |||||
2574 | <!-- --> | |||||
2575 | <xsl:va riable nam e="VarAltT ext"> | |||||
2576 | <xsl:c all-templa te name="I mages-AltT ext"> | |||||
2577 | <xsl: with-param name="Par amFrame" s elect="$Pa ramFrame" /> | |||||
2578 | <xsl: with-param name="Par amBehavior Frame" sel ect="$VarB ehaviorFra me" /> | |||||
2579 | </xsl: call-templ ate> | |||||
2580 | </xsl:v ariable> | |||||
2581 | ||||||
2582 | <!-- Lo ng Descrip tion --> | |||||
2583 | <!-- --> | |||||
2584 | <xsl:va riable nam e="VarLong Descriptio n"> | |||||
2585 | <xsl:c all-templa te name="I mages-Long Descriptio n"> | |||||
2586 | <xsl: with-param name="Par amSplitsFr ame" selec t="$ParamS plitsFrame " /> | |||||
2587 | <xsl: with-param name="Par amBehavior Frame" sel ect="$VarB ehaviorFra me" /> | |||||
2588 | </xsl: call-templ ate> | |||||
2589 | </xsl:v ariable> | |||||
2590 | ||||||
2591 | <!-- Be gin EmbedO bject --> | |||||
2592 | <!-- --> | |||||
2593 | <wwexsl doc:Text d isable-out put-escapi ng="yes"> | |||||
2594 | <xsl:t ext><&l t;EmbedObj ect(</xsl: text> | |||||
2595 | ||||||
2596 | <!-- S VG image - -> | |||||
2597 | <!-- - -> | |||||
2598 | <xsl:v alue-of se lect="$Var Src" /> | |||||
2599 | ||||||
2600 | <!-- T ype attrib ute --> | |||||
2601 | <!-- --> | |||||
2602 | <xsl:t ext>, type ="image/sv g+xml"</xs l:text> | |||||
2603 | ||||||
2604 | <!-- C lass attri bute --> | |||||
2605 | <!-- --> | |||||
2606 | <xsl:i f test="st ring-lengt h($VarClas s) > 0" > | |||||
2607 | <xsl: text>, cla ss="</xsl: text> | |||||
2608 | <xsl: value-of s elect="$Va rClass" /> | |||||
2609 | <xsl: text>"</xs l:text> | |||||
2610 | </xsl: if> | |||||
2611 | ||||||
2612 | <!-- W idth attri bute --> | |||||
2613 | <!-- --> | |||||
2614 | <xsl:i f test="$V arWidth &g t; 0"> | |||||
2615 | <xsl: text>, wid th="</xsl: text> | |||||
2616 | <xsl: value-of s elect="$Va rWidth"/> | |||||
2617 | <xsl: text>"</xs l:text> | |||||
2618 | </xsl: if> | |||||
2619 | ||||||
2620 | <!-- H eight attr ibute --> | |||||
2621 | <!-- --> | |||||
2622 | <xsl:i f test="$V arHeight & gt; 0"> | |||||
2623 | <xsl: text>, hei ght="</xsl :text> | |||||
2624 | <xsl: value-of s elect="$Va rHeight"/> | |||||
2625 | <xsl: text>"</xs l:text> | |||||
2626 | </xsl: if> | |||||
2627 | ||||||
2628 | <!-- T itle attri bute --> | |||||
2629 | <!-- --> | |||||
2630 | <xsl:c hoose> | |||||
2631 | <xsl: when test= "string-le ngth($VarA ltText) &g t; 0"> | |||||
2632 | <xsl :text>, ti tle="</xsl :text> | |||||
2633 | <xsl :value-of select="$V arAltText" /> | |||||
2634 | <xsl :text>"</x sl:text> | |||||
2635 | </xsl :when> | |||||
2636 | ||||||
2637 | <xsl: when test= "string-le ngth($Para mSplitsFra me/@title) > 0"> | |||||
2638 | <xsl :text>, ti tle="</xsl :text> | |||||
2639 | <xsl :value-of select="$P aramSplits Frame/@tit le" /> | |||||
2640 | <xsl :text>"</x sl:text> | |||||
2641 | </xsl :when> | |||||
2642 | </xsl: choose> | |||||
2643 | ||||||
2644 | <!-- E nd EmbedOb ject --> | |||||
2645 | <!-- --> | |||||
2646 | <xsl:t ext>)>& gt;</xsl:t ext> | |||||
2647 | </wwexs ldoc:Text> | |||||
2648 | ||||||
2649 | <!-- Ge nerate D L inks --> | |||||
2650 | <!-- --> | |||||
2651 | <xsl:va riable nam e="VarGene rateDLinks " select=" wwprojext: GetFormatS etting('ac cessibilit y-image-d- links', 'f alse')" /> | |||||
2652 | <xsl:if test="$Va rGenerateD Links = 't rue'"> | |||||
2653 | <xsl:i f test="st ring-lengt h($VarLong Descriptio n) > 0" > | |||||
2654 | <xsl: variable n ame="VarLo ngDescript ionTitle" select="ww string:For mat($Globa lUILocale/ wwlocale:L ocale/wwlo cale:Strin gs/wwlocal e:String[@ name = 'DL inkDescrip tion']/@va lue, wwfil esystem:Ge tFileName( $ParamSpli tsFrame/@p ath))" /> | |||||
2655 | ||||||
2656 | <wwex sldoc:Text disable-o utput-esca ping="yes" > | |||||
2657 | <xsl :text> </x sl:text> | |||||
2658 | <xsl :text>[</x sl:text> | |||||
2659 | <xsl :text>[[</ xsl:text> | |||||
2660 | <xsl :call-temp late name= "MoinMoin- EscapeLink "> | |||||
2661 | <xs l:with-par am name="P aramLink" select="$V arLongDesc ription" / > | |||||
2662 | </xs l:call-tem plate> | |||||
2663 | <xsl :text>|</x sl:text> | |||||
2664 | <xsl :text>D</x sl:text> | |||||
2665 | <xsl :text>|</x sl:text> | |||||
2666 | <xsl :text>titl e="</xsl:t ext> | |||||
2667 | <xsl :value-of select="$V arLongDesc riptionTit le" /> | |||||
2668 | <xsl :text>"</x sl:text> | |||||
2669 | <xsl :text>]]</ xsl:text> | |||||
2670 | <xsl :text>]</x sl:text> | |||||
2671 | </wwe xsldoc:Tex t> | |||||
2672 | </xsl: if> | |||||
2673 | </xsl:i f> | |||||
2674 | ||||||
2675 | <!-- No tes --> | |||||
2676 | <!-- --> | |||||
2677 | <xsl:ch oose> | |||||
2678 | <!-- T humbnail - -> | |||||
2679 | <!-- - -> | |||||
2680 | <xsl:w hen test=" $ParamThum bnail"> | |||||
2681 | <!-- Nothing to do --> | |||||
2682 | <!-- --> | |||||
2683 | </xsl: when> | |||||
2684 | ||||||
2685 | <!-- F ullsize -- > | |||||
2686 | <!-- -- > | |||||
2687 | <xsl:o therwise> | |||||
2688 | <!-- Frame Foot notes --> | |||||
2689 | <!-- --> | |||||
2690 | <xsl: variable n ame="VarNo tes" selec t="$ParamF rame//wwdo c:Note" /> | |||||
2691 | <xsl: call-templ ate name=" Content-No tes"> | |||||
2692 | <xsl :with-para m name="Pa ramNotes" select="$V arNotes" / > | |||||
2693 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
2694 | <xsl :with-para m name="Pa ramCargo" select="$P aramCargo" /> | |||||
2695 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
2696 | <xsl :with-para m name="Pa ramTOCData " select=" ''" /> | |||||
2697 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
2698 | </xsl :call-temp late> | |||||
2699 | </xsl: otherwise> | |||||
2700 | </xsl:c hoose> | |||||
2701 | </xsl:fo r-each> | |||||
2702 | </xsl:tem plate> | |||||
2703 | ||||||
2704 | ||||||
2705 | <xsl:temp late name= "Frame-Mar kup-Raster "> | |||||
2706 | <xsl:par am name="P aramFrame" /> | |||||
2707 | <xsl:par am name="P aramSplits " /> | |||||
2708 | <xsl:par am name="P aramCargo" /> | |||||
2709 | <xsl:par am name="P aramLinks" /> | |||||
2710 | <xsl:par am name="P aramSplit" /> | |||||
2711 | <xsl:par am name="P aramSplits Frame" /> | |||||
2712 | <xsl:par am name="P aramContex tRule" /> | |||||
2713 | <xsl:par am name="P aramImageI nfo" /> | |||||
2714 | <xsl:par am name="P aramThumbn ail" /> | |||||
2715 | ||||||
2716 | <!-- Acc ess frame behavior - -> | |||||
2717 | <!-- - -> | |||||
2718 | <xsl:for -each sele ct="$Param Cargo/wwbe haviors:Be haviors[1] "> | |||||
2719 | <xsl:va riable nam e="VarBeha viorFrame" select="k ey('wwbeha viors-fram es-by-id', $ParamFra me/@id)[1] " /> | |||||
2720 | ||||||
2721 | <!-- Re solve proj ect proper ties --> | |||||
2722 | <!-- --> | |||||
2723 | <xsl:va riable nam e="VarReso lvedProper tiesAsXML" > | |||||
2724 | <xsl:c all-templa te name="P roperties- ResolveCon textRule"> | |||||
2725 | <xsl: with-param name="Par amDocument Context" s elect="$Pa ramFrame" /> | |||||
2726 | <xsl: with-param name="Par amProperti es" select ="$ParamCo ntextRule/ wwproject: Properties /wwproject :Property" /> | |||||
2727 | <xsl: with-param name="Par amStyleNam e" select= "$ParamFra me/@stylen ame" /> | |||||
2728 | <xsl: with-param name="Par amStyleTyp e" select= "'Graphic' " /> | |||||
2729 | <xsl: with-param name="Par amContextS tyle" sele ct="$Param Frame/wwdo c:Style" / > | |||||
2730 | </xsl: call-templ ate> | |||||
2731 | </xsl:v ariable> | |||||
2732 | <xsl:va riable nam e="VarReso lvedProper ties" sele ct="msxsl: node-set($ VarResolve dPropertie sAsXML)/ww project:Pr operty" /> | |||||
2733 | ||||||
2734 | <!-- Cl ass --> | |||||
2735 | <!-- --> | |||||
2736 | <xsl:va riable nam e="VarClas s"> | |||||
2737 | <!-- A dditional CSS classe s --> | |||||
2738 | <!-- --> | |||||
2739 | <xsl:v ariable na me="VarAdd itionalCSS ClassesOpt ion" selec t="normali ze-space($ ParamConte xtRule/wwp roject:Opt ions/wwpro ject:Optio n[@Name = 'additiona l-css-clas ses']/@Val ue)" /> | |||||
2740 | </xsl:v ariable> | |||||
2741 | ||||||
2742 | <!-- Wi dth/Height --> | |||||
2743 | <!-- --> | |||||
2744 | <xsl:va riable nam e="VarByRe ferenceGra phicsUseDo cumentDime nsionsOpti on" select ="$ParamCo ntextRule/ wwproject: Options/ww project:Op tion[@Name = 'by-ref erence-use -document- dimensions ']/@Value" /> | |||||
2745 | <xsl:va riable nam e="VarByRe ferenceGra phicsUseDo cumentDime nsions" se lect="(str ing-length ($VarByRef erenceGrap hicsUseDoc umentDimen sionsOptio n) = 0) or ($VarByRe ferenceGra phicsUseDo cumentDime nsionsOpti on = 'true ')" /> | |||||
2746 | <xsl:va riable nam e="VarWidt h"> | |||||
2747 | <xsl:c hoose> | |||||
2748 | <xsl: when test= "$ParamThu mbnail"> | |||||
2749 | <xsl :value-of select="nu mber($Para mImageInfo /@width)" /> | |||||
2750 | </xsl :when> | |||||
2751 | ||||||
2752 | <xsl: when test= "$ParamSpl itsFrame/@ byref = 't rue'"> | |||||
2753 | <xsl :choose> | |||||
2754 | <xs l:when tes t="$VarByR eferenceGr aphicsUseD ocumentDim ensions"> | |||||
2755 | <x sl:variabl e name="Va rByReferen ceFrame" s elect="$Pa ramFrame// wwdoc:Face t[@type = 'by-refere nce'][1]/. ./.." /> | |||||
2756 | ||||||
2757 | <x sl:value-o f select=" floor(wwun its:Conver t(wwunits: NumericPre fix($VarBy ReferenceF rame/wwdoc :Attribute [@name = ' width']/@v alue), 'pt ', 'px'))" /> | |||||
2758 | </x sl:when> | |||||
2759 | ||||||
2760 | <xs l:otherwis e> | |||||
2761 | <x sl:value-o f select=" number($Pa ramImageIn fo/@width) " /> | |||||
2762 | </x sl:otherwi se> | |||||
2763 | </xs l:choose> | |||||
2764 | </xsl :when> | |||||
2765 | ||||||
2766 | <xsl: otherwise> | |||||
2767 | <xsl :value-of select="nu mber($Para mImageInfo /@width)" /> | |||||
2768 | </xsl :otherwise > | |||||
2769 | </xsl: choose> | |||||
2770 | </xsl:v ariable> | |||||
2771 | <xsl:va riable nam e="VarHeig ht"> | |||||
2772 | <xsl:c hoose> | |||||
2773 | <xsl: when test= "$ParamThu mbnail"> | |||||
2774 | <xsl :value-of select="nu mber($Para mImageInfo /@height)" /> | |||||
2775 | </xsl :when> | |||||
2776 | ||||||
2777 | <xsl: when test= "$ParamSpl itsFrame/@ byref = 't rue'"> | |||||
2778 | <xsl :choose> | |||||
2779 | <xs l:when tes t="$VarByR eferenceGr aphicsUseD ocumentDim ensions"> | |||||
2780 | <x sl:variabl e name="Va rByReferen ceFrame" s elect="$Pa ramFrame// wwdoc:Face t[@type = 'by-refere nce'][1]/. ./.." /> | |||||
2781 | ||||||
2782 | <x sl:value-o f select=" floor(wwun its:Conver t(wwunits: NumericPre fix($VarBy ReferenceF rame/wwdoc :Attribute [@name = ' height']/@ value), 'p t', 'px')) " /> | |||||
2783 | </x sl:when> | |||||
2784 | ||||||
2785 | <xs l:otherwis e> | |||||
2786 | <x sl:value-o f select=" number($Pa ramImageIn fo/@height )" /> | |||||
2787 | </x sl:otherwi se> | |||||
2788 | </xs l:choose> | |||||
2789 | </xsl :when> | |||||
2790 | ||||||
2791 | <xsl: otherwise> | |||||
2792 | <xsl :value-of select="nu mber($Para mImageInfo /@height)" /> | |||||
2793 | </xsl :otherwise > | |||||
2794 | </xsl: choose> | |||||
2795 | </xsl:v ariable> | |||||
2796 | ||||||
2797 | <!-- Sr c --> | |||||
2798 | <!-- --> | |||||
2799 | <xsl:va riable nam e="VarSrc" > | |||||
2800 | <xsl:t ext>attach ment:../</ xsl:text> | |||||
2801 | <xsl:v alue-of se lect="wwur i:GetRelat iveTo($Par amImageInf o/@path, $ ParamSplit /@path)" / > | |||||
2802 | </xsl:v ariable> | |||||
2803 | ||||||
2804 | <!-- Al ign --> | |||||
2805 | <!-- --> | |||||
2806 | <xsl:va riable nam e="VarAlig n"> | |||||
2807 | <xsl:v ariable na me="VarInW rapperPage " select=" count($Par amCargo/ww behaviors: WrapperPag e) > 0" /> | |||||
2808 | <xsl:i f test="no t($VarInWr apperPage) "> | |||||
2809 | <xsl: variable n ame="VarFl oatPropert y" select= "$VarResol vedPropert ies[@Name = 'float'] /@Value" / > | |||||
2810 | ||||||
2811 | <xsl: if test="$ VarFloatPr operty != 'none'"> | |||||
2812 | <xsl :value-of select="$V arFloatPro perty" /> | |||||
2813 | </xsl :if> | |||||
2814 | </xsl: if> | |||||
2815 | </xsl:v ariable> | |||||
2816 | ||||||
2817 | <!-- Al t Text --> | |||||
2818 | <!-- --> | |||||
2819 | <xsl:va riable nam e="VarAltT ext"> | |||||
2820 | <xsl:c all-templa te name="I mages-AltT ext"> | |||||
2821 | <xsl: with-param name="Par amFrame" s elect="$Pa ramFrame" /> | |||||
2822 | <xsl: with-param name="Par amBehavior Frame" sel ect="$VarB ehaviorFra me" /> | |||||
2823 | </xsl: call-templ ate> | |||||
2824 | </xsl:v ariable> | |||||
2825 | ||||||
2826 | <!-- Lo ng Descrip tion --> | |||||
2827 | <!-- --> | |||||
2828 | <xsl:va riable nam e="VarLong Descriptio n"> | |||||
2829 | <xsl:c all-templa te name="I mages-Long Descriptio n"> | |||||
2830 | <xsl: with-param name="Par amSplitsFr ame" selec t="$ParamS plitsFrame " /> | |||||
2831 | <xsl: with-param name="Par amBehavior Frame" sel ect="$VarB ehaviorFra me" /> | |||||
2832 | </xsl: call-templ ate> | |||||
2833 | </xsl:v ariable> | |||||
2834 | ||||||
2835 | <!-- Li nk? --> | |||||
2836 | <!-- --> | |||||
2837 | <xsl:va riable nam e="VarLink InfoAsXML" > | |||||
2838 | <xsl:c all-templa te name="F rame-LinkI nfo"> | |||||
2839 | <xsl: with-param name="Par amFrame" s elect="$Pa ramFrame" /> | |||||
2840 | <xsl: with-param name="Par amSplits" select="$P aramSplits " /> | |||||
2841 | <xsl: with-param name="Par amCargo" s elect="$Pa ramCargo" /> | |||||
2842 | <xsl: with-param name="Par amLinks" s elect="$Pa ramLinks" /> | |||||
2843 | <xsl: with-param name="Par amSplit" s elect="$Pa ramSplit" /> | |||||
2844 | <xsl: with-param name="Par amSplitsFr ame" selec t="$ParamS plitsFrame " /> | |||||
2845 | <xsl: with-param name="Par amThumbnai l" select= "$ParamThu mbnail" /> | |||||
2846 | <xsl: with-param name="Par amBehavior Frame" sel ect="$VarB ehaviorFra me" /> | |||||
2847 | </xsl: call-templ ate> | |||||
2848 | </xsl:v ariable> | |||||
2849 | <xsl:va riable nam e="VarLink Info" sele ct="msxsl: node-set($ VarLinkInf oAsXML)/ww links:Link Info" /> | |||||
2850 | ||||||
2851 | <!-- Li nk begin - -> | |||||
2852 | <!-- - -> | |||||
2853 | <xsl:if test="str ing-length ($VarLinkI nfo/@href) > 0"> | |||||
2854 | <xsl:t ext>[[</xs l:text> | |||||
2855 | <xsl:v alue-of se lect="$Var LinkInfo/@ href" /> | |||||
2856 | <xsl:t ext>|</xsl :text> | |||||
2857 | </xsl:i f> | |||||
2858 | ||||||
2859 | <!-- Im age --> | |||||
2860 | <!-- --> | |||||
2861 | <wwexsl doc:Text d isable-out put-escapi ng="yes"> | |||||
2862 | <xsl:t ext>{{</xs l:text> | |||||
2863 | <xsl:v alue-of se lect="$Var Src" /> | |||||
2864 | ||||||
2865 | <!-- A lt --> | |||||
2866 | <!-- --> | |||||
2867 | <xsl:t ext>|</xsl :text> | |||||
2868 | <xsl:v alue-of se lect="$Var AltText" / > | |||||
2869 | ||||||
2870 | <!-- O ptions --> | |||||
2871 | <!-- --> | |||||
2872 | <xsl:t ext>|</xsl :text> | |||||
2873 | <xsl:t ext>width= "</xsl:tex t> | |||||
2874 | <xsl:v alue-of se lect="$Var Width" /> | |||||
2875 | <xsl:t ext>",</xs l:text> | |||||
2876 | <xsl:t ext>height ="</xsl:te xt> | |||||
2877 | <xsl:v alue-of se lect="$Var Height" /> | |||||
2878 | <xsl:t ext>",</xs l:text> | |||||
2879 | <xsl:t ext>title= "</xsl:tex t> | |||||
2880 | <xsl:v alue-of se lect="$Par amSplitsFr ame/@title " /> | |||||
2881 | <xsl:t ext>",</xs l:text> | |||||
2882 | <xsl:i f test="st ring-lengt h($VarClas s) > 0" > | |||||
2883 | <xsl: text>class ="</xsl:te xt> | |||||
2884 | <xsl: value-of s elect="$Va rClass" /> | |||||
2885 | <xsl: text>",</x sl:text> | |||||
2886 | </xsl: if> | |||||
2887 | <xsl:i f test="st ring-lengt h($VarAlig n) > 0" > | |||||
2888 | <xsl: text>align ="</xsl:te xt> | |||||
2889 | <xsl: value-of s elect="$Va rAlign" /> | |||||
2890 | <xsl: text>",</x sl:text> | |||||
2891 | </xsl: if> | |||||
2892 | <xsl:i f test="st ring-lengt h($VarLong Descriptio n) > 0" > | |||||
2893 | <xsl: text>longd esc="</xsl :text> | |||||
2894 | <xsl: value-of s elect="$Va rLongDescr iption" /> | |||||
2895 | <xsl: text>",</x sl:text> | |||||
2896 | </xsl: if> | |||||
2897 | ||||||
2898 | <!-- C lose Image --> | |||||
2899 | <!-- --> | |||||
2900 | <xsl:t ext>}}</xs l:text> | |||||
2901 | </wwexs ldoc:Text> | |||||
2902 | ||||||
2903 | <!-- Li nk end --> | |||||
2904 | <!-- --> | |||||
2905 | <xsl:if test="str ing-length ($VarLinkI nfo/@href) > 0"> | |||||
2906 | <!-- L ink option s --> | |||||
2907 | <!-- --> | |||||
2908 | <xsl:v ariable na me="VarLin kOptions"> | |||||
2909 | <xsl: if test="s tring-leng th($VarLin kInfo/@tit le) > 0 "> | |||||
2910 | <xsl :text>titl e="</ xsl:text> | |||||
2911 | <xsl :value-of select="$V arLinkInfo /@title" / > | |||||
2912 | <xsl :text>&quo t;,</xsl:t ext> | |||||
2913 | </xsl :if> | |||||
2914 | <xsl: if test="s tring-leng th($VarLin kInfo/@tar get) > 0"> | |||||
2915 | <xsl :text>targ et="< /xsl:text> | |||||
2916 | <xsl :value-of select="$V arLinkInfo /@target" /> | |||||
2917 | <xsl :text>&quo t;,</xsl:t ext> | |||||
2918 | </xsl :if> | |||||
2919 | </xsl: variable> | |||||
2920 | <xsl:i f test="st ring-lengt h($VarLink Options) & gt; 0"> | |||||
2921 | <xsl: text>|</xs l:text> | |||||
2922 | <xsl: value-of s elect="$Va rLinkOptio ns" /> | |||||
2923 | </xsl: if> | |||||
2924 | ||||||
2925 | <xsl:t ext>]]</xs l:text> | |||||
2926 | </xsl:i f> | |||||
2927 | ||||||
2928 | <!-- Ge nerate D L inks --> | |||||
2929 | <!-- --> | |||||
2930 | <xsl:va riable nam e="VarGene rateDLinks " select=" wwprojext: GetFormatS etting('ac cessibilit y-image-d- links', 'f alse')" /> | |||||
2931 | <xsl:if test="$Va rGenerateD Links = 't rue'"> | |||||
2932 | <xsl:i f test="st ring-lengt h($VarLong Descriptio n) > 0" > | |||||
2933 | <xsl: variable n ame="VarLo ngDescript ionTitle" select="ww string:For mat($Globa lUILocale/ wwlocale:L ocale/wwlo cale:Strin gs/wwlocal e:String[@ name = 'DL inkDescrip tion']/@va lue, wwfil esystem:Ge tFileName( $ParamSpli tsFrame/@p ath))" /> | |||||
2934 | ||||||
2935 | <wwex sldoc:Text disable-o utput-esca ping="yes" > | |||||
2936 | <xsl :text> </x sl:text> | |||||
2937 | <xsl :text>[</x sl:text> | |||||
2938 | <xsl :text>[[</ xsl:text> | |||||
2939 | <xsl :call-temp late name= "MoinMoin- EscapeLink "> | |||||
2940 | <xs l:with-par am name="P aramLink" select="$V arLongDesc ription" / > | |||||
2941 | </xs l:call-tem plate> | |||||
2942 | <xsl :text>|</x sl:text> | |||||
2943 | <xsl :text>D</x sl:text> | |||||
2944 | <xsl :text>|</x sl:text> | |||||
2945 | <xsl :text>titl e="</xsl:t ext> | |||||
2946 | <xsl :value-of select="$V arLongDesc riptionTit le" /> | |||||
2947 | <xsl :text>"</x sl:text> | |||||
2948 | <xsl :text>]]</ xsl:text> | |||||
2949 | <xsl :text>]</x sl:text> | |||||
2950 | </wwe xsldoc:Tex t> | |||||
2951 | </xsl: if> | |||||
2952 | </xsl:i f> | |||||
2953 | ||||||
2954 | <!-- No tes --> | |||||
2955 | <!-- --> | |||||
2956 | <xsl:ch oose> | |||||
2957 | <!-- T humbnail - -> | |||||
2958 | <!-- - -> | |||||
2959 | <xsl:w hen test=" $ParamThum bnail"> | |||||
2960 | <!-- Nothing to do --> | |||||
2961 | <!-- --> | |||||
2962 | </xsl: when> | |||||
2963 | ||||||
2964 | <!-- F ullsize -- > | |||||
2965 | <!-- -- > | |||||
2966 | <xsl:o therwise> | |||||
2967 | <!-- Frame Foot notes --> | |||||
2968 | <!-- --> | |||||
2969 | <xsl: variable n ame="VarNo tes" selec t="$ParamF rame//wwdo c:Note" /> | |||||
2970 | <xsl: call-templ ate name=" Content-No tes"> | |||||
2971 | <xsl :with-para m name="Pa ramNotes" select="$V arNotes" / > | |||||
2972 | <xsl :with-para m name="Pa ramSplits" select="$ ParamSplit s" /> | |||||
2973 | <xsl :with-para m name="Pa ramCargo" select="$P aramCargo" /> | |||||
2974 | <xsl :with-para m name="Pa ramLinks" select="$P aramLinks" /> | |||||
2975 | <xsl :with-para m name="Pa ramTOCData " select=" ''" /> | |||||
2976 | <xsl :with-para m name="Pa ramSplit" select="$P aramSplit" /> | |||||
2977 | </xsl :call-temp late> | |||||
2978 | </xsl: otherwise> | |||||
2979 | </xsl:c hoose> | |||||
2980 | </xsl:fo r-each> | |||||
2981 | </xsl:tem plate> | |||||
2982 | ||||||
2983 | ||||||
2984 | <xsl:temp late name= "Frame-Lin kInfo"> | |||||
2985 | <xsl:par am name="P aramFrame" /> | |||||
2986 | <xsl:par am name="P aramSplits " /> | |||||
2987 | <xsl:par am name="P aramCargo" /> | |||||
2988 | <xsl:par am name="P aramLinks" /> | |||||
2989 | <xsl:par am name="P aramSplit" /> | |||||
2990 | <xsl:par am name="P aramSplits Frame" /> | |||||
2991 | <xsl:par am name="P aramThumbn ail" /> | |||||
2992 | <xsl:par am name="P aramBehavi orFrame" / > | |||||
2993 | ||||||
2994 | <xsl:cho ose> | |||||
2995 | <!-- Th umbnail -- > | |||||
2996 | <!-- -- > | |||||
2997 | <xsl:wh en test="$ ParamThumb nail"> | |||||
2998 | <wwlin ks:LinkInf o> | |||||
2999 | <!-- Link --> | |||||
3000 | <!-- --> | |||||
3001 | <xsl: attribute name="href "> | |||||
3002 | <xsl :call-temp late name= "MoinMoin- RelativePa geLink"> | |||||
3003 | <xs l:with-par am name="P aramSource " select=" $ParamSpli t/@path" / > | |||||
3004 | <xs l:with-par am name="P aramTarget " select=" $ParamSpli tsFrame/ww splits:Wra pper/@path " /> | |||||
3005 | </xs l:call-tem plate> | |||||
3006 | </xsl :attribute > | |||||
3007 | ||||||
3008 | <!-- Alt Text - -> | |||||
3009 | <!-- - -> | |||||
3010 | <xsl: attribute name="alt" > | |||||
3011 | <xsl :call-temp late name= "Images-Al tText"> | |||||
3012 | <xs l:with-par am name="P aramFrame" select="$ ParamFrame " /> | |||||
3013 | <xs l:with-par am name="P aramBehavi orFrame" s elect="$Pa ramBehavio rFrame" /> | |||||
3014 | </xs l:call-tem plate> | |||||
3015 | </xsl :attribute > | |||||
3016 | </wwli nks:LinkIn fo> | |||||
3017 | </xsl:w hen> | |||||
3018 | ||||||
3019 | <!-- Li nk --> | |||||
3020 | <!-- --> | |||||
3021 | <xsl:wh en test="c ount($Para mFrame/wwd oc:Link[1] ) = 1"> | |||||
3022 | <xsl:c all-templa te name="L inkInfo"> | |||||
3023 | <xsl: with-param name="Par amSplits" select="$P aramSplits " /> | |||||
3024 | <xsl: with-param name="Par amLinks" s elect="$Pa ramLinks" /> | |||||
3025 | <xsl: with-param name="Par amSplit" s elect="$Pa ramSplit" /> | |||||
3026 | <xsl: with-param name="Par amDocument Link" sele ct="$Param Frame/wwdo c:Link" /> | |||||
3027 | </xsl: call-templ ate> | |||||
3028 | </xsl:w hen> | |||||
3029 | ||||||
3030 | <!-- Em pty --> | |||||
3031 | <!-- --> | |||||
3032 | <xsl:ot herwise> | |||||
3033 | <wwlin ks:LinkInf o /> | |||||
3034 | </xsl:o therwise> | |||||
3035 | </xsl:ch oose> | |||||
3036 | </xsl:tem plate> | |||||
3037 | ||||||
3038 | ||||||
3039 | <!-- wwmo de:linktex t --> | |||||
3040 | <!-- --> | |||||
3041 | ||||||
3042 | <xsl:temp late match ="wwdoc:Te xtRun" mod e="wwmode: linktext"> | |||||
3043 | <xsl:app ly-templat es mode="w wmode:link text" /> | |||||
3044 | </xsl:tem plate> | |||||
3045 | ||||||
3046 | ||||||
3047 | <xsl:temp late match ="wwdoc:Te xt" mode=" wwmode:lin ktext"> | |||||
3048 | <xsl:par am name="P aramText" select="." /> | |||||
3049 | ||||||
3050 | <wwexsld oc:Text di sable-outp ut-escapin g="yes"> | |||||
3051 | <xsl:va lue-of sel ect="$Para mText/@val ue" /> | |||||
3052 | </wwexsl doc:Text> | |||||
3053 | </xsl:tem plate> | |||||
3054 | ||||||
3055 | ||||||
3056 | <xsl:temp late match ="*" mode= "wwmode:li nktext"> | |||||
3057 | <!-- Not hing to do --> | |||||
3058 | <!-- --> | |||||
3059 | </xsl:tem plate> | |||||
3060 | ||||||
3061 | ||||||
3062 | <xsl:temp late match ="text() | comment() | process ing-instru ction()" m ode="wwmod e:linktext "> | |||||
3063 | <!-- Not hing to do --> | |||||
3064 | <!-- --> | |||||
3065 | </xsl:tem plate> | |||||
3066 | ||||||
3067 | ||||||
3068 | <!-- wwmo de:passthr ough-with- numbering --> | |||||
3069 | <!-- --> | |||||
3070 | ||||||
3071 | <xsl:temp late match ="wwdoc:Pa ragraph" m ode="wwmod e:passthro ugh-with-n umbering"> | |||||
3072 | <xsl:app ly-templat es mode="w wmode:pass through-wi th-numberi ng" /> | |||||
3073 | </xsl:tem plate> | |||||
3074 | ||||||
3075 | ||||||
3076 | <xsl:temp late match ="wwdoc:Nu mber" mode ="wwmode:p assthrough -with-numb ering"> | |||||
3077 | <xsl:app ly-templat es mode="w wmode:pass through-wi th-numberi ng" /> | |||||
3078 | </xsl:tem plate> | |||||
3079 | ||||||
3080 | ||||||
3081 | <xsl:temp late match ="wwdoc:Te xtRun" mod e="wwmode: passthroug h-with-num bering"> | |||||
3082 | <xsl:app ly-templat es mode="w wmode:pass through-wi th-numberi ng" /> | |||||
3083 | </xsl:tem plate> | |||||
3084 | ||||||
3085 | ||||||
3086 | <xsl:temp late match ="wwdoc:Te xt" mode=" wwmode:pas sthrough-w ith-number ing"> | |||||
3087 | <xsl:par am name="P aramText" select="." /> | |||||
3088 | ||||||
3089 | <wwexsld oc:Text di sable-outp ut-escapin g="yes"> | |||||
3090 | <xsl:va lue-of sel ect="$Para mText/@val ue" /> | |||||
3091 | </wwexsl doc:Text> | |||||
3092 | </xsl:tem plate> | |||||
3093 | ||||||
3094 | ||||||
3095 | <xsl:temp late match ="wwdoc:Li neBreak" m ode="wwmod e:passthro ugh-with-n umbering"> | |||||
3096 | <xsl:tex t> | |||||
3097 | </xsl:text > | |||||
3098 | </xsl:tem plate> | |||||
3099 | ||||||
3100 | ||||||
3101 | <xsl:temp late match ="*" mode= "wwmode:pa ssthrough- with-numbe ring"> | |||||
3102 | <!-- Not hing to do --> | |||||
3103 | <!-- --> | |||||
3104 | </xsl:tem plate> | |||||
3105 | ||||||
3106 | ||||||
3107 | <xsl:temp late match ="text() | comment() | process ing-instru ction()" m ode="wwmod e:passthro ugh-with-n umbering"> | |||||
3108 | <!-- Not hing to do --> | |||||
3109 | <!-- --> | |||||
3110 | </xsl:tem plate> | |||||
3111 | ||||||
3112 | ||||||
3113 | <!-- wwmo de:passthr ough --> | |||||
3114 | <!-- --> | |||||
3115 | ||||||
3116 | <xsl:temp late match ="wwdoc:Pa ragraph" m ode="wwmod e:passthro ugh"> | |||||
3117 | <xsl:app ly-templat es mode="w wmode:pass through" / > | |||||
3118 | </xsl:tem plate> | |||||
3119 | ||||||
3120 | ||||||
3121 | <xsl:temp late match ="wwdoc:Te xtRun" mod e="wwmode: passthroug h"> | |||||
3122 | <xsl:app ly-templat es mode="w wmode:pass through" / > | |||||
3123 | </xsl:tem plate> | |||||
3124 | ||||||
3125 | ||||||
3126 | <xsl:temp late match ="wwdoc:Te xt" mode=" wwmode:pas sthrough"> | |||||
3127 | <xsl:par am name="P aramText" select="." /> | |||||
3128 | ||||||
3129 | <wwexsld oc:Text di sable-outp ut-escapin g="yes"> | |||||
3130 | <xsl:va lue-of sel ect="$Para mText/@val ue" /> | |||||
3131 | </wwexsl doc:Text> | |||||
3132 | </xsl:tem plate> | |||||
3133 | ||||||
3134 | ||||||
3135 | <xsl:temp late match ="wwdoc:Li neBreak" m ode="wwmod e:passthro ugh"> | |||||
3136 | <xsl:tex t> | |||||
3137 | </xsl:text > | |||||
3138 | </xsl:tem plate> | |||||
3139 | ||||||
3140 | ||||||
3141 | <xsl:temp late match ="*" mode= "wwmode:pa ssthrough" > | |||||
3142 | <!-- Not hing to do --> | |||||
3143 | <!-- --> | |||||
3144 | </xsl:tem plate> | |||||
3145 | ||||||
3146 | ||||||
3147 | <xsl:temp late match ="text() | comment() | process ing-instru ction()" m ode="wwmod e:passthro ugh"> | |||||
3148 | <!-- Not hing to do --> | |||||
3149 | <!-- --> | |||||
3150 | </xsl:tem plate> | |||||
3151 | </xsl:styl esheet> |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2007 Araxis Ltd (www.araxis.com). All rights reserved.