From mboxrd@z Thu Jan 1 00:00:00 1970 From: Baoqiu Cui Subject: Re: DocBook exporter for Org-mode Date: Tue, 03 Mar 2009 14:21:05 -0800 Message-ID: References: <18860.14549.718412.149720@muchbodyking-lm.gateway.2wire.net> <878wnmy3g8.fsf@kassiopeya.MSHEIMNETZ> <87wsb6wmz9.fsf@kassiopeya.MSHEIMNETZ> <87d4cywawk.fsf@kassiopeya.MSHEIMNETZ> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LeczN-0001Jf-WE for emacs-orgmode@gnu.org; Tue, 03 Mar 2009 17:21:26 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LeczL-0001IL-Tq for emacs-orgmode@gnu.org; Tue, 03 Mar 2009 17:21:25 -0500 Received: from [199.232.76.173] (port=58531 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LeczL-0001ID-Qe for emacs-orgmode@gnu.org; Tue, 03 Mar 2009 17:21:23 -0500 Received: from main.gmane.org ([80.91.229.2]:56369 helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LeczL-0001Os-1S for emacs-orgmode@gnu.org; Tue, 03 Mar 2009 17:21:23 -0500 Received: from list by ciao.gmane.org with local (Exim 4.43) id 1LeczE-0008HE-FR for emacs-orgmode@gnu.org; Tue, 03 Mar 2009 22:21:16 +0000 Received: from nat-dip4.cfw-a-gci.corp.yahoo.com ([209.131.62.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 03 Mar 2009 22:21:16 +0000 Received: from cbaoqiu by nat-dip4.cfw-a-gci.corp.yahoo.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 03 Mar 2009 22:21:16 +0000 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Sebastian Rose writes: >> I have not tried it, but it seems that syntax highlighting of source >> code listing can be done. See this page: >> >> http://www.sagehill.net/docbookxsl/SyntaxHighlighting.html > > > Does this know about the fonts and colors I use in Emacs? htmlize.el > does. I don't think it will use the fonts and colors that you use in Emacs. The colors seem to be configurable, though. >>> Wouldn't it be easier to transform the XHTML to docbook through xslt? >>> The types are not lost, since all types that emacs is aware of, are >>> exported as .... >> >> It should be DocBook -> XHTML if we are talking about general >> publishing. DocBook has enough features, tags, and more importantly, >> much more available tools. > > ...and needs an editor like emacs/Org-mode because there is none :-) I am just thinking that by supporting DocBook export we can turn Emacs + Org-mode into a good DocBook editor, which should be much more powerful than other GUI-based XML/DocBook editors. > but > A) Most of those tools are simply XML related. XHTML is XML. > B) We have those information the *.org file format gives us. XHTML > export can display all those. > C) Do you really want to tell a windows user to setup a complete SGML > system, just to publish to PDF or XHTML? I have to *emphasize* this earlier: I am NOT suggesting that we should replace LaTeX or XHTML exporters with a DocBook exporter. Both LaTeX and XHTML exporters have their good features and I don't think DocBook can replace them. DocBook exporter can simply be another addition to Org-mode, and it can be used by people who need to write DocBook documents for publishing. (People use DocBook on both Windows and Unix, and normally they do not have to know the internal setup of all DocBook tools.) > It's true: Docbook is more general in sense of more non-org-users > might know Docbook, than Orgs XHTML export format. > > But for sure more non-org-users will understand the XHTML, than the > Docbook. Once we have the DocBook exporter, people do not have to know DocBook at all to write DocBook documents. All they need to know is simply text files written in Org format. :-) The DocBook documents they generate from Org-mode will be guaranteed to be valid and well-formed. > I hihgly apreciate the support of Docbook and your effort. Yet, I think > I don't want to publish XHTML through Docbook. Again, I am not suggesting that we replace current XHTML exporter, which is a great tool and I can see that people already put a lot of efforts there to make it very powerful. DocBook is just an addition. (Certainly people can use exported DocBook format to generate XHTML format in some styles different from Org-mode's native XHTML export result.) > Right now, I have a bunch of org-files, and I get a bunch of XHTML files > as output. Nothing else. No special setup required, no xslt stylesheets, > no FO or saxon.jar in $CLASSPATH (how many users know the contents of > his $CLASSPATH ?), xsltproc, xslt stylesheets, no waiting for a > Java-Application (I prefer C/C++ Tools), no waisted disk space, no > external dependencies. This is understandable. But generating DocBook documents from Emacs + Org-mode does not require these things either! How users use the generated DocBook XML files for their publishing tasks (including how to configure and tweak the final PDF format, and how to display them well as XHTML in browser, etc.) are really up to them; such things are outside of Emacs + Org-mode! [To me, within an Org-mode buffer, I can use one key binding to do all the thing I need: exporting DocBook format, creating PDF and HTML formats from exported DocBook file, etc. If I want, I can generate the info file, man page, pure text format or RTF, etc. at the same time too.] > We can't force end users to use Docbook to get XHTML. ... We should NOT. :-) > ... Java is _not_ part > of emacs, xsltproc is not part of emacs either (most of this is true for > LaTeX). > > The XHTML export _is_ part of emacs and has _no_ external > dependencies. It's results are pages displayed in every browser, even > text browsers. This is nice for XHTML exporter. The results of DocBook exporter are not supposed to be displayed directly on any browsers, just like we do not expect any browsers to display *.tex files from LaTeX exporter. > Docbook is displayed correctly in some of those browsers but only in > conjunction with a stylesheet. But not enough to publish Docbook and > your done. That's why Docbook is hardly ever met in the wild. It's badly > supported by the tools for end users and as complicated to setup, use > and transform as LaTeX (but LaTeX _is_ met in a lot in the wild). Neither LaTeX nor DocBook is easy to set up. While LaTeX is popular in academia, not so many software companies use it to write software documentation. > Please don't get me wrong. I really think supporting Docbook is a big > step. I suddenly would have a cool Docbook editor on all the systems I > work on! I'm always happy to see people making such efforts as you > did. And I hope, this will bring more users to emacs/Org-mode too. This is my thought too... Thanks a lot for all the comments! Baoqiu