[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Formatting Agenda entries
From: |
Nick Dokos |
Subject: |
Re: [O] Formatting Agenda entries |
Date: |
Mon, 30 Jul 2012 14:34:21 -0400 |
Rasmus <address@hidden> wrote:
> Hi,
>
> I use org-google-weather.el to display the weather condition of a couple
> of cities in my Agenda. I would like to format the strings so that
> certain elements are aligned.
>
> Sometimes it looks like this:
>
> W: I Clear, 19-35 ᵒC (Florence)
> W: I Partly Sunny, 19-26 ᵒC (Berlin)
>
> (I is the icon). I want it to look like:
>
> W: I Clear, 19-35 ᵒC (Florence)
> W: I Partly Sunny, 19-26 ᵒC (Berlin)
>
> The string I use is:
>
> (setq org-google-weather-format
> "%i %c, %l-%h %s (%L)")
>
> I tried something like
>
> (format "%s %-7s %s %s %s" "%i" "%c," "%l-%h" "%s" "(%L)")
>
> but this obviously doesn't work as the strings are only expanded in the
> Agenda buffer. Thus, I need to format my string after placeholders have
> been expanded but before it's actually displayed in the Agenda buffer.
>
> Is that somehow possible?
>
Have you tried something like
(setq org-google-weather-format "%i %-30c, %l-%h %s (%L)")
perhaps? Seems to work for me.
Nick