recent development directions for makeinfo
play

Recent Development Directions for makeinfo Patrice Dumas - PowerPoint PPT Presentation

Recent Development Directions for makeinfo Patrice Dumas pertusus@gnu.org GHM 2011 Texinfo and the GNU project Texinfo is the official documentation format for the GNU project Syntax similar with T EX, with structural markup,


  1. Recent Development Directions for makeinfo Patrice Dumas pertusus@gnu.org GHM 2011

  2. Texinfo and the GNU project ◮ Texinfo is the “official” documentation format for the GNU project ◮ Syntax similar with T EX, with structural markup, for technical manuals ◮ competition: Docbook benefits of XML, but lots of markup L A T EX presentation markup Asciidoc less structured ◮ two converters: texi2dvi, texi2pdf plain T EX to convert to dvi, ps, pdf makeinfo, texi2html, texi2any converts to Info, HTML, Docbook, Texinfo XML

  3. Table of Contents texi2html and makeinfo: from collaborative competition to rewrite The Texinfo Parser

  4. “Recent” makeinfo development until 2008 L M X , k o o b c o D , t f i e l p r X s L L L M M M n 8 T T T 1 H H H i : 1 3 : : : 1 0 7 1 1 . . . . . 4 4 4 4 4 2000 2005 2010

  5. In parallel with texi2html f e n r X o i t L a M z i m T o H t s , u r e c s r : t a n r p n a t a e : s m s i k c a y : h i i r m w s r c P n r e a u a o B i B D . C d R e . . . . . M K O D P L 2000 2005 2010

  6. texi2html in texinfo ◮ lilypond manual switches to texi2html ◮ July 2008 decision to switch to texi2html in texinfo if made compatible with makeinfo ◮ September 2008 last texinfo release with C makeinfo installed ◮ June 2010 last stand alone texi2html release, in texinfo source tree ◮ November 2010 possibility of a first release with texi2html as makeinfo Selling points: customization (design) Problematic points: speed and design.

  7. The new Texinfo Parser development ◮ September to November 2010 a Texinfo Parser is developped ◮ November 2010 decision to use the Parser in next release! ◮ March 2011 enhanced Info backend done ◮ August 2011 HTML backend done Selling points: correctness, customization and design. Problematic point: speed.

  8. Table of Contents texi2html and makeinfo: from collaborative competition to rewrite The Texinfo Parser

  9. The Parser and backends ◮ The Parser parses the Texinfo code into a tree ◮ Additional information is gathered on the tree, like sectioning and nodes trees ◮ Backends convert the tree to an output format ◮ Perl modules and a command (makeinfo/texi2any) ◮ First level of customization through “customization variables”. Example USE ACCESSKEY ◮ Convert::HTML fully customizable with hashes and functions

  10. The Texinfo tree Common keys for tree element cmdname the @-command name if corresponding to a command type element type, in general not present with cmdname text a text fragment args array of arguments in @-command brace, or line, or menu entry contents array, all purpose container, holding paragraph content, argument content, block command content parent the parent element extra placeholder for any other information Other keys with line numbers, and directions for sectioning commands and nodes.

  11. Example of tree @quotation Text @@ @code { c } @end quotation { ’cmdname ’ = > ’ quotation ’ , ’ contents ’ = > [ { ’ type ’ = > ’ empty line after command ’ } ’ t e x t ’ = > ’ ’ } , { ’ type ’ = > ’ paragraph ’ , ’ contents ’ = > [ { ’ t e x t ’ = > ’ Text ’ } , { ’cmdname ’ = > ’@ ’ } , { ’ t e x t ’ = > ’ ’ } , { ’cmdname ’ = > ’ code ’ , ’ args ’ = > [ { ’ type ’ = > ’ brace command arg ’ ’ contents ’ = > [ { ’ t e x t ’ = > ’ c ’ } ] } ] } , { ’ t e x t ’ = > ’ ’ } ] } ] }

  12. HTML customization Functions references called for elements. Defined in customization files. $commands conversion { ’ quotation ’ } = \ &my quotation ; sub my quotation ( $$$$$ ) { my $ c o n v e r t e r = s h i f t ; # opaque o b j e c t my $cmdname = s h i f t ; # the @ − command cmdname my $command = s h i f t ; # the t r e e o b j e c t my $args = s h i f t ; # formated arguments a r r a y my $content = s h i f t ; # formatted content my $ r e s u l t = ’ ’ ; i f ($command − > { ’ e x t r a ’ } and $command − > { ’ e x t r a ’ }− > { ’ authors ’ } ) { $ r e s u l t = ’ With author ’ ; } $ r e s u l t .= ’ pre ’ i f ( $converter − > i n p r e f o r m a t t e d ( ) ) ; $ r e s u l t .= $args − > [0] − > { ’ normal ’ } i f ( $args − > [0]); return $ r e s u l t . $content ; }

  13. The future ◮ a release as soon as possible (docbook, Texinfo XML) ◮ @node and @menu automatic generation ◮ re-enable math formatting through latex2html/tex4ht ◮ maybe revive Mediawiki, roff outputs ◮ finish L A T EX backend ◮ epub, odp? ◮ use m4 to preprocess the Texinfo ◮ more simple math commands, and math environments

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend