Re: [O] How to show the complete syntax tree

2014-07-14 Thread Thorsten Jolitz
Shiyuan gshy2...@gmail.com writes:

 [...]
 For example, if the current org buffer has the following content: 

 #+TITLE: Hello World
 Hello World!
 * HEADLINE 1
 ** Sub-topic 
 + ItemA
 + ItemB
 - Item1
 - Item2
 *** Sub-Sub-topic
 \begin{equation}
 \label{eq:test}
 Bx=b
 \end{equation}
 [...]

Following up in outorg, I evaluate this in the *outorg-edit-buffer*:

#+begin_src emacs-lisp :results raw
(org-element-parse-buffer 'object)
#+end_src

#+results:

(org-data nil (headline (:raw-value --text follows this line-- :begin 1
:end 1604 [...]
 For example, if the current org buffer has the following content: 

 #+TITLE: Hello World
 Hello World!
 * HEADLINE 1
 ** Sub-topic 
 + ItemA
 + ItemB
 - Item1
 - Item2
  (bold (:begin 533 :end 537 :contents-begin 534 :contents-end 535
  :post-blank 1 :parent #3) *) Sub-Sub-topic
  (latex-fragment (:value \begin{equation} :begin 553 :end 569
  :post-blank 0 :parent #3))
  (latex-fragment (:value \label{eq:test} :begin 572 :end 587
  :post-blank 0 :parent #3))
 Bx=b
  (latex-fragment (:value \end{equation} :begin 597 :end 611
  :post-blank 0 :parent #3))
[...]

-- 
cheers,
Thorsten




Re: [O] Removing the title in LaTeX export

2014-07-14 Thread Julien Cubizolles
t...@tsdye.com (Thomas S. Dye) writes:

 Aloha Julien,

 Julien Cubizolles j.cubizol...@free.fr writes:

 Is there a way to remove the title from during a LaTeX export? the
 :with-toc nil keyword in org-publish-project-alist removes the table
 of contents but I with-title nil doesn't seem to be recognized.

 Julien.
  
 I use (setq org-latex-title-command ).

Good idea, I'll try to use it in the preparation-function property of
org-publish-project-alist.

Julien.




Re: [O] remove sectionning structure in latex export

2014-07-14 Thread Julien Cubizolles
Nick Dokos ndo...@gmail.com writes:

 Julien Cubizolles j.cubizol...@free.fr writes:


 I've tried playing with :headline-levels so that all headings get
 translated as section, subsection, subsubsection and redefining the
 \section,\subsection,\subsubsection commands in the LaTeX class to
 \relax but for some reason, the third level still gets translated as an
 enumerate list.


 #+OPTIONS: H:4

 perhaps?

That's the first thing I tried but something seems wrong with the way
the 
From: Julien Cubizolles j.cubizol...@free.fr
Gcc: nnfolder+archive:sent-news-2014-07
--text follows this line--
Nick Dokos ndo...@gmail.com writes:

 Julien Cubizolles j.cubizol...@free.fr writes:


 I've tried playing with :headline-levels so that all headings get
 translated as section, subsection, subsubsection and redefining the
 \section,\subsection,\subsubsection commands in the LaTeX class to
 \relax but for some reason, the third level still gets translated as an
 enumerate list.


 #+OPTIONS: H:4

 perhaps?

That's the first thing I tried but something seems wrong with the way
the org-latex-publish-to-pdf function handles this property:
H:0, H:1 and H:2 behave as expected but H:3 and higher act as H:2.

Julien.




Re: [O] Problem with org-mode after upgradiing to org 8

2014-07-14 Thread Roland Everaert
org-mode will makes me crazy. After a deep review (well rewrite my entire
configuration based on norang's one) org-mode is working again, but its the
version bundled with emacs that seems to be loaded and not the one I
downloaded from the git repository.


My emacs configuration is structured like so:

~/.emacs.d/init.el
~/.emacs.d/site-lisp/ -- contains alot of lisp codes including the
directory of org.


At the top of the init.el file I put the following:

(let ((default-directory ~/.emacs.d/site-lisp/))
  (normal-top-level-add-to-load-path '(.))
  (normal-top-level-add-subdirs-to-load-path))


I, later, load a file containing all my org-mode configuration. That file
is located in ~/.emacs.d/site-lisp/. I load that file in this way:

(load-library my-org-mode-config)

 At the top of that configuration file is written:

(add-to-list 'load-path (expand-file-name
~/.emacs.d/site-lisp/org-mode/lisp))
(add-to-list 'load-path (expand-file-name
~/.emacs.d/site-lisp/org-mode/contrib/lisp))
(add-to-list 'auto-mode-alist '(\\.\\(org\\|org_archive\\)$ . org-mode))

(require 'org)


So I don't understand why M-x org-version gives me:

Org-mode version 7.9.3f (release_7.9.3f-17-g7524ef @
/usr/share/emacs/24.3/lisp/org/)


Any help welcomed,


Roland.

On Fri, Jul 4, 2014 at 4:21 PM, John Hendy jw.he...@gmail.com wrote:

 On Fri, Jul 4, 2014 at 5:55 AM, Roland Everaert reveatw...@gmail.com
 wrote:
  Hi,
 
  After further investigation, it is the call to the function
  (org-agenda-to-appt) inside the function bh/org-agenda-to-appt that is
  causing the error.
 
  The body of the function:
 
  ; Erase all reminders and rebuilt reminders for today from the agenda
  (defun bh/org-agenda-to-appt ()
(interactive)
(setq appt-time-msg-list nil)
   (org-agenda-to-appt)
  )

 I know approximately nothing about elisp... but my intuitive
 interpretation is that it's setting the variable appt-time-msg-list to
 the value nil. When I do M-x help RET appt-msg-[TAB], I don't get any
 completions listed. Does that variable still exist?

 When googling that variable, I find evidence of people referring to
 it, but I'm not sure it's built into emacs -- are you sure you don't
 need to add something else, such as appt.el?
 - http://www.emacswiki.org/emacs-en/appt.el


 John

 
 
  I will deactivate the call to bh/org-agenda-to-appt, so I can have a
 normal
  life again and use emacs and org-mode without any problem. I will review
 and
  clean my configuration when times permit.
 
  I am anyway curious to know why that function call generate such error.
 
  Thanks for your help,
 
 
  Roland.
 
 
 
 
  On Thu, Jul 3, 2014 at 10:10 AM, Roland Everaert reveatw...@gmail.com
  wrote:
 
  Hi John,
 
  I am using Bernt's configuration (at least a part of it) for years
 without
  problems until I switch to org 8.
 
  I hame commented most of my init.el file and uncomment bits of
  configuration lines one at a time. and I have found where is located the
  problem. I have know to investigate why it is a problem.
 
  The offending line is (bh/org-agenda-to-appt), this is one of the
 function
  from the configuration of Bernt, so I have now to check my version
 against
  the one on his page to see if he doesn't update it.
 
  And to answer your question, the loaded version of org-mode is Org-mode
  version beta_8.3 (beta_8.3-16-g16c71d6 @
  /home/reveatwork/.emacs.d/site-lisp/org-mode/lisp/)
 
  I will also perform a make clean  make of my installation of org-mode
  just in case some their is some garbage left from previous version.
 
 
  Thanks for your help,
 
 
  Roland.
 
 
 
 
 
  On Tue, Jul 1, 2014 at 5:55 PM, John Hendy jw.he...@gmail.com wrote:
 
  On Tue, Jul 1, 2014 at 5:04 AM, Roland Everaert reveatw...@gmail.com
  wrote:
   I have upgraded using git on a Linux fedora 20 64 bit.
  
   I perform the following commands from the directory of org-mode:
  
   make clean
   git pull
   make
 
  I usually do git pull  make clean  make, but don't know if that
  makes a difference, so that's probably fine.
 
   I have also read the following page:
   http://orgmode.org/worg/org-8.0.html
  
   And search for all variables in my configuration that start with
   org-export,
   but I have none of them.
 
  Well, I'm interested in the original error, Autoloading failed to
  define function org-element-cache-reset, not anything to do with
  org-export. You should be able to start emacs without any errors, and
  I think that's the primary thing to troubleshoot first.
 
   My configuration is heavily inspired by this article:
   http://doc.norang.ca/org-mode.html
 
  Bernt's page is one of the most advanced orgmode setups documented
  that I've ever seen. I wouldn't get too deep into that before figuring
  out what's going on at the basic level.
 
  
   I have quickly browsed it in case some specific changes needs to be
   done,
   but the only ones concernes the exporters that I have not configured
   yet.
  
   Which lines from the my 

[O] fill-paragraph running slowly in org mode

2014-07-14 Thread Sean Markan
Hi all,

I just upgraded to a new version of Linux/emacs/org-mode, and am finding
that fill-paragraph (M-q) runs very slowly in org-mode on large files.
With about 50k lines in the buffer, fill-paragraph takes around 3 seconds
even if the paragraph is only a couple lines.  (The behavior is correct,
the problem is just the slowness.)  The time seems to scale linearly with
the number of lines in the buffer as if the whole file is being processed
during each fill-paragraph.

I have tried (setq  fill-paragraph-function nil) in an effort to use emacs'
default fill function instead of org mode's, but that did not fix the
problem.  When switching to text-mode the problem goes away.  I have also
tried running emacs with no customizations, and the problem is still
present in that case.

Things used to work fine in the versions of emacs and org-mode that I was
previously using, but those were a few years old and I am not sure exactly
which versions they were.  I am not using linum (I've seen that mentioned
as a cause of slowness).  Output from org-submit-bug-report is below.

Any help would be appreciated!

- Sean





Emacs  : GNU Emacs 24.3.1 (i686-pc-linux-gnu, GTK+ Version 3.10.7)
 of 2014-03-07 on toyol, modified by Debian
Package: Org-mode version 8.2.7b (8.2.7b-dist @
/home/markan/software/org-8.2.7b/lisp/)

current state:
==
(setq
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point
org-babel-execute-safely-maybe)
 org-agenda-todo-ignore-scheduled t
 org-tab-first-hook '(org-hide-block-toggle-maybe
org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe
  org-babel-header-arg-expand)
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
org-cycle-hide-inline-tasks org-cycle-show-empty-lines
  org-optimize-window-after-visibility-change)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-speed-command-hook '(org-speed-command-default-hook
org-babel-speed-command-hook)
 org-babel-pre-tangle-hook '(save-buffer)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-confirm-elisp-link-function 'yes-or-no-p
 org-format-latex-options '(:foreground default :background default :scale
1.8 :html-foreground Black :html-background
Transparent :html-scale 1.0 :matchers
(begin $1 $ $$ \\( \\[))
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-mode-hook '((lambda nil
  (org-add-hook (quote change-major-mode-hook) (quote
org-show-block-all) (quote append) (quote local)))
 (lambda nil
  (org-add-hook (quote change-major-mode-hook) (quote
org-babel-show-result-all) (quote append) (quote local)))
 org-babel-result-hide-spec org-babel-hide-all-hashes)
 org-link-frame-setup '((vm . vm-visit-folder-other-frame) (gnus .
gnus-other-frame) (file . find-file))
 org-from-is-user-regexp \\Sean Markan\\
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-startup-folded 'all
 org-agenda-files [REDACTED])
 org-file-apps '((auto-mode . emacs) (\\.x?html?\\' . default)
(\\.pdf\\' . default))
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
org-src-mode-configure-edit-buffer)
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-confirm-shell-link-function 'yes-or-no-p
 )


[O] Beamer export: can't get frame level right

2014-07-14 Thread Gabor Retvari
Hi,

I guess this should be easy but I just can't get frame levels right in my 
beamer exports. 

So as far as I understand, this should get my first level headlines (`* 
headline 1' and stuff) into separate frames in my beamer export.

=== ORG MODE TEXT: ===

#+LaTeX_CLASS: beamer
#+LaTeX_CLASS_OPTIONS: [presentation,bigger]
#+OPTIONS: H:1

* headline 1

- stuff

- stuff too

* headline 2

- list 1

- list 2

- ...

* headline 3

- no stuff

I expected the headlines top level headlines (`* headline 1'...) to appear 
inside separate `\begin{frame}...\end{frame}' environments.  Problem is that 
they do not, intead every headline goes into LaTeX `\section' sections.

=== LATEX EXPORT: ===
\documentclass[presentation,bigger]{beamer}
[..]

\section{headline 1}
\label{sec-1}

\begin{itemize}
\item stuff

\item stuff too
\end{itemize}

\section{headline 2}
\label{sec-2}

\begin{itemize}
\item list 1

\item list 2

\item \ldots{}
\end{itemize}

\section{headline 3}
\label{sec-3}

\begin{itemize}
\item no stuff
\end{itemize}
% Emacs 24.3.1 (Org mode 8.2.7b)
\end{document}

No `OPTIONS: H:n' setting seems to solve this problem. So how do I get this 
right? 

This is Org mode 8.2.7b by the way, as of the `org-mode' package version 
8.2.7b-1 in Debian testing.

Thanks a lot,
Gabor



[O] Bug: Problem with hook added to org-mode-hook [8.2.6 (release_8.2.6-1 @ /usr/local/share/emacs/24.4.50/lisp/org/)]

2014-07-14 Thread Tianxiang Xiong

Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.  You don't know how to make a good report?  See

 http://orgmode.org/manual/Feedback.html#Feedback

Your bug report will be posted to the Org-mode mailing list.


I'm organizing my init file as an init.org file that I will then tangle
into init.el.

I want to define an after-save-hook that applies only to org-mode. I
used the following:

(add-hook 'org-mode-hook
  (lambda ()
 (add-hook 'after-save-hook 'tangle-init nil t)))

However, when I open my init.org file, I see that the after-save-hook
variable is nil. If I manually reapply org-mode, however, it works as
expected.

Why is it that when I simply open an org file, the hook function is not
applied?

At least one other individual has been able to reproduce the problem:
http://www.reddit.com/r/emacs/comments/2alwnd/hook_for_major_mode/


Emacs  : GNU Emacs 24.4.50.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.10.9)
 of 2014-07-08 on localhost.localdomain
Package: Org-mode version 8.2.6 (release_8.2.6-1 @ 
/usr/local/share/emacs/24.4.50/lisp/org/)

current state:
==
(setq
 org-tab-first-hook '(org-hide-block-toggle-maybe 
org-src-native-tab-command-maybe
  org-babel-hide-result-toggle-maybe 
org-babel-header-arg-expand)
 org-speed-command-hook '(org-speed-command-default-hook 
org-babel-speed-command-hook)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-confirm-shell-link-function 'yes-or-no-p
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-src-mode-hook '(org-src-babel-configure-edit-buffer 
org-src-mode-configure-edit-buffer)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-mode-hook '((lambda nil (add-hook (quote after-save-hook) (quote 
tangle-init) nil t))
 #[nil \300\301\302\303\304$\207
   [org-add-hook change-major-mode-hook org-show-block-all 
append local] 5]
 #[nil \300\301\302\303\304$\207
   [org-add-hook change-major-mode-hook 
org-babel-show-result-all append local] 5]
 org-babel-result-hide-spec org-babel-hide-all-hashes 
turn-on-auto-fill
 #[nil \300\301\302\303\304$\207 [add-hook after-save-hook 
tangle-init nil t] 5])
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point 
org-babel-execute-safely-maybe)
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers 
org-cycle-hide-inline-tasks
  org-cycle-show-empty-lines 
org-optimize-window-after-visibility-change)
 org-confirm-elisp-link-function 'yes-or-no-p
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 )



Re: [O] Removing the title in LaTeX export

2014-07-14 Thread Rasmus
Julien Cubizolles j.cubizol...@free.fr writes:

 Is there a way to remove the title from during a LaTeX export? the
 :with-toc nil keyword in org-publish-project-alist removes the table
 of contents but I with-title nil doesn't seem to be recognized.

Does this give you what you want?

#+TITLE: 
* test 

It will suppress \maketitle.  

If you always want to suppress it Thom's suggestion may suit you
better.

—Rasmus

-- 
I almost cut my hair, it happened just the other day




Re: [O] How to show the complete syntax tree

2014-07-14 Thread Nick Dokos
Shiyuan gshy2...@gmail.com writes:

 Hi, 
 The command I can find in the manual to show the syntax tree is
 (org-element-parse-buffer). However, when the structure is output to
 the buffer, by using the commands C-u M-: (org-element-parse-buffer),
 it seems that only the part up to a certain depth is printed.


C-h v print-length RET
C-h v print-level RET
C-h v eval-expression-print-length RET
C-h v eval-expression-print-level RET

-- 
Nick




Re: [O] emails written in Org Mode

2014-07-14 Thread Esben Stien
Esben Stien b...@esben-stien.name writes:

 Do you have any means to bring replies and such back into the org file?

This seems like it could be a really good thing. 

To be able to move the discussion to the relevant org file and then
structure it and prioritize/schedule from there. 

It seems a lot better than to have all these different discussions
inside gnus, so I'd really like to try this. 

-- 
Esben Stien is b0ef@e s  a 
 http://www. s tn m
  irc://irc.  b  -  i  .   e/%23contact
   sip:b0ef@   e e 
   jid:b0ef@n n



Re: [O] Removing the title in LaTeX export

2014-07-14 Thread Julien Cubizolles
Rasmus ras...@gmx.us writes:

 Julien Cubizolles j.cubizol...@free.fr writes:

 Is there a way to remove the title from during a LaTeX export? the
 :with-toc nil keyword in org-publish-project-alist removes the table
 of contents but I with-title nil doesn't seem to be recognized.

 Does this give you what you want?

 #+TITLE: 
 * test 

 It will suppress \maketitle.  

 If you always want to suppress it Thom's suggestion may suit you
 better.

I want to suppress it selectively, depending on the export backend used,
so Thom's way, in org-publish-project-alist, works best for me.

Julien.




[O] Docu bug for key of 'org-babel-load-in-session'

2014-07-14 Thread marcowahlsoft
Hi!

I think the texi documentation of the key triggering
'org-babel-load-in-session' is not up to date.  The documentation says
'C-up' but it looks like it should be 'M-up'.

Suggestion for a patch:

Modified   doc/org.texi
diff --git a/doc/org.texi b/doc/org.texi
index b21c93d..05c1575 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -15792,6 +15792,6 @@ are active:
 @kindex C-c C-o
 @item @kbd{C-c C-o} @tab @code{org-babel-open-src-block-result}
-@kindex C-up
-@item @kbd{C-@key{up}}@tab @code{org-babel-load-in-session}
+@kindex M-up
+@item @kbd{M-@key{up}}@tab @code{org-babel-load-in-session}
 @kindex M-down
 @item @kbd{M-@key{down}}  @tab @code{org-babel-pop-to-session}


My 1 ₰,  Marco
-- 
http://www.wahlzone.de




Re: [O] How to call org-display-inline-images so that after a graphviz block is evaluated the image is refreshed?

2014-07-14 Thread Rick Frankel

On 2014-07-11 20:28, Ken Mankoff wrote:

Try (org-redisplay-inline-images). Note re.

#+BEGIN_SRC lang :post (org-redisplay-inline-images)
#+END_SRC
#+RESULTS:


I believe it is on WORG somewhere:

#+BEGIN_SRC emacs-lisp
(add-hook 'org-babel-after-execute-hook
(lambda () (org-display-inline-images nil t)))
#+END_SRC

rick



Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer presentation doesn't break presentation in slides

2014-07-14 Thread Suhas Pai
Hi Josiah,

Thanks for your reply.

Upon closer examination, I found that there are two commands to export to PDF.
C-c C-e l small-o   (converts to regular pdf)
C-c C-e l capital-O  (converts to presentation pdf, i.e., converts all 
headings to slides)

I tested C-c C-e l O successfully for a simple text but I'm getting the 
following error for the attached file in my last email.

org-latex-compile: PDF file ./presentation.pdf wasn't produced: Runaway argument

I was trying the example (What is Beamer? etc.) from the following link: Record 
of Motion

  
          
Record of Motion
Now then, with the reasoning for why you'd use Org-mode out of the way I can 
move onto how to actually use the damn thing! If you're already comfortable 
with Emacs, it is very, very simple.   
View on atlanis.net Preview by Yahoo  
  
  

Not sure how to debug this. Any ideas would be appreciated. 


Regards,
Suhas



 From: Josiah Schwab jsch...@gmail.com
To: Suhas Pai suhas...@yahoo.com 
Cc: emacs-orgmode@gnu.org emacs-orgmode@gnu.org 
Sent: Monday, July 14, 2014 8:39 AM
Subject: Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer 
presentation doesn't break presentation in slides
 

Hi Suhas,


 I was expecting all top heading to be converted to slides but they
 appear as continuous text in exported pdf.  Both are attached. Not
 sure what all init is needed in .emacs for this to work.

When I export in 8.2.7b I get the attached file, which seems like what
you want.  I don't have any LaTeX/Beamer customizations in my .emacs.



Not sure what's going on here.

Sorry I can't be more helpful,
Josiah

Re: [O] How to show the complete syntax tree

2014-07-14 Thread Charles Berry
Shiyuan gshy2014 at gmail.com writes:

 
 Hi,     The command I can find in the manual to show the syntax tree is
(org-element-parse-buffer). However, when the structure is output to the
buffer, by using the commands C-u M-: (org-element-parse-buffer), it seems
that only the part up to a certain depth is printed. 

Yes, as Nick explained there are variables that control this.

My eyes sometimes like this approach to viewing lisp objects:

#+BEGIN_SRC emacs-lisp
(pp-to-string (org-element-parse-buffer))
#+END_SRC

HTH,

Chuck






Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer presentation doesn't break presentation in slides

2014-07-14 Thread Josiah Schwab
Hi Suhas,

 Upon closer examination, I found that there are two commands to export to PDF.
 C-c C-e l small-o (converts to regular pdf)
 C-c C-e l capital-O (converts to presentation pdf, i.e., converts all 
 headings to slides)

Yes, I exported via the Beamer exporter with C-c C-e l O.   

 I tested C-c C-e l O successfully for a simple text but I'm getting the 
 following error for the attached file in my last email.

 org-latex-compile: PDF file ./presentation.pdf wasn't produced: Runaway 
 argument

I just tried this with 8.2.5h and could not reproduce your problem.
Are you sure you're exporting the exact same file you attached?


Best,
Josiah



Re: [O] Beamer export: can't get frame level right

2014-07-14 Thread John Hendy
On Mon, Jul 14, 2014 at 10:29 AM, Josiah Schwab jsch...@gmail.com wrote:
 Hi Gabor,

 I guess this should be easy but I just can't get frame levels right in my
 beamer exports.

 So as far as I understand, this should get my first level headlines (`*
 headline 1' and stuff) into separate frames in my beamer export.

 ... snipped 61 lines ...

 No `OPTIONS: H:n' setting seems to solve this problem. So how do I get this
 right?

 Which export command are you using?

 I think you may be using the regular LaTeX exporter.  Adding beamer to
 your LaTeX_CLASS is not sufficient (or necessary).  Rather, you want to
 use the Beamer export commands.

Tend to agree. Make sure you're doing C-c C-e l P (capital P).

Attached my result of running your example, which I think is what
you're looking for?

John

P.S. Don't feel bad. I've done the exact same thing multiple times
wondering what the hell was going on :)


 http://orgmode.org/manual/Beamer-export.html

 Hope that helps,
 Josiah



test.pdf
Description: Adobe PDF document


Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer presentation doesn't break presentation in slides

2014-07-14 Thread Josiah Schwab
Hi Suhas,

 Yes, I downloaded the same file and tried again and got the following debug 
 trace:

 Debugger entered--Lisp error: (error PDF file ./presentation-1.pdf wasn't 
 produced: Runaway argument)

That message is indicating an error during the LaTeX - PDF step.

Why don't you take a look at the presentation-1.tex file and see where
things are going wrong.

You can probably reproduce this typeset the file (outside of emacs)
  pdflatex presentation-1.tex

Runway LaTeX arguments usually signify something like this (closing
curly brace missing).

,
| \documentclass{article}
| 
| \begin{document}
| 
| \section{Runaway
| 
| \end{document}
`

Sorry, I don't have any more time to spend on this.  Maybe someone else
will be able to help.

Best,
Josiah



Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer presentation doesn't break presentation in slides

2014-07-14 Thread Nick Dokos
Josiah Schwab jsch...@gmail.com writes:

 Hi Suhas,

 Yes, I downloaded the same file and tried again and got the following debug 
 trace:

 Debugger entered--Lisp error: (error PDF file ./presentation-1.pdf wasn't 
 produced: Runaway argument)

 That message is indicating an error during the LaTeX - PDF step.

 Why don't you take a look at the presentation-1.tex file and see where
 things are going wrong.

 You can probably reproduce this typeset the file (outside of emacs)
   pdflatex presentation-1.tex


That's indeed the best approach to debug such problems. FWIW, I also had
no trouble exporting it to PDF. If you still have problems, post the
presentation-1.tex file that is produced. Or you can do the comparison
with the one I got (attached):



presentation-1.tex
Description: presentation-1.tex

 Runway LaTeX arguments usually signify something like this (closing
 curly brace missing).

 ,
 | \documentclass{article}
 | 
 | \begin{document}
 | 
 | \section{Runaway
 | 
 | \end{document}
 `

 Sorry, I don't have any more time to spend on this.  Maybe someone else
 will be able to help.


--
Nick


Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer presentation doesn't break presentation in slides

2014-07-14 Thread Suhas Pai
Hi Josiah,

Thanks for the tips. I'll take that line of investigation and see if I can 
resolve it.
I'll let you know if I find the issue. Thanks again for volunteering your time 
to
look into the issue.


Best,
Suhas



 From: Josiah Schwab jsch...@gmail.com
To: Suhas Pai suhas...@yahoo.com 
Cc: emacs-orgmode@gnu.org emacs-orgmode@gnu.org 
Sent: Monday, July 14, 2014 12:15 PM
Subject: Re: [O] Org mode 8.2.5h and emacs-24.3.1: exporting org-beamer 
presentation doesn't break presentation in slides
 

Hi Suhas,

 Yes, I downloaded the same file and tried again and got the following debug 
 trace:

 Debugger entered--Lisp error: (error PDF file ./presentation-1.pdf wasn't 
 produced: Runaway argument)

That message is indicating an error during the LaTeX - PDF step.

Why don't you take a look at the presentation-1.tex file and see where
things are going wrong.

You can probably reproduce this typeset the file (outside of emacs)
  pdflatex presentation-1.tex

Runway LaTeX arguments usually signify something like this (closing
curly brace missing).

,
| \documentclass{article}
| 
| \begin{document}
| 
| \section{Runaway
| 
| \end{document}
`

Sorry, I don't have any more time to spend on this.  Maybe someone else
will be able to help.




Best,
Josiah

Re: [O] How to call org-display-inline-images so that after a graphviz block is evaluated the image is refreshed?

2014-07-14 Thread John Kitchin
That is a nice tip!
-- 
---
John Kitchin
Professor
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
http://kitchingroup.cheme.cmu.edu



[O] Macros in included file not expanded in batch export

2014-07-14 Thread Suvayu Ali
Hi,

I am trying to export to LaTeX in batch mode, but it seems the exporter
ignores macros defined in included files when exporting in batch mode.

I tried to export like this:

  $ emacs --eval (require 'ox-latex) include-test.org \
--eval '(org-LaTeX-export-to-latex nil nil nil t)' -f kill-emacs

  $ emacs --batch --eval (require 'ox-latex) include-test.org \
--eval '(org-LaTeX-export-to-latex nil nil nil t)'

The first one exports correctly, the second doesn't.  The org files, and
the good and bad exported TeX files are attached.

Can someone else reproduce this?

Thanks,

-- 
Suvayu

Open source is the future. It sets us free.
#+INCLUDE: include.org

* Some heading 1
{{{todo(foo)}}}

* Some heading 2
#+MACRO: todo @@l:\todo[size=\scriptsize,$2]{@@$1@@l:}@@

\section{Some heading 1}
\label{sec-1}
\todo[size=\scriptsize,]{foo}

\section{Some heading 2}
\label{sec-2}

\section{Some heading 1}
\label{sec-1}
foo

\section{Some heading 2}
\label{sec-2}


[O] proposal to make C-c C-c not remove latex overlays

2014-07-14 Thread John Kitchin
I am using org-mode files with equations and code blocks in lectures,
and it is problematic that C-c C-c removes the equation overlays when
running a code block. First, you have to press C-c C-c twice to run the
block, since the first one gets rid of the equations, but then you have
run C-c C-x C-l to get the equations back! and the cycle repeats
throughout a lecture.

I would prefer that the equations stay untouched, and that the code
blocks run without modifying them. 

I think the best behavior would be for C-c C-x C-l to toggle the
equations, and to remove the C-c C-c behavior for latex overlays
completely. But it would be ok if this was done by a C-c C-c hook
function, so that a user could remove the latex overlay without touching
the org-code.

Maybe a new function like this:

#+BEGIN_SRC emacs-lisp
(defun org-toggle-latex-overlays (arg)
  Toggle LaTeX fragments.
  (interactive P)
  (if org-latex-fragment-image-overlays
  (org-remove-latex-fragment-image-overlays)
(org-preview-latex-fragment arg)))
#+END_SRC

 could be added. Any thoughts?



-- 
---
John Kitchin
Professor




[O] [PATCH] better parsing of latex fragments

2014-07-14 Thread Florian Beck
Hi,

this patch allows, once again, latex fragments inside parentheses and
also fragments like $\left(\frac12\right.$
-- 
Florian Beck
From 3ef8041c8dd8acbdf810f72feb8e9e104545badb Mon Sep 17 00:00:00 2001
From: Florian Beck f...@miszellen.de
Date: Sun, 13 Jul 2014 14:59:24 +0200
Subject: [PATCH] Allow latex fragments inside parentheses and those ending with
 punctuation.

* lisp/org-element.el:
(org-element-latex-fragment-parser): more lenient regexps
*
  testing/lisp/test-org-element.el (test-org-element/latex-fragment-parser): add tests
---
 lisp/org-element.el  | 4 ++--
 testing/lisp/test-org-element.el | 8 
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/lisp/org-element.el b/lisp/org-element.el
index 7aa8208..7d10d61 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -2918,8 +2918,8 @@ Assume point is at the beginning of the LaTeX fragment.
 		(and (not (eq (char-before) ?$))
 			 (search-forward $ nil t 2)
 			 (not (memq (char-before (match-beginning 0))
-'(?\s ?\t ?\n ?, ?.)))
-			 (looking-at \\([- \t.,?;:'\]\\|$\\))
+'(?\s ?\t ?\n)))
+			 (looking-at \\([[:space:][:punct:]]\\|$\\))
 			 (point)))
 		(case (char-after (1+ (point)))
 		  (?\( (search-forward \\) nil t))
diff --git a/testing/lisp/test-org-element.el b/testing/lisp/test-org-element.el
index b2b0c52..788f13b 100644
--- a/testing/lisp/test-org-element.el
+++ b/testing/lisp/test-org-element.el
@@ -1337,6 +1337,14 @@ e^{i\\pi}+1=0
(org-test-with-temp-text \\[a\\]
  (org-element-map
 	 (org-element-parse-buffer) 'latex-fragment 'identity)))
+  (should
+   (org-test-with-temp-text ($a$)
+ (org-element-map
+	 (org-element-parse-buffer) 'latex-fragment 'identity)))
+  (should
+   (org-test-with-temp-text $\\left(a\right.$
+ (org-element-map
+	 (org-element-parse-buffer) 'latex-fragment 'identity)))
   ;; Test fragment at the beginning of an item.
   (should
(eq 'latex-fragment
-- 
1.9.1



Re: [O] key collision for auto completion

2014-07-14 Thread John Kitchin
I turned off flymode minor mode, and it looks like M-tab (on windows
Esc-tab) is bound to (pcomplete optional INTERACTIVELY)

That seems to do some expansion of the special symbols.


Shiyuan gshy2...@gmail.com writes:

 Hi all, 
 According to the manual :
 http://orgmode.org/manual/Special-symbols.html , M-tab would perform
 auto complete in org mode for special symbols. However, it looks like
 that the key is shadowed by flyspell-auto-correct-word on my emacs and
 I need to rebind the key. I digged into the org.el file but failed to
 locate the code for key binding. Any pointer or hints are appreciated.
 In particular, what command is M-tab supposed to be bound to for auto
 completion for the special symbols? Thanks. 

 Shiyuan 


-- 
---
John Kitchin
Professor
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
http://kitchingroup.cheme.cmu.edu



Re: [O] emails written in Org Mode

2014-07-14 Thread John Kitchin
I usually do this kind of tracking with a link to the email instead. It
is not automated communication between email and org, and it is not that
complicated, but it does what I need, when I need it.

Esben Stien b...@esben-stien.name writes:

 Esben Stien b...@esben-stien.name writes:

 Do you have any means to bring replies and such back into the org file?

 This seems like it could be a really good thing. 

 To be able to move the discussion to the relevant org file and then
 structure it and prioritize/schedule from there. 

 It seems a lot better than to have all these different discussions
 inside gnus, so I'd really like to try this. 

-- 
---
John Kitchin
Professor
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
http://kitchingroup.cheme.cmu.edu



Re: [O] proposal to make C-c C-c not remove latex overlays

2014-07-14 Thread Aaron Ecay
Hi John,

2014ko uztailak 14an, John Kitchin-ek idatzi zuen:
 
 I am using org-mode files with equations and code blocks in lectures,
 and it is problematic that C-c C-c removes the equation overlays when
 running a code block. First, you have to press C-c C-c twice to run the
 block, since the first one gets rid of the equations, but then you have
 run C-c C-x C-l to get the equations back! and the cycle repeats
 throughout a lecture.
 
 I would prefer that the equations stay untouched, and that the code
 blocks run without modifying them. 
 
 I think the best behavior would be for C-c C-x C-l to toggle the
 equations, and to remove the C-c C-c behavior for latex overlays
 completely. But it would be ok if this was done by a C-c C-c hook
 function, so that a user could remove the latex overlay without touching
 the org-code.
 
 Maybe a new function like this:
 
 #+BEGIN_SRC emacs-lisp
 (defun org-toggle-latex-overlays (arg)
   Toggle LaTeX fragments.
   (interactive P)
   (if org-latex-fragment-image-overlays
   (org-remove-latex-fragment-image-overlays)
 (org-preview-latex-fragment arg)))
 #+END_SRC
 
  could be added. Any thoughts?

I don’t have a comment on the substance of the proposal, but rather two
suggestions for workarounds.

The first is to use the C-c C-v C-e binding to execute source blocks
rather than C-c C-c.

The second is to let-bind ‘org-latex-fragment-image-overlays’ to nil
in an advice around the ‘org-ctrl-c-ctrl-c’ function, allowing you to
still use the more convenient C-c C-c binding.

-- 
Aaron Ecay



Re: [O] emails written in Org Mode

2014-07-14 Thread Eric Abrahamsen
John Kitchin jkitc...@andrew.cmu.edu writes:

 I usually do this kind of tracking with a link to the email instead. It
 is not automated communication between email and org, and it is not that
 complicated, but it does what I need, when I need it.

I will stop with shameless plugs at some point here, but this is exactly
what Gnorb does -- uses org to keep track of email conversations.
Tracking is done with vanilla org links and state-change log notes, but
the various gnorb functions make the whole process pretty much
automated.

https://github.com/girzel/gnorb#using-gnorb-for-tracking-email-todos

 Esben Stien b...@esben-stien.name writes:

 Esben Stien b...@esben-stien.name writes:

 Do you have any means to bring replies and such back into the org file?

 This seems like it could be a really good thing. 

 To be able to move the discussion to the relevant org file and then
 structure it and prioritize/schedule from there. 

 It seems a lot better than to have all these different discussions
 inside gnus, so I'd really like to try this. 




Re: [O] emails written in Org Mode

2014-07-14 Thread Thorsten Jolitz
Eric Abrahamsen e...@ericabrahamsen.net writes:

 John Kitchin jkitc...@andrew.cmu.edu writes:

 I usually do this kind of tracking with a link to the email instead. It
 is not automated communication between email and org, and it is not that
 complicated, but it does what I need, when I need it.

 I will stop with shameless plugs at some point here, but this is exactly
 what Gnorb does ...

Why? Nothing more frustrating than implementing a *brandnew* idea only
to find out later on that idea  implementation already existed. I would
not call this 'shameless plugs' but rather necessary and useful library
advertising, but maybe I'm biased since I tend to do the same thing ;)

PS 

Hadn't have the time to try Gnorb, but the combination of gnusorg is
definitely interesting for me.

-- 
cheers,
Thorsten




Re: [O] emails written in Org Mode

2014-07-14 Thread Eric Abrahamsen
Thorsten Jolitz tjol...@gmail.com writes:

 Eric Abrahamsen e...@ericabrahamsen.net writes:

 John Kitchin jkitc...@andrew.cmu.edu writes:

 I usually do this kind of tracking with a link to the email instead. It
 is not automated communication between email and org, and it is not that
 complicated, but it does what I need, when I need it.

 I will stop with shameless plugs at some point here, but this is exactly
 what Gnorb does ...

 Why? Nothing more frustrating than implementing a *brandnew* idea only
 to find out later on that idea  implementation already existed. I would
 not call this 'shameless plugs' but rather necessary and useful library
 advertising, but maybe I'm biased since I tend to do the same thing ;)

It's true it's hard to keep quiet when people are mulling over the
*exact* thing your library does... :)

 PS 

 Hadn't have the time to try Gnorb, but the combination of gnusorg is
 definitely interesting for me.




Re: [O] proposal to make C-c C-c not remove latex overlays

2014-07-14 Thread Grant Rettke
On Mon, Jul 14, 2014 at 7:33 PM, Aaron Ecay aarone...@gmail.com wrote:
 The first is to use the C-c C-v C-e binding to execute source blocks
 rather than C-c C-c.

Like this?

(setq org-babel-no-eval-on-ctrl-c-ctrl-c +1)



Re: [O] still seeing semi-regular lockups

2014-07-14 Thread York Zhao
 On Mon, Jun 30, 2014 at 8:43 PM, York Zhao gtdplatf...@gmail.com wrote:

 I got the problem today, with org-mode version 815c218 in Emacs 24.3.1.
The
 error message is: if: Lisp nesting exceeds `max-lisp-eval-depth'.
Attached is
 the backtrace saved in a file. Hope this will help.

Just an update. I haven't been bitten by this deadly problem for awhile,
highly
likely that it had been fixed. Thanks a lot.

York


Re: [O] Macros in included file not expanded in batch export

2014-07-14 Thread Nick Dokos
Suvayu Ali fatkasuvayu+li...@gmail.com writes:

 Hi,

 I am trying to export to LaTeX in batch mode, but it seems the exporter
 ignores macros defined in included files when exporting in batch mode.

 I tried to export like this:

   $ emacs --eval (require 'ox-latex) include-test.org \
 --eval '(org-LaTeX-export-to-latex nil nil nil t)' -f kill-emacs

   $ emacs --batch --eval (require 'ox-latex) include-test.org \
 --eval '(org-LaTeX-export-to-latex nil nil nil t)'

 The first one exports correctly, the second doesn't.  The org files, and
 the good and bad exported TeX files are attached.


I haven't tried it but --batch implies -q, so it may be that the second
form is missing something essential from your init file - maybe?
-- 
Nick




[O] Test failures

2014-07-14 Thread Nick Dokos
I just updated to Org-mode version 8.3beta (release_8.3beta-40-g9cf3c4)
and got three test failures:

,
| 3 unexpected results:
|FAILED  test-org/open-at-point-in-comment
|FAILED  test-org/open-at-point-in-property
|FAILED  test-org/open-at-point/info
`

Apparently these tests assume that the org info file can be found, but
the `make clea'n that is done at the beginning of make test wipes it
out. That's probably because I'm working out of the cloned git tree, but
if possible, I would like `make test' to work in that case.  My
workaround for now is to add `make info' in targets.mk:

--8---cut here---start-8---
index d390fdb..6d8b61a 100644
--- a/mk/targets.mk
+++ b/mk/targets.mk
@@ -100,6 +100,7 @@ vanilla:
 
 check test::   compile
 check test test-dirty::
+   make info
-$(MKDIR) $(testdir)
TMPDIR=$(testdir) $(BTEST)
 ifeq ($(TEST_NO_AUTOCLEAN),) # define this variable to leave $(testdir) around 
for inspection
--8---cut here---end---8---

Thanks!
-- 
Nick