From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/60624 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: ConTeXt vs. LaTeX -> XML/MathML -> XHTML/SVG/PNG -> ePub Date: Mon, 2 Aug 2010 13:20:58 -0400 (EDT) Message-ID: References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1280769446 17777 80.91.229.12 (2 Aug 2010 17:17:26 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 2 Aug 2010 17:17:26 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Aug 02 19:17:20 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OfydW-0005Fn-K2 for gctc-ntg-context-518@m.gmane.org; Mon, 02 Aug 2010 19:17:14 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 35816C9E93; Mon, 2 Aug 2010 19:17:14 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 9wGBT89xIqeQ; Mon, 2 Aug 2010 19:17:02 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 30029C9E86; Mon, 2 Aug 2010 19:17:02 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 899DDC9E86 for ; Mon, 2 Aug 2010 19:17:00 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id tWOdQOywMUwr for ; Mon, 2 Aug 2010 19:16:57 +0200 (CEST) Original-Received: from hellskitchen.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.14.82]) by balder.ntg.nl (Postfix) with ESMTP id 4D12DC9E83 for ; Mon, 2 Aug 2010 19:16:56 +0200 (CEST) Original-Received: FROM [192.168.0.104] (c-71-235-82-170.hsd1.ct.comcast.net [71.235.82.170]) By hellskitchen.mr.itd.umich.edu ID 4C56FD87.5A0A8.27748 ; Authuser adityam; 2 Aug 2010 13:16:55 EDT In-Reply-To: User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:60624 Archived-At: On Mon, 2 Aug 2010, Grant W. Petty wrote: > On Mon, Aug 2, 2010 at 10:10 AM, Grant W. Petty wrote: >> I am trying out ConTeXt for the very first time, hoping to assess >> whether it's worth re-tooling from LaTeX for authoring scientific >> textbooks. >> > > To elaborate on this comment which I made in another thread, I have > written and self-published two university-level atmospheric science > textbooks in LaTeX which are doing quite well by the standards of my > small field. I am now also contracting to publish textbooks for > other authors. > > I am very interested in eventually reformatting my own existing books, > as well as future books, as documents that can be both printed as > professional-quality bound textbooks as well as distributed as e-books > -- for example ePub format and/or XHTML. The principle technical > hurdle seems to be posed by the heavy use of mathematical equations. > I want the math in the electronic versions to be very clean and > scalable (e.g., SVG; eventually MathML as e-readers do a better job of > supporting it). > > While there are programs like TeX4HT and LaTeXML that convert LaTeX > source to XML/MathML, they seem to have trouble with unfamiliar > packages and macros, and the math rendering seems quite imperfect as > well (though I can't yet tell whether that's a problem with the > conversion to MathML or rather with current e-readers imperfect > support for MathML). I think that it is better to test mathml on a recent web browser rather than ereaders. > My question is whether anyone has insight into the relative strengths > of LaTeX vs. ConTeXt as an authoring environment in the specific case > that the author wants high-quality multi-format outputs for print and > electronic distribution. An example workflow I could imagine would be > > ConTeXT or LaTeX source -> XML/MathML (DocBook?) -> PDF or > XHTML with math encoded as MathML and/or SVG and/or PNG -> ePub with > high-quality math readable on various commercial readers > > I'm quite new to this subject matter, having only begun to learn about > e-publishing formats a couple of weeks ago, so I'll welcome any > advice, however basic. Context/latex to xml will never work unless you are willing to restrict yourself to a subset of supported input syntax. If you are willing to do that, then a cleaner alternative to is to *input* all your text as XML. For plain text XML is not too verbose, but MathML is a pain to type by hand. There are various libraries that convert tex math markup to mathml that may ease the task. If the math is not too complicated, one option is to use asciimath. ConTeXt has some basic support for asciimath, and I believe that it is possible to convert asciimath to mathml. Another option is to explore Microsoft's linear math format. It has a well defined grammer, so in principle it will be much easier to convert it to latex/context/mathml input. The big advantage of using such a setup is that you can use the same source to display the document on web (or epub, which is essentially zipped xml files) and to generate pdf (context handles xml input very well). One less toolchain to debug. > It's my impression, by the way, that ConTeXT does not directly support > AMSMath, which might mean having to not only rewrite a lot of existing > source but also to re-learn how to write math. You can start by looking at http://dl.contextgarden.net/myway/context-latex-math.pdf 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 ___________________________________________________________________________________