Xfce Forum

Sub domains

You are not logged in.

#1 2011-11-14 04:54:30

Registered: 2011-11-14
Posts: 2

Clock Foreground Color


can anyone please tell me if there is a way of changing the foreground color of the clock? I am using the default clock (installed with xfce4-panel).
I digged through the source of the clock, but didn't find any reference to a configuration setting - but maybe i just haven't looked deep enough.



#2 2011-11-14 14:08:51

Registered: 2010-10-11
Posts: 168

Re: Clock Foreground Color

Not the answer to your question, but Orage's clock has a setting for the foreground colour. I also like it better because I can configure what is displayed (time, day of week...)


#3 2011-11-14 14:56:41

From: Toronto, Canada
Registered: 2011-06-02
Posts: 935

Re: Clock Foreground Color

In the clock properties, set the format to "Custom Format" and wrap the format in a <span></span> statement - something like this:

<span color="#FF0000">%a %b %_d%n%l:%M %P</span>

- http://crunchbanglinux.org/forums/post/98478/#p98478
- http://wiki.xfce.org/tips#customize_the … nel_plugin
- http://developer.gnome.org/pango/unstab … ormat.html

Last edited by ToZ (2011-11-14 15:01:50)


#4 2013-09-25 10:43:07

Registered: 2013-09-25
Posts: 2

Re: Clock Foreground Color

I'm sorry I'm an amateur - what does it mean?

<span color="#FF0000">%a %b %_d%n%l:%M %P</span>



#5 2013-09-25 12:53:48

From: Toronto, Canada
Registered: 2011-06-02
Posts: 935

Re: Clock Foreground Color

Right-click the clock panel item and select properties. Change "Clock Options->Format" to "Custom" and enter that string as the custom format. Feel free to play around with the "%a %b %_d%n%l:%M %P" part to get the proper formatting for the clock. From "man date":

       FORMAT controls the output.  Interpreted sequences are:

       %%     a literal %

       %a     locale's abbreviated weekday name (e.g., Sun)

       %A     locale's full weekday name (e.g., Sunday)

       %b     locale's abbreviated month name (e.g., Jan)

       %B     locale's full month name (e.g., January)

       %c     locale's date and time (e.g., Thu Mar  3 23:05:25 2005)

       %C     century; like %Y, except omit last two digits (e.g., 20)

       %d     day of month (e.g., 01)

       %D     date; same as %m/%d/%y

       %e     day of month, space padded; same as %_d

       %F     full date; same as %Y-%m-%d

       %g     last two digits of year of ISO week number (see %G)

       %G     year of ISO week number (see %V); normally useful only with %V

       %h     same as %b

       %H     hour (00..23)

       %I     hour (01..12)

       %j     day of year (001..366)

       %k     hour, space padded ( 0..23); same as %_H

       %l     hour, space padded ( 1..12); same as %_I

       %m     month (01..12)

       %M     minute (00..59)

       %n     a newline

       %N     nanoseconds (000000000..999999999)

       %p     locale's equivalent of either AM or PM; blank if not known

       %P     like %p, but lower case
       %r     locale's 12-hour clock time (e.g., 11:11:04 PM)

       %R     24-hour hour and minute; same as %H:%M

       %s     seconds since 1970-01-01 00:00:00 UTC

       %S     second (00..60)

       %t     a tab

       %T     time; same as %H:%M:%S

       %u     day of week (1..7); 1 is Monday

       %U     week number of year, with Sunday as first day of week (00..53)

       %V     ISO week number, with Monday as first day of week (01..53)

       %w     day of week (0..6); 0 is Sunday

       %W     week number of year, with Monday as first day of week (00..53)

       %x     locale's date representation (e.g., 12/31/99)

       %X     locale's time representation (e.g., 23:13:48)

       %y     last two digits of year (00..99)

       %Y     year

       %z     +hhmm numeric time zone (e.g., -0400)

       %:z    +hh:mm numeric time zone (e.g., -04:00)

       %::z   +hh:mm:ss numeric time zone (e.g., -04:00:00)

       %:::z  numeric time zone with :  to  necessary  precision  (e.g.,  -04,

       %Z     alphabetic time zone abbreviation (e.g., EDT)

Last edited by ToZ (2013-09-25 12:54:46)


#6 2013-10-02 19:04:56

From: Italy
Registered: 2012-02-08
Posts: 21

Re: Clock Foreground Color

It works! Thank you


Board footer

Powered by FluxBB