From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: Radio targets with mixed capitalisation do not work in HTML export Date: Mon, 17 Mar 2014 13:04:20 +0100 Message-ID: <87zjkpghff.fsf@bzg.ath.cx> References: <874n2xlgzx.fsf@bzg.ath.cx> <87eh21qgmh.fsf@gmail.com> <87d2hlhxm2.fsf@bzg.ath.cx> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:42264) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPWHT-0000B6-8T for emacs-orgmode@gnu.org; Mon, 17 Mar 2014 08:04:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WPWHN-0004J9-Qc for emacs-orgmode@gnu.org; Mon, 17 Mar 2014 08:04:35 -0400 Received: from rs249.mailgun.us ([209.61.151.249]:58278) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPWHN-0004Il-He for emacs-orgmode@gnu.org; Mon, 17 Mar 2014 08:04:29 -0400 In-Reply-To: <87d2hlhxm2.fsf@bzg.ath.cx> (Bastien's message of "Mon, 17 Mar 2014 12:29:25 +0100") 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: Nicolas Goaziou Cc: Noah Slater , emacs-orgmode@gnu.org --=-=-= Content-Type: text/plain Bastien writes: > If we do this, I don't see the need to enforce case sensitivity. I attach a patch that illustrates the fix I propose on top on my previous commit. With this, ======================================================================== <<>> Let's say hello \alpha world to test. ======================================================================== gets converted into ========================================================================

Hello α world

Let's say hello α world to test.

======================================================================== which I think is what the OP expected. We preserve case sensitivity of the target, and we preserve the link description. (I think the confusion comes from calling "path" what is really the description when path and description are the same, like in a link to a radio target.) Let me know what you think, --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=fix-org-radio.patch diff --git a/lisp/ox-html.el b/lisp/ox-html.el index 4d6180d..0cacd57 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -2775,9 +2775,13 @@ INFO is a plist holding contextual information. See (let ((destination (org-export-resolve-radio-link link info))) (when destination (format "%s" - (org-export-data (org-element-contents destination) info) + (org-export-solidify-link-text + (org-export-data (org-element-contents destination) info)) attributes - (org-export-solidify-link-text path))))) + (org-export-data + (org-element-parse-secondary-string + path + (org-element-restriction 'paragraph)) info))))) ;; Links pointing to a headline: Find destination and build ;; appropriate referencing command. ((member type '("custom-id" "fuzzy" "id")) --=-=-= Content-Type: text/plain -- Bastien --=-=-=--