From: "Christopher M. Miles" <numbchild@gmail.com>
To: Samim Pezeshki <p.samim@gmail.com>
Cc: emacs-orgmode@gnu.org, Nicolas Goaziou <mail@nicolasgoaziou.fr>
Subject: [ISSUE] Re: [PATCH] lisp/org-agenda.el: Add header to agenda clock report table
Date: Fri, 28 Jan 2022 17:01:36 +0800 [thread overview]
Message-ID: <PAXPR08MB6640274350AC08560F866661A3229@PAXPR08MB6640.eurprd08.prod.outlook.com> (raw)
In-Reply-To: <CAJAdVc22-_-4QnFk81xns5qxeSZvc9PmvGD-jEbBpb5pVwt4Xw@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 2139 bytes --]
I tested this commit, it should auto append a newline character after
~org-agenda-clock-report-header~. Otherwise the header line will in same line with table first line.
Samim Pezeshki <p.samim@gmail.com> writes:
> Thanks Nicolas for reviewing the changes!
>
> I applied the changes.
> Attached is the updated patch.
>
> On Fri, Jan 21, 2022 at 1:58 PM Nicolas Goaziou <mail@nicolasgoaziou.fr> wrote:
>
> Hello,
>
> Samim Pezeshki <p.samim@gmail.com> writes:
>
> > +(defcustom org-agenda-clock-report-header nil
> > + "Header for org agenda clock report mode"
> > + :group 'org-agenda
> > + :type 'string)
>
> Please add :package-version and :safe keywords to the definition.
>
> Also, type does not match the default value. You probably mean
>
> (choice
> (string :tag "Header")
> (const :tag "No header" nil))
>
> > +
> > (defun org-agenda-time-of-day-to-ampm (time)
> > "Convert TIME of a string like \"13:45\" to an AM/PM style time string."
> > (let* ((hour-number (string-to-number (substring time 0 -3)))
> > @@ -4473,6 +4478,10 @@ items if they have an hour specification like [h]h:mm."
> > (setq p (plist-put p :tend clocktable-end))
> > (setq p (plist-put p :scope 'agenda))
> > (setq tbl (apply #'org-clock-get-clocktable p))
> > + (when org-agenda-clock-report-header
> > + (put-text-property 0 (length org-agenda-clock-report-header) 'face 'org-agenda-structure
> > + org-agenda-clock-report-header)
> > + (insert org-agenda-clock-report-header))
>
> Maybe:
>
> (insert (propertize org-agenda-clock-report-header 'face 'org-agenda-structure))
>
> Could you send an updated patch?
>
> Regards,
> --
> Nicolas Goaziou
>
> [4. text/x-patch; 0001-lisp-org-agenda.el-Add-header-to-agenda-clock-report.patch]...
--
[ stardiviner ]
I try to make every word tell the meaning that I want to express.
Blog: https://stardiviner.github.io/
IRC(freenode): stardiviner, Matrix: stardiviner
GPG: F09F650D7D674819892591401B5DF1C95AE89AC3
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2022-01-28 9:24 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-10 9:26 [PATCH] lisp/org-agenda.el: Add header to agenda clock report table Samim Pezeshki
2022-01-10 10:27 ` Christopher M. Miles
2022-01-21 9:13 ` Samim Pezeshki
2022-01-21 10:28 ` Nicolas Goaziou
2022-01-22 16:24 ` Samim Pezeshki
2022-01-26 20:08 ` Nicolas Goaziou
2022-01-28 9:01 ` Christopher M. Miles [this message]
2022-05-09 12:38 ` [PATCH] Re: [ISSUE] " Ihor Radchenko
2022-07-11 5:03 ` Ihor Radchenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=PAXPR08MB6640274350AC08560F866661A3229@PAXPR08MB6640.eurprd08.prod.outlook.com \
--to=numbchild@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=mail@nicolasgoaziou.fr \
--cc=p.samim@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).