This file is indexed.

/usr/share/perl5/sdf/home/stdlib/html.sdn is in sdf 2.001+1-3.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
# $Id$
#
# >>Title::     HTML Tuning
#
# >>Copyright::
# Copyright (c) 1992-1996, Ian Clatworthy (ianc@mincom.com).
# You may distribute under the terms specified in the LICENSE file.
#
# >>History::
# -----------------------------------------------------------------------
# Date      Who     Change
# 26-Apr-99 ianc    Added HTML_OLD_FOOTERS
# 29-Feb-96 ianc    SDF 2.000
# -----------------------------------------------------------------------
#
# >>Purpose::
# The {{stdlib/html.sdn}} module defines [[SDF]] configuration details for
# generating [[HTML]] files.
#
# >>Description::
#
# >>Limitations::
#

# Make HTML a restricted family of variables
!restrict 'HTML'

# Declare HTML document variables
!block variables; family="HTML"; export
Name                        Type            Rule
TITLE                       string
BG_IMAGE                    string
BG_FIXED                    boolean
BG_COLOR                    string
TEXT_COLOR                  string
LINK_COLOR                  string
VLINK_COLOR                 string
CHANGED_COLOR               string
PRE_HEADER                  string
POST_FOOTER                 string

# Section separator stuff
SECTION_LEVEL               integer
PRE_SECTION                 string

# header/footer URLs
URL_HOME                    string
URL_CATALOG                 string
URL_SEARCH                  string

# Navigation text
TEXT_CONTENTS               string
TEXT_PARENT                 string
TEXT_PREVIOUS               string
TEXT_NEXT                   string
TEXT_HOME                   string
TEXT_CATALOG                string
TEXT_SEARCH                 string

# Stuff for building topics
TOPIC                       string
SDT                         string
TOPIC_PATTERN               string

# For now, this is the way to tune table unit widths
TABLE_UNIT                  number
!endblock

# Declare HTML paragraph attributes
!block paraattrs; family="html"
Name                Type            Rule
!endblock

# Declare HTML phrase attributes
!block phraseattrs; family="html"
Name            Type            Rule
!endblock

# Declare HTML table parameters
!block tableparams; family="html"
Name            Type            Rule
!endblock

# Declare HTML row parameters
!block rowparams; family="html"
Name            Type            Rule
!endblock

# Declare HTML cell parameters
!block cellparams; family="html"
Name                Type            Rule
!endblock

# Define paragraph styles (default is P if not known and not below)
!block parastyles
Name        To                      Attributes
Line        HR
PB          HR
Addr        ADDRESS
Sign        ADDRESS
TITLE       TITLE
!endblock

# Mapping of phrase styles (default is Name if not below)
# The SDF_* one will be ignored - this seems better than "UNKNOWN"
!block phrasestyles
Name    To
A       SDF_ASIS
B       B
I       I
N       SDF_NORMAL
U       U
EX      TT
FILE    TT
#JUMP    A
1       EM
2       STRONG
3       =U
SUB     SUB
SUP     SUP
S       SDF_ASIS
ST      STRONG
Y       =ST
!endblock


# Mapping tables for attribute/parameter values
!block script
%html_align = (
    '1',    'Justify',
    'Full', 'Justify',
);
!endblock

# Mapping of paragraph attributes
!block paraattrs
Name        To          Map         Attributes
align       align       %html_align
!endblock

# Mapping of phrase attributes
!block phraseattrs
Name        To          Map         Attributes
family
size
bold
italics
underline
changed
color
!endblock

# Mapping of cell parameters
!block cellparams
Name        To          Map         Parameters
!endblock

## Set the default navigation text strings
#!define HTML_TEXT_CONTENTS      "Contents"
#!define HTML_TEXT_PARENT        "Parent Topic"
#!define HTML_TEXT_PREVIOUS      "Previous Topic"
#!define HTML_TEXT_NEXT          "Next Topic"
#!define HTML_TEXT_HOME          "Home"
#!define HTML_TEXT_CATALOG       "Catalog"
#!define HTML_TEXT_SEARCH        "Search"

## Set the default color for changed text
!default HTML_CHANGED_COLOR "teal"

# Setup the default section separator stuff
!default HTML_SECTION_LEVEL $var{'HTML_SUBTOPICS_MODE'} ? 2 : 1
!if HTMLDOC
    !macro HTML_PRE_SECTION
    !endmacro
!else
    !macro HTML_PRE_SECTION
    Line:
    !endmacro
!endif

# Prepend a separator before each section (the notoc stuff ensures
# that this rule isn't applied to the H1 generated by build_title)
!on paragraph '[HAP]\d';; \
    $my_style = $var{'HTML_SUBTOPICS_MODE'} ? $attr{'orig_style'} : $style; \
    if ($var{'DOC_TOC'} && substr($my_style, 1) <= $var{'HTML_SECTION_LEVEL'}) { \
        &PrependText('!HTML_PRE_SECTION') unless $attr{'notoc'}; \
    }

# In topics mode, special processing is needed on headings
!if $var{'HTML_TOPICS_MODE'} || $var{'HTML_SUBTOPICS_MODE'}
    !on paragraph '[HAP]\d';; &HtmlTopicsModeHeading
!endif

# ignore Page-breaks in html
!on paragraph 'PB';; $style = 'N'

# Default build_title output
!macro build_html_cover
!if $var{'OPT_DRIVER'} eq 'html'
        !div title
        !default DOC_TOC 2
        !default DOC_HTML_LOGO  $var{'DOC_LOGO'}
        !if DOC_HTML_LOGO
            !default DOC_HTML_LOGO_BASE  $var{'DOC_LOGO_BASE'}
            !import DOC_HTML_LOGO; align=Right; base=$var{'DOC_HTML_LOGO_BASE'}
            P1[notoc; class='doc-title'] [[DOC_TITLE]]
        !else
            P1[notoc; class='doc-title'] [[DOC_TITLE]]
        !endif
        !if $var{'OPT_STYLE'} eq 'paper'
            #Sign: [[DOC_STATUS]]
        !elsif DOC_STATUS
            Sign: {{A[class='doc-id'][[DOC_ID]]}} {{A[class='doc-status']([[DOC_STATUS]])}}
        !elsif DOC_ID
            Sign: {{A[class='doc-id'][[DOC_ID]]}}
        !endif
        Sign[class='doc-author'] [[join(", ", grep(/\w/, &Var('DOC_AUTHOR'), &Var('DOC_AUTHOR2'), &Var('DOC_AUTHOR3')))]]
        Sign[class='doc-modified'] [[DATE:DOC_MODIFIED]]
        !clear
        !enddiv

        # Setup the HTML title
        !HTML_BUILD_TITLE

        # This is no longer required now that the title is put in it's own div
        ## Mark the contents so we know where it is in topics mode
        #!block inline; target='html'
#<!-- TOC -->
#<!-- ENDTOC -->
        #!endblock
!else
    # This is used for HTML documents generated via Frame
	dName: [[DOC_TITLE]]
	dStat: [[DOC_ID]] ([[DOC_STATUS]])
	dAuth: [[join(", ", grep(/\w/, @variable{'DOC_AUTHOR', 'DOC_AUTHOR2', 'DOC_AUTHOR3'}))]]
!endif
!endmacro

# Macro for building the title of the document and/or topic
!macro HTML_BUILD_TITLE
    !if HTML_SUBTOPICS_MODE
        !if DOC_PROJECT
            !define HTML_TITLE "$var{'DOC_PROJECT'}: $var{'HTML_MAIN_TITLE'}: $var{'DOC_TITLE'}"
        !else
            !define HTML_TITLE "$var{'HTML_MAIN_TITLE'}: $var{'DOC_TITLE'}"
        !endif
    !elsif DOC_PROJECT
        !define HTML_TITLE "$var{'DOC_PROJECT'}: $var{'DOC_TITLE'}"
    !else
        !define HTML_TITLE DOC_TITLE
    !endif
!endmacro


# Subroutine to build the main document navigation line
!block script
sub _html_mdnav {
    local($mdn);

    $mdn .= '{{A[jump=HTML_URL_HOME] [[HTML_TEXT_HOME]]}} | ' if $var{'HTML_URL_HOME'};
    $mdn .= '{{A[jump=HTML_URL_CATALOG] [[HTML_TEXT_CATALOG]]}} | ' if $var{'HTML_URL_CATALOG'};
    $mdn .= '{{A[jump=HTML_URL_SEARCH] [[HTML_TEXT_SEARCH]]}} | ' if $var{'HTML_URL_SEARCH'};
    $mdn =~ s/ \| $//;
    return $mdn;
}
!endblock

# Build the default header and footer for the main document
!macro HTML_HEADER
    !HTML_NAVIGATE
!endmacro
!macro HTML_FOOTER
    !HTML_NAVIGATE
!endmacro
!macro HTML_NAVIGATE
    !if HTML_TOPICS_MODE
        !HTML_TOPIC_NAVIGATE
    !else
        !div navigate
        !define _HTML_NAV &_html_mdnav
        !if _HTML_NAV
            [align='Center'] [[_HTML_NAV]]
        !endif
        !enddiv
    !endif
!endmacro

# Build the default header and footer for topics
!macro HTML_TOPIC_HEADER
    !default DOC_TOPIC_LOGO $var{'DOC_LOGO'}
    !if DOC_TOPIC_LOGO
        !default DOC_TOPIC_LOGO_BASE  $var{'DOC_LOGO_BASE'}
        !import DOC_TOPIC_LOGO; align="Right"; base=$var{'DOC_TOPIC_LOGO_BASE'}
        !HTML_TOPIC_NAVIGATE
        !clear "Right"
    !else
        !HTML_TOPIC_NAVIGATE
    !endif
!endmacro
!macro HTML_TOPIC_FOOTER
    !HTML_TOPIC_NAVIGATE
!endmacro
!macro HTML_TOPIC_NAVIGATE
!div navigate
    !block script
    if ($var{'HTML_TOPICS_MODE'}) {
        $_next = $topics[0] . ".html";
        $_prev = $topics[$#topics] . ".html";
    }
    else {
        $_base = $var{'HTML_TOPIC'};
        $_next = $topic_next{$_base} ? $topic_next{$_base} . ".html" : '';
        $_prev = $topic_prev{$_base} ? $topic_prev{$_base} . ".html" : '';
        $_up   = $topic_up{$_base} ? $topic_up{$_base} . ".html" : '';
    }

    # Build the second navigation line, if any
    $_nav2 = &_html_mdnav;
    if ($_nav2) {
        $_nav2 = "{{CHAR:nl}}" . $_nav2;
    }
    !endblock
    
    !if HTML_TOPICS_MODE
        [align='Center']
        {{A[jump=$_prev] [[HTML_TEXT_PREVIOUS]]}}
        | {{A[jump=$_next] [[HTML_TEXT_NEXT]]}}
        [[$_nav2]]
    !else
        [align='Center']
        {{A[jump=HTML_URL_CONTENTS] [[HTML_TEXT_CONTENTS]]}}
        | {{A[jump=$_up] [[HTML_TEXT_PARENT]]}}
        | {{A[jump=$_prev] [[HTML_TEXT_PREVIOUS]]}}
        | {{A[jump=$_next] [[HTML_TEXT_NEXT]]}}
        [[$_nav2]]
    !endif
!enddiv
!endmacro

# Use old footers, if requested
!if HTML_OLD_FOOTERS
    !macro HTML_FOOTER
        !HTML_PRE_SECTION
        !HTML_NAVIGATE
    !endmacro
    !macro HTML_TOPIC_FOOTER
        !HTML_PRE_SECTION
        !HTML_TOPIC_NAVIGATE
    !endmacro
!endif