View Single Post
  #2 (permalink)  
Old 08-03-2007, 11:13 AM
Erel's Avatar
Erel Erel is online now
Administrator
 
Join Date: Apr 2007
Posts: 15,676
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default

If you are using ImageLib, then you could draw on the back layer with transparency.
That way, many drawings can overlap without hiding each other.
Code:
Sub App_Start
      Form1.Show
      drawer1.New1(
"Form1",false)
      bmpSrc.New1(AppPath & 
"\smiley.gif"'Loads an image from a file named smiley.gif
      rectSrc.New1(0,0,bmpSrc.Width,bmpSrc.Height) 'Same size as the image.
      rectDest.New1(100,100,25,25)
      drawer1.SetTransparentColor1(bmpSrc.GetPixel1(
0,0)) 'Sets the transparent color to be the color of pixel (0,0) in the bitmap
      drawer1.DrawImage1(bmpSrc.Value,rectSrc.Value,rectDest.Value,true)
       rectDest.X = 
80
        drawer1.DrawImage1(bmpSrc.Value,rectSrc.Value,rectDest.Value,
true)
      drawer1.Refresh2(rectDest.Value)     
End Sub
Reply With Quote