How to render Arabic "(" symbol, using "svg-net"?

问题描述 投票:0回答:0

我正在使用 c# 中的 svg-net 将 SVG 转换为 PNG。 问题是当我遇到阿拉伯字符 "(" 或 ")" 时。 -(其他角色没问题)。

“(”符号的位置和方向呈现方式与原始 SVG 文本不同。

text in SVG file

render result

我的开发环境如下

我的预期结果如下, expecting result

我试过这样的事情:

  • 将 'U+200E' 添加到字符串中。
  • 在文本中的 svg 标签中添加 dir="rtl" 标签。

最后,我不知道如何更改 svgDocument 中的内容。

var svgDoc = SvgDocument.Open<SvgDocument>(tempSvgname);
svgDoc.GetElementById("A11").Children[k].Content = "changed text";

using (MagickImage img = new MagickImage(svgDoc.Draw(width * 2, height * 2)))
{
  // no change text in render result
  ...
}
c# .net svg arabic
© www.soinside.com 2019 - 2024. All rights reserved.