diff --git a/README.md b/README.md index b5066dd5..faab367d 100644 --- a/README.md +++ b/README.md @@ -248,6 +248,7 @@ __Docker 最新版本由 [Sakuracio](https://github.com/Sakuracio) 提供__ * 修复webui中plugins2setting修改时会改变plugins2setting.cmd为字符串 * 修复昵称系统`BLACK_WORD`为空时造成报错 * 修复特殊头像时背景透明化出错 +* 修复text2image纯文本时换行时颜色不统一 * 优化webUI,当有插件出错时不会影响其他插件显示 * 优化Config类型注释 [@pull/830](https://github.com/HibiKier/zhenxun_bot/pull/830) * 优化browser diff --git a/utils/image_utils.py b/utils/image_utils.py index d0cb58ed..b9c50704 100755 --- a/utils/image_utils.py +++ b/utils/image_utils.py @@ -1507,7 +1507,7 @@ async def text2image( w, _ = _tmp.getsize(x.strip() or "正") height += h + line_height width = width if width > w else w - image_list.append(BuildImage(w, h, font=font, font_size=font_size, plain_text=x.strip())) + image_list.append(BuildImage(w, h, font=font, font_size=font_size, plain_text=x.strip(), color=color)) width += pw height += ph A = BuildImage(