Desktop painting

Painting in the browser can be costly, but we tend to forget that the browser isn't the only place where it can occur. By testing the limits of the browser capabilities, we sometimes ignore the fact that OS resource usage and machine configurations also affect browser rendering. That these remain outside our control doesn't mean that we should neglect them during development. Otherwise we may reach the limits of the possible sooner than we thought, which will lead to a browser crash.

The browser exists thanks to the operating system, which can affect its painting and even terminate it. If we assume for a second that we have a transparent browser window, then everything underneath will need to be rendered too in order to be visible. In this case, painting the browser and the underlying windows, including the desktop, is a task that may require time sharing of the available machine resources due to the competitive environment in which the rendering occurs. When we resize the browser window and make it smaller, the painting costs inside of it will decrease due to the smaller painting area and the fact that fewer pixels will need to be updated during page loading, scrolling and general user interactions with the page. But the painting area outside the browser increases and because the nature of the resize event is to fire continuously, the cost of the desktop repaint will be introduced to the system, multiple times per second. If we have a huge background photo with lots of icons and text labels that have to be anti-aliased, these costs may slow down the system and thus affect the rate with which we can continue to resize the window.

We can use the desktop as a file distributor in our system. As soon as new files arrive, we can decide what to do with them. We can use them, transfer them to the appropriate directory if they have long-term value or delete them when they are no longer needed. This eliminates the case where we have many files in a directory that we see rarely and fear to clean up, because we have lost track what was valuable after it was used, but not deleted. On the desktop, new files are always in front of us, directly contributing to visual disorder, which stops our willingness to download more. To keep the space clean, we have no other option except of acting on these files immediately.

By cleaning up the desktop, we eliminate distractions during our work, minimize painting costs for window operations that also affect the browser and finally, we eliminate the possibility that excessive number of files will slow down our system over time.