all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Insert LOGBOOK drawer removes indendation of first line under headline
@ 2009-03-20 21:17 David Maus
  2009-03-20 21:42 ` Peter Jones
  2009-03-20 22:25 ` [PATCH] " Peter Jones
  0 siblings, 2 replies; 5+ messages in thread
From: David Maus @ 2009-03-20 21:17 UTC (permalink / raw)
  To: emacs-orgmode


[-- Attachment #1.1: Type: text/plain, Size: 667 bytes --]

Hi,

When I start to clock a headline (C-c C-x C-i) that does not have a
LOGBOOK drawer orgmode inserts one but removes the indentation of the
first line below the headline:

Example:

* TODO Do something
  Do this, do that etc.

after C-c C-x C-i becomes

* TODO Do something
  :LOGBOOK:
  CLOCK: [2009-03-20 Fr 19:03]--[2009-03-20 Fr 19:03] =>  0:00
  :END:
Do this, do that etc.


Org-mode version 6.24trans
GNU Emacs 23.0.91.1 (i486-pc-linux-gnu) of 2009-03-08 on elegiac, modified by Debian

Regards,

  -- David

-- 
Email..... maus.david@gmail.com
Jabber.... dmjena@jabber.org
ICQ....... 241051416
OpenPGP... 0x316F4BE4670716FD

[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

[-- Attachment #2: Type: text/plain, Size: 204 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Insert LOGBOOK drawer removes indendation of first line under headline
  2009-03-20 21:17 Insert LOGBOOK drawer removes indendation of first line under headline David Maus
@ 2009-03-20 21:42 ` Peter Jones
  2009-03-20 22:25 ` [PATCH] " Peter Jones
  1 sibling, 0 replies; 5+ messages in thread
From: Peter Jones @ 2009-03-20 21:42 UTC (permalink / raw)
  To: emacs-orgmode

David Maus <maus.david@gmail.com> writes:
> When I start to clock a headline (C-c C-x C-i) that does not have a
> LOGBOOK drawer orgmode inserts one but removes the indentation of the
> first line below the headline:
>
> Example:
>
> * TODO Do something
>   Do this, do that etc.
>
> after C-c C-x C-i becomes
>
> * TODO Do something
>   :LOGBOOK:
>   CLOCK: [2009-03-20 Fr 19:03]--[2009-03-20 Fr 19:03] =>  0:00
>   :END:
> Do this, do that etc.


This might be due to my recent indentation patch.  It's not working the
way I expected it would.  I'll look into it.

-- 
Peter Jones, http://pmade.com
pmade inc.  Louisville, CO US

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH] Re: Insert LOGBOOK drawer removes indendation of first line under headline
  2009-03-20 21:17 Insert LOGBOOK drawer removes indendation of first line under headline David Maus
  2009-03-20 21:42 ` Peter Jones
@ 2009-03-20 22:25 ` Peter Jones
  2009-03-21  6:54   ` David Maus
  2009-03-21 17:21   ` Carsten Dominik
  1 sibling, 2 replies; 5+ messages in thread
From: Peter Jones @ 2009-03-20 22:25 UTC (permalink / raw)
  To: emacs-orgmode

David Maus <maus.david@gmail.com> writes:
> When I start to clock a headline (C-c C-x C-i) that does not have a
> LOGBOOK drawer orgmode inserts one but removes the indentation of the
> first line below the headline:

This patch fixes your problem.  Sorry about that.

diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index c79a6af..8d2279a 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -444,13 +444,13 @@ the clocking selection, associated with the letter `d'."
 		(stringp org-clock-into-drawer)
 		(and (integerp org-clock-into-drawer)
 		     (< org-clock-into-drawer 2)))
-	(org-indent-line-function)
 	(insert ":" drawer ":\n:END:\n")
-	(beginning-of-line 0)
-	(org-indent-line-function)
-	(beginning-of-line 0)
+        (beginning-of-line -1)
+        (org-indent-line-function)
 	(org-flag-drawer t)
-	(beginning-of-line 2)
+        (beginning-of-line 2)
+        (org-indent-line-function)
+	(beginning-of-line)
 	(or org-log-states-order-reversed
 	    (and (re-search-forward org-property-end-re nil t)
 		 (goto-char (match-beginning 0))))))))

-- 
Peter Jones, http://pmade.com
pmade inc.  Louisville, CO US

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] Re: Insert LOGBOOK drawer removes indendation of first line under headline
  2009-03-20 22:25 ` [PATCH] " Peter Jones
@ 2009-03-21  6:54   ` David Maus
  2009-03-21 17:21   ` Carsten Dominik
  1 sibling, 0 replies; 5+ messages in thread
From: David Maus @ 2009-03-21  6:54 UTC (permalink / raw)
  To: emacs-orgmode


[-- Attachment #1.1: Type: text/plain, Size: 512 bytes --]


On 20 Mar 09, Peter Jones wrote:
> David Maus <maus.david@gmail.com> writes:
> > When I start to clock a headline (C-c C-x C-i) that does not have a
> > LOGBOOK drawer orgmode inserts one but removes the indentation of the
> > first line below the headline:
> 
> This patch fixes your problem.  Sorry about that.

Indeed, patch applied, problem fixed.

Regards,

  -- David

-- 
Email..... maus.david@gmail.com
Jabber.... dmjena@jabber.org
ICQ....... 241051416
OpenPGP... 0x316F4BE4670716FD

[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

[-- Attachment #2: Type: text/plain, Size: 204 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Re: Insert LOGBOOK drawer removes indendation of first line under headline
  2009-03-20 22:25 ` [PATCH] " Peter Jones
  2009-03-21  6:54   ` David Maus
@ 2009-03-21 17:21   ` Carsten Dominik
  1 sibling, 0 replies; 5+ messages in thread
From: Carsten Dominik @ 2009-03-21 17:21 UTC (permalink / raw)
  To: Peter Jones; +Cc: emacs-orgmode


[-- Attachment #1.1: Type: text/plain, Size: 1493 bytes --]

Applied, thanks.

- Carsten

On Mar 20, 2009, at 11:25 PM, Peter Jones wrote:

> David Maus <maus.david@gmail.com> writes:
>> When I start to clock a headline (C-c C-x C-i) that does not have a
>> LOGBOOK drawer orgmode inserts one but removes the indentation of the
>> first line below the headline:
>
> This patch fixes your problem.  Sorry about that.
>
> diff --git a/lisp/org-clock.el b/lisp/org-clock.el
> index c79a6af..8d2279a 100644
> --- a/lisp/org-clock.el
> +++ b/lisp/org-clock.el
> @@ -444,13 +444,13 @@ the clocking selection, associated with the  
> letter `d'."
> 		(stringp org-clock-into-drawer)
> 		(and (integerp org-clock-into-drawer)
> 		     (< org-clock-into-drawer 2)))
> -	(org-indent-line-function)
> 	(insert ":" drawer ":\n:END:\n")
> -	(beginning-of-line 0)
> -	(org-indent-line-function)
> -	(beginning-of-line 0)
> +        (beginning-of-line -1)
> +        (org-indent-line-function)
> 	(org-flag-drawer t)
> -	(beginning-of-line 2)
> +        (beginning-of-line 2)
> +        (org-indent-line-function)
> +	(beginning-of-line)
> 	(or org-log-states-order-reversed
> 	    (and (re-search-forward org-property-end-re nil t)
> 		 (goto-char (match-beginning 0))))))))
>
> -- 
> Peter Jones, http://pmade.com
> pmade inc.  Louisville, CO US
>
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Remember: use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[-- Attachment #1.2: Type: text/html, Size: 3278 bytes --]

[-- Attachment #2: Type: text/plain, Size: 204 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-03-21 19:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-20 21:17 Insert LOGBOOK drawer removes indendation of first line under headline David Maus
2009-03-20 21:42 ` Peter Jones
2009-03-20 22:25 ` [PATCH] " Peter Jones
2009-03-21  6:54   ` David Maus
2009-03-21 17:21   ` Carsten Dominik

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.