MfS
unread,Mar 25, 2012, 8:51:19 AM3/25/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to origami-pdf
Hello there,
I am currently working on a Ruby project which uses Origami to create
PDF pages out of UTF-8 Strings coming from a SQLite database. This
works well as long as the String does not contain umlauts like ä,ö,ü.
The umlauts in the resulting PDF page look like "^/" or so. Is there a
way to get correct umlauts into the PDF?
Thank you for your help!
mfs
A sample ruby script illustrating the problem:
# coding: utf-8
require 'origami'
include Origami
OUTPUTFILE = "new.pdf"
# Creating a new file
pdf = PDF.new
s=String.new("ä")
contents = ContentStream.new
contents.write s, :x => 250, :y => 750, :rendering =>
Text::Rendering::FILL, :size => 30
pdf.append_page Page.new.setContents(contents)
pdf.save(OUTPUTFILE)