Rails prawn中的阿拉伯词显示相反的顺序

时间:2019-03-07 06:14:25

标签: ruby-on-rails ruby-on-rails-4 prawn

当我尝试用阿拉伯语创建pdf时,我得到的字母顺序相反。

我使用以下代码生成pdf文件。

 note_section = {content: "#{order_item.try(:notes).try(:connect_arabic_letters)}" , 
  size: 8, 
  font: "app/assets/fonts/ufonts.com_arial-unicode-ms.ttf", 
  text_color: "313131"}

期望的文本是: enter image description here

虾中的样子:

enter image description here

宝石版本=>大虾版本:2.2.2 Rails版本:5.1.6

非常感谢您的帮助!

0 个答案:

没有答案