use strict; sub my_set_shortcontents_header { my $self = shift; my $special_elements_heading = $self->get_conf('SPECIAL_ELEMENTS_HEADING'); $special_elements_heading->{'Overview'} = {}; # other example #$special_elements_heading->{'Overview'} = $self->gdt('@slanted{heeadeer}'); } texinfo_register_handler('structure', \&my_set_shortcontents_header); # if there is a @documentlanguage, the string will be changed # change it back again here sub my_set_shortcontents_header_translation { my $self = shift; my $cmdname = shift; my $command = shift; my $result = &{$self->default_commands_conversion($cmdname)}($self, $cmdname, $command, undef); my $special_elements_heading = $self->get_conf('SPECIAL_ELEMENTS_HEADING'); $special_elements_heading->{'Overview'} = {}; # other example #$special_elements_heading->{'Overview'} = $self->gdt('@slanted{heeadeer}'); return $result; } texinfo_register_command_formatting('documentlanguage', \&my_set_shortcontents_header_translation); 1;