LEADTOOLS Special Effects (Leadtools.SpecialEffects assembly)
LEAD Technologies, Inc

SpecialEffectsProcessor Class

Example 





Members 
The SpecialEffectsProcessor class gives you precise control over a large variety of effects when you paint bitmaps, text, patterns, and shapes onto a device context.
Object Model
SpecialEffectsProcessor Class
Syntax
public class SpecialEffectsProcessor 
'Declaration
 
Public Class SpecialEffectsProcessor 
'Usage
 
Dim instance As SpecialEffectsProcessor
public sealed class SpecialEffectsProcessor 
function Leadtools.SpecialEffects.SpecialEffectsProcessor()
public ref class SpecialEffectsProcessor 
Remarks
For more information on how to use this class, refer to Implementing Special Effects.
Example
Copy CodeCopy Code  
Public Sub Draw3dText(ByVal g As Graphics, ByVal destRect As Rectangle)
      Dim processor As SpecialEffectsProcessor = New SpecialEffectsProcessor()
      Dim textFont As Font = New Font("Arial", 24)

      Dim img As Image = Image.FromFile(Path.Combine(LEAD_VARS.ImagesDir, "Ulay1.bmp"))

      processor.Draw3dText(g, "3D Text - LEADTOOLS", destRect, SpecialEffectsTextStyle.DropShadow, SpecialEffectsTextAlignmentFlags.HorizontalCenter Or _
                           SpecialEffectsTextAlignmentFlags.VerticalCenter, 2, 2, Color.Blue, Color.Black, Color.White, textFont, img)

      img.Dispose()
   End Sub

Public NotInheritable Class LEAD_VARS
   Public Const ImagesDir As String = "C:\Users\Public\Documents\LEADTOOLS Images"
End Class
public void Draw3dText(Graphics g, Rectangle destRect)
   {
      SpecialEffectsProcessor processor = new SpecialEffectsProcessor();
      Font textFont = new Font("Arial", 24);

      Image image = Image.FromFile(Path.Combine(LEAD_VARS.ImagesDir, "Ulay1.bmp"));

      processor.Draw3dText(g,
                           "3D Text - LEADTOOLS",
                           destRect,
                           SpecialEffectsTextStyle.DropShadow,
                           SpecialEffectsTextAlignmentFlags.HorizontalCenter | SpecialEffectsTextAlignmentFlags.VerticalCenter,
                           2, /* horizontal  shadow position */
                           2, /* vertical shadow position */
                           Color.Blue, /* text color, blue */
                           Color.Black,/* shadow color, black */
                           Color.White, /* border color, white */
                           textFont,
                           image);

      image.Dispose();
   }

static class LEAD_VARS
{
   public const string ImagesDir = @"C:\Users\Public\Documents\LEADTOOLS Images";
}
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

SpecialEffectsProcessor Members
Leadtools.SpecialEffects Namespace

 

 


Products | Support | Contact Us | Copyright Notices

© 2006-2012 All Rights Reserved. LEAD Technologies, Inc.