Author Topic: Change Edit Panel Digital Clock  (Read 330 times)

Offline Goofy

  • Newbie
  • *
  • Posts: 36
Change Edit Panel Digital Clock
« on: January 07, 2017, 11:33:45 am »
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?
 :)

Offline blaze

  • Jr. Member
  • **
  • Posts: 73
  • blazing away
Re: Change Edit Panel Digital Clock
« Reply #1 on: January 10, 2017, 06:12:07 pm »
Seriously I do not have a clue if this is link below is "komfortabler"  ;D

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

Offline pavroo

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1545
    • SparkyLinux
Re: Change Edit Panel Digital Clock
« Reply #2 on: January 10, 2017, 08:17:03 pm »
As you said, it's the LXDE panel so, go to:
Code: [Select]
~HOME/.config/lxpanel/default/panels/panelMake backup of the panel file, just in case.
Then edit it, go to section:
Code: [Select]
Plugin {
  type=dclock
  Config {
    ClockFmt=%R
    TooltipFmt=%A %x
    BoldFont=0
    IconOnly=0
    CenterText=0
  }
}
Change the line:
Code: [Select]
ClockFmt=%Rusing the formats you enclosed in the first post, for example:
Code: [Select]
ClockFmt=%H %M %S(try with others too)
Save the file, and reboot the panel:
Code: [Select]
killall -9 lxpanel &
lxpanel &
or log out and log in back to take effects.
« Last Edit: January 10, 2017, 08:20:26 pm by pavroo »
Nothing is easy as it looks.
Danielle Steel

Offline Goofy

  • Newbie
  • *
  • Posts: 36
Re: Change Edit Panel Digital Clock
« Reply #3 on: January 11, 2017, 07:16:43 am »
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.
 :)

Offline seppalta

  • Full Member
  • ***
  • Posts: 112
Re: Change Edit Panel Digital Clock
« Reply #4 on: January 17, 2017, 09:43:32 am »

Offline Goofy

  • Newbie
  • *
  • Posts: 36
Re: Change Edit Panel Digital Clock
« Reply #5 on: January 18, 2017, 04:19:59 pm »
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

 :)