<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Am 03.03.2012 10:43, schrieb Thomas Freitag:
<blockquote cite="mid:4F51E7D6.5010603@kabelmail.de" type="cite">Am
02.03.2012 20:14, schrieb Albert Astals Cid:
<br>
<blockquote type="cite">El Dilluns, 27 de febrer de 2012, a les
09:25:03, Thomas Freitag va escriure:
<br>
<blockquote type="cite">Am 26.02.2012 23:04, schrieb Albert
Astals Cid:
<br>
<blockquote type="cite">El Diumenge, 26 de febrer de 2012, a
les 08:44:09, Thomas Freitag va
<br>
</blockquote>
</blockquote>
escriure:
<br>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">Hi,
<br>
</blockquote>
Hi, it would be you really cool if you configured your
Visual Studio with
<br>
the poppler [crazy] indentation settings, it's getting
harder and harder
<br>
to read/diff/apply your patches :-/
<br>
</blockquote>
Sorry, I'll try. Should be only GlobalParamsWin.cc, which I
edited in
<br>
Visual Studio, isn't it?
<br>
</blockquote>
No, the other was wrong too, poppler has a very weird indenting
pattern and is
<br>
difficult to get right, it's basically 2 spaces for each
indentation but when
<br>
you have 8 spaces it gets replaced with a tab character
<br>
</blockquote>
<br>
I hope the attached patch is better. At least it fits to the head
revision.
<br>
</blockquote>
Sorry once again. Just saw that it seems to my PSPad editior, which
inserted tabs. I try to repair it just in the diff, hopefully looks
better!<br>
So try this patch.<br>
<br>
Thomas<br>
<blockquote cite="mid:4F51E7D6.5010603@kabelmail.de" type="cite">
<br>
<blockquote type="cite">
<br>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">I implemented a patch which supports
CJK fonts in the postscript output
<br>
device and on Windows platforms in general. It consists
mainly of three
<br>
parts:
<br>
<br>
1. Adapt bug fix for bug 11413 to the postscript device
<br>
2. A small bug fix when locateFont doesn't find a suitable
font and
<br>
returns a null pointer
<br>
3. CJK substitute implementation on WIndows platforms.
<br>
<br>
to 1.:
<br>
Adapting the implementation of the bug fix for splash and
cairo to the
<br>
postscript device was quite easy. But my first proofs of
the output with
<br>
ghostscript 8.71 shows some regressions where the CJK
chars have a
<br>
smaller height than the default square of the font. But
the "48" in the
<br>
output of bug-poppler11413.pdf which is set in a "normal"
font but
<br>
rotated was at the right position. Then I stepped to
ghostscript 9.04,
<br>
and now the CJK chars were shown correctly, but the 48 was
positioned
<br>
wrong. But because of these different tests I think that
it is still a
<br>
problem in ghostscript when using a mix of CJK fonts and
"normal" fonts.
<br>
BTW, also Acrobat X distiller has problems with the
position of the "48"!
<br>
</blockquote>
I understand this applies to non-windows too, right?
<br>
</blockquote>
Yes, point 1 and 2 applies to all platforms (even if 2
probably only
<br>
happens if don't using fonfconfig, so just under Windows)
<br>
</blockquote>
So what's the difference i should see when running in linux? The
outputted ps
<br>
file having a different rendering for CJK files?
<br>
</blockquote>
<br>
Yes. Do You haven't seen it or haven't tried it with
bug-poppler11413.pdf? I attach sreenshots before and after. If You
haven't seen any differences, is it possible that You haven't
installed "our" language pack, i.e. the poppler data dir isn't at
the correct place? Under windows I normally patch the allocation
of GlobalParms, i.e.
<br>
<br>
globalParams = new
GlobalParams("E:\\Downloads\\poppler\\poppler-data-0.4.5");
<br>
<br>
under unix I link it to /usr/local/share/poppler
<br>
<br>
Thomas
<br>
<blockquote type="cite">
<br>
Albert
<br>
<br>
<blockquote type="cite">Thomas
<br>
<br>
<blockquote type="cite">Albert
<br>
<br>
<blockquote type="cite">to 2.:
<br>
On my first tests with PDF which uses non embedded CJK
fonts on Windows
<br>
I got crashes. Reason for it was that GlobalParamWin
returns Helvetica,
<br>
which is not a CID font, but locateFont accepts here only
CID fonts and
<br>
therefore returns a NULL pointer. I first fixed that and
then decided to
<br>
return as default MS Mincho if a CID font is expected.
<br>
<br>
to 3.:
<br>
When You install ghostscript on WIndows You're able to
switch on CJK
<br>
support. This will create a cidfmap file in the gs-lib
directory. The
<br>
ps file which creates it (mkcidfm.ps) runs over the
windows font
<br>
directory and tries to create a suitable substitution
table for missing
<br>
CJK fonts. The cidfmap file is more or less PDF like, so
it's quite easy
<br>
to parse it with our parser and create a substitution
table in
<br>
GlobalParamsWin and use that table. But I expect it in the
poppler data
<br>
dir instead of searching for ghostscript installation. If
it is not
<br>
there, it always returns the default CID font of point 2.
<br>
You can either copy it from the gs lib directory or create
it with the
<br>
ghostscript tool calling
<br>
<br>
gswin32c -q -dBATCH -sFONTDIR=<windows font
directory>
<br>
-sCIDFMAP=<popper data dir>/cidfmap mkcidfm.ps
<br>
<br>
To clearify the format of cidfmap I attach the file
produced on my
<br>
installation. Keep care: I have not a default windows
installation with
<br>
windows on c:/windows, my windows installation is on drive
f!
<br>
<br>
Cheers,
<br>
Thomas
<br>
</blockquote>
_______________________________________________
<br>
poppler mailing list
<br>
<a class="moz-txt-link-abbreviated" href="mailto:poppler@lists.freedesktop.org">poppler@lists.freedesktop.org</a>
<br>
<a class="moz-txt-link-freetext" href="http://lists.freedesktop.org/mailman/listinfo/poppler">http://lists.freedesktop.org/mailman/listinfo/poppler</a>
<br>
<br>
.
<br>
</blockquote>
_______________________________________________
<br>
poppler mailing list
<br>
<a class="moz-txt-link-abbreviated" href="mailto:poppler@lists.freedesktop.org">poppler@lists.freedesktop.org</a>
<br>
<a class="moz-txt-link-freetext" href="http://lists.freedesktop.org/mailman/listinfo/poppler">http://lists.freedesktop.org/mailman/listinfo/poppler</a>
<br>
</blockquote>
_______________________________________________
<br>
poppler mailing list
<br>
<a class="moz-txt-link-abbreviated" href="mailto:poppler@lists.freedesktop.org">poppler@lists.freedesktop.org</a>
<br>
<a class="moz-txt-link-freetext" href="http://lists.freedesktop.org/mailman/listinfo/poppler">http://lists.freedesktop.org/mailman/listinfo/poppler</a>
<br>
<br>
.
<br>
<br>
</blockquote>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
poppler mailing list
<a class="moz-txt-link-abbreviated" href="mailto:poppler@lists.freedesktop.org">poppler@lists.freedesktop.org</a>
<a class="moz-txt-link-freetext" href="http://lists.freedesktop.org/mailman/listinfo/poppler">http://lists.freedesktop.org/mailman/listinfo/poppler</a>
</pre>
</blockquote>
<br>
</body>
</html>