[NTG-context] context -> docx ??

Idris Samawi Hamid ادريس سماوي حامد ishamid at colostate.edu
Wed Jan 14 21:29:05 CET 2015

Hi Pablo,

On Wed, 14 Jan 2015 13:15:38 -0700, Pablo Rodriguez <oinos at gmx.es> wrote:

>> There must be some way to get this into Word...

> pandoc may be the way.

> I say “may be” instead of “is” because pandoc ignores some attributes
> when converting from XHTML

> (http://pandoc.org/try/?text=%3Cp%3EThis+is+sample+with+a+foreign+word%3A+%3Cem+lang%3D%22de%22%3EFremdsprache%3C%2Fem%3E.%3C%2Fp%3E&from=html&to=markdown).

I was just about to ask about how pandoc handles xhtml. Some questions for  

Context produces three relevant files:


1. Which one of these three files is the one we want to convert to docx?

2. I modified Alan's test file [same preamble]:


\input darwin

\bf \input darwin


darwin-xml-div.xhtml and darwin-xml-tag.xhtml show up in the browser, but  
the bold does not. In Opera 12.17, darwin-xml-raw.xml gives a syntax error

XML parsing failed: syntax error (Line: 17, Character: 0)

But the "Reparse document as HTML" does work.

In each of the three cases, there is no bold effect at all.

What is needed to get the typography info transmitted?

3. My assumption is this: If I can get the xml/xhtml file looking right in  
the browser, I should be able to build a working docx file via pandoc.

Thanks for any and all advice! and

Best wishes
Idris Samawi Hamid
Professor of Philosophy
Colorado State University
Fort Collins, CO 80523

More information about the ntg-context mailing list