[NTG-context] Context to epub: itemize

Axel Kielhorn tex at axelkielhorn.de
Tue Feb 17 07:11:16 CET 2015


Am 16.02.2015 um 19:55 schrieb Hans Hagen <pragma at wxs.nl>:

> On 2/16/2015 5:17 PM, Axel Kielhorn wrote:
>> Hi,
>> 
>> I'm trying to generate epub from ConTeXt and I couldn't get the itemize environment to work.
>> 
>> I follow http://wiki.contextgarden.net/ePub and get the structure described but when I look into the xhtml, there is no itemize environment. (At least no with Safari, Firefox or Calibre.) When use vi I see something that looks like my items in a very complex form.
>> 
>> I was expecting something like
>> 
>> <ul>
>>   <li>   </li>
>>   <li>   </li>
>> </ul>
>> 
>> but i see
>> 
>> <div class="itemgroup itemize level-1 symbol-1">
>>   <div class="item">
>>     <div class="itemtag"><m:math display="inline" xmlns:m="http://www.w3.org/1998/Math/MathML"><m:mo>•</m:mo></m:math></div>
>>     <div class="itemcontent">Listenpunkt 1</div>
>>   </div>
>>   <div class="item">
>>     <div class="itemtag"><m:math display="inline" xmlns:m="http://www.w3.org/1998/Math/MathML"><m:mo>•</m:mo></m:math></div>
>>     <div class="itemcontent">Listenpunkt 2
>>       <div class="itemgroup itemize level-2 symbol-2">
>>       <div class="item">
>>       <div class="itemtag"><m:math display="inline" xmlns:m="http://www.w3.org/1998/Math/MathML"><m:mo>−</m:mo></m:math></div>
>>     <div class="itemcontent">Listenpunkt 2.1</div></div>
>>     <div class="item">
>>     <div class="itemtag"><m:math display="inline" xmlns:m="http://www.w3.org/1998/Math/MathML"><m:mo>−</m:mo></m:math></div>
>>     <div class="itemcontent">Listenpunkt 2.2</div></div></div></div>
>>     </div>
>> 
>> Shouldn't the itemtag definition come from the default.css instead of using MathML?
>> 
>> itemgroup[symbol="1"], div.itemgroup.symbol-1 { list-style-type : disc ; }
>> 
>> I’m using: mtx-context     | current version: 2015.02.03 23:55
>> 
>> and
>> 
>> context --script epub --make epub_mwe
>> 
>> to create the epub.
> 
> the bullets come from math fonts (currently, awaiting additional symbols in the text fonts)


Yes I know.
Let me rephrase the question:

Should the symbols used in epub be identical to those used in the pdf or should the css determine the look of the symbols?
Especially when one considers that most current ebook readers can't display MathML.

Even if I substitute the Symbols:

\definesymbol[uni1][•]
\definesymbol[uni2][–]
\definesymbol[uni3][*]
\definesymbol[uni4][·]

\setupitemgroup [itemize] [1] [symbol=uni1]
\setupitemgroup [itemize] [2] [symbol=uni2]
\setupitemgroup [itemize] [3] [symbol=uni3]
\setupitemgroup [itemize] [4] [symbol=uni4]

I get a result that neither ADE nor Calibre interprets as a list.
(Wrapping it in <ul> </ul> doesn't help.) 

Axel



More information about the ntg-context mailing list