def update_clock(self, dt):
        """This method is called by the ClockApp whenever the timer fires
        to update the clock.  `dt` is a timezone-aware datetime object.
        """
        dt = dt.astimezone(self.tzinfo)
        fmt = "%H:%M"
        if self.show_seconds:
            fmt = "%H:%M:%S"

        self.time_txt.text = dt.strftime(fmt)

        suppl_text = "{0} {1}".format(dt.strftime("%Y-%m-%d"), self.timezone)
        self.suppl_txt.text = suppl_text

        self.viewer.redraw(whence=3)
def update_clock ( self , dt ) : dt = dt . astimezone ( self . tzinfo ) fmt = "%H:%M" if self . show_seconds : fmt = "%H:%M:%S" self . time_txt . text = dt . strftime ( fmt ) suppl_text = "{0} {1}" . format ( dt . strftime ( "%Y-%m-%d" ) , self . timezone ) self . suppl_txt . text = suppl_text self . viewer . redraw ( whence = 3 )
This method is called by the ClockApp whenever the timer fires
        to update the clock.  `dt` is a timezone-aware datetime object.