diff --git a/PROMS/Volian.Svg.Library/iTextSharp.cs b/PROMS/Volian.Svg.Library/iTextSharp.cs index 10be53e5..85e189f3 100644 --- a/PROMS/Volian.Svg.Library/iTextSharp.cs +++ b/PROMS/Volian.Svg.Library/iTextSharp.cs @@ -1140,6 +1140,15 @@ namespace Volian.Svg.Library if (!AllowAllWatermarks && !AllowedWatermarks.Contains(Watermark)) return; cb.SaveState(); if (_WatermarkLayer != null) cb.BeginLayer(_WatermarkLayer); + if (IsLandscape) + { + // The watermark needs to be rotated back for landscape pagelist - B2016-191 + //double a = -33 * (Math.PI / 180); + //System.Drawing.Drawing2D.Matrix myMatrix = new System.Drawing.Drawing2D.Matrix((float)Math.Cos(a), (float)Math.Sin(a), (float)-Math.Sin(a), (float)Math.Cos(a), -60, 320); + double a = -90 * (Math.PI / 180); + System.Drawing.Drawing2D.Matrix myMatrix = new System.Drawing.Drawing2D.Matrix((float)Math.Cos(a), (float)Math.Sin(a), (float)-Math.Sin(a), (float)Math.Cos(a), 0, 800); + cb.Transform(myMatrix); + } SvgWatermark myWatermark = new SvgWatermark(cb, Watermark, System.Drawing.Color.Blue, .15F); //myWatermark.SetSquareDotPattern(.7F); myWatermark.Draw();