emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] avoiding "First item of list cannot move without its subtree"


From: Max Rydahl Andersen
Subject: Re: [O] avoiding "First item of list cannot move without its subtree"
Date: Thu, 23 Feb 2017 08:36:35 +0100

On 22 Feb 2017, at 12:04, Nicolas Goaziou wrote:

> Hello,
>
> "Max Rydahl Andersen" <address@hidden> writes:
>
>> What am I doing wrong ?
>
> Nothing. There is a typo in my code.

Fixed the typo - but still nothing happens :/

/max

>
>> (add-hook 'org-shiftmetaleft-hook
>>        (lambda ()
>>          (interactive)
>>          (let* ((element (org-element-at-point))
>>                 (list-parent (org-element-lineage element '(item plain-list) 
>> t)))
>>            (when (and list-parent
>>                       (= (line-beginning-position)
>>                          (org-element-property :post-affiliated element)))
>
> -> (org-element-property :post-affiliated list-parent)
>
>>              (call-interactively
>>               (if (org-element-lineage list-parent '(item)) ;not at top level
>>                   #'org-outdent-item-tree
>>                 #'org-ctrl-c-star))
>>              t))))
>
> Regards,
>
> -- 
> Nicolas Goaziou                                                0x80A93738


/max
http://about.me/maxandersen



reply via email to

[Prev in Thread] Current Thread [Next in Thread]