If files are specified, htmlsection reads HTML from these files. But, if files are not specified, htmlsection reads HTML from standard input.
Synopsis:
htmlsection [-options] [files ...]
> makesearch path to perl, create head of script (Ex. #!/usr/bin/perl), create comments from README, create manual page, make htmlsection from htmlsection.pl, and create htmlsection.html from htmlsection_orig.html.
> cat htmlsection_orig.html | ./htmlsection -english > htmlsection.html
> su Password: # make installhtmlsection and manual page are installed to your system.
> su Password: # make uninstallhtmlsection and manual page are deleted from your system.
list3.1: Section Number Example
<section name="intro" number=no>Introduction</section> This is introduction. <section name="howto">How to use htmlsection</section> <subsection name="howtouse">Let's use htmlsection!</subsection> If you want to know about htmlsection, see <sectionref name="howto">, and <subsectionref name="howtouse" title=no>. <section number=no>Ending</section>
And execute,
> cat example.html | htmlsectionhtmlsection will output as list3.2.
list3.2: Section Number Example after Convertion
list3.3: Table, Figure and List Number ExampleAfter convertion by htmlsection, See list3.4.
<center> <tablereference name="sample_table">Sample Table</tablereference> <table border=1> <tr><td align=center>name</td><td align=center>function</td></tr> <tr><td>printf</td><td>print strings by a format.</td></tr> </table> </center> <p> <center> <img src="picture/sample.jpg"> <br> <figurereference name="sample_figure">Sample Figure</figurereference> </center> <p> <pre> <listreference name="sample_list">Sample List</listreference> int main() { int i; for (i = 0; i < 10; i++) printf("%d\n", i); exit (0); } </pre> <p> See <tableref name="sample_table">. See <figureref name="sample_figure">. See <listref name="sample_list">.
list3.4: Table, Figure and List Number Example after Convertion
name | function |
printf | print strings by a format. |
list1: Sample List int main() { int i; for (i = 0; i < 10; i++) printf("%d\n", i); exit (0); }
See table1. See figure1. See list1.
list3.5: Reference ExampleAfter convertion by htmlsection, See list3.6.
See <ref name="KandR2">. <references> <reference name="KandR">Brian W. Kernighan and Dennis M. Ritchie, "The C Programming Language", Prentice-Hall, 1978. <reference name="KandR2">Brian W. Kernighan and Dennis M. Ritchie, "The C Programming Language", Second Edition, Prentice Hall, 1988. <reference name="NumericalRecipe">William H. Press, Saul A. Teukolsky, William T. Vetterling, and Brian P.Flannery, "Numerical Recipes in C", Second Edition, Cambridge University Press, 1992. </references>
list3.6: Reference Example after ConvertionSee [2].
Option | Description |
-h, -help | Output help messages. |
-max-depth [depth] | Specify the max depth of subsection of section tag. If you specify -max-depth 10, you can use <subsubsubsubsubsubsubsubsubsection> tag. |
-spacer | Spacing <section>, <subsection> and <subsubsection> tag. |
-no-spacer | No spacing. |
-english, -japanese |
Specify the language. If you don't specify these options, htmlsection sees environment variable LANG. |
-start-section [section] | Specify the section number at start. For example, if you specify -start-section 3.5.6, htmlsection sets the section number to it at start. |
-toc-section [section] | Specify the section depth to make the table of contents. If you specify -toc-section 2, htmlsection makes the table of contents by section and subsection only. |
-table-section [section] | Specify the section number at beginning of table number. If you specify -table-section 2, format of table number is [section_number].[subsection_number].[table_number]. If you specify -table-section 0, format of table number is [table_number] only. |
-figure-section [section], -list-section [section] |
Same as -table-section option. |
-start-table [number] | Specify the table number at start. |
-start-figure [number], -start-list [number], -start-ref [number] |
Same as -start-table option. |
-toc-file [filename] | If you specify -toc-file, output the table of contents to the file. |
-table-file [filename] | If you specify -table-file, output the table index to the file. |
-figure-file [filename], -list-file [filename] |
Same as -table-file option. |
-o [filename] | Specify the output file. If you don't specify the filename, htmlsection outputs HTML to the standard output. |
Variable | Description |
LANG | Specify the language. |
Tag | Options |
<section>Title</section>, <subsection>Title</subsection>, ... |
name="section_name"
number=yes or no |
<sectionref>, <subsectionref>, ... |
name="section_name"
title=yes or no |
<tablereference>Title</tablereference> |
name="table_name"
number=yes or no |
<figurereference>Title</figurereference> |
name="figure_name"
number=yes or no |
<listreference>Title</listreference> |
name="list_name"
number=yes or no |
<tableref>Title</tableref> |
name="table_name"
title=yes or no |
<figureref>Title</figureref> |
name="figure_name"
title=yes or no |
<listref>Title</listref> |
name="list_name"
title=yes or no |
<references></references> | none |
<reference> | name="reference_name" |
<ref> |
name="reference_name"
title=yes or no |
<tableofcontents></tableofcontents> | none |
<tableindex></tableindex> | none |
<figureindex></figureindex> | none |
<listindex></listindex> | none |
E-Mail: sakai@seki.ee.kagu.sut.ac.jp, hsakai@m8.people.or.jp, hsakai@pfu.fujitsu.com
Web site:
http://www.seki.ee.kagu.sut.ac.jp/~sakai/myfreesoft/index.html
Mirror site:
http://hp.vector.co.jp/authors/VA014157/myfreesoft/index.html
http://www.people.or.jp/~hsakai/myfreesoft/index.html
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version.