emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Bug: org-agenda-overriding-columns-format destroyed on revert [9


From: Allen Li
Subject: Re: [O] Bug: org-agenda-overriding-columns-format destroyed on revert [9.2.1 (9.2.1-2-gc6d37c-elpaplus)]
Date: Mon, 25 Feb 2019 08:01:39 +0000

Thank you for the comments, attached new patch.

On Mon, Feb 18, 2019 at 9:16 PM Nicolas Goaziou <address@hidden> wrote:
>
> >  (defun org-agenda-finalize ()
> >    "Finishing touch for the agenda buffer, called just before displaying 
> > it."
> >    (unless org-agenda-multi
> > @@ -3783,7 +3784,7 @@ FILTER-ALIST is an alist of filters we need to apply 
> > when
> >       (unless org-agenda-with-colors
> >         (remove-text-properties (point-min) (point-max) '(face nil)))
> >       (when (bound-and-true-p org-agenda-overriding-columns-format)
> > -       (setq-local org-agenda-overriding-columns-format
> > +       (setq-local org-agenda-local-overriding-columns-format
>
> Since this is a local variable, `setq' is enough, isn't it?

I don't know if the defvar-local in org-colview will be loaded before
this point,
so I think it's safer to just use setq-local.

> >  (defvar org-agenda-overriding-columns-format nil
> >    "When set, overrides any other format definition for the agenda.
> > -Don't set this, this is meant for dynamic scoping.")
> > +Don't set this, this is meant for dynamic scoping.  Set
> > +`org-agenda-local-overriding-columns-format' instead.")
>
> The first line of a docstring cannot contain an incomplete sentence (due
> to `apropos` design).

I think you misread?  I didn't touch the first line.

>
> > +(defvar-local org-agenda-local-overriding-columns-format nil
> > +  "When set, overrides any other format definition for the agenda.
> > +This can be set as a buffer local value to avoid interfering with
> > +dynamic scoping for `org-agenda-overriding-columns-format'.")
>
> The two variable names are somewhat confusing. Could
> `org-agenda-local-overriding-columns-format' be renamed into
> `org-local-columns-format'? Since it is defined in "org-colview.el", it
> doesn't deserve the "org-agenda" prefix (and neither does the original
> `org-agenda-overriding-columns-format'.).
>
> Regards,
>
> --
> Nicolas Goaziou

Attachment: 0001-Fix-buffer-local-org-agenda-overriding-columns-forma.patch
Description: Text Data


reply via email to

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