Aesthetics is the study of art and beauty; it was an important issue for 18th- and 19th-century philosophers such as Kant and Hegel. Classical philosophers like Plato and Aristotle also theorized about art and painting in particular. Plato disregarded painters (as well as sculptors) in his philosophical system; he maintained that painting cannot depict the truth—it is a copy of reality (a shadow of the world of ideas) and is nothing but a craft, similar to shoemaking or iron casting. By the time of Leonardo, painting had become a closer representation of the truth than painting was in Ancient Greece. Leonardo da Vinci, on the contrary, said that "Italian: La Pittura è cosa mentale" ("English: painting is a thing of the mind"). Kant distinguished between Beauty and the Sublime, in terms that clearly gave priority to the former. Although he did not refer to painting in particular, this concept was taken up by painters such as J.M.W. Turner and Caspar David Friedrich.
You saw that, to define a decorator, you typically define a function returning a wrapper function. The wrapper function uses *args and **kwargs to pass on arguments to the decorated function. If you want your decorator to also take arguments, you need to nest the wrapper function inside another function. In this case, you usually end up with three return statements.
The decorator pattern, also known as the wrapper pattern, is when you wrap an object within another object, thus providing a means of enhancing or overriding certain behavior. The wrapper object will delegate any incoming method calls to the original object, unless it defines a new method to enhance or replace the original object’s behavior. By using the decorator pattern, you can dynamically create as many decorated objects as you want, each enhancing the behavior of the original object in a unique way — and all without mutating the original object. In this manner, you can effectively add, remove, or extend behaviors at runtime.
Thanks to enhanced support for multi-core processors and CPUs that use AVX2 extensions and extensive code optimizations, this is the fastest version of Painter yet. A huge selection of brushes are noticeably faster — some as much as twice as fast. You can also take advantage of faster document rendering when zooming, panning and rotating — up to 50% faster.