fix: 解决验证码显示不全的问题

This commit is contained in:
ssongliu 2023-02-24 18:50:07 +08:00 committed by ssongliu
parent b7324d14dc
commit 1e79b096fe

View File

@ -31,7 +31,7 @@ func CreateCaptcha() (*dto.CaptchaResponse, error) {
driverString.Height = 50
driverString.NoiseCount = 0
driverString.Length = 4
driverString.Fonts = []string{"wqy-microhei.ttc"}
driverString.Fonts = []string{"RitaSmith.ttf", "actionj.ttf", "chromohv.ttf"}
driver := driverString.ConvertFonts()
c := base64Captcha.NewCaptcha(driver, store)
id, b64s, err := c.Generate()