Re: [O] problems with org-tempo

2018-12-14 Thread Uwe Brauer
>>> "Uwe" == Uwe Brauer  writes:

>> You need `(require 'org-tempo)', then

>> #+begin_src emacs-lisp
>> (tempo-define-template "org-display-bib"
>> '("bibliographystyle:plain" n
>> "bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib"  p n)
>> "> #+end_src

> Thanks that works like charm.  However I have some more templates of
> the form so I tried 

> #+begin_src emacs-lisp

> (tempo-define-template "org-display-bib"
>  '("bibliographystyle:plain" n
>
> "bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib"  p n)
>  " (tempo-define-template "org-display-comentario"
>  '("* Comentarios Hoja ?" n
>  "| Documentación codigo | Explicación código | 
> Ficheros matlab | Fichero MLX | Impresión |" p n
>  
> "|--++-+-+---|"
>  p n
>  "|  ||   
>   | |   |" p n)
>  " #+end_src

After restarting emacs, the second template also works, so this is
settled. Sorry for not having tested it before.

An additional question though: it is possible to have the cursor at a
specific position, as in the old org template system (using ?)

Thanks

Uwe Brauer 




Re: [O] problems with org-tempo

2018-12-14 Thread Uwe Brauer



   > You need `(require 'org-tempo)', then

   > #+begin_src emacs-lisp
   > (tempo-define-template "org-display-bib"
   >   '("bibliographystyle:plain" n
   > 
"bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib"  p n)
   >   " #+end_src

Thanks that works like charm.  However I have some more templates of
the form so I tried 


#+begin_src emacs-lisp

(tempo-define-template "org-display-bib"
   '("bibliographystyle:plain" n
 
"bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib"  p n)
   "

smime.p7s
Description: S/MIME cryptographic signature


Re: [O] problems with org-tempo

2018-12-13 Thread Berry, Charles



> On Dec 13, 2018, at 2:36 PM, Uwe Brauer  wrote:
> 
> 
> Hi 
> 
> I hoped that org-tempo would be a substitute for the old beloved org
> template system. well
> 
>1. It expands  
>2. The syntax is not the same for example I want 
> 
> Key: b
>Keyword:   
>bibliographystyle:plain
>bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib
> 
> 
> But 
>  
> Expands to 
> 
> #+bibliographystyle:plain
> bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib: 
> 
> Which is annoying. It should be
> 
> bibliographystyle:plain
> bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib
> 
> Any chance to get that behavior. I don't feel like learning a new tool
> for inserting template, since I am very acquainted with the old one.
> 


You need `(require 'org-tempo)', then

#+begin_src emacs-lisp
(tempo-define-template "org-display-bib"
   '("bibliographystyle:plain" n
 
"bibliography:/home/oub/texmf/bibtex/bib/bibgraf.bib"  p n)
   "

[O] problems with org-tempo

2018-12-13 Thread Uwe Brauer


Hi 

I hoped that org-tempo would be a substitute for the old beloved org
template system. well

1. It expands