File: texi2html.init

package info (click to toggle)
maxima 5.47.0-9
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 193,104 kB
  • sloc: lisp: 434,678; fortran: 14,665; tcl: 10,990; sh: 4,577; makefile: 2,763; ansic: 447; java: 328; python: 262; perl: 201; xml: 60; awk: 28; sed: 15; javascript: 2
file content (36 lines) | stat: -rw-r--r-- 1,073 bytes parent folder | download | duplicates (2)
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
$options->{"EXTRA_HEAD"} = '<link rel="icon" href="figures/favicon.ico">
<script src="https://polyfill.io/v3/polyfill.min.js?features=es6>"></script>
<script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>';

# Make the output file names consist of the base name followed by a number.
use strict;

use vars qw($element_file_name);

my $file_nr = -1;

sub filename_simple($$$)
{
  my $converter = shift;
  my $element = shift;
  my $filename = shift;

  my $prefix = $converter->{'document_name'};
  # If we're not splitting, just return the name.
  if (!get_conf('SPLIT')) {
    return $prefix.'.'.$converter->get_conf('EXTENSION');
  }
  if ($converter->element_is_top($element)) {
    # The table of contents file should be named this.
    return "maxima_toc.html";
  } else {
    $file_nr++;
    if ($file_nr == 0) {
      return $prefix.'.'.$converter->get_conf('EXTENSION');
    } else {
      return $prefix.'_'.$file_nr.'.'.$converter->get_conf('EXTENSION');
    }
  }
}

$element_file_name = \&filename_simple;