Re: [NTG-context] HTML output

2013-02-19 Thread Marco Patzer
On 2013–02–19 Troy Henderson wrote:

 I would like to convert my ConTeXt document to both PDF and plain HTML.

My suggestion: Use markdown (or reST) with pandoc.

 I need plain HTML output (i.e., not XML or XHTML) because my institution's
 web based management software allows me to copy/paste plain HTML snippets
 but not XML or XHTML.

ConTeXt does output XML, not XHTML. You would need to do the
XML → XHTML conversion yourself.

 Is it possible for ConTeXt to output HTML so that the result looks
 as close to the PDF output as possible?

\startnitpicking
  HTML does not look like anything. It's a markup language that simply
  states that *this* element is a header and *that* element is a list,
  etc. How the HTML is rendered is mostly controlled by the CSS.
\stopnitpicking

Within the limits of CSS you obtain a quite close match¹. But it's
up to you to create the matching CSS.

Marco


¹ http://tex.stackexchange.com/a/55945/5245


signature.asc
Description: Digital signature
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] HTML output

2013-02-19 Thread Bill Meahan

On 02/19/2013 09:22 AM, Marco Patzer wrote:

Within the limits of CSS you obtain a quite close match¹. But it's
up to you to create the matching CSS.

Marco

You can do a pretty good job of matching the printed page with HTML5 + 
CSS3 here's a good reference:


http://www.w3schools.com/html/default.asp

Unfortunately, implementation of these standards is a bit spotty. The 
problem is in the browsers. Chrome/Chromium has done the best job of 
implementing HTML5 to date, IE the worst. with Firefox and Safari in 
between.


Similarly, EPUB (based on XHTML) is in a similar situation. EPUB3 is 
based on HTML5 while EPUB2 on XHTML1.1 The corresponding CSS support 
tells you how well most e-book readers handle the new format. At the 
moment, there is very little support for EPUB3 in applications and 
dedicated readers (Kindle, Nook  al.)


It's best if you design your document with these formats in mind or put 
up with how your document is rendered.


As a not-very-good fallback, you can always convert your document to 
PNG/JPEG images and use HTML to simply display them in the proper order.


--
Bill Meahan
Westland, Michigan USA

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] HTML output

2013-02-19 Thread Aditya Mahajan

On Tue, 19 Feb 2013, Troy Henderson wrote:


I would like to convert my ConTeXt document to both PDF and plain HTML.
I need plain HTML output (i.e., not XML or XHTML) because my institution's
web based management software allows me to copy/paste plain HTML snippets
but not XML or XHTML.


I was in a similar position, and, in the end opted for markdown + 
gpp-preprocessing as the input format, and using pandoc to convert from 
markdown to HTML and ConTeXt.


Aditya
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] HTML output

2013-02-19 Thread Henning Hraban Ramm

Am 2013-02-19 um 19:08 schrieb Bill Meahan:

 On 02/19/2013 09:22 AM, Marco Patzer wrote:
 Within the limits of CSS you obtain a quite close match¹. But it's
 up to you to create the matching CSS.
 
 Marco
 
 You can do a pretty good job of matching the printed page with HTML5 + CSS3 
 here's a good reference:
 http://www.w3schools.com/html/default.asp

No, that's not a good reference. Please read http://w3fools.com/ and refere to 
an actual reference like http://www.w3.org/wiki/HTML/Elements or 
https://developer.mozilla.org/en-US/docs/HTML/Element


Greetlings, Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___