Welcome to SparkyLinux forums
Zapraszamy również na polsko-języczne Forum https://forum.linuxiarze.pl

Change Edit Panel Digital Clock

Started by Goofy, January 07, 2017, 11:33:45 AM

Previous topic - Next topic

Goofy

Hello Linux-fighters,    ;)

I wanted to change the clock from the LXPanel in the bottom right corner of the desktop. I wanted to change from time to time and date.
But I couldn't find any information about this simply thing. I searched two hours   >:(
...but I'm sure, it must give a simpler way. I have likely only overlooked it...   :-\

Ok, here my results for other Linux-newbies:
The only helpfull website, which I founded:

http://netgator.blogspot.de/2012/09/change-edit-panel-digital-clock-format.html

The crucial table:

    %a - The abbreviated weekday name (Sun)
    %A - The full weekday name (Sunday)
    %b - The abbreviated month name (Jan)
    %B - The full month name (January)
    %d - Day of the month (01..31)
    %e - Day of the month (1..31)
    %H - Hour of the day, 24-hour clock (00..23)
    %I - Hour of the day, 12-hour clock (01..12)
    %l - Hour of the day ()
    %j - Day of the year (001..366)
    %m - Month of the year (01..12)
    %M - Minute of the hour (00..59)
    %p - Meridian indicator (AM or PM)
    %S - Second of the minute (00..60)
    %w - Day of the week (Sunday is 0, 0..6)
    %y - Year without a century (00..99)
    %Y - Year with century
    %Z - Time zone name
    %% - Literal % character

Maybe there's a way for a little bit komfortabler?
:)

blaze

Seriously I do not have a clue if this is link below is "komfortabler"  ;D

http://www.foragoodstrftime.com/
Unstable OpenBoxer

pavroo

#2
As you said, it's the LXDE panel so, go to:
~HOME/.config/lxpanel/default/panels/panel
Make backup of the panel file, just in case.
Then edit it, go to section:
Plugin {
  type=dclock
  Config {
    ClockFmt=%R
    TooltipFmt=%A %x
    BoldFont=0
    IconOnly=0
    CenterText=0
  }
}

Change the line:
ClockFmt=%R
using the formats you enclosed in the first post, for example:
ClockFmt=%H %M %S
(try with others too)
Save the file, and reboot the panel:
killall -9 lxpanel &
lxpanel &

or log out and log in back to take effects.
Nothing is easy as it looks. Danielle Steel

Goofy

Hello blaze,

yes, that frontend in your link for the clock looks nice; But if you click the link, there is nothing to find about that...   :o
...I remember, that I found the same over my searching... -But just not this App.   :)

Thank you pavroo for these commands for the Terminal...     ::)

No, to change the time display is not difficulty (by rigth-click, and choose time-options); But I must know the characters, which I need to set the clock in my way. And I tell you, that this table in my link is not complete: There are more, because the default-settings contains characters, which there are not in that table. But both sources together were ok...   :-\

If somebody could find a complete table, this would be beautiful, for the future.
:)


Goofy

Hello seppalta,

nice simulator...   :)

I have set now:
%A %x %n %R:%S

in our table sources is missing %n or %x for example...    :o

:)

View the most recent posts on the forum