View Single Post
  #3  
Old 26-08-2010, 07:09
ljesus7
Guest
 
Posts: n/a
Default Thanks For your Reply

Code:
 
// Shape Error Check
if (corel.ActiveDocument.ActivePage.Shapes.FindShapes(string.Empty, cdrShapeType.cdrNoShape, true, 
"@type='3DObject' or 
@type='ArtisticMediaGroup' or
@type=BevelGroup or 
@type=BlendGroup or 
@type=Connector or 
@type=ContourGroup or 
@type=CustomEffectGroup or 
@type=CustomEffectGroup or 
@type=DropShadowGroup or 
@type=ExtrudeGroup or 
@type=HTMLActiveObject or 
@type=HTMLFormObject or 
@type=LinearDimension or 
@type=MeshFill or 
@type=OLEObject or 
@type=Perfect or 
@type=Symbol or 
@type=text").Count != 0)
           {
                throw new Exception();
            }

            if (corel.ActiveDocument.ActivePage.Shapes.FindShapes(string.Empty, cdrShapeType.cdrNoShape, true, "@color.IsCMYK = false").Count != 0)
            {
                throw new Exception();
            }

 Top of the page has a type check and color check using a CQL, but I don't know what Effect Check
 As you can see, CorelDraw have a lot of many type object.. so I would like to know how to find a lot of many object information using a CQL
 For example. 
 
 CQL Manual
 Returns an array of colors used in the fill and the outline of the shape. 
 This array contains only unique colors, so if both the fill and the outline have the same color, only one color will be returned
 @colors.find(cmyk(0,0,0,100)) => finds if the shape contains a CMYK black color
 !@color.filter($item.cmyk.k <> 0).empty => Finds if the shape has any color that has non-empty black color component.

                if (sh.Shapes.FindShapes(string.Empty, cdrShapeType.cdrNoShape, true, "@color.cmyk.k <> 0 and @fill.Type = 'uniform'").Count > 0)
                {
                    color = 1;
                }

                if (sh.Shapes.FindShapes(string.Empty, cdrShapeType.cdrNoShape, true, "(@color.cmyk.c + @color.cmyk.m + and @color.cmyk.y + @color.cmyk.k = 0) or 
                (@color.cmyk.c + @color.cmyk.m + and @color.cmyk.y) and  @fill.Type = 'uniform'").Count > 0)
                {
                    color = 4;
                }
How to Check a Black Color [range 0 to 100] , How to check a CMYK Color without @color.IsCmyk , How to check a object included Effect [Blend, Extrude, PowerClip, Fountain, Etc]
Thank For you Replay again

Last edited by ljesus7; 26-08-2010 at 07:20.
Reply With Quote