KV(lang), 775730 B :D
Not a competing answer, rather showing a language Kivy uses to make designing its widgets easier. The language requires indentation and newlines, therefore I'm forced to leave it in this shape. Kivy also takes rgb(a) as a color input, so I need to convert it and although there's a built-in, it's surely not suitable for golfing. :D
I'm traveling and with Kivy I'm able to code even on android. + its code is already crossplatform in I think 9/10 cases. ^^
#:import h kivy.utils.get_color_from_hexrgba
<F>:
canvas:
Color:
rgb: h('#d72828')
Rectangle:
size: [100,72]
Color:
rgb: h('#ffffff')
Rectangle:
pos: [40,0]
size: [60,32]
Rectangle:
pos: [40,40]
size: [60,32]
Rectangle:
pos: [0,40]
size: [32,32]
Rectangle:
size: [32,32]
Color:
rgb: h('#0048e0')
Rectangle:
pos: [44,0]
size: [56,28]
Rectangle:
pos: [44,44]
size: [56,28]
Rectangle:
pos: [0,44]
size: [28,28]
Rectangle:
size: [28,28]
To run it you need to install Kivy and either save it as a .kv
file, or have something like this in Python to parse it as a string:
from kivy.lang import Builder
from kivy.base import runTouchApp
from kivy.uix.boxlayout import BoxLayout
Builder.load_string('''KVstring''')
class F(BoxLayout):pass
runTouchApp(F())