[
https://issues.apache.org/jira/browse/FREEMARKER-50?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15982897#comment-15982897
]
Bayardo commented on FREEMARKER-50:
-----------------------------------
I have a ODT template (binary format, editable over MS Word or Libre Office)
with place holders. e.g. ${name}. The application over JBoss then set the
corresponding values over a Context object. e.g
name=Marie Česká,
address=Štětkova 18
InputStream in = get the ODT template ..
IXDocReport report = XDocReportRegistry.getRegistry().loadReport(in,
TemplateEngineKind.Freemarker);
...
After calling report.convert(context, options, outputStream) and writting then
the outputStream as byte[] to a PDF file, such PDF displays the following fonts:
On Ubuntu 16.04.1 => Marie Česká, Štětkova 18
That is ok!
On SUSE Linux Ent. Server 11 => Marie eská, Šttkova 18
Tha is wrong. Č and ě are missing.
In both scenarios the the value of JVM setting file.encoding and
Charset.defaultCharset Java API are set to UTF-8.
So, I am not sure if the Freemarker converter access internally any fonts
setting from the JVM or Operating System?
Does the converter translate the ODT template in binary format firstly to XML
and then again to binary?
After many test scenarios seems to be that the freemarker converter engine
access fonts configurations set on OS level.
I hope I was able to provide enough details of my issue.
Best.
> Czech encoding issues after coversion from ODT to PDF on Suse Linux
> -------------------------------------------------------------------
>
> Key: FREEMARKER-50
> URL: https://issues.apache.org/jira/browse/FREEMARKER-50
> Project: Apache Freemarker
> Issue Type: Bug
> Components: engine
> Affects Versions: 2.3.25-incubating
> Environment: Suse Linux Enterprise Server 11
> Reporter: Bayardo
>
> Some Czech characters are ignored in my PDF generated report on Suse Linux
> Server, even though the different encoding settings on JVM and FreeMarker
> engine Configuration are set to UTF-8. On the other side, Czech characters on
> PDF generated on Ubuntu Linux works perfect!
> Czech characters within 'context' are passed correctly to
> report.convert(context, options, outputStream);
> but after calling 'report.convert(...)', some characters are ignored!
> SUSE Linux Ent. Server 11
> XdocReport 1.05.
> Freemarker 2.3.25
> OdfToolkit.odfdom 1.0.5
> iText 2.1.7
> Any help is appreciated.
> Thanks a lot.
> Bayardo
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)