Jump to content


Photo

How to make ananalog clock in the skin


  • Please log in to reply
48 replies to this topic

Re: How to make ananalog clock in the skin #41 littlesat

  • PLi® Core member
  • 56,964 posts

+695
Excellent

Posted 17 December 2012 - 22:08

Can you post your Watches.py that you are using now here?

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: How to make ananalog clock in the skin #42 alsat1

  • Senior Member
  • 221 posts

+1
Neutral

Posted 18 December 2012 - 01:47

It will be nice if Pli Team will add this clock to standard plihd skin on feed....regards.:rolleyes:

Re: How to make ananalog clock in the skin #43 littlesat

  • PLi® Core member
  • 56,964 posts

+695
Excellent

Posted 18 December 2012 - 07:42

When I find a good location for it.... For now I think the analogue clock is a nice gatget but the look is a bit more chaotic then a digital clock....

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: How to make ananalog clock in the skin #44 blzr

  • PLi® Core member
  • 2,269 posts

+118
Excellent

Posted 18 December 2012 - 09:56

Is that clock being rendered with the new lineDraw? Or does that still only draw black lines?

shouldn't speak for @Loui, but I suppose that still uses original Watches.py (so embedded drawLine function is not used for drawing)
//my (strong ;)) suspicion is based on the simple fact that for me, clock hands are still black (which should not be much surprising since there were no changes in this regard since introducing this function/?/)

When I find a good location for it.... For now I think the analogue clock is a nice gatget but the look is a bit more chaotic then a digital clock....

not sure about adding analog clock to the default skin (maybe better to add an alternate version?),
but, adding tools for analog clock might be useful (of course when they'll be OpenPLi-ready)...
- Watches.py - seems that there is some work in progress to improve it...
- ExtraNumText converter - actually all jobs of it are done in OpenPLI by other converters, so maybe these secHand minHand hourHand could be added to some existing converter (ClockToText?)?

thoughts?
True sarcasm doesn't need green font...

Re: How to make ananalog clock in the skin #45 littlesat

  • PLi® Core member
  • 56,964 posts

+695
Excellent

Posted 18 December 2012 - 11:02

blzr,

As far I can see you understand how it works.... probably you can give us at least a patch to make ExtraNumText obsolete... ;)

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: How to make ananalog clock in the skin #46 Loui (PD1LOI)

  • Senior Member
  • 4,583 posts

+146
Excellent

Posted 18 December 2012 - 11:05

Can you post your Watches.py that you are using now here?

Attached File  Watches_Extranumtext.rar   3.16KB   18 downloads Attached File  usr.rar   2.92KB   14 downloads A.u.b.

Edited by Loui (PD1LOI), 18 December 2012 - 11:09.


Re: How to make ananalog clock in the skin #47 blzr

  • PLi® Core member
  • 2,269 posts

+118
Excellent

Posted 18 December 2012 - 23:18

blzr
...you understand how it works....

little overstatement (to say the least... ;))

probably you can give us at least a patch to make ExtraNumText obsolete... ;)

ok, FWIW, you got two (pieces of a copy/paste coding ;)), to choose from:
1. analog clock convert types added to ClockToText converter (but am not quite sure, if it's the right place for it...)
or
2. new small and neat ;) ClockToHand converter
converters and patches (just in case) attached...
//and please, don't be too harsh, remember "NOBODY expects the Spanish Inquisition!" :P

Attached Files


True sarcasm doesn't need green font...

Re: How to make ananalog clock in the skin #48 blzr

  • PLi® Core member
  • 2,269 posts

+118
Excellent

Posted 26 December 2012 - 20:26

but after applying this change, clock hands are drawed, but they're all black (hence barely visible unless you have white clock-face


Hmm, maybe still something missing in the line draw code then. Probably this is the first time it was ever used...

FWIW
in gpixmap.cpp there's quite a difference regarding (rgb)colors in fill and line functions
void gPixmap::fill(const gRegion &region, const gRGB &color)

void gPixmap::line(const gRegion &clip, ePoint start, ePoint dst, gColor color)
...

maybe this could be some clue?
//and please note, my c++ skills are on par with Python ones (ie pretty absent) ;)
True sarcasm doesn't need green font...

Re: How to make ananalog clock in the skin #49 MiLo

  • PLi® Core member
  • 14,054 posts

+298
Excellent

Posted 27 December 2012 - 12:08

A clue indeed. Pushed the fix, now it draws lines in any color.
Real musicians never die - they just decompose


7 user(s) are reading this topic

0 members, 7 guests, 0 anonymous users