🎨 改进代码样式 (#648)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
github-actions[bot] 2023-03-30 15:24:15 +08:00 committed by GitHub
parent df4c0438a2
commit 52ef28cd6a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -62,13 +62,13 @@ func init() {
ctx.SendChain(message.Text("ERROR: ", err)) ctx.SendChain(message.Text("ERROR: ", err))
return return
} }
//获得画布预计 // 获得画布预计
testcov := gg.NewContext(1, 1) testcov := gg.NewContext(1, 1)
if err = testcov.ParseFontFace(data, 30); err != nil { if err = testcov.ParseFontFace(data, 30); err != nil {
ctx.SendChain(message.Text("ERROR: ", err)) ctx.SendChain(message.Text("ERROR: ", err))
return return
} }
//取最长段 // 取最长段
txt = "" txt = ""
for _, v := range strlist { for _, v := range strlist {
if len([]rune(v)) > len([]rune(txt)) { if len([]rune(v)) > len([]rune(txt)) {