From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wanrong Lin Subject: Re: Blank lines in literal html Date: Wed, 05 Dec 2007 14:31:20 -0500 Message-ID: <4756FC88.1050701@gmail.com> References: <475453D3.30604@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Izzy1-000118-8o for emacs-orgmode@gnu.org; Wed, 05 Dec 2007 14:31:33 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Izzxz-00010D-FJ for emacs-orgmode@gnu.org; Wed, 05 Dec 2007 14:31:32 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Izzxz-000109-Ak for emacs-orgmode@gnu.org; Wed, 05 Dec 2007 14:31:31 -0500 Received: from rv-out-0910.google.com ([209.85.198.186]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Izzxx-00030q-VQ for emacs-orgmode@gnu.org; Wed, 05 Dec 2007 14:31:30 -0500 Received: by rv-out-0910.google.com with SMTP id c27so5126523rvf for ; Wed, 05 Dec 2007 11:31:28 -0800 (PST) In-Reply-To: <475453D3.30604@gmail.com> 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: org-mode list Finally, I decided to learn some elisp debugging techniques and as a practice, it seems I found the bug and fixed it with this patch (against org.el in 5.16b) @@ -24437,7 +24437,7 @@ (when (re-search-backward "\\(

\\)\\([ \t\r\n]*\\)\\=" (- (point) 100) t) (setq par (match-string 1)) - (replace-match "\\2\n")) + (replace-match "")) (insert line "\n") (while (and lines (get-text-property 0 'org-protected (car lines))) I am not completely sure whether this is the right fix, but so far the output looks OK to me. Can Carsten take a look of it and see whether it is OK to check this into the next release? Thanks a lot. Wanrong Wanrong Lin wrote: > Hi, > > Sometimes I use "htmlize" to convert a section of my buffer into > html and then insert it into my org file with "#+BEGIN_HTML" and > "#+END_HTML". One thing I noticed is the blank lines in the original > text is "amplified". For example, I have a section like this in my org > file: > > #+BEGIN_HTML >

> Line 1
>
> Line 2 with a blank line in between
> 
> #+END_HTML > > When I export the above to a html file, there are actaully 3 blank > lines between my "Line 1" and "Line 2". > > Is the above a bug or I mis-configured something? Thank you very much. > > Wanrong > > > >