* org-clock-goto plus org-narrow-to-subtree?
@ 2010-04-12 13:05 Karsten Heymann
2010-04-12 13:33 ` Carsten Dominik
0 siblings, 1 reply; 5+ messages in thread
From: Karsten Heymann @ 2010-04-12 13:05 UTC (permalink / raw)
To: Org Mode
Hi,
does anyone have a solution to combine org-clock-goto with
org-narrow-to-subtree, so that upon keypress I get a buffer with only
the currently clocked task in it? Maybe this could even become a
optional parameter for org-clock-goto?
Yours
Karsten
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: org-clock-goto plus org-narrow-to-subtree?
2010-04-12 13:05 org-clock-goto plus org-narrow-to-subtree? Karsten Heymann
@ 2010-04-12 13:33 ` Carsten Dominik
2010-04-12 13:47 ` Karsten Heymann
0 siblings, 1 reply; 5+ messages in thread
From: Carsten Dominik @ 2010-04-12 13:33 UTC (permalink / raw)
To: Karsten Heymann; +Cc: Org Mode
On Apr 12, 2010, at 3:05 PM, Karsten Heymann wrote:
> Hi,
>
> does anyone have a solution to combine org-clock-goto with
> org-narrow-to-subtree, so that upon keypress I get a buffer with only
> the currently clocked task in it? Maybe this could even become a
> optional parameter for org-clock-goto?
(defun my-clock-goto-narrow ()
(interactive)
(when (org-clock-is-active)
(org-clock-goto)
(org-narrow-to-subtree)))
(define-key global-map "\C-cc" my-clock-goto-narrow)
HTH
- Carsten
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: org-clock-goto plus org-narrow-to-subtree?
2010-04-12 13:33 ` Carsten Dominik
@ 2010-04-12 13:47 ` Karsten Heymann
2010-04-12 14:25 ` Richard Riley
0 siblings, 1 reply; 5+ messages in thread
From: Karsten Heymann @ 2010-04-12 13:47 UTC (permalink / raw)
To: Carsten Dominik; +Cc: Karsten Heymann, Org Mode
Hi Carsten,
Carsten Dominik <carsten.dominik@gmail.com> writes:
> On Apr 12, 2010, at 3:05 PM, Karsten Heymann wrote:
>> does anyone have a solution to combine org-clock-goto with
>> org-narrow-to-subtree, so that upon keypress I get a buffer with only
>> the currently clocked task in it? Maybe this could even become a
>> optional parameter for org-clock-goto?
>
> (defun my-clock-goto-narrow ()
> (interactive)
> (when (org-clock-is-active)
> (org-clock-goto)
> (org-narrow-to-subtree)))
>
> (define-key global-map "\C-cc" my-clock-goto-narrow)
Thanks, applied. :-)
Yours
Karsten
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: org-clock-goto plus org-narrow-to-subtree?
2010-04-12 13:47 ` Karsten Heymann
@ 2010-04-12 14:25 ` Richard Riley
2010-04-12 19:54 ` Bernt Hansen
0 siblings, 1 reply; 5+ messages in thread
From: Richard Riley @ 2010-04-12 14:25 UTC (permalink / raw)
To: emacs-orgmode
Karsten Heymann <karsten.heymann@blue-cable.net> writes:
> Hi Carsten,
>
> Carsten Dominik <carsten.dominik@gmail.com> writes:
>> On Apr 12, 2010, at 3:05 PM, Karsten Heymann wrote:
>>> does anyone have a solution to combine org-clock-goto with
>>> org-narrow-to-subtree, so that upon keypress I get a buffer with only
>>> the currently clocked task in it? Maybe this could even become a
>>> optional parameter for org-clock-goto?
>>
>> (defun my-clock-goto-narrow ()
>> (interactive)
>> (when (org-clock-is-active)
>> (org-clock-goto)
>> (org-narrow-to-subtree)))
>>
>> (define-key global-map "\C-cc" my-clock-goto-narrow)
>
> Thanks, applied. :-)
here is a slight variation I use which lists older clocked tasks if
there is not one already clocked in. It also restores the window layout.
,----
| (defun rgr/org-add-note-to-current-task ()
| (interactive)
| (save-window-excursion
| (if(org-clock-is-active)
| (org-clock-goto)
| (org-clock-goto t))
| (org-narrow-to-subtree)
| (org-add-note)))
|
| (define-key global-map "\C-cn" 'rgr/org-add-note-to-current-task)
`----
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: org-clock-goto plus org-narrow-to-subtree?
2010-04-12 14:25 ` Richard Riley
@ 2010-04-12 19:54 ` Bernt Hansen
0 siblings, 0 replies; 5+ messages in thread
From: Bernt Hansen @ 2010-04-12 19:54 UTC (permalink / raw)
To: Richard Riley; +Cc: emacs-orgmode
Richard Riley <rileyrgdev@gmail.com> writes:
> Karsten Heymann <karsten.heymann@blue-cable.net> writes:
>
>> Hi Carsten,
>>
>> Carsten Dominik <carsten.dominik@gmail.com> writes:
>>> On Apr 12, 2010, at 3:05 PM, Karsten Heymann wrote:
>>>> does anyone have a solution to combine org-clock-goto with
>>>> org-narrow-to-subtree, so that upon keypress I get a buffer with only
>>>> the currently clocked task in it? Maybe this could even become a
>>>> optional parameter for org-clock-goto?
>>>
>>> (defun my-clock-goto-narrow ()
>>> (interactive)
>>> (when (org-clock-is-active)
>>> (org-clock-goto)
>>> (org-narrow-to-subtree)))
>>>
>>> (define-key global-map "\C-cc" my-clock-goto-narrow)
>>
>> Thanks, applied. :-)
>
> here is a slight variation I use which lists older clocked tasks if
> there is not one already clocked in. It also restores the window layout.
>
> ,----
> | (defun rgr/org-add-note-to-current-task ()
> | (interactive)
> | (save-window-excursion
> | (if(org-clock-is-active)
> | (org-clock-goto)
> | (org-clock-goto t))
> | (org-narrow-to-subtree)
> | (org-add-note)))
> |
> | (define-key global-map "\C-cn" 'rgr/org-add-note-to-current-task)
> `----
>
And another variation...
F11 - calls org-clock-goto (from any buffer, any mode), and goes to the
last clocked task if the clock is not active.
F5 - narrows to subtree and calls org-show-todo-tree to show what there
is to do on that subtree.
I don't combine them into a single key - since I'm used to using F5 and
S-F5 to narrow and widen respectively.
,----
| (global-set-key (kbd "<f5>") 'bh/org-todo)
| (global-set-key (kbd "<S-f5>") 'bh/widen)
| (global-set-key (kbd "<f11>") 'org-clock-goto)
|
| (defun bh/org-todo ()
| (interactive)
| (org-narrow-to-subtree)
| (org-show-todo-tree nil))
|
| (defun bh/widen ()
| (interactive)
| (widen)
| (org-reveal))
|
`----
-Bernt
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-04-12 19:55 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-12 13:05 org-clock-goto plus org-narrow-to-subtree? Karsten Heymann
2010-04-12 13:33 ` Carsten Dominik
2010-04-12 13:47 ` Karsten Heymann
2010-04-12 14:25 ` Richard Riley
2010-04-12 19:54 ` Bernt Hansen
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.