Tonec.com Bringing Internet Technology Innovations to Market since 1991
  News Products Outsourcing About Us Contact Us
what's new?what's new? featuresfeatures samplessamples manualmanual downloaddownload buybuy
  Tonec Homepage
ProductsActive Imagesamples

Please view complete list of samples

Sample 20


Drawing text with a shadow


The sample shows how to create a text with a shadow.

shadow.vbs

Dim im
Dim width, height, str


width = 350
height = 70
str = "Shadow Text"

Set im = CreateObject("ActiveImage.Images.1")
im.CreateImage width, height
im.SetImageType 1

im.CreateImage width, height
im.SetColor 255,255,0
im.DrawFilledRectangle 0,0,width, height
im.SetFontPathTTFAuto
im.SetFontSizeTTF 38

im.SetFontTTF "tahomabd"
'Set the text color
im.SetColor 20,20,150
im.DrawTextTTF 4,48,str

im.SetColor 255,255,230
im.DrawTextTTF 6,45,str

im.WriteToFile "C:\AI\shadow.jpg"
im.DestroyImage
Set im = Nothing


 shadow.jpg
 Picture 1. Shadow.jpg (size - 6,1Kb)

Next sample >> 

If you have any questions or bug reports, write to support@tonec.com for technical support.

  TonecPrivacy Policy
  © 1999-2005. Tonec, Inc. All rights reserved.