Browse Source

Update SimpleMathsCaptchaGenerator.cs

pull/18003/head
liangshiwei 3 years ago
parent
commit
0a5d116f71
  1. 2
      modules/cms-kit/src/Volo.CmsKit.Public.Web/Security/Captcha/SimpleMathsCaptchaGenerator.cs

2
modules/cms-kit/src/Volo.CmsKit.Public.Web/Security/Captcha/SimpleMathsCaptchaGenerator.cs

@ -128,7 +128,7 @@ public class SimpleMathsCaptchaGenerator : ITransientDependency
var text = character.ToString();
var color = options.TextColor[random.Next(0, options.TextColor.Length)];
var location = new PointF(startWith + position, random.Next(6, 13));
image.Mutate(ctx => ctx.DrawText(text, font, color, location));D
image.Mutate(ctx => ctx.DrawText(text, font, color, location));
position += TextMeasurer.MeasureSize(character.ToString(), new TextOptions (font)
{
Origin = location

Loading…
Cancel
Save