|
@@ -281,8 +281,12 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
annotHandlerEventArgs.CurrentType = C_ANNOTATION_TYPE.C_ANNOTATION_SQUARE;
|
|
|
byte[] LineColor = new byte[] { squareData.BorderColor.R, squareData.BorderColor.G, squareData.BorderColor.B };
|
|
|
(annotHandlerEventArgs as SquareParam).LineColor = LineColor;
|
|
|
- byte[] FillColor = new byte[] { squareData.FillColor.R, squareData.FillColor.G, squareData.FillColor.B };
|
|
|
- (annotHandlerEventArgs as SquareParam).BgColor = FillColor;
|
|
|
+ if(squareData.FillColor!=Colors.Transparent)
|
|
|
+ {
|
|
|
+ byte[] FillColor = new byte[] { squareData.FillColor.R, squareData.FillColor.G, squareData.FillColor.B };
|
|
|
+ (annotHandlerEventArgs as SquareParam).BgColor = FillColor;
|
|
|
+ (annotHandlerEventArgs as SquareParam).HasBgColor = true;
|
|
|
+ }
|
|
|
(annotHandlerEventArgs as SquareParam).LineWidth = squareData.Thickness;
|
|
|
(annotHandlerEventArgs as SquareParam).Transparency = Convert.ToByte(squareData.Opacity * 255);
|
|
|
ParamConverter.ParseDashStyle(squareData.DashStyle, out float[] LineDash, out C_BORDER_STYLE BorderStyle);
|
|
@@ -302,8 +306,12 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
annotHandlerEventArgs.CurrentType = C_ANNOTATION_TYPE.C_ANNOTATION_CIRCLE;
|
|
|
byte[] LineColor = new byte[] { cicleData.BorderColor.R, cicleData.BorderColor.G, cicleData.BorderColor.B };
|
|
|
(annotHandlerEventArgs as CircleParam).LineColor = LineColor;
|
|
|
- byte[] BgColor = new byte[] { cicleData.FillColor.R, cicleData.FillColor.G, cicleData.FillColor.B };
|
|
|
- (annotHandlerEventArgs as CircleParam).BgColor = BgColor;
|
|
|
+ if(cicleData.FillColor!=Colors.Transparent)
|
|
|
+ {
|
|
|
+ byte[] BgColor = new byte[] { cicleData.FillColor.R, cicleData.FillColor.G, cicleData.FillColor.B };
|
|
|
+ (annotHandlerEventArgs as CircleParam).BgColor = BgColor;
|
|
|
+ (annotHandlerEventArgs as CircleParam).HasBgColor=true;
|
|
|
+ }
|
|
|
(annotHandlerEventArgs as CircleParam).LineWidth = cicleData.Thickness;
|
|
|
(annotHandlerEventArgs as CircleParam).Transparency = Convert.ToByte(cicleData.Opacity * 255);
|
|
|
ParamConverter.ParseDashStyle(cicleData.DashStyle, out float[] LineDash, out C_BORDER_STYLE BorderStyle);
|