emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: cdlatex-tab in math-env isn't considered when inside of a list item. [7.7 (release_7.7.513.g2a5877)]
@ 2011-11-10 10:36 Maik Beckmann
  2011-11-10 11:09 ` Maik Beckmann
  0 siblings, 1 reply; 7+ messages in thread
From: Maik Beckmann @ 2011-11-10 10:36 UTC (permalink / raw)
  To: emacs-orgmode

* The observed behavior
Inside a list item cdlatex-tab isn't considered.  An example:

  To circumvent emacs' fill-paragrah issue with \[ \] I prefer using a
  inline math environment in a single item list.  Unfortunately cdlatex
  isn't considered when hitting TAB then
   - $y = a_0 + a_{1[TAB]}$ .
  Emacs echos "EMPTY ENTRY" instead.  The same line without the leading
  list item qualifier works fine.  This line
     $y = a_0 + a_{1[TAB]}$
  results in
     $y = a_0 + a_1$ .


* The reason
In org.el in org-cycle a `cond' statement dispatches is done when
TAB is pressed.  The call to `org-try-cdlatex-tab' is part of
this dispatch.  Before `cond' reaches this entry it reaches the
one which determines whether or not the current context is a list
item.  Since this is true here, `cond' is satified and never
considers `org-try-cdlatex-tab'.  The entry calls
`org-cycle-internal-local' which then emits the "EMPTY ENTRY"
message.


* What I expected
Lets considering the case that there is a sub-item.
 - $y = a_0 + a_{1}$
  + foo
I expect cdlatex-tab to be tried first.  If it's nothing cdlatex
can reason about, expand/collapse the list.  For
 - $y = a_0 + a_{1[TAB]}$
  + foo
turns into
 - $y = a_0 + a_1$
  + foo
Another TAB
 - $y = a_0 + a_1[TAB]$
  + foo
turns it into
 - $y = a_0 + a_1$...


* Org mode version info
Emacs  : GNU Emacs 24.0.91.1 (x86_64-unknown-linux-gnu, GTK+ Version 2.24.7)
 of 2011-11-04 on myhost
Package: Org-mode version 7.7 (release_7.7.513.g2a5877)

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-11-13 11:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-10 10:36 Bug: cdlatex-tab in math-env isn't considered when inside of a list item. [7.7 (release_7.7.513.g2a5877)] Maik Beckmann
2011-11-10 11:09 ` Maik Beckmann
2011-11-12 14:08   ` Nicolas Goaziou
2011-11-13  7:20     ` Maik Beckmann
2011-11-13  9:40       ` Nicolas Goaziou
2011-11-13 10:45         ` Maik Beckmann
2011-11-13 11:34           ` Maik Beckmann

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).