gambas-source-code/app/examples/Drawing/Painting/Example11
Benoît Minisini 21e325b27a [EXAMPLES]
* NEW: Put the old examples in '/trunk/app/examples'.


git-svn-id: svn://localhost/gambas/trunk@6724 867c0c6c-44f3-4631-809d-bfa615b0a4ec
2014-12-11 23:49:07 +00:00

27 lines
489 B
Text

Public Sub Example11()
Dim X, Y, W, H As Float
Dim hBrush As PaintBrush
Dim hImage As Image
hImage = Image.Load(IMAGE_NAME)
X = 16
Y = 40
W = 200
H = 200
'Paint.DrawImage(hImage, X, Y, W, H)
hBrush = Paint.Image(hImage)
hBrush.Translate(X, Y)
hBrush.Scale(W / hImage.W, H / hImage.H)
Paint.Brush = hBrush
Paint.Rectangle(X, Y, W, H)
Paint.Fill
Paint.Brush = Paint.Color(Color.RGB(255, 127, 127, 153))
Paint.Arc(X, Y, 10)
Paint.Fill
End