Re: [O] Bind an agenda filter to a global shortcut

2011-10-26 Thread Darlan Cavalcante Moreira

You can do this (and more) with the custom agenda views [1].

[1] http://orgmode.org/manual/Custom-agenda-views.html#Custom-agenda-views

--
Darlan

At Wed, 26 Oct 2011 12:13:52 -0500,
Marcelo de Moraes Serpa celose...@gmail.com wrote:
 
 [1  text/plain; ISO-8859-1 (7bit)]
 Hi list,
 
 So, I'd like to bind a specific agenda filter to a simple one-key shortcut,
 maybe one of the function keys. This might be an easy think to do, but I'm
 not sure how. How could I trigger an agenda filter action directly through
 elisp (without needing to go to the agenda view and use the shortcut I
 made?) so that I can bind it straight to a global shortcut?
 
 Thanks,
 
 Marcelo.
 [2  text/html; ISO-8859-1 (quoted-printable)]
 



Re: [O] Bind an agenda filter to a global shortcut

2011-10-26 Thread Marcelo de Moraes Serpa
Obrigado Darlan :) I'll check it out.

On Wed, Oct 26, 2011 at 3:34 PM, Darlan Cavalcante Moreira 
darc...@gmail.com wrote:


 You can do this (and more) with the custom agenda views [1].

 [1] http://orgmode.org/manual/Custom-agenda-views.html#Custom-agenda-views

 --
 Darlan

 At Wed, 26 Oct 2011 12:13:52 -0500,
 Marcelo de Moraes Serpa celose...@gmail.com wrote:
 
  [1  text/plain; ISO-8859-1 (7bit)]
  Hi list,
 
  So, I'd like to bind a specific agenda filter to a simple one-key
 shortcut,
  maybe one of the function keys. This might be an easy think to do, but
 I'm
  not sure how. How could I trigger an agenda filter action directly
 through
  elisp (without needing to go to the agenda view and use the shortcut I
  made?) so that I can bind it straight to a global shortcut?
 
  Thanks,
 
  Marcelo.
  [2  text/html; ISO-8859-1 (quoted-printable)]
 



Re: [O] Bind an agenda filter to a global shortcut

2011-10-26 Thread Marcelo de Moraes Serpa
Hmm, I actually already do that. The shortcut is not bad, but what I want to
do is to bind it to a single keypress. With the custom agenda view, I still
need to C-c a and then the shortcut, which is not bad, but there are one or
two views that I use too often, and I'm being spoiled by VIM, I would like a
single keypress :)

Anyway, thanks for pointing out the manual page.

Marcelo.

On Wed, Oct 26, 2011 at 4:44 PM, Marcelo de Moraes Serpa 
celose...@gmail.com wrote:

 Obrigado Darlan :) I'll check it out.


 On Wed, Oct 26, 2011 at 3:34 PM, Darlan Cavalcante Moreira 
 darc...@gmail.com wrote:


 You can do this (and more) with the custom agenda views [1].

 [1]
 http://orgmode.org/manual/Custom-agenda-views.html#Custom-agenda-views

 --
 Darlan

 At Wed, 26 Oct 2011 12:13:52 -0500,
 Marcelo de Moraes Serpa celose...@gmail.com wrote:
 
  [1  text/plain; ISO-8859-1 (7bit)]
  Hi list,
 
  So, I'd like to bind a specific agenda filter to a simple one-key
 shortcut,
  maybe one of the function keys. This might be an easy think to do, but
 I'm
  not sure how. How could I trigger an agenda filter action directly
 through
  elisp (without needing to go to the agenda view and use the shortcut I
  made?) so that I can bind it straight to a global shortcut?
 
  Thanks,
 
  Marcelo.
  [2  text/html; ISO-8859-1 (quoted-printable)]
 





Re: [O] Bind an agenda filter to a global shortcut

2011-10-26 Thread Bernt Hansen
Marcelo de Moraes Serpa celose...@gmail.com writes:

 Hmm, I actually already do that. The shortcut is not bad, but what I
 want to do is to bind it to a single keypress. With the custom agenda
 view, I still need to C-c a and then the shortcut, which is not bad,
 but there are one or two views that I use too often, and I'm being
 spoiled by VIM, I would like a single keypress :)

So just bind your favourite key to the view you want.

(global-set-key (kbd f9) (lambda () (interactive) (org-agenda nil X)))

to make f9 do the same as C-c a X

-Bernt