Re: [O] Agenda printing: org-agenda-write doesn't use ps-paper-type

2013-06-12 Thread Christian Egli
Myles English  writes:

> Trying to print an agenda to pdf always results in the paper size being
> US letter even though ps-paper-type is set to a4.
>
> This is how I try to print it:
>
> (org-agenda-write "/home/myles/tmp/agenda.pdf" nil nil "*Org Agenda(a)*")

org-agenda-write uses ps-print to do the work so setting ps-paper-type
should indeed help.

> and setting this doesn't fix it either:
>
> (eval-after-load "ps-print"
>   '(setq ps-paper-type 'a4))
>

Have you tried setting this variable with the custom interface, i.e. M-x
customize-variable RET ps-paper-type RET?

HTH
Christian
-- 
Christian Egli
Swiss Library for the Blind, Visually Impaired and Print Disabled
Grubenstrasse 12, CH-8045 Zürich, Switzerland




Re: [O] export to odt

2013-06-12 Thread Eric S Fraga
Manfred Lotz  writes:

> On Tue, 11 Jun 2013 11:33:56 +0100
> Eric S Fraga  wrote:

[...]

>> 2. The title and author fields in the exported document are protected
>> in some way and I cannot figure out how to enable editing on them.  I
>>  can change the style for these just fine but I cannot change the
>>  text.
>> 
>
> You easily can setup both title and author in your org document like
> this:
>
> #+TITLE: My Important Documentation
> #+AUTHOR: Manfred Lotz
>
> Is this what you mean?

No.  I know I can set the title and author in org.  However, sometimes,
I need to tweak the title or author information *only* in the exported
document.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.1, Org release_8.0.3-193-g334581




Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Feng Shu
Viktor Rosenfeld  writes:

> Hi,
>
> Feng Shu wrote:
>
>> org-mode odt exporter are using 'org-odt-styles-file, which are odt
>> templetes, I think latex exporter should do like this. for example:
>
> I would also like to have a template mechanism for my LaTeX exports.
> However, I think the way to do it in LaTeX is to write custom *.sty
> files which can then be included using #+LATEX_HEADER: \usepackage{...}
> for individual exports or more generally using org-latex-packages-alist.

.sty can be easily resolved.

The problem is that many template should be writen as "class" instead of
"style".   If I want to use a custom class , I need to do:

1. (add-to-list 'org-latex-classes ...)
2. (setq org-latex-default-class ...)


I don't know other language users, for Chinese latex user, the first
thing of write a document may  change the document class, for example,
change "article" to "ctexart". If I want use org-mode ,I should add all
the "class" common used  to the "org-latex-classes", It will be  a
nightmare.

In org-latex-class, "article"  and  "ctexart" elements are  very similar, the
only different may be their class names.

I want such result:

1. I don't need customize 'org-latex-classes
2. #+LATEX_CLASS: ctexart  can work!

>
> I've been wanting to learn how to do it but I did not find the time yet.
> (Any pointers to good tutorials would be appreciated.)
>
> Cheers,
> Viktor
>
>> 
>>
>> org-latex-styles-file  or  org-latex-templete-file
>> 
>> 
>> we can include many different language's templates into org, and no need
>> touch the ox-latex.el and the user can write theirs template easily,
>> 
>> 
>> 
>> we can use "locale" to determine which template will be used
>> 
>> 
>> 
>> converting latex fragements can use templates too, like:
>> 
>> 
>> org-latex-fragment-templete-file
>> 
>> 
>> 
>> -- 
>> 

-- 



Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Feng Shu
Feng Shu  writes:

> Viktor Rosenfeld  writes:
>
>> Hi,
>>
>> Feng Shu wrote:
>>
>>> org-mode odt exporter are using 'org-odt-styles-file, which are odt
>>> templetes, I think latex exporter should do like this. for example:
>>
>> I would also like to have a template mechanism for my LaTeX exports.
>> However, I think the way to do it in LaTeX is to write custom *.sty
>> files which can then be included using #+LATEX_HEADER: \usepackage{...}
>> for individual exports or more generally using org-latex-packages-alist.
>
> .sty can be easily resolved.
>
> The problem is that many template should be writen as "class" instead of
> "style".   If I want to use a custom class , I need to do:
>
> 1. (add-to-list 'org-latex-classes ...)
> 2. (setq org-latex-default-class ...)
>
>
> I don't know other language users, for Chinese latex user, the first
> thing of write a document may  change the document class, for example,
> change "article" to "ctexart". If I want use org-mode ,I should add all
> the "class" common used  to the "org-latex-classes", It will be  a
> nightmare.
>
> In org-latex-class, "article"  and  "ctexart" elements are  very similar, the
> only different may be their class names.
>
> I want such result:
>
> 1. I don't need customize 'org-latex-classes
> 2. #+LATEX_CLASS: ctexart  can work!

#+LATEX_ARTICLE_CLASS: ctexart   ?
#+LATEX_CLASS:  article:ctexart  ?

>
>>
>> I've been wanting to learn how to do it but I did not find the time yet.
>> (Any pointers to good tutorials would be appreciated.)
>>
>> Cheers,
>> Viktor
>>
>>> 
>>>
>>> org-latex-styles-file  or  org-latex-templete-file
>>> 
>>> 
>>> we can include many different language's templates into org, and no need
>>> touch the ox-latex.el and the user can write theirs template easily,
>>> 
>>> 
>>> 
>>> we can use "locale" to determine which template will be used
>>> 
>>> 
>>> 
>>> converting latex fragements can use templates too, like:
>>> 
>>> 
>>> org-latex-fragment-templete-file
>>> 
>>> 
>>> 
>>> -- 
>>> 

-- 



Re: [O] face for inline-tasks

2013-06-12 Thread Carsten Dominik

On Jun 11, 2013, at 9:42 PM, Andreas Leha  
wrote:

> Hi all,
> 
> how can I achieve, that the whole inline-task uses a font face
> (esp. with background)?
> 
> I customized the face org-inlinetask, but that only fontifies the last
> stars and the 'END'.  I would like to color the whole line plus all the
> contents.  I have similar settings for my code blocks and find it very
> convenient.
> (see http://orgmode.org/worg/images/color-themes/color-theme-leuven.png
> for an example of what I mean)
> 
> Is that possible for inline-tasks, as well?

No, this is not possible.

- Carsten

> 
> Best,
> Andreas
> 
> 




Re: [O] Agenda printing: org-agenda-write doesn't use ps-paper-type

2013-06-12 Thread Myles English

Hi Christian,

Christian Egli writes:

> Myles English  writes:
>
>> Trying to print an agenda to pdf always results in the paper size being
>> US letter even though ps-paper-type is set to a4.

> Have you tried setting this variable with the custom interface, i.e. M-x
> customize-variable RET ps-paper-type RET?

The customise interface shows that ps-paper-type is indeed set to a4,
but still the agenda prints on US letter.

Any other ideas?

Myles



Re: [O] face for inline-tasks

2013-06-12 Thread Andreas Leha
Carsten Dominik  writes:

> On Jun 11, 2013, at 9:42 PM, Andreas Leha 
>  wrote:
>
>> Hi all,
>> 
>> how can I achieve, that the whole inline-task uses a font face
>> (esp. with background)?
>> 
>> I customized the face org-inlinetask, but that only fontifies the last
>> stars and the 'END'.  I would like to color the whole line plus all the
>> contents.  I have similar settings for my code blocks and find it very
>> convenient.
>> (see http://orgmode.org/worg/images/color-themes/color-theme-leuven.png
>> for an example of what I mean)
>> 
>> Is that possible for inline-tasks, as well?
>
> No, this is not possible.
>

Ok, good to know.  Thanks,

Andreas




[O] org-babel, gnuplot and buffer-wide header arguments

2013-06-12 Thread Carlos Russo

Hi

it seems that org-babel-gnuplot only recognizes a few header arguments.
I would like to set the following on top of the buffer:

#+PROPERTY: term pdfcairo enhanced mono size 8cm,6cm font "Helvetica"

in order to control the appearance of a bunch of figures generated by gnuplot
#+begin_src gnuplot :exports result :file file.pdf
plot ...
#+end_src

Basically, I would like to avoid writing the :term property all the time:

#+begin_src gnuplot :exports result :file file.pdf :term pdfcairo 
enhanced mono size 8cm,6cm font "Helvetica"

plot ...
#+end_src

It seems that this requires a modification to ob-gnuplot.el.
Any hints on how to do this?

Thanks,
Carlos





Re: [O] [RFC] BibELTeX: native bibtex support in org-mode

2013-06-12 Thread Rüdiger Sonderfeld
Rasmus  gmx.us> writes:

> 
> Rüdiger Sonderfeld  c-plusplus.de> writes:
> 
> > I've started writing BibELTeX as an alternative to =ox-bibtex.el=. 
> >
> > https://github.com/ruediger/bibeltex
> 
> Would you consider providing a test file showing off its features?

I added a file test/example.org.  Put bibeltex.el somewhere in your load-path 
and require it.  This should be enough to make it work (use unload-feature to 
remove it again).

You can then export the document to any format you like.  Good test case is 
using org-mode export (ox-org.el).

> I'm skeptical but probably it is 'cause I've misunderstood something!
> Someone put a lot of thought into writing e.g. biblatex or
> odt-bibliographies.  Surely(?) we would want to leverage upon those
> and only have org-support insofar as serving some backend-specific
> parser enough information to do its work?

Certainly.  BibELTeX is designed to do this.  For LaTeX export it just 
generates the corresponding LaTeX instructions (can be adopted even for 
biblatex).

But except for LaTeX there doesn't seem to be a real support for bibliography.  
It can be simulated for html using bibtex2html (ox-bibtex.el).  But even that 
is not compatible with biber/biblatex.  That's the reason behind BibELTeX.

Regards




Re: [O] [patch][ox-koma-letter] Support for to and from headings

2013-06-12 Thread Alan Schmitt
Hi Rasmus,

Rasmus writes:

> Rasmus  writes:
>
>> Rasmus  writes:
>>
>>> Hi,
>>>
>>> Some more patches that should work against the master branch.
>>>
>>> Patch 1: bug fixes.  Most notably use symbols some places rather than
>>> strings.
>>>
>>> Patch 2 adds support for TO and FROM headings.  If you've got time for
>>> testing I would appreciate feedback.  It's explained in the top of the
>>> patch.
>>
>> Patch 1 and 2 are updated.  Patch three adds support for an
>> `org-koma-letter-default-class' and a plug-in function to make it
>> easier to use letters.  They should apply against master.
>
> Updated again and hopefully better changelog etc. . .

I applied the patches (just changing a small typo in the changelog).

Alan



Re: [O] Trigger org-capture window using linux shortcut key

2013-06-12 Thread jackin
Sincere thanks for your reply . I got it to work on my Debian machine as
follows.

Ref: http://comments.gmane.org/gmane.emacs.orgmode/33650

1) I appended these lines to my ~/.emacs file

(defadvice org-capture-finalize (after delete-capture-frame activate)
  "Advise capture-finalize to close the frame if it is the capture
frame"
  (if (equal "capture" (frame-parameter nil 'name))
  (delete-frame)))

(defadvice org-capture-destroy (after delete-capture-frame activate)
  "Advise capture-destroy to close the frame if it is the capture frame"
  (if (equal "capture" (frame-parameter nil 'name))
  (delete-frame)))

(defun make-capture-frame ()
  "Create a new frame and run org-capture."
  (interactive)
  (make-frame '((name . "capture")))
  (select-frame-by-name "capture")
  (delete-other-windows)
  (org-capture)
  )


2) On the debian machine - 
System -> Preferences -> Keyboard Shortcuts -> Add ->
Command : /usr/bin/emacsclient -n -e '(make-capture-frame)'
Shortcut : Ctrl+Alt+C (or any of your favorite key combination)

That's it! Works like a charm for me and now I can capture anything that
flashes across my mind in a fraction of seconds, not disturbing my
original work flow on the PC.


regards,
Jackin



On Wed, 2013-05-22 at 17:00 -0500, Matt Lundin wrote:
> Jackin  writes:
> 
> >   I am wondering if it is possible to start a org-capture window
> > (when not within emacs) using a shortcut key. Org-protocol allows this
> > to be done from a web browser or adobe reader which is very useful. But
> > I am thinking of a more general solution, for triggering a org-capture
> > window from any where in Linux -> type in something and -> C-c c-c.
> >
> >  Any ideas or solutions? Thanks in advance.
> 
> The answer will likely depend on which desktop or window manager you
> use. I have the following in my openbox rc.xml:
> 
> 
>   
> emacsclient -c -e "(org-capture)"
>   
> 
> 
> Gnome and KDE will likely have a GUI for adding custom keyboard
> shortcuts.
> 
> Best,
> Matt
> 





Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Nicolas Goaziou
Hello,

Feng Shu  writes:

> I don't know other language users, for Chinese latex user, the first
> thing of write a document may  change the document class, for example,
> change "article" to "ctexart". If I want use org-mode ,I should add all
> the "class" common used  to the "org-latex-classes", It will be  a
> nightmare.
>
> In org-latex-class, "article"  and  "ctexart" elements are  very similar, the
> only different may be their class names.
>
> I want such result:
>
> 1. I don't need customize 'org-latex-classes

I don't see why customizing `org-latex-classes' _once_ would be
a nightmare.


Regards,

-- 
Nicolas Goaziou



Re: [O] Alarms in orgmode

2013-06-12 Thread Rene

Sébastien Vauban  writes:

> --8<---cut here---start->8---
>   (defun rgr/org-display (min-to-app new-time msg)
> (shell-command
>  (concat "notify-send "
>  "-i
/usr/share/icons/gnome/32x32/status/appointment-soon.png "
>  "'Appointment' "
>  "'" msg "'")))
>   ;; TODO For Windows users: use todochicku.el and the snarl notifier
> 
>   (setq appt-disp-window-function (function rgr/org-display)))
> --8<---cut here---end--->8---


If two (or more) appointments happen to start at the same time then
appt-disp-window-function leads to the following error: “Argtype error in
‘appt-disp-window-function’ - update it for multiple appts?”

A more suited piece of code would be:

(setq appt-disp-window-function
  (lambda  (min-to-app new-time appt-msg) ; these args could be lists
(or (listp min-to-app)
(setq appt-msg (list appt-msg)))
(dotimes (i (length appt-msg))
  (shell-command
(concat "notify-send "
  "-i /usr/share/icons/gnome/32x32/status/appointment-soon.png "
"-t 1000 "
"'Appointment' "
"'" (nth i appt-msg) "'")





Re: [O] [PATCH (v5)][ox-latex.el] Allow AUTO argument to org-latex-guess-babel-language.

2013-06-12 Thread Nicolas Goaziou
Hello,

Rasmus  writes:

> v5! Documentation added.  Let me know if more stuff needs to be
> polished.

Applied. Thank you!

Note that commit message's first line mustn't end with a period.
Moreover, I slightly changed phrasing in `org-latex-classes' in order to
insist on the fact that `org-export-default-language' is a language
code, not a language /per se/. Eventually, I added TINYCHANGE since,
AFAIK, you haven't signed FSF papers yet.


Regards,

-- 
Nicolas Goaziou



Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Eric Abrahamsen
Feng Shu  writes:

> Feng Shu  writes:
>
>> Viktor Rosenfeld  writes:
>>
>>> Hi,
>>>
>>> Feng Shu wrote:
>>>
 org-mode odt exporter are using 'org-odt-styles-file, which are odt
 templetes, I think latex exporter should do like this. for example:
>>>
>>> I would also like to have a template mechanism for my LaTeX exports.
>>> However, I think the way to do it in LaTeX is to write custom *.sty
>>> files which can then be included using #+LATEX_HEADER: \usepackage{...}
>>> for individual exports or more generally using org-latex-packages-alist.
>>
>> .sty can be easily resolved.
>>
>> The problem is that many template should be writen as "class" instead of
>> "style".   If I want to use a custom class , I need to do:
>>
>> 1. (add-to-list 'org-latex-classes ...)
>> 2. (setq org-latex-default-class ...)
>>
>>
>> I don't know other language users, for Chinese latex user, the first
>> thing of write a document may  change the document class, for example,
>> change "article" to "ctexart". If I want use org-mode ,I should add all
>> the "class" common used  to the "org-latex-classes", It will be  a
>> nightmare.
>>
>> In org-latex-class, "article"  and  "ctexart" elements are  very similar, the
>> only different may be their class names.
>>
>> I want such result:
>>
>> 1. I don't need customize 'org-latex-classes
>> 2. #+LATEX_CLASS: ctexart  can work!
>
> #+LATEX_ARTICLE_CLASS: ctexart   ?
> #+LATEX_CLASS:  article:ctexart  ?

I do Chinese documents using xelatex, and it works just fine (with the
xeCJK package). I make a "mychinesestylefile.sty" file with all my
xelatex and Chinese font stuff. Then:

(eval-after-load 'ox-latex
  '(add-to-list 'org-latex-classes
  '("myclass" "\\documentclass{article}
[NO-DEFAULT-PACKAGES]
[NO-PACKAGES]
[EXTRA]
\\usepackage{mychinesestylefile}"
("\\section{%s}" . "\\section*{%s}")
("\\subsection{%s}" . "\\subsection*{%s}")
("\\subsubsection{%s}" . "\\subsubsection*{%s}")
("\\paragraph{%s}" . "\\paragraph*{%s}")
("\\subparagraph{%s}" . "\\subparagraph*{%s}"

And then in any given document:

#+LaTeX_CLASS: myclass

If I need to layer another project-specific style file on top of that, I
add a second line in the header:

#+LaTeX_HEADER: \usepackage{someparticularpackage}

Any document that might require Chinese starts as a "myclass", and then
goes from there. I set this up a year ago, and haven't needed to mess
with it since.

Hope that helps,
Eric




Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Feng Shu
Nicolas Goaziou  writes:

> Hello,
>
> Feng Shu  writes:
>
>> I don't know other language users, for Chinese latex user, the first
>> thing of write a document may  change the document class, for example,
>> change "article" to "ctexart". If I want use org-mode ,I should add all
>> the "class" common used  to the "org-latex-classes", It will be  a
>> nightmare.
>>
>> In org-latex-class, "article"  and  "ctexart" elements are  very similar, the
>> only different may be their class names.
>>
>> I want such result:
>>
>> 1. I don't need customize 'org-latex-classes
>
> I don't see why customizing `org-latex-classes' _once_ would be
> a nightmare.

If all the CJKV org-mode users need customize this virable _once_ ,
It's a nightmare for org-mode, for all the CJKV org-mode users need to
know how to customize this virable!

If we add all the "class" common used in the world, `org-latex-classes
will be very very long!

>
>
> Regards,

-- 



Re: [O] [RFC] BibELTeX: native bibtex support in org-mode

2013-06-12 Thread Ista Zahn
On Wed, Jun 12, 2013 at 6:48 AM, Rüdiger Sonderfeld
 wrote:
> Rasmus  gmx.us> writes:
>
>>
>> Rüdiger Sonderfeld  c-plusplus.de> writes:
>>
>> > I've started writing BibELTeX as an alternative to =ox-bibtex.el=.
>> >
>> > https://github.com/ruediger/bibeltex
>>
>> Would you consider providing a test file showing off its features?
>
> I added a file test/example.org.  Put bibeltex.el somewhere in your load-path
> and require it.  This should be enough to make it work (use unload-feature to
> remove it again).
>
> You can then export the document to any format you like.  Good test case is
> using org-mode export (ox-org.el).

Thank you for this, I've been waiting for this capability a long time.
I look forward to giving it a more through test!

Best,
Ista


>
>> I'm skeptical but probably it is 'cause I've misunderstood something!
>> Someone put a lot of thought into writing e.g. biblatex or
>> odt-bibliographies.  Surely(?) we would want to leverage upon those
>> and only have org-support insofar as serving some backend-specific
>> parser enough information to do its work?
>
> Certainly.  BibELTeX is designed to do this.  For LaTeX export it just
> generates the corresponding LaTeX instructions (can be adopted even for
> biblatex).
>
> But except for LaTeX there doesn't seem to be a real support for bibliography.
> It can be simulated for html using bibtex2html (ox-bibtex.el).  But even that
> is not compatible with biber/biblatex.  That's the reason behind BibELTeX.
>
> Regards
>
>



Re: [O] [PATCH (v5)][ox-latex.el] Allow AUTO argument to org-latex-guess-babel-language.

2013-06-12 Thread Rasmus
Nicolas Goaziou  writes:

> Applied. Thank you!
>
> Note that commit message's first line mustn't end with a period.
> Moreover, I slightly changed phrasing in `org-latex-classes' in order to
> insist on the fact that `org-export-default-language' is a language
> code, not a language /per se/. Eventually, I added TINYCHANGE since,
> AFAIK, you haven't signed FSF papers yet.

Yeah, it is a TINYCHANGE.  Anyway, papers are on their way to the FSF.

–Rasmus

-- 
Hvor meget poesi tror De kommer ud af et glas isvand?



Re: [O] [patch][ox-koma-letter] Support for to and from headings

2013-06-12 Thread Rasmus
Alan Schmitt  writes:

> I applied the patches (just changing a small typo in the changelog).

Thanks, let me know if any errors pop up.

–Rasmus

-- 
When in doubt, do it!



Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Rasmus
Feng Shu  writes:

>>> 1. I don't need customize 'org-latex-classes
>>
>> I don't see why customizing `org-latex-classes' _once_ would be
>> a nightmare.
>
> If all the CJKV org-mode users need customize this virable _once_ ,
> It's a nightmare for org-mode, for all the CJKV org-mode users need to
> know how to customize this virable!
>
> If we add all the "class" common used in the world, `org-latex-classes
> will be very very long!

Org ships with like three or four classes. . .  Not all classes in the
world. You can add your own.  With add-to-list it's not even
'dangerous'.  Are you looking for a system to your custom classes?

I have at least five classes that I use, e.g. #+LATEX_CLASS:
problemset loads lots of math stuff and tikz. . .  This seems pretty
close to optimal to me less the fact that you need to escape '\', but
that's just Emacs Lisp.

–Rasmus

-- 
May the Force be with you




Re: [O] [suggest] We should import latex template system

2013-06-12 Thread Feng Shu
>
> (eval-after-load 'ox-latex
>   '(add-to-list 'org-latex-classes
>   '("myclass" "\\documentclass{article}
> [NO-DEFAULT-PACKAGES]
> [NO-PACKAGES]
> [EXTRA]
> \\usepackage{mychinesestylefile}"
>   ("\\section{%s}" . "\\section*{%s}")
>   ("\\subsection{%s}" . "\\subsection*{%s}")
>   ("\\subsubsection{%s}" . "\\subsubsection*{%s}")
>   ("\\paragraph{%s}" . "\\paragraph*{%s}")
>   ("\\subparagraph{%s}" . "\\subparagraph*{%s}"
>
> And then in any given document:
>
> #+LaTeX_CLASS: myclass

At the moment, I am using the similar solution!  

If you use this way,  org-mode fragement previewing  may be broken if
you setting \pagestyle{fancy}. 


>
> If I need to layer another project-specific style file on top of that, I
> add a second line in the header:
>
> #+LaTeX_HEADER: \usepackage{someparticularpackage}
>
> Any document that might require Chinese starts as a "myclass", and then
> goes from there. I set this up a year ago, and haven't needed to mess
> with it since.

There are many, the first one is "ctex", which may be the most popular
latex solution of  chinese users.

All the university latex templates in China seem to be writen as
"class", instead of "style".

and nearly all  of them are derive from  class "article" or "book"

It is the reason that I want this feature:

#+LaTeX_CLASS: article:myclass

It will use default "article" template, and replace class name to myclass!

>
> Hope that helps,
> Eric

-- 



Re: [O] BUG - Problem in tangle-mode

2013-06-12 Thread Rainer M Krug
Rainer M Krug  writes:

> On Tuesday, June 11, 2013, Eric Schulte wrote:
>
>> Rainer M Krug > writes:
>>
>> > Eric Schulte > writes:
>> >
>> >
>> > I've added a :tangle-mode header argument which may be used to
>> control
>> > the permissions of tangled files.  See the manual for instructions on
>> > it's usage.
>> 
>> 
>>  Thanks a lot. I will try it out today or tomorrow.
>> >>>
>> >>> I did, and there is a problem with tangling multiple blocks into a
>> >>> single file:
>> >>>
>> >>
>> >> Oh, stupid of me.  Thanks for sending this alert, I've just pushed up a
>> >> change which should fix this problem.  We now wait to set the file modes
>> >> until after all blocks are tangled and after the post-tangle-hook has
>> >> been run.
>> >>
>> >> Thanks,
>> >
>> > Hi
>> >
>> > Unfortunately, it is now worse, as even without the tangle-mode header,
>> > I can't tangle two blocks - the second block overwrites the before
>> > tangled blocks. It tells me that two blocks were tangled, but only the
>> > last one is in the tangled file.
>> >
>> > I will for revert for now to the version from yesterday.
>> >
>> > Cheers,
>> >
>>
>> Just pushed up a fix.  Cheers,
>
>
> Thanks. Will try it out tomorrow,

Hi

it seems that I have no luck at the moment.

Now the post tangle hook does not seem to be called.

If I use the file below, evaluate the code to set the hook, the hook is
not executed.

,
| #+PROPERTY: tangle ./test.R
| 
| * Internal configurations  :noexport:
| ** Evaluate to run post tangle script
| #+begin_src emacs-lisp :results silent :tangle no :exports none
| (add-hook 'org-babel-post-tangle-hook(
| lambda () (call-process-shell-command 
"./postTangleScript.sh" nil 0 nil))
| )
| #+end_src
| 
| ** Post tangle script
| #+begin_src sh :tangle postTangleScript.sh
| touch PostTangleScriptHasBeenExecuted
| #+end_src
| 
| #+results:
| 
| 
| * Two blocks
| Block 1
| #+begin_src R
|   suitName <- function(species)
| {
|   return( paste(species$layer, "suitability", sep="_") )
| }
| #+end_src  
| 
| Block 2
| #+begin_src R
|   statDistName <- function(species){
|   return( paste(species$layer, "disturbances_static", sep="_") )
|   }
| #+end_src  
`

The hook is set:
,
| Its value is
| ((lambda nil
|(call-process-shell-command "./postTangleScript.sh" nil 0 nil)))
| 
| Original value was nil
`

Strangely enough, if I use

,
| #+begin_src emacs-lisp :tangle no
| (defvar org-babel-tangled-file nil
|   "If non-nill, current file was tangled with org-babel-tangle")
| (put 'org-babel-tangled-file 'safe-local-variable 'booleanp)
| 
| (defun org-babel-mark-file-as-tangled ()
|   
|   (when  (string-match "[.]R" (buffer-file-name))
|   (add-file-local-variable 'org-babel-tangled-file t)
| (add-file-local-variable 'buffer-read-only t)
| ;; (add-file-local-variable 'eval: (auto-revert-mode))
| (basic-save-buffer)))
| 
| (add-hook 'org-babel-post-tangle-hook 'org-babel-mark-file-as-tangled)
| #+end_src
`

and evaluate this block (after resetting the post-tangle-hook), this
function is executed?

Sorry about all the hassles,

Rainer


>
> Cheers,
>
> Rainer
>
>>
>> --
>> Eric Schulte
>> http://cs.unm.edu/~eschulte
>>


-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :   +33 - (0)9 53 10 27 44
Cell:   +33 - (0)6 85 62 59 98
Fax :   +33 - (0)9 58 10 27 44

Fax (D):+49 - (0)3 21 21 25 22 44

email:  rai...@krugs.de

Skype:  RMkrug


pgpML9UV3sGef.pgp
Description: PGP signature


[O] Bug in export orgtbl / LaTeX

2013-06-12 Thread AW
Hi!

If I try to use orgtbl-mode in this file and export the orgtbl block inside the 
comment environment to the RECEIVE ORGTBL area, the LaTeX-file will not 
compile, because the numbering in the org-table is exported as

\begin{enumerate}
\item installment
\end{enumerate}

I'd say that inside tabulars numbers like "1." should not be considered as a 
part of a numbered list.

Regards,

Alexander



===
\documentclass[ngerman]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{babel, comment}


\begin{document}



\begin{center}
  \begin{tabular}{lrrr}
Rate& Fälligkeit & {Betrag (netto) EUR} & Umsatzst. \\
% BEGIN RECEIVE ORGTBL Zahlungsraten

% END RECEIVE ORGTBL Zahlungsraten

  \end{tabular}
\end{center}

\begin{comment}
  #+ORGTBL: SEND Zahlungsraten orgtbl-to-latex :splice t :skip 1
  |+-+--+--|
  | 1. installment | Vertragsschluss | 0,00 | zuzügl. USt. |
  | 2. installment | Begin 1 | ,00  | zuzügl. USt. |
  | 3. installment | Begin 2 | ,00  | zuzügl. USt. |
  | 4. installment | Abschluss 1 | ,00  | zuzügl. USt. |
  | 5. installment | Abschluss 2 | 000,00   | zuzügl. USt. |
  | 6. installment | Inbetriebnahme  | 000,00   | zuzügl. USt. |
  |+-+--+--|
  | Summe: | | 0.00 | zuzügl. USt. |

  #+TBLFM: @7$3=vsum(@I..@II);%.2f
  #$
\end{comment}
\end{document}

==



Re: [O] Agenda printing: org-agenda-write doesn't use ps-paper-type

2013-06-12 Thread Eric S Fraga
Myles English  writes:

> Hi Christian,
>
> Christian Egli writes:
>
>> Myles English  writes:
>>
>>> Trying to print an agenda to pdf always results in the paper size being
>>> US letter even though ps-paper-type is set to a4.
>
>> Have you tried setting this variable with the custom interface, i.e. M-x
>> customize-variable RET ps-paper-type RET?
>
> The customise interface shows that ps-paper-type is indeed set to a4,
> but still the agenda prints on US letter.

Have you checked to see if the postscript version uses the right paper
size?  Just in case the ps -> pdf conversion is at fault?  The pdf is
created from the ps file.  In any case, both ps and pdf work just fine
for me to A4 with ps-paper-type set to 'a4.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.1, Org release_8.0.3-193-g334581




Re: [O] List of Figures not being generated in 8.0.3?

2013-06-12 Thread Eric S Fraga
Luke Crook  writes:

> I just noticed that the List of Figures is not being generated in 8.0.3.
>
> I have a figure with;
>
> #+LATEX: \listoffigures
>
> #+ATTR_LaTeX: width=5.5cm

Maybe try with

#+attr_latex: :width 5.5cm

The format for attributes has changed in version 8 of org.
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.1, Org release_8.0.3-193-g334581




[O] Bug: font locking breaks by saying "#+SETUPFILE" in the middle of a line [8.0.3 (release_8.0.3-165-g60ca9e @ /home/youngfrog/sources/org-mode/lisp/)]

2013-06-12 Thread Nicolas Richard

Hi all,

Consider the following testing.el

#+BEGIN_SRC emacs-lisp
  (setq inhibit-splash-screen t)
  (add-to-list 'load-path "~/sources/org-mode/lisp/")
  (let ((org-agenda-files '("testing.org")))
 (org-agenda-list))
#+END_SRC

and the following testing.org

#+begin_src org
  ,* Heading
  On peut aussi utiliser #+SETUPFILE.
#+end_src

Launching those with
  emacs -l testing.el testing.org
shows[1] that the buffer testing.org doesn't have its headline in blue
like it should. If I then launch Gnus for instance, it also has problems
of missing colors.

I've had such a line in one of my org file for one year now, and it used
to work fine, but I have to catch my train right now so can't debug
further atm. Maybe this rings a bell already ?


-- 
Nico.

[1] This loads the .el file, which in particular loads testing.org, and
then shows that buffer



Re: [O] List of Figures not being generated in 8.0.3?

2013-06-12 Thread Nick Dokos

Eric S Fraga  writes:

> Luke Crook  writes:
>
>> I just noticed that the List of Figures is not being generated in 8.0.3.
>>
>> I have a figure with;
>>
>> #+LATEX: \listoffigures
>>
>> #+ATTR_LaTeX: width=5.5cm
>
> Maybe try with
>
> #+attr_latex: :width 5.5cm
>
> The format for attributes has changed in version 8 of org.

Although this might lead to a problem in how the figure appears on the
page, I believe the main problem was that there was no caption
associated with the image, so it was not put in a figure environment, it
was just inlined: inline images do not contribute to the list of
figures.

As Rasmus pointed out, #+caption was incorrectly associated with the
code block, rather than with the resulting image. The trick is to name
the code block and its results block, using the same name: that ties
them together, so that further execution of the code block does not
produce a new results block. Then you attach #+caption to the results
block:

,
| #+name: foo
| #+begin_src ...
| ...
| #+end_src
| 
| #+caption: bar
| #+results: foo
| 
`

It used to be that the naming was mandatory: the intervening #+caption
line would cause babel to produce a new results block. ISTR that Nicolas
fixed it so that the naming is no longer necessary and babel will DTRT -
IOW, the following will work:

,
| #+begin_src
| ...
| #+end_src
| 
| #+caption: bar
| #+results:
`

I just checked btw, and it does work.

Org-mode version 8.0.3 (release_8.0.3-197-g221768 @ 
/home/nick/elisp/org-mode/lisp/)
-- 
Nick




[O] managing a work log

2013-06-12 Thread Adam Spiers
Hi all,

With `org-archive-mark-done' set to `t', entries will be marked as
done when `org-archive-subtree' is invoked.  However, this does not
honour the expected behaviour when `org-log-done' is set to `'time',
i.e. that a `CLOSED: [timestamp]' line will be inserted just after the
headline.  Is that a bug/feature, or am I missing something?

Thanks,
Adam



Re: [O] export to odt

2013-06-12 Thread Manfred Lotz
On Wed, 12 Jun 2013 08:33:55 +0100
Eric S Fraga  wrote:

> Manfred Lotz  writes:
> 
> > On Tue, 11 Jun 2013 11:33:56 +0100
> > Eric S Fraga  wrote:
> 
> [...]
> 
> >> 2. The title and author fields in the exported document are
> >> protected in some way and I cannot figure out how to enable
> >> editing on them.  I can change the style for these just fine but I
> >> cannot change the text.
> >> 
> >
> > You easily can setup both title and author in your org document like
> > this:
> >
> > #+TITLE: My Important Documentation
> > #+AUTHOR: Manfred Lotz
> >
> > Is this what you mean?
> 
> No.  I know I can set the title and author in org.  However,
> sometimes, I need to tweak the title or author information *only* in
> the exported document.
> 

Aah, ok. Now I see what your are after.

GO to menu entry File/Properties and then you click tab Description.
There you can edit Title.


It seems that you can edit author via menu Tools/Options. Then
choose LibreOffice/User Data and edit First/Last Name. Finally, you
have to go to File/Properties and click on Reset (Please note, that
there 'Apply user data' must be clicked on). 

This is really weird or it is because just my knowledge about
Libreoffice is limited. At least, I'm happy to be able to use LaTeX in
most cases instead of an office product.




-- 
Manfred



Re: [O] Starting emacs followed directly by org-agenda search and visiting file removes color formatting

2013-06-12 Thread John Hendy
Just wanted to follow up on this. I haven't been using =C-a s= a ton
so it drifted off my radar, but recently needed to use it a lot and
noticed this was still persisting.

Thanks!
John

On Mon, May 27, 2013 at 2:00 AM, Bastien  wrote:
> Hi Rainer,
>
> Rainer Stengele  writes:
>
>> any chance to get that bug resolved? I did not upgrade org since the
>> commit introducing it.
>
> Yes, it is on top of my list, I was away from computer for a while,
> but I'll tackle this ASAP.
>
> --
>  Bastien



[O] Relation between todo-mode.el and Org-mode?

2013-06-12 Thread Thorsten Jolitz

Hi List, 

on the 'emacs-devel' mailing list I saw the announcement of a new
version of `todo-mode.el', which I found a bit surprising - I would not
have expected that something else as Org-mode is used nowadays to manage
todo lists with Emacs?

How is the relation between these two packages - if there is any?
Anybody with more insights?

-- 
cheers,
Thorsten





Re: [O] Starting emacs followed directly by org-agenda search and visiting file removes color formatting

2013-06-12 Thread Bastien
Hi John,

John Hendy  writes:

> Just wanted to follow up on this. I haven't been using =C-a s= a ton
> so it drifted off my radar, but recently needed to use it a lot and
> noticed this was still persisting.

... it's still on my radar too, I've just been overwhelmed by work
and other stuff.  I should have more time next week, sorry for the
delay.

-- 
 Bastien



Re: [O] Relation between todo-mode.el and Org-mode?

2013-06-12 Thread Bastien
Hi Thorsten,

Thorsten Jolitz  writes:

> How is the relation between these two packages - if there is any?

To my knowledge, there is no relation -- I'd be curious to know
if anyone on this list has been testing/using it.

> Anybody with more insights?

Not from my side, but given the lengthy manual that the maintainer
posted, I put this on my list of stuff to test.  I may report my
experience in testing this if this is useful!

-- 
 Bastien



Re: [O] BUG - Problem in tangle-mode

2013-06-12 Thread Eric Schulte
>
> Hi
>
> it seems that I have no luck at the moment.
>
> Now the post tangle hook does not seem to be called.
>

It is called, however the shell script you are trying to execute is not
executing because it is not set as executable.  The permissions of
tangled files are set *after* the post-tangle hook is called (so that
the post-tangle hook has a chance to modify files which will eventually
be set to read only).

You example is trying to run a tangled shell script before it is set to
be executable.  This can not work.  My attached alternative of your
example does run the shell script by not assuming it is executable.

#+PROPERTY: tangle ./test.R

* Internal configurations  :noexport:
** Evaluate to run post tangle script
#+begin_src emacs-lisp :results silent :tangle no :exports none
(add-hook 'org-babel-post-tangle-hook
  (lambda ()
(message "running the post-tangle shell script")
(shell-command "bash ./postTangleScript.sh")))
#+end_src

** Post tangle script
#+begin_src sh :tangle postTangleScript.sh :results silent
touch PostTangleScriptHasBeenExecuted
#+end_src

* Two blocks
Block 1
#+begin_src R
  suitName <- function(species)
{
  return( paste(species$layer, "suitability", sep="_") )
}
#+end_src  

Block 2
#+begin_src R
  statDistName <- function(species){
  return( paste(species$layer, "disturbances_static", sep="_") )
  }
#+end_src  

-- 
Eric Schulte
http://cs.unm.edu/~eschulte


Re: [O] Agenda printing: org-agenda-write doesn't use ps-paper-type

2013-06-12 Thread Myles English

Eric S Fraga writes:

>>> Myles English  writes:
>>>
 Trying to print an agenda to pdf always results in the paper size being
 US letter even though ps-paper-type is set to a4.
>
> Have you checked to see if the postscript version uses the right paper
> size?  Just in case the ps -> pdf conversion is at fault?  The pdf is
> created from the ps file.  In any case, both ps and pdf work just fine
> for me to A4 with ps-paper-type set to 'a4.

Thanks for checking it.  Yes, I had to change this line in
org-agenda.el:

- (call-process "ps2pdf" nil nil nil
+ (call-process "ps2pdf" nil nil nil "-sPAPERSIZE=a4"

I wonder if we need to allow a set of options to be passed to ps2pdf as
we do for ps?

Myles



Re: [O] List of Figures not being generated in 8.0.3?

2013-06-12 Thread Luke Crook
On Tue, Jun 11, 2013 at 4:58 PM, Rasmus  wrote:

>
>
> Hi Luke!
>
> It seems you're using v8.0.3. . .
>


Thank you for the feedback.  I should have scrubbed my tags pre-8.0 tags to
conform to the post-8.0 world, sorry about that.

The following tags now work as expected.  The "List of Figures" links to
the figure.  I had to add a #+LABEL tag for the \ref{fig-1} to generate the
correct link.

#+NAME: fig-1
#+begin_src plantuml :file fig_1.png :cmdline -Tpng
(*) --> "Test"
#+end_src

#+ATTR_LaTeX: width: 2cm
#+CAPTION: Caption for Figure 1
#+LABEL: fig:fig-1
#+RESULTS: fig-1
[[file:fig_1.png]]


So, everything working again.
Thank you.


Re: [O] List of Figures not being generated in 8.0.3?

2013-06-12 Thread Luke Crook
On Tue, Jun 11, 2013 at 4:58 PM, Rasmus  wrote:
>
>
> It seems you're using v8.0.3. . .
>
> Your example would be something like
>
> #+OPTIONS: toc:nil
> #+TOC: figures ## <-- not implemented currently
> #+LATEX: \listoffigures
>
> The following generates the "List of Figures"

#+TOC: listings

No need for the specific latex tags below it seems, as #+TOC seems to
output correctly in latex now.

#+LATEX: \listoftables
#+LATEX: \listoffigures


Re: [O] Starting emacs followed directly by org-agenda search and visiting file removes color formatting

2013-06-12 Thread Samuel Wales
I don't know if this is related, but I had issues with org-mouse not
working on Org files that I load with find-file-noselect in .emacs.

-- 
The Kafka Pandemic: http://thekafkapandemic.blogspot.com

The disease DOES progress.  MANY people have died from it.  ANYBODY can get it.



[O] org-id should require newcomment?

2013-06-12 Thread Samuel Wales
If newcomment is loaded, this bug does not occur:

Pasting link results in "org-run-like-in-org-mode: Symbol's value as
variable is void: comment-region-function".

Thanks.

Samuel

-- 
The Kafka Pandemic: http://thekafkapandemic.blogspot.com

The disease DOES progress.  MANY people have died from it.  ANYBODY can get it.



Re: [O] Org-mode and Taskjuggler

2013-06-12 Thread Louis Turk
Hi Christian and others that are helping me,

Many thanks!  I've run into more problems, but I'm encouraged that with
your help I'll soon have Taskjuggler enabled.

On 06/11/2013 04:46 PM, Christian Egli wrote:
> Hi Louis
>
> Louis Turk  writes:
>
>> I'm very interested in your work to get Org-mode to export to
>> Taskjuggler version 3 --- very exciting! Being able to export to tj3
>> from org-mode would be extremely helpful to me. 
> Cool.
>
>> However, I'm having trouble getting it to work. I suspect that the
>> documentation I've been reading is too old --- for version 2 of
>> Taskjuggler---, and I have version 3 installed.
> Yes, the documentation should be updated. John Hendy promised to do so a
> while ago :-) (hint, hint).
>
> What are the problems you are encountering? It should work out of the
> box. Once you have an org file as explained on the worg page you just
> invoke the exporter with C-c C-e J o for example and you should see the
> schedule in a browser.
>
>> Would you please send me:
>>
>> 1 The related code in your .emacs file. 
> There is nothing special in my .emacs file. You need to include contrib
> to your load path (add-to-list 'load-path "~/src/org-mode/contrib/lisp")
I did this.
> and you need to enable the taskjuggler exporter (M-x customize
> org-export-backends).

"M-x customize org-export-backends" did not work for me. If I type "M-x 
customize-group" then type "org" I get into org related stuff, but nothing 
about export-backends. And in trying to figure this out I somehow disabled C-c 
C-e, so now I can't export to anything. I'm hoping I haven't disable a whole 
lot of other commands also. How can I fix this?

I'm using Emacs 23.3 which is the latest version packaged by Mint Linux. Do I 
need to upgrade to version 24.1?

>
>> 2 A sample full-featured org-mode file that compiles successfully to
>>   tj3. 
> The one on from the taskjuggler tutorial on the worg page should work.
I am (and will be) using that file until I get everything working.
>
>> 3 Any up-to-date documentation that is available.
> The best ATM is the tutorial on worg and the comments in the code.
>
>> 4 Anything other information needed to get it to work.
> If there is any other info needed then I'd say it is the official
> TaskJuggler documentation.
>
>> Thank you in advance for your help. And thanks for all your work
>> already done on this project.
> My pleasure.
>
> HTH
> Christian
Thanks again.

Louis




Re: [O] Bug: Babel Haskell mode [8.0.3 (8.0.3-30-g56b864-elpa @ /Users/ix/.emacs.d/elpa/org-20130610/)]

2013-06-12 Thread Eric Schulte
Simon Beaumont  writes:

> Well that's really odd: I modded the paths in init.el and did the following:
>
> emacs -Q -l init.el foo.org
>
> When I eval'ed the code block in foo.org (twice) I still get message:
> "Code block returned no value" I've attached the inferior haskell
> buffer and all relevant files.
>
> (add-to-list 'load-path "~/.emacs.d/elpa/haskell-mode-20130610.152")

I thought maybe it could be a difference between our haskell modes, so I
switched to the latest available through my elpa (haskell-mode-13.6),
and I still see the correct behavior.

> GHClet fac n = product [1..n]
> [(x,fac x) | x <- [0..11]]
> "org-babel-haskell-eoe"
> i, version 7.6.3: http://www.haskell.org/ghc/  :? for help
> Loading package ghc-prim ... linking ... done.
> Loading package integer-gmp ... linking ... done.
> Loading package base ... linking ... done.
>> [(0,1),(1,1),(2,2),(3,6),(4,24),(5,120),(6,720),(7,5040),(8,40320),(9,362880),(10,3628800),(11,39916800)]
>> "org-babel-haskell-eoe"
>> let fac n = product [1..n]
> [(x,fac x) | x <- [0..11]]
> "org-babel-haskell-eoe"
>> [(0,1),(1,1),(2,2),(3,6),(4,24),(5,120),(6,720),(7,5040),(8,40320),(9,362880),(10,3628800),(11,39916800)]
>> "org-babel-haskell-eoe"
>

My *haskell* buffer looks different then yours.  Namely I have
"Prelude>" where as you just have ">".  I don't know if this is
significant.  Maybe you've customized your ghci prompts in such a way
that the comint functions can no longer recognize where output begins?

,
| GHCi, version 7.6.3: http://www.haskell.org/ghc/  :? for help
| Loading package ghc-prim ... let fac n = product [1..n]
| [(x,fac x) | x <- [0..11]]
| "org-babel-haskell-eoe"
| linking ... done.
| Loading package integer-gmp ... linking ... done.
| Loading package base ... linking ... done.
| Prelude> Prelude> 
[(0,1),(1,1),(2,2),(3,6),(4,24),(5,120),(6,720),(7,5040),(8,40320),(9,362880),(10,3628800),(11,39916800)]
| Prelude> "org-babel-haskell-eoe"
| Prelude> let fac n = product [1..n]
| [(x,fac x) | x <- [0..11]]
| "org-babel-haskell-eoe"
| Prelude> 
[(0,1),(1,1),(2,2),(3,6),(4,24),(5,120),(6,720),(7,5040),(8,40320),(9,362880),(10,3628800),(11,39916800)]
| Prelude> "org-babel-haskell-eoe"
| Prelude> 
`

I'm not sure what else this could be.  One option would be to instrument
`org-babel-execute:haskell' or `org-babel-comint-with-output' with
edebug, and then step through evaluation to see if you can pinpoint
where the problem lies.

Hope this helps,

-- 
Eric Schulte
http://cs.unm.edu/~eschulte



Re: [O] Org-mode and Taskjuggler

2013-06-12 Thread Nick Dokos
Louis Turk  writes:


> "M-x customize org-export-backends" did not work for me. If I type
> "M-x customize-group" then type "org" I get into org related stuff,
> but nothing about export-backends. And in trying to figure this out I
> somehow disabled C-c C-e, so now I can't export to anything. I'm
> hoping I haven't disable a whole lot of other commands also. How can I
> fix this?
>

Restarting emacs will probably restore C-c C-e.

What version of org-mode are you using? Do C-u M-x org-version RET to
find out. org-export-backends is new with 8.x, so if you are not running
v8.x, org-export-backends is not going to be present.

If you *are* running v8.x, do C-h v org-export-backends RET
and then click the customize link towards the bottom of the help text.
That will take you directly to the place where you can customize
the variable.

> I'm using Emacs 23.3 which is the latest version packaged by Mint
> Linux. Do I need to upgrade to version 24.1?
>

As mentioned above, the more interesting question is what version of
org you are running.

-- 
Nick




Re: [O] org-babel, gnuplot and buffer-wide header arguments

2013-06-12 Thread Eric Schulte
Carlos Russo  writes:

> Hi
>
> it seems that org-babel-gnuplot only recognizes a few header arguments.
> I would like to set the following on top of the buffer:
>
> #+PROPERTY: term pdfcairo enhanced mono size 8cm,6cm font "Helvetica"
>
> in order to control the appearance of a bunch of figures generated by gnuplot
> #+begin_src gnuplot :exports result :file file.pdf
>  plot ...
> #+end_src
>
> Basically, I would like to avoid writing the :term property all the time:
>
> #+begin_src gnuplot :exports result :file file.pdf :term pdfcairo 
> enhanced mono size 8cm,6cm font "Helvetica"
>  plot ...
> #+end_src
>
> It seems that this requires a modification to ob-gnuplot.el.
> Any hints on how to do this?
>

I've just pushed up a fix.  Take a look at commit 1720613 in the
repository to see what was required to make this change.  In this case
it was very simple.

Best,

>
> Thanks,
> Carlos
>
>
>

-- 
Eric Schulte
http://cs.unm.edu/~eschulte



[O] [PATCH] Override the default class name with a new one.

2013-06-12 Thread Feng Shu

#+LATEX_CLASS: article

%%output:

\documentclass[11pt]{article}

...

--

#+LATEX_CLASS: article
#+LATEX_CLASS_NAME: ctexart

%%output:

\documentclass[11pt]{ctexart}



-- 
>From 338ce85c306ae400ba8c62bfaecaf8973346faa0 Mon Sep 17 00:00:00 2001
From: Feng Shu 
Date: Thu, 13 Jun 2013 13:36:50 +0800
Subject: [PATCH] Override the default latex class name with a new one

* lisp/ox-latex.el (latex): Add :latex-class-name to :options-alist.
(org-latex-default-latex-class-name): The default name of LaTeX class file.
(org-latex-template): Replace default latex class name with :latex-class-name.

Override  the default latex class name in template. It will be very
useful if you are using a class and it's setting is very similar to
one which has been defined in the `org-latex-classes, for example:

If you want to use latex class: "ctexart"  and you find that it's
setting will be very similar to "article", you don't need to add a
new list to `org-latex-classes, just type:

#+LATEX_CLASS: article
#+LATEX_CLASS_NAME: ctexart
---
 lisp/ox-latex.el |   16 ++--
 1 个文件被修改,插入 14 行(+),删除 2 行(-)

diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el
index 9172cd7..ecfb0ce 100644
--- a/lisp/ox-latex.el
+++ b/lisp/ox-latex.el
@@ -98,6 +98,7 @@
 	  (if a (org-latex-export-to-pdf t s v b)
 		(org-open-file (org-latex-export-to-pdf nil s v b)))
   :options-alist '((:latex-class "LATEX_CLASS" nil org-latex-default-class t)
+		   (:latex-class-name "LATEX_CLASS_NAME" nil org-latex-default-latex-class-name t)
 		   (:latex-class-options "LATEX_CLASS_OPTIONS" nil nil t)
 		   (:latex-header "LATEX_HEADER" nil nil newline)
 		   (:latex-header-extra "LATEX_HEADER_EXTRA" nil nil newline)
@@ -182,6 +183,11 @@
   :group 'org-export-latex
   :type '(string :tag "LaTeX class"))
 
+(defcustom org-latex-default-latex-class-name ""
+  "The default name  of LaTeX class file."
+  :group 'org-export-latex
+  :type '(string :tag "LaTeX class"))
+
 (defcustom org-latex-classes
   '(("article"
  "\\documentclass[11pt]{article}"
@@ -1061,15 +1067,21 @@ holding export options."
 	  (format-time-string "%% Created %Y-%m-%d %a %H:%M\n"))
  ;; Document class and packages.
  (let ((class (plist-get info :latex-class))
+	   (latex-class-name (plist-get info :latex-class-name))
 	   (class-options (plist-get info :latex-class-options)))
(org-element-normalize-string
 	(let* ((header (nth 1 (assoc class org-latex-classes)))
-	   (document-class-string
+	   (document-class-string-tmp
 		(and (stringp header)
 		 (if (not class-options) header
 		   (replace-regexp-in-string
 			"^[ \t]*documentclass\\(\\(\\[[^]]*\\]\\)?\\)"
-			class-options header t nil 1)
+			class-options header t nil 1
+	   (document-class-string
+		 (if (not latex-class-name) document-class-string-tmp
+		   (replace-regexp-in-string
+			"^[ \t]*documentclass\\[[^]]*\\]?{\\(.*\\)}"
+			latex-class-name document-class-string-tmp t nil 1
 	  (if (not document-class-string)
 	  (user-error "Unknown LaTeX class `%s'" class)
 	(org-latex-guess-babel-language
-- 
1.7.10.4



[O] Bug: Exporter omits inline code blocks [8.0.3 (release_8.0.3-238-g172061 @ /home/horn/Repos/el/org-mode/lisp/)]

2013-06-12 Thread Tassilo Horn

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.


Hi all,

lately, I've used ox-reveal.el to create a presentation.  Thereby, I
found out that inline source code blocks are ignored, i.e., the text is
simply not there in the HTML5 output.

Here's a test heading:

--8<---cut here---start->8---
* Test Heading

  - Here's some inline code: src_clojure{(+ 1 2 3)}
  - Here's some more inline code: src_clojure{(- 1 2 3)}
--8<---cut here---end--->8---


ox-reveal.el derives the export from ox-html.  That defines

(inline-src-block . org-html-inline-src-block)

with

--8<---cut here---start->8---
(defun org-html-inline-src-block (inline-src-block contents info)
  "Transcode an INLINE-SRC-BLOCK element from Org to HTML.
CONTENTS holds the contents of the item.  INFO is a plist holding
contextual information."
  (let* ((org-lang (org-element-property :language inline-src-block))
 (code (org-element-property :value inline-src-block)))
(error "Cannot export inline src block")))
--8<---cut here---end--->8---

and ox-reveal doesn't (yet) override that.  So in theory, exporting the
entry above should signal an error, but it doesn't

I also tried the plain html export.  Still, there's no error.  The
function is simply not called at all.

So there seems to be a bug in the exporter which doesn't seem to
recognize inline source code.

That said, I've never used inline source blocks before, so maybe I'm
doing something wrong.  On the one hand, the manual is pretty clear on
their syntax.  But on the other hand, they aren't highlighted in the org
buffer...

Bye,
Tassilo

Emacs  : GNU Emacs 24.3.50.1 (x86_64-pc-linux-gnu, GTK+ Version 3.8.2)
 of 2013-06-12 on thinkpad
Package: Org-mode version 8.0.3 (release_8.0.3-238-g172061 @ 
/home/horn/Repos/el/org-mode/lisp/)

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)
 outline-minor-mode-hook '(th-outline-minor-mode-init)
 org-speed-command-hook '(org-speed-command-default-hook 
org-babel-speed-command-hook)
 org-gnus-prefer-web-links t
 org-special-ctrl-k t
 org-occur-hook '(org-first-headline-recenter)
 org-src-tab-acts-natively t
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-log-done 'time
 org-confirm-shell-link-function 'yes-or-no-p
 org-complete-tags-always-offer-all-agenda-tags t
 org-id-link-to-org-use-id t
 org-columns-default-format "%50ITEM %TODO %ALLTAGS %SCHEDULED %DEADLINE"
 org-export-date-timestamp-format "%Y-%m-%d"
 org-agenda-restore-windows-after-quit t
 org-special-ctrl-a/e 'reversed
 org-agenda-custom-commands '(("n" "Next 21 days" agenda "" ((org-agenda-span 
21)))
  ("^" "Calfw Month Calendar" 
th-calfw-open-calendar))
 org-return-follows-link t
 org-latex-format-headline-function 'org-latex-format-headline-default-function
 org-agenda-time-leading-zero t
 org-capture-templates '(("n" "NORMAL" entry (file 
"/home/horn/Repos/org/remember.org")
  "* %?\n  :PROPERTIES:\n  :created: %U\n  :link: %a\n  
:END:\n %i")
 ("t" "TODO" entry (file 
"/home/horn/Repos/org/remember.org")
  "* TODO %?\n  :PROPERTIES:\n  :created: %U\n  :link: 
%a\n  :END:\n  %i")
 ("i" "IDEA" entry (file 
"/home/horn/Repos/org/remember.org")
  "* IDEA %?\n  :PROPERTIES:\n  :created: %U\n  :link: 
%a\n  :END:\n  %i")
 )
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-icalendar-include-body 100
 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-export-copy-to-kill-ring t
 org-mode-hook '(th-org-mode-init
 #[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)
 org-refile-targets '((org-agenda-files :maxlevel . 5))
 org-attach-method 'mv
 org-export-with-tags 'not-in-toc
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point 
org-babel-execute-safely-maybe)
 org-refile-use-outline-path