[tex4ht] [bug #387] New commands for semantic elements

Michal Hoftich michal.h21 at gmail.com
Wed Feb 7 14:45:13 CET 2018


                 Summary: New commands for semantic elements
                 Project: tex4ht
            Submitted by: michal_h21
            Submitted on: Wed 07 Feb 2018 03:45:13 PM EET
                Category: None
                Priority: 5 - Normal
                Severity: 5 - Normal
                  Status: None
                 Privacy: Public
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any



I've created some alternative commands to \HCode or \Tg. The idea is to define
semantic names for logical elements of the document, such as titles, authors,
sections etc. It is possible to assign HTML elements and attributes to these
logical elements. There are commands for inline and block level elements,
which should eliminate the need for constructs like \ifvmode\IgnorePar\fi\EndP

I think it will be best to show some concrete examples:






The \NewLogicalBlock creates a new logical element. The used tag is configured
using \SetTag, the attributes are set using \SetBlockProperty. The blocks are
inserted to the document using \InlineElementStart ...  \InlineElementEnd or
\BlockElementStart ... \BlockElementEnd pairs. The start commands take two
parameters, first is the logical block name, the second can be local
parameters which shouldn't be used for the given logical block globally. 

The main idea behind this mechanism is to allow easy work with new HTML5
elements and attributes for WAI-ARIA or Schema.org properties. I hope that
this should allow us to make somehow more clear configurations for basic
document building blocks.


Reply to this item at:


  Message sent via/by Puszcza

More information about the tex4ht mailing list