Added comments to the scripst. To fully understand what the scripst are doing, one should know python and understand how CSS works. Most important is to understand how th access pvs and widget properties in CSS with python. The CSS Help is really useful for this.