From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rick Frankel Subject: Re: [PATCH] export to various flavors of (X)HTML Date: Tue, 30 Apr 2013 10:38:44 -0400 Message-ID: References: <87y5cdkiuj.fsf@ericabrahamsen.net> <20130423010019.GA65517@BigDog.local> <87sj2h3m3s.fsf@ericabrahamsen.net> <86wqrtwisf.fsf@iro.umontreal.ca> <517732AF.6080308@gmail.com> <86y5c82hxy.fsf@iro.umontreal.ca> <871u9ytihc.fsf@ericabrahamsen.net> <8f433f7c2e7d4892d6286afc9524d9a6@mail.rickster.com> <87li85tdsm.fsf@ericabrahamsen.net> <20130426184949.GB79236@BigDog.local> <87bo8xeuxd.fsf@ericabrahamsen.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([208.118.235.92]:39814) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UXBhj-0002qY-DS for emacs-orgmode@gnu.org; Tue, 30 Apr 2013 10:38:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UXBhd-0006bW-23 for emacs-orgmode@gnu.org; Tue, 30 Apr 2013 10:38:51 -0400 Received: from [204.62.15.78] (port=58590 helo=mail.rickster.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UXBhc-0006bQ-VS for emacs-orgmode@gnu.org; Tue, 30 Apr 2013 10:38:45 -0400 In-Reply-To: <87bo8xeuxd.fsf@ericabrahamsen.net> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org On 29.04.2013 02:02, Eric Abrahamsen wrote: > Rick Frankel writes: > >> On Fri, Apr 26, 2013 at 10:14:17AM -0700, Eric Abrahamsen wrote: >>> Rick Frankel writes: >>> > See the discussions of polyglot markup @ >>> > http://en.wikipedia.org/wiki/Polyglot_markup >>> > and >>> > >>> http://www.w3.org/TR/2011/WD-html-polyglot-20110405/#dfn-polyglot-markup >>> > for the rationale. >>> >>> Ah, those were interesting links, I hadn't considered those issues. >>> Luckily, your second option was a three-line change to the existing >>> patch: using "xhtml5" now produces the same output as "html5", >>> except >>> that self-closing tags are self-closed, and there's a xmlns >>> declaration >>> in the element. Best of all worlds, I hope. >> Overall, works well. A couple of things related to `org-html-xml-declaration': - It should not be added by default for xhtml5 (from http://www.w3.org/TR/2011/WD-html-polyglot-20110405/#PI-and-xml): #+BEGIN_QUOTE 2. Processing Instructions and the XML Declaration Processing Instructions and the XML Declaration are both forbidden in polyglot markup. #+END_QUOTE - If `org-html-xml-declaration' is set to nil or the empty string, a blank first line is placed in the document prior to the DOCTYPE declaration. If the above fix is added (so it is not generated for xhtml5) that should solve the immediate problem, but i think that the formatting code in org-html-html-template should check that the inner format (line #1697). A patch is attached to fix both issues. > 1. There's a new export option, > org-html-html5-fancy/HTML_HTML5_FANCY, > which defaults to 'nil, making most of the following opt-in only. Very nice. > 5. It's generally accepted that one should use some variety of the > html5shiv[1] to make IE <9 render new HTML5 elements correctly. I've > dropped a note to this effect in the docstring of > `org-html-html5-fancy', but I suppose it's possible we could take a > more > interventionist stance, perhaps including hosting a version of the > shiv > on orgmode.org, and linking to it automatically. I guess I'm in favor > of > leaving it to the user, though. I agree that we should comment and leave it to the user. I believe the owner of html5shiv is against CDN hosting the javascript and feels that it should always be downloaded and included locally. > Tangential coding question: I've noticed that setting > HTML_HTML5_FANCY > to nil at the top of the export file results in `(plist-get info > :html-html5-fancy)' returning the string "nil", ie true. Not right, > obviously, and it makes it impossible to set it to 'nil per-file if > the > global value is 't. Am I handling this wrong? I believe Nicolas answered the is a previous email, but the solution is use "'()" and not nil. rick