21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
# File 'app/app_delegate.rb', line 21
def viewDidLoad
self.view.backgroundColor = :black.uicolor
bluebox = UIView.alloc.initWithFrame([[20, 84], [30, 30]])
bluebox.backgroundColor = :blue.uicolor
self.view << bluebox
darkbox = UIView.alloc.initWithFrame(bluebox.frame.below(8))
darkbox.backgroundColor = '#222222'.uicolor
self.view << darkbox
lightbox = UIView.alloc.initWithFrame(darkbox.frame.below(8))
lightbox.backgroundColor = :white.uicolor
self.view << lightbox
label = UILabel.alloc.initWithFrame(lightbox.frame.below(8))
label.backgroundColor = :clear.uicolor
label.textColor = :white.uicolor
label.text = 'A Label'
label.sizeToFit
self.view << label
end
|