> $KCODE = 'u'
> require 'prawn'
> require 'prawn/layout'
> Prawn::Document.generate("test.pdf") do
> font "#{Prawn::BASEDIR}/data/fonts/DejaVuSans.ttf"
> data = [[{ :text => "First Name", :font_style => :bold }, "Günther"]]
> table data, :font_size => 10, :position => :left, :border_width => 0
> end
>
> but unfortunately the error remains the same.
> Could the problem be with the font?
No, I'm pretty sure the problem is with your text editor producing
non-UTF-8 output.
Chris
Yeah, I think the windows APIs are weird about this...
Jack, is it a possibility to use the iconv stdlib to transcode to
ASCII w. translit?
That'd preserve your 'ö' as an 'o'. (This is not a Prawn problem,
but a Ruby one, I think)
-greg
> I'll carry on playing about with things in prawn and post back here if
> I have any more questions.
To be clear, it doesn't make much sense to add this to the PDF layer
(in PDF::Writer or Prawn)
This is an issue with Ruby's File class.
You can do this trick before passing your filename to Prawn and it
should work fine.
-greg