* A bug of org-freemind.el in org-mode package 3.34c
@ 2010-01-26 22:31 Yu Shen (MCBU)
2010-01-26 22:50 ` Lennart Borgman
0 siblings, 1 reply; 2+ messages in thread
From: Yu Shen (MCBU) @ 2010-01-26 22:31 UTC (permalink / raw)
To: emacs-orgmode; +Cc: lennart.borgman, yubrshen
[-- Attachment #1.1: Type: text/plain, Size: 1502 bytes --]
It seems in the function of org-freemind-write-mm-buffer, in the
following code segment, the treatment of sub-node level may have some
problem. If the level is one level more than its parent's level, the
function will abort, abandoning the expert. I'd wish that it would be
more robust to do the export regardless the unusual level number, and
just give clearer warning.
(when (> next-level current-level)
(if (not (and org-odd-levels-only
(/= (mod current-level 2) 0)
(= next-level (+ 2 current-level))))
(setq skipping-odd nil)
(setq skipping-odd t)
(setq skipped-odd (1+ skipped-odd)))
(unless (or (= next-level (1+ current-level))
skipping-odd)
(if (or org-odd-levels-only
(/= next-level (+ 2 current-level)))
(error "Next level step > +1 for node ending at
line %s" (line-number-at-pos))
(error "Next level step = +2 for node ending at
line %s, forgot org-odd-levels-only?"
(line-number-at-pos)))
))
Attached is an example to demonstrate the problem.
I'd like to know the author's (Lennart Borgman) intension before I
attempt to modify it.
Yu Shen
yubrshen@gmail.com
[-- Attachment #1.2: Type: text/html, Size: 7486 bytes --]
[-- Attachment #2: test.org --]
[-- Type: application/octet-stream, Size: 38 bytes --]
* Top level
*** Not the 2nd level
[-- Attachment #3: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: A bug of org-freemind.el in org-mode package 3.34c
2010-01-26 22:31 A bug of org-freemind.el in org-mode package 3.34c Yu Shen (MCBU)
@ 2010-01-26 22:50 ` Lennart Borgman
0 siblings, 0 replies; 2+ messages in thread
From: Lennart Borgman @ 2010-01-26 22:50 UTC (permalink / raw)
To: Yu Shen (MCBU); +Cc: emacs-orgmode, yubrshen
[-- Attachment #1: Type: text/plain, Size: 2250 bytes --]
On Tue, Jan 26, 2010 at 11:31 PM, Yu Shen (MCBU) <yushen@utstar.com> wrote:
> It seems in the function of org-freemind-write-mm-buffer, in the following
> code segment, the treatment of sub-node level may have some problem. If the
> level is one level more than its parent’s level, the function will abort,
> abandoning the expert. I’d wish that it would be more robust to do the
> export regardless the unusual level number, and just give clearer warning.
>
>
>
>
>
> (when (> next-level current-level)
>
> (if (not (and org-odd-levels-only
>
> (/= (mod current-level 2) 0)
>
> (= next-level (+ 2 current-level))))
>
> (setq skipping-odd nil)
>
> (setq skipping-odd t)
>
> (setq skipped-odd (1+ skipped-odd)))
>
> (unless (or (= next-level (1+ current-level))
>
> skipping-odd)
>
> (if (or org-odd-levels-only
>
> (/= next-level (+ 2 current-level)))
>
> (error "Next level step > +1 for node ending at line
> %s" (line-number-at-pos))
>
> (error "Next level step = +2 for node ending at line
> %s, forgot org-odd-levels-only?"
>
> (line-number-at-pos)))
>
> ))
>
>
>
> Attached is an example to demonstrate the problem.
>
>
>
> I’d like to know the author’s (Lennart Borgman) intension before I attempt
> to modify it.
Hi Yu,
My intention was just to help the user find errors. If the subnode
level is not just node level+1 then I expect that there is some
trouble with the org file (if not org-odd-levels-only).
If you think it is useful with bigger level steps then perhaps you
could make the check optional with a defcustom?
Kind regards,
L
> Yu Shen
>
> yubrshen@gmail.com
[-- Attachment #2: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-01-26 22:50 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-26 22:31 A bug of org-freemind.el in org-mode package 3.34c Yu Shen (MCBU)
2010-01-26 22:50 ` Lennart Borgman
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).