[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Bug: org-export-as

From: drymer
Subject: Re: [O] Bug: org-export-as
Date: Wed, 8 Mar 2017 12:43:56 +0000
User-agent: NeoMutt/20170206-5-dca6fe (1.7.2)

Ah, I see, you're wright. I believe I can fix the problem, but I still don't 
understand why it behaves differently on that two versions. Anyway, thank you 
very much.

On Wed, Mar 08, 2017 at 11:58:57AM +0100, Nicolas Goaziou wrote:

drymer <address@hidden> writes:


Thanks for your time. Could you please retry and evaluate this:

| (defun test-org-export ()
|   (interactive)
|   (save-excursion
|     (org-mark-element)
|     (forward-line) ;; donot export title
|     (setq b (region-beginning))
|     (setq e (region-end)))
|   (message (org-export-as 'html t nil t)))

And execute `M-x test-org-export RET' on the example header:

 | * TODO Testing                                                    :test:
 |   Nullam eu ante vel est convallis dignissim.  Fusce suscipit, wisi nec
 |   facilisis facilisis, est dui fermentum leo, quis tempor ligula erat
 |   quis odio.  Nunc porta vulputate tellus.  Nunc rutrum turpis sed pede.
 |   Sed bibendum.  Aliquam posuere.  Nunc aliquet, augue nec adipiscing
 |   interdum, lacus tellus malesuada massa, quis varius mi purus non odio.
 |   Pellentesque condimentum, magna ut suscipit hendrerit, ipsum augue
 |   ornare nulla, non luctus diam neque sit amet urna.  Curabitur
 |   vulputate vestibulum lorem.  Fusce sagittis, libero non molestie
 |   mollis, magna orci ultrices dolor, at vulputate neque nulla lacinia
 |   eros.  Sed id ligula quis est convallis tempor.  Curabitur lacinia
 |   pulvinar nibh.  Nam a sapien.

And see if it happens?

It does, but the problem is in `test-org-export'. There, `org-export-as'
is called outside the `save-excursion' so region beginning is not the
same as b anymore. The region then includes the headline, and "subtree
export" feature is ignored since there is an active region.


Nicolas Goaziou                                                0x80A93738

Attachment: signature.asc
Description: PGP signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]