Giter Club home page Giter Club logo

pygtkworldclock's Introduction

pyGTKWorldClock

This is simple world clock application written in Python and Cairo.

Requirement

  • Python3
  • PyCairo
  • PyGObject (GTK3)

Configuration

See example.yaml for reference. Basically config file is a YAML file, which contain a definition of timezone and the label, which in the end maps as python dictionary:

{'tz': 'string of timezone'
 'label': 'string of some label'}

For example, single clock can be represended as:

---
-
  tz: UTC
  label: The real world clock

which would have an effect:

single clock

Note, that it have to be a list in YAML format (line started with -) followed by a definition of key-value of timezone and a label. Analogically, several clocks (let's take an example of US timezones) can be vertically arranged by providing a list of key-values:

---
-
  tz: US/Hawaii
  label: Honolulu, Hawaii, US
-
  tz: US/Alaska
  label: Anchorage, Alaska, US
-
  tz: US/Pacific
  label: Portland, Oregon, US
-
  tz: US/Mountain
  label: Salt Lake City, Utah, US
-
  tz: US/Central
  label: Austin, Texas, US
-
  tz: US/Eastern
  label: New York, US

and the result:

single clock

Same in horizontal arrangement:

---
-
  -
    tz: US/Hawaii
    label: Honolulu, Hawaii, US
  -
    tz: US/Alaska
    label: Anchorage, Alaska, US
  -
    tz: US/Pacific
    label: Portland, Oregon, US
  -
    tz: US/Mountain
    label: Salt Lake City, Utah, US
  -
    tz: US/Central
    label: Austin, Texas, US
  -
    tz: US/Eastern
    label: New York, US

obviously the result would be:

single clock

And finally the same in two rows, three columns:

---
-
  -
    tz: US/Hawaii
    label: Honolulu, Hawaii, US
  -
    tz: US/Alaska
    label: Anchorage, Alaska, US
  -
    tz: US/Pacific
    label: Portland, Oregon, US
-
  -
    tz: US/Mountain
    label: Salt Lake City, Utah, US
  -
    tz: US/Central
    label: Austin, Texas, US
  -
    tz: US/Eastern
    label: New York, US

which will look like that:

single clock

You can experiment to get the layout of your choice.

License

This software is licensed under 3-clause BSD license. See LICENSE file for details.

pygtkworldclock's People

Contributors

gryf avatar

Stargazers

 avatar

Watchers

 avatar  avatar

pygtkworldclock's Issues

gtk4?

Has it been tried with gtk4? Perhaps we coudld embed it in a gtk grid now.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.