Wish : New Property TransparencyMethod for vdFigure
Article | 60001669 |
Type | Wish |
Product | Engine |
Version | 6022 |
Date Added | 3/29/2012 |
Fixed | Yes [3/29/2012] |
Submitted by | Peter Chanios |
Keywords | |
Subject
New Property TransparencyMethod for vdFigure
Summary
New Property TransparencyMethod for vdFigure that controls the transparency of the object.
Solution
In version 6023 we added a new property for the vdFigure object called TransparencyMethod.
This property takes values from the vdFigure.TransparencyMethodEnum like below
enum TransparencyMethodEnum
The object takes the Transparency (AlphaBlending value) of the color of it's layer.
ByLayer,
The object takes the owner's color transparency (AlphaBlending value).
ByBlock,
The object takes it's own transparency value if it is True Color , If the pencolor is by index then the palette's color transparency value is used.
Default,
The object always takes it's own transparency (AlphaBlending value).
KeepOwn
c# example
//In this example the circle will be drawn with color's palette index 2 but it will take the Alpha Blending 120 of the circle.
vdCircle circle = new vdCircle(doc, new gPoint(10, 10, 0), 3.0);
circle.PenColor.ColorIndex = 2;
circle.PenColor.AlphaBlending = 120;
circle.TransparencyMethod = vdFigure.TransparencyMethodEnum.KeepOwn;
doc.Model.Entities.AddItem(circle);
vb6 Code
VDraw1.CommandAction.CmdCircle Array(10, 10, 0), 3#
Dim cir As VectorDraw_Professional.vdFigure
Set cir = VDraw1.ActiveDocument.Model.entities.Last.WrapperObject
cir.TransparencyMethod = TransparencyMethodEnum_KeepOwn
cir.PenColor.AlphaBlending = 100