/*
   --------------------------------------------------------
   Filename.....: analogClock.wfm
   ClassName....: analogClockForm
   Purpose......: SDI Analog Clock form with a PopUp menu
                  for copying the displayed time.
   Programmer...: Peter Balfour with
                  revisions by Rick Miller.
   Date.........: January 29, 2003.
   Notes........: See Notes below.
   Written for..: dBASE PLUS 2.01 and newer.
                  May work with dB2K and VdB7.
   Rev. History.: See Revisions below.
   Dependencies.: None
   Calls........: See x_InitializeExterns for API calls.
   Called by....: Any
   Usage........: do analogClock.wfm
   Example......: None.
   ----------------------------------------------------------------
   Notes:
   ----------------------------------------------------------------
      1) The original Code was from a dBASE newsgroup posting.
         Posted by: Peter Balfour.
         Posted on: January 29, 2003.
      2) The colors can be changed with the ANALOG_BG/FG constants.
   ----------------------------------------------------------------
   Revisions:
   ----------------------------------------------------------------
      September 05, 2006.
      -------------------------------------------------------------
         1) Added a PopUp menu for changing the displayed time
            format and copying to the ClipBoard.
         2) Added the docked property for auto-positioning.
         3) Added color change between AM and PM.
         4) Added color offset for the current hour.
   ----------------------------------------------------------------
   Properties: type:       default:    purpose:
   ----------------------------------------------------------------
      docked   <logical>   true        automatic or manual
                                       positioning
   ----------------------------------------------------------------
   Methods:
   ----------------------------------------------------------------
      action([<int>])            called by PopUp menu.
      onTimer()                  update the clock hands.
      onUpdate()                 update the form and object
                                 size and position.
      pbCheckSize_onClick()      used for testing.
      setPosition()              dock the form.
   ----------------------------------------------------------------
   */