Debian Codegraph @

texmf-dist/tex/generic/tex4ht/javahelp-a.4ht

raw
1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2 % javahelp-a.4ht 2008-07-23-00:03 %
3 % Copyright (C) 2003--2008 Eitan M. Gurari %
4 % %
5 % This work may be distributed and/or modified under the %
6 % conditions of the LaTeX Project Public License, either %
7 % version 1.3 of this license or (at your option) any %
8 % later version. The latest version of this license is %
9 % in %
10 % http://www.latex-project.org/lppl.txt %
11 % and version 1.3 or later is part of all distributions %
12 % of LaTeX version 2003/12/01 or later. %
13 % %
14 % This work has the LPPL maintenance status "maintained".%
15 % %
16 % This Current Maintainer of this work %
17 % is Eitan M. Gurari. %
18 % %
19 % If you modify this program your changing its signature %
20 % with a directive of the following form will be %
21 % appreciated. %
22 % \message{signature} %
23 % %
24 % [email protected] %
25 % http://www.cse.ohio-state.edu/~gurari %
26 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
27 \immediate\write-1{version 2008-07-23-00:03}
28
29 \NextFile{\jobname.tmp}
30 \HPage{}
31 \bgroup
32 \catcode`\:=11
33 \catcode`\@=11
34 \catcode`\"=12
35 \Configure{PROLOG}{}
36 \Configure{HtmlPar}{}{}{}{}
37 \Configure{tableofcontents}{}{}{}{}{}
38 \Configure{htf}{0}{+}{}{}{}{}{}{}{}
39 \ScriptEnv{dito}{\IgnorePar}{}
40 \a:jhxml
41 \def\set:endtocitem#1{%
42 \csname catchAt:#1\endcsname
43 \expandafter\ifx\csname a:end#1\endcsname\relax
44 \HCode{</tocitem>}%
45 \else
46 \expandafter\ifx \csname jh:#1\endcsname\relax
47 \append:def\end:jhhook{%
48 \csname jh:#1\endcsname
49 \expandafter\global\expandafter
50 \let\csname jh:#1\endcsname\:UnDef}%
51 \global\let\end:jhhook\end:jhhook
52 %
53 \def\:tempc##1,{\if ,##1,%
54 \expandafter\gob:pardel
55 \else
56 \expandafter\ifx \csname catchAt:##1\endcsname \relax
57 \expandafter\gdef\csname
58 catchAt:##1\endcsname{\csname jh:#1\endcsname}%
59 \else
60 \expandafter\pend:def\csname
61 catchAt:##1\endcsname{\csname jh:#1\endcsname}%
62 \expandafter\global\expandafter\let\csname
63 catchAt:##1\expandafter\endcsname\csname catchAt:##1\endcsname
64 \fi
65 %
66 \expandafter\:tempc
67 \fi}%
68 \expandafter\expandafter\expandafter
69 \:tempc\csname a:end#1\endcsname,,!*?: %
70 \fi
71 \csname jh:#1\endcsname
72 \expandafter\gdef\csname jh:#1\endcsname{%
73 \expandafter\global\expandafter\let\csname jh:#1\endcsname=\empty
74 \HCode{</tocitem><!--/#1-->}}%
75 %
76 \fi
77 }
78 \def\gob:pardel#1!*?: {}
79
80 \edef\tocLabel{\ifx\contentsname\:UnDef Table Of Contents\else
81 \ifx\contentsname\empty Table Of Contents\else
82 \contentsname\fi\fi}
83 \edef\indexLabel{\ifx\indexname\:UnDef Index\else
84 \ifx\indexname\empty Index\else \indexname\fi\fi}
85 \ifTag{TITLE+}
86 {\edef\titleLabel{\LikeRef{TITLE+}}}
87 {\def\titleLabel{\jobname}}
88
89 \IgnorePar\par\leavevmode\special{t4ht>\jobname.hs}%
90 \begin{dito}-\
91 <?xml version="1.0" encoding="ISO-8859-1" ?>
92 \end{dito}
93 \begin{dito}-\
94 <!DOCTYPE helpset PUBLIC
95 "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version \dotVersion//\dTdLaNg"
96 "http://java.sun.com/products/javahelp/helpset_\subVersion.dtd">
97 \end{dito}
98
99 \begin{dito}-\
100 <!-\relax- \jhNote
101 -\relax->
102 <helpset version="\dotVersion">
103 <title>\titleLabel</title>
104 <maps>
105 <homeID>\jobname</homeID>
106 <mapref location="\jobname.jhm"/>
107 </maps>
108 <view>
109 <name>TOC</name>
110 <label>\tocLabel</label>
111 <type>javax.help.TOCView</type>
112 <data>\jobname-jht.xml</data>
113 </view>
114 <view>
115 <name>Index</name>
116 <label>\indexLabel</label>
117 <type>javax.help.IndexView</type>
118 <data>\jobname-jhi.xml</data>
119 </view>
120 <view>
121 <name>Search</name>
122 <label>Search</label>
123 <type>javax.help.SearchView</type>
124 <data
125 engine="com.sun.java.help.search.DefaultSearchEngine">\jobname-jhs</data>
126 </view>
127 </helpset>
128 \end{dito}
129 \IgnorePar\par\leavevmode\special{t4ht<\jobname.hs}
130
131 \bgroup
132 %\immediatetrue
133 \Configure{TocLink}
134 {\HCode{<tocitem target="\a:mapIdTarget"\Hnewline
135 text="}\hbox{#4}\HCode{ ">\Hnewline}}
136 \let\jh:doTocEntry\:doTocEntry
137 \def\:doTocEntry#1#2#3{%
138 \edef\sectioningKey{\expandafter\gob:IV\string#1}%
139 \edef\:temp{\noexpand\ConfigureToc{\sectioningKey}
140 {}{\noexpand\set:endtocitem{\sectioningKey}}{}{}}\:temp
141 \expandafter\target:info#3//%
142 \b:mapIdTarget
143 %
144 \jh:doTocEntry#1{#2}{#3}}
145 \def\gob:IV#1#2#3#4{}
146 \def\sectioningKey{NoToc}
147
148 \IgnorePar\par\leavevmode\special{t4ht>\jobname-jht.xml}%
149 \begin{dito}-\
150 <?xml version="1.0" encoding="ISO-8859-1" ?>
151 \end{dito}
152 \begin{dito}-\
153 <!DOCTYPE toc PUBLIC
154 "-//Sun Microsystems Inc.//DTD JavaHelp TOC Version \dotVersion//\dTdLaNg"
155 "http://java.sun.com/products/javahelp/toc_\subVersion.dtd">
156 \end{dito}
157
158 \begin{dito}-\
159 <!-\relax- \jhNote
160 -\relax->
161 <toc version="\dotVersion">
162 <tocitem target="\jobname" text="\titleLabel ">
163 \end{dito}
164 \let\end:jhhook=\empty
165 \catcode`\:=12 \catcode`\@=12 \let\contentsname\empty
166 \NoFonts
167
168 \expandafter\ifx \csname jh:toc\endcsname\relax
169 \tableofcontents
170 \else
171 \expandafter\expandafter\expandafter\tableofcontents
172 \expandafter\expandafter\expandafter[\csname
173 jh:toc\endcsname]%
174 \fi
175 %
176 \EndNoFonts
177 \catcode`\:=11 \catcode`\@=11
178 \end:jhhook
179 \begin{dito}
180 </tocitem>
181 </toc>
182 \end{dito}
183 \special{t4ht<\jobname-jht.xml}
184
185 \egroup
186
187 \bgroup
188
189 \IgnorePar\par\leavevmode\special{t4ht>\jobname-jhi.xml}%
190 \begin{dito}-\
191 <?xml version="1.0" encoding="ISO-8859-1" ?>
192 \end{dito}
193 \begin{dito}-\
194 <!DOCTYPE index PUBLIC
195 "-//Sun Microsystems Inc.//DTD JavaHelp Index Version \dotVersion//\dTdLaNg"
196 "http://java.sun.com/products/javahelp/index_\subVersion.dtd">
197 \end{dito}
198
199 \begin{dito}-\
200 <!-\relax- \jhNote
201 -\relax->
202 <index version="\dotVersion">
203 \end{dito}
204
205 \let\indexname\empty
206 \def\gobbleLnk#1, \LNK#2#3#4#5{#1\HCode{" target="indexentry-#5"}}
207 \Configure{theindex}
208 {}{}
209 {\hbox\bgroup\HCode{<\string !--index-item--><indexitem
210 text="}\gobbleLnk}
211 {\HCode{/>}\egroup\hfill\break}
212 {\hbox\bgroup\HCode{<\string !--subex-item--><indexitem
213 text="}\gobbleLnk}
214 {\HCode{/>}\egroup\hfill\break}
215 {\hbox\bgroup\HCode{<\string !--subsubitem--><indexitem
216 text="}\gobbleLnk}
217 {\HCode{/>}\egroup\hfill\break}
218 {}
219 \immediate\openin15=\jobname.ind
220 \ifeof15
221 \immediate\closein15
222 \else
223 \immediate\closein15
224 \input \jobname.ind
225 \fi
226 %
227 \begin{dito}
228 </index>
229 \end{dito}
230 \special{t4ht<\jobname-jhi.xml}%
231
232 \egroup
233
234 \special{t4ht>\jobname.jhm}%
235 \bgroup
236 \Configure{Link}{mapID}{target="\a:mapIdTarget" url=}{}{}
237 \Configure{TocLink}{\Link{#2}{}\EndLink}
238 \let\jh:doTocEntry\:doTocEntry
239 \def\:doTocEntry#1#2#3{%
240 \edef\sectioningKey{\expandafter\gob:IV\string#1}%
241 \edef\:temp{\noexpand\ConfigureToc{\sectioningKey}
242 {}{\relax}{}{}}\:temp
243 \expandafter\target:info#3//%
244 \b:mapIdTarget
245 %
246 \jh:doTocEntry#1{#2}{#3}}
247 \def\gob:IV#1#2#3#4{}
248 \def\sectioningKey{NoToc}
249
250 \bgroup \catcode`\:=12 \catcode`\@=12 \let\contentsname\empty
251 \expandafter\ifx \csname jh:toc\endcsname\relax
252 \tableofcontents
253 \else
254 \expandafter\expandafter\expandafter\tableofcontents
255 \expandafter\expandafter\expandafter[\csname
256 jh:toc\endcsname]%
257 \fi
258 %
259 \egroup
260 \HCode {</map>\Hnewline}
261 \egroup
262 \special{t4ht*>\jobname.jhm}%
263 \special{t4ht*>}%
264
265 \egroup
266 \EndHPage{}
267