-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
有序列表、无序列表后跟中文,文本会向下偏移 #8
Comments
在用到有序列表的文件开头加上下面这段代码:
可以识别出含有中文的一项,并把它向上平移一点。 但是尝试集成到tongjithesis.typ文件中时会报错 |
发现报错是因为我的文章中有些item.body中有空格,导致item.body的类型变成了一个content数组,没有了text属性。 tongjithesis.typ修改如下,就不会偏移了。但是写法实在不优雅。
|
Hi,星云, 感谢你提出 Issue 并分享解决方案! 这个文本偏移问题可能与我们所用的中文字体有关。你有尝试过切换其他字体吗?有时不同字体的基线设置会影响对齐。如果更换字体后问题仍然存在,我们可以考虑在模板中做更通用的调整,避免每个列表项都手动调整;如果更换字体后问题被解决,我们可以考虑更换模版的默认字体。 谢谢! |
使用平台详情
工具:VSCode + Typst Preview插件
问题描述
有序列表和无序列表后跟中文,中文字符会向下偏移一些距离。
例如:
后面跟英文是正常的:
The text was updated successfully, but these errors were encountered: