Function Reference: function_texi2html

pkg-octave-doc: function_texi2html (fcnname, pkgfcns, info)

Generate HTML page for a particular function.

function_texi2html requires three input arguments: fcnname, a char string with the function’s name; pkgfcns, a cell array with all available functions of a package; and info, a structure with relevant information about the package, which the function fcnname belongs to.

pkgfcns can be either a N×2 or a N×3 cell array, whose 1st column list all available function names, the 2nd column list the each function’s category, and the 3rd column contains the URL to the function’s source code. pkgfcns is used to relative references to other pages of functions which are listed in the See also tag. When a 3rd column is present, function_texi2html uses it to add a source code link of the the function in fcnname.

The info structure requires at least the following fields:

Field NameDescription
PKG_ICONThe relative reference to the package’s logo image which must be either in .svg or .png format and it is located in the newly created assets/ folder inside the working directory.
PKG_NAMEThe package’s name (e.g. "pkg-octave-doc")
PKG_TITLEThe package’s title (e.g. "Octave Package Documentation")
OCTAVE_LOGOThe relative reference to Octave’s logo, also located inside the assets/ folder.

To generate a suitable N×2 cell array for a specific package, use the package_texi2html function and to populate is with the 3rd column use find_GHurls. The info structure can also be created with package_texi2html.

function_texi2html depends on the texi2html command line tool version 1.82, which must be installed and available on the system’s $PATH, and the generated HTML code is based on the function_template.html and default.html layouts.

See also: package_texi2html, classdef_texi2html, find_GHurls, build_DEMOS

Source Code: function_texi2html