These are known as Mondrian’s art, after the Dutch painter Piet Mondrian. Somehow just straight lines and a few colours can produce aesthetics pleasing images!
I used SAS Proc Report to produce these images - not the best tool for this but I want to demonstrate that it can be done! You can make it more complex (i.e. more cells) if you have the will to do it! One advantage of doing these programmatically is that you can easily switch to different colours’ palettes and resizing the cells.
I mentioned about how to save in PNG etc in previous posts.