khal
                                
                                 khal copied to clipboard
                                
                                    khal copied to clipboard
                            
                            
                            
                        RGB colours only working with `ikhal` but not in non-interactive commands
Hi,
First thanks for making such a great bit of software and second I had a look through open issues and didn't see this one already raised but sorry if I missed it.
I'm using khal version 0.10.3. At the moment if I set the color to an RGB value or use auto to pick the colour used on the server it will work fine in khal interactive

but not so fine with khal calendar (which is the one I use more often)

If I use the word values for color (i.e. light green, dark red, etc) both work fine.
I'm using the following config:
[calendars]
  [[birthdays]]
  path = ~/.local/share/contacts/cards/
  type = birthdays
  color = light magenta
  [[calendars]]
  path = ~/.local/share/calendars/*
  type = discover
And all calendars render with their correct colour with both khal calendar and khal interactive.
Can you post your config (at least the relevant bits)?
(side note: khal interactiverenders the contacts birthdays bold, whereas khal calendar renders them non-bold, so it sees there's some difference in how both interpret the color command).
Hi, thanks for responding and sorry for delayed reply. Interesting note about the bold! As an example with the config entries
[[calendar1]]
path = ~/.config/calendars/ba05fa43-6a68-4cfa-d189-8cf971575e0c/
color="#FF0000"
[[calendar2]]
path = ~/.config/calendars/ef3187cd-cad9-7916-6397-0eb7eee02f1a/
color="#00FF00"
[[calendar3]]
path = ~/.config/calendars/be1c74ae-95de-0cc6-f9e9-b15ba0fe3951/
color="#0000FF"
[[calendar4]]
path = ~/.config/calendars/945dcf76-3b83-3d81-3a3f-ad2049536e10/
color="light green"
I created an event for each one today. In interactive mode I see

but in calendar mode I see

You can see when I use the word as the value it's fine, but the RGB provided values don't seem to work.
In case it matters this is happening in urxvt version 9.22
At least on mac os x, I cannot reproduce this behavior
can you test what the output of the following is in your terminal?
echo "\x1b[38;2;0;0;255m14:30-15:30 text\x1b[0m\x1b[0m
\x1b[38;2;255;0;0m23:00-24:00 test\x1b[0m\x1b[0m
\x1b[38;2;0;255;0m23:00-24:00 test\x1b[0m\x1b[0m"
I get the following on iterm on mac os
(but it also doesn't work with Apple's terminal).
Hi geier, thanks for getting back to me.
For that command I had to add -e to enable backslash interpretation. The result was still no colouring though:
I did some googling and I came across a few pages that said urxvt doesn't support the 38;2 codes, but other pages that say that it does, so not sure what to make of that.
Sorry didn't mean to close it, misclick :/