poppler issueshttps://gitlab.freedesktop.org/poppler/poppler/-/issues2019-12-09T23:52:17Zhttps://gitlab.freedesktop.org/poppler/poppler/-/issues/8300.83.0: cmake fails2019-12-09T23:52:17ZTomasz Kłoczko0.83.0: cmake fails<pre>+ /usr/bin/cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_AR=/usr/bin/gcc-ar -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_Fortran_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_NM=/usr/bin/gcc-nm -DC...<pre>+ /usr/bin/cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_AR=/usr/bin/gcc-ar -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_Fortran_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_NM=/usr/bin/gcc-nm -DCMAKE_RANLIB=/usr/bin/gcc-ranlib -DCMAKE_VERBOSE_MAKEFILE=ON -DINCLUDE_INSTALL_DIR=/usr/include -DLIB_INSTALL_DIR=/usr/lib64 -DLIB_SUFFIX=64 -DSHARE_INSTALL_PREFIX=/usr/share -DSYSCONF_INSTALL_DIR=/etc . -Bx86_64-redhat-linux-gnu -DENABLE_CMS=lcms2 -DENABLE_DCTDECODER=libjpeg -DENABLE_GTK_DOC=ON -DENABLE_LIBOPENJPEG=openjpeg2 -DENABLE_UNSTABLE_API_ABI_HEADERS=ON -DENABLE_ZLIB=OFF -DTEST_BIG_ENDIAN=OFF
-- The C compiler identification is GNU 9.2.1
-- The CXX compiler identification is GNU 9.2.1
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/g++
-- Check for working CXX compiler: /usr/bin/g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test GCC_HAS_AS_NEEDED
-- Performing Test GCC_HAS_AS_NEEDED - Success
-- Found PkgConfig: /usr/bin/pkg-config (found version "1.6.3")
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Check if compiler accepts -pthread
-- Check if compiler accepts -pthread - no
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Check if the system is big endian
-- Searching 16 bit integer
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of unsigned short
-- Check size of unsigned short - failed
-- Check size of unsigned int
-- Check size of unsigned int - failed
-- Check size of unsigned long
-- Check size of unsigned long - failed
CMake Error at /usr/share/cmake/Modules/TestBigEndian.cmake:50 (message):
no suitable type found
Call Stack (most recent call first):
CMakeLists.txt:21 (test_big_endian)
-- Configuring incomplete, errors occurred!
See also "/home/tkloczko/rpmbuild/BUILD/poppler-0.81.0/x86_64-redhat-linux-gnu/CMakeFiles/CMakeOutput.log".
See also "/home/tkloczko/rpmbuild/BUILD/poppler-0.81.0/x86_64-redhat-linux-gnu/CMakeFiles/CMakeError.log".
error: Bad exit status from /var/tmp/rpm-tmp.QOZXAF (%build)
</pre>https://gitlab.freedesktop.org/poppler/poppler/-/issues/848Glyph not displayed using Arthur backend in Windows2019-12-06T14:56:09ZJörg HoffmannGlyph not displayed using Arthur backend in WindowsI've build a poppler-qt5.dll for windows and used it in frescobaldi. Using the splash backend, everything is fine, but when switching over to Arthur, the glyphs are missing.
The PDF: [Untitled.pdf](/uploads/ddf4df599904a35a5036a85b05656...I've build a poppler-qt5.dll for windows and used it in frescobaldi. Using the splash backend, everything is fine, but when switching over to Arthur, the glyphs are missing.
The PDF: [Untitled.pdf](/uploads/ddf4df599904a35a5036a85b0565650c/Untitled.pdf)
Result with splash:
![Splash_](/uploads/943466bc3c8b170c40501fcdf5fc4d89/Splash_.png)
Result with Arthur:
![Arthur_](/uploads/b80cbdbf22462b87f83822a6f7495b8e/Arthur_.png)
When swithing over to Arthur these messages are issued:
```
QWindowsFontDatabase::fontEngine: Can't change family name of font
RawFont is not valid
QWindowsFontDatabase::fontEngine: Can't change family name of font
RawFont is not valid
RawFont is not valid
QWindowsFontDatabase::fontEngine: Can't change family name of font
RawFont is not valid
RawFont is not valid
RawFont is not valid
RawFont is not valid
RawFont is not valid
QWindowsFontDatabase::fontEngine: Can't change family name of font
RawFont is not valid
QWindowsFontDatabase::fontEngine: Can't change family name of font
RawFont is not valid
RawFont is not valid
RawFont is not valid
RawFont is not valid
RawFont is not valid
RawFont is not valid
RawFont is not valid
```
Did I maybe miss something when building poppler?https://gitlab.freedesktop.org/poppler/poppler/-/issues/839Annotations not shown in some other readers because we don't save appearance ...2019-11-10T20:29:39ZTobias DeimingerAnnotations not shown in some other readers because we don't save appearance streamsPDF 2.0 requires annotations to be saved along with an appearance stream (a pre-generated visual representation). This was optional in PDF 1.7. Poppler doesn't write them and also doesn't claim (yet) to produce PDF 2.0, so it's fine from...PDF 2.0 requires annotations to be saved along with an appearance stream (a pre-generated visual representation). This was optional in PDF 1.7. Poppler doesn't write them and also doesn't claim (yet) to produce PDF 2.0, so it's fine from that perspective. But a consequence in practice is that some wide spread readers like [PDF.js don't show](https://github.com/mozilla/pdf.js/issues/6810) our annotations.
To be more precise, poppler actually generates appearance streams quite well for a lot of annotations types, but it keeps them in memory and doesn't save them to the document.
This is related to
- [Okular bug 410642](https://bugs.kde.org/show_bug.cgi?id=410642)
- [Okular bug 413819](https://bugs.kde.org/show_bug.cgi?id=413819)
- #522, it is/was about generating in-memory appearance streams so that poppler can render `/AP`-less annotations. #839 is about saving those in-memory appearances back into the file so that other readers are unburdened from generating their own in-memory `/AP`.https://gitlab.freedesktop.org/poppler/poppler/-/issues/776pdfinfo sends arbitrary bytes to stdout2019-10-20T20:58:58ZDaniel Kahn Gillmorpdfinfo sends arbitrary bytes to stdoutI've found a pdf file whose "producer" string has an embedded NUL byte in it. running `pdfinfo` on it sends the NUL byte to stdout.
This suggested to me that a suitably nasty PDF document can emit terminal escape sequences, which is po...I've found a pdf file whose "producer" string has an embedded NUL byte in it. running `pdfinfo` on it sends the NUL byte to stdout.
This suggested to me that a suitably nasty PDF document can emit terminal escape sequences, which is potentially a security vulnerability (e.g. similar to [CVE-2009-4487](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2009-4487)).
[x.pdf](/uploads/3ff44aeda3195a206e3fa93313342b1f/x.pdf) is a relatively benign PDF that demonstrates some of this. It will set the window title, add a fake `Subject:` line (via an injected `\n`), set some colors, and add some blinking text if you run `pdfinfo x.pdf`. I have not tried to weaponize it, but i don't think it would be hard to do, if `pdfinfo` is run in a vulnerable terminal. (see the `console_codes(4)` manpage to read up on the range of things that terminal escape sequences can do in some contexts)
Interestingly, an embedded NUL bytes makes it so that a typical `pdfinfo | grep` pipeline fails, because grep says `Binary file (standard input) matches`. So even if it were safe (it's not, because the ability to inject newlines screws up `pdfinfo`'s structured output), you'd have to use `grep -a` to force grep to consider it not a binary file.
pdfinfo should probably try to render any document-supplied text more carefully.https://gitlab.freedesktop.org/poppler/poppler/-/issues/829pdffonts: long font names break fixed-width output2019-10-15T22:42:13Ztamunropdffonts: long font names break fixed-width outputIn ~pdffonts 0.80.0, fonts with long names break the fixed-width table format of the output. Here are examples from the attached file,
[Font_problems.pdf](/uploads/bf3d5e0b05d8211469274543a219a32d/Font_problems.pdf)
```
name ...In ~pdffonts 0.80.0, fonts with long names break the fixed-width table format of the output. Here are examples from the attached file,
[Font_problems.pdf](/uploads/bf3d5e0b05d8211469274543a219a32d/Font_problems.pdf)
```
name type encoding emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
MHAFVK+Times#20New#20Roman TrueType WinAnsi yes yes no 103 0
BMPSSD+Times#20New#20Roman,BoldItalic TrueType WinAnsi yes yes no 105 0
GXZEYL+Times#20New#20Roman,Bold_00 TrueType Custom yes yes no 108 0
WLZFBK+Times#20New#20Roman,Bold_0 TrueType WinAnsi yes yes no 110 0
GXZEYL+Times#20New#20Roman,BoldItalic_1_00 TrueType Custom yes yes no 112 0
LOMNPV+Times#20New#20Roman,Italic TrueType WinAnsi yes yes no 114 0
RXNFTE+Times#20New#20Roman_2_00 TrueType Custom yes yes no 117 0
QWBTND+Symbol_00 TrueType Custom yes yes no 120 0
AQAEUC+Times#20New#20Roman,Italic_3_01 TrueType Custom yes yes no 123 0
#cb#ce#cc#e5-GBK-EUC-H-Identity-H-Identity-H CID Type 0C Identity-H yes no no 59 0
CLIMBI+TimesNewRomanPSMT Type 1C Custom yes yes yes 54 0
CLIMDK+TimesNewRomanPS-BoldItalicMT Type 1C Custom yes yes yes 52 0
CLIMDL+Times#20New#20Roman Type 1C Custom yes yes yes 56 0
CLIMCI+TimesNewRomanPS-BoldMT Type 1C Custom yes yes yes 63 0
CLIMEL+TimesNewRomanPS-ItalicMT Type 1C Custom yes yes yes 60 0
MS#20Mincho-90ms-RKSJ-H-Identity-H-Identity-H CID Type 0C Identity-H yes no no 66 0
```
This introduces errors when importing into a spreadsheet. I've tried replacing spaces with tabs using regular expressions, but some font types and names contain spaces, so that introduces other errors. A simple fix for this could be to widen the name column by 20 characters, at least as an option. More elaborate, but probably more robust and useful, would be to offer tab-separated output as an option.https://gitlab.freedesktop.org/poppler/poppler/-/issues/828Support addition of revisions ("replies") to annotations with Qt5 bindings2019-10-15T22:39:25ZHugo DammeSupport addition of revisions ("replies") to annotations with Qt5 bindingsThe current Qt5 binding allows to retrieve the replies to a text/highlight annotation by using the revisions() method.
However, there is no method to allow adding new revisions to an annotation.
A service could be provided to add either...The current Qt5 binding allows to retrieve the replies to a text/highlight annotation by using the revisions() method.
However, there is no method to allow adding new revisions to an annotation.
A service could be provided to add either 1 annotation to the revision list, such as addRevision(const Annotation *), or a list of revisions addRevisions(const QVector<const Annotation *> &).https://gitlab.freedesktop.org/poppler/poppler/-/issues/290printing entries from the Viewer Preferences dictionary2019-10-14T20:55:25ZBugzilla Migration Userprinting entries from the Viewer Preferences dictionary## Submitted by Pablo Rodríguez `@ousia`
Assigned to **poppler-bugs**
**[Link to original bug (#92779)](https://bugs.freedesktop.org/show_bug.cgi?id=92779)**
## Description
Pages 364 and 365 from the PDF specification
(https://www...## Submitted by Pablo Rodríguez `@ousia`
Assigned to **poppler-bugs**
**[Link to original bug (#92779)](https://bugs.freedesktop.org/show_bug.cgi?id=92779)**
## Description
Pages 364 and 365 from the PDF specification
(https://wwwimages2.adobe.com/content/dam/Adobe/en/devnet/pdf/pdfs/PDF32000_2008.pdf#page=364)
contain some entries in the viewer dictonary that set up printing
options from the PDF file itself.
The main entries and their values are:
/PrintScaling /AppDefault or /None.
/Duplex /Simplex (required when printer’s default is double-sided
/DuplexFlipShortEdge (double-sided for landscape)
/DuplexFlipLongEdge (double-sided for portrait)
/PickTrayByPDFSize boolean (evince implements it as "Select page size using document page size)
/NumCopies integer (the specification points the number allowed in the printing dialog, but Adobe allows up to 5).
evince enables all these features in the printing dialog. But it cannot read them from the PDF file.
Could you implement them in poppler?https://gitlab.freedesktop.org/poppler/poppler/-/issues/730recursive function call in function JBIG2Stream::readGenericBitmap()2019-09-20T22:08:03ZLoginsoftrecursive function call in function JBIG2Stream::readGenericBitmap()**What is vulnerability** - During our research there is a recursive function call in function JBIG2Stream::readGenericBitmap() located at JBIG2Stream.cc in poppler 0.74.0.
**Command**- : pdfseperate -f 1 -l 2 $POC res-%d.pdf
**POC**- ...**What is vulnerability** - During our research there is a recursive function call in function JBIG2Stream::readGenericBitmap() located at JBIG2Stream.cc in poppler 0.74.0.
**Command**- : pdfseperate -f 1 -l 2 $POC res-%d.pdf
**POC**- [REPRODUCER](https://github.com/SegfaultMasters/covering360/blob/master/poppler/URL7_POC?raw=true)
**Debug** -
**GDB** -
```
[ Legend: Modified register | Code | Heap | Stack | String ]
───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ registers ]────
$rax : 0x1
$rbx : 0x11
$rcx : 0x619000001500 → 0x004e00330038003d ("="?)
$rdx : 0x0
$rsp : 0x7fffffffb858 → 0x00007ffff6731a83 → <JBIG2Stream::readGenericBitmap(bool,+0> mov DWORD PTR [rbp-0x104], eax
$rbp : 0x7fffffffba10 → 0x00007fffffffbf90 → 0x00007fffffffc1d0 → 0x00007fffffffc200 → 0x00007fffffffc520 → 0x00007fffffffc780 → 0x00007fffffffc910 → 0x00007fffffffca20
$rsi : 0x7
$rdi : 0x2
$rip : 0x7ffff6716411 → <JArithmeticDecoder::decodeBit(unsigned+0> ret
$r8 : 0x5b
$r9 : 0x10007d307e93 → 0xfafafafafafafa02
$r10 : 0x4032
$r11 : 0x202
$r12 : 0x7fffffffb980 → 0x0000000041b58ab3
$r13 : 0xffffffff730 → 0x0000000000000000
$r14 : 0x7fffe97eb800 → 0xffffffffffffffff
$r15 : 0x7fffffffb980 → 0x0000000041b58ab3
$eflags: [zero carry PARITY adjust SIGN trap INTERRUPT direction overflow resume virtualx86 identification]
$ss: 0x002b $fs: 0x0000 $es: 0x0000 $cs: 0x0033 $gs: 0x0000 $ds: 0x0000
───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ stack ]────
0x00007fffffffb858│+0x00: 0x00007ffff6731a83 → <JBIG2Stream::readGenericBitmap(bool,+0> mov DWORD PTR [rbp-0x104], eax ← $rsp
0x00007fffffffb860│+0x08: 0x0000000000000000
0x00007fffffffb868│+0x10: 0x00007fffffffbf20 → 0x00000000ffffffd8 → 0x0000000000000000
0x00007fffffffb870│+0x18: 0x00007fffffffbee0 → 0x0000000000000000
0x00007fffffffb878│+0x20: 0x0000000000000000
0x00007fffffffb880│+0x28: 0x0000000000000000
0x00007fffffffb888│+0x30: 0x0000001700000002 → 0x0000000000000000
0x00007fffffffb890│+0x38: 0x0000000000033676
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ code:i386:x86-64 ]────
0x7ffff6716408 <JArithmeticDecoder::decodeBit(unsigned+0> jmp 0x7ffff67162df <JArithmeticDecoder::decodeBit(unsigned int, JArithmeticDecoderStats*)+2579>
0x7ffff671640d <JArithmeticDecoder::decodeBit(unsigned+0> mov eax, DWORD PTR [rbp-0x10]
0x7ffff6716410 <JArithmeticDecoder::decodeBit(unsigned+0> leave
→ 0x7ffff6716411 <JArithmeticDecoder::decodeBit(unsigned+0> ret
↳ 0x7ffff6731a83 <JBIG2Stream::readGenericBitmap(bool,+0> mov DWORD PTR [rbp-0x104], eax
0x7ffff6731a89 <JBIG2Stream::readGenericBitmap(bool,+0> cmp DWORD PTR [rbp-0x104], 0x0
0x7ffff6731a90 <JBIG2Stream::readGenericBitmap(bool,+0> setne al
0x7ffff6731a93 <JBIG2Stream::readGenericBitmap(bool,+0> test al, al
0x7ffff6731a95 <JBIG2Stream::readGenericBitmap(bool,+0> je 0x7ffff6731b48 <JBIG2Stream::readGenericBitmap(bool, int, int, int, bool, bool, JBIG2Bitmap*, int*, int*, int)+21084>
0x7ffff6731a9b <JBIG2Stream::readGenericBitmap(bool,+0> mov rax, QWORD PTR [rbp-0xd0]
──────────────────────────────────────────────────────────────────────────────────────────────────────────────[ source:/home/aceteam/Desktop/packages/poppler-master/poppler/JArithmeticDecoder.cc+230 ]────
225 c <<= 1;
226 --ct;
227 } while (!(a & 0x80000000));
228 }
229 return bit;
→ 230 }
231
232 int JArithmeticDecoder::decodeByte(unsigned int context,
233 JArithmeticDecoderStats *stats) {
234 int byte;
235 int i;
─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ threads ]────
[#0] Id 1, Name: "pdfseparate", stopped, reason: SIGINT
───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ trace ]────
[#0] 0x7ffff6716411 → Name: JArithmeticDecoder::decodeBit(this=0x604000001a50, context=0xaa, stats=0x602000024bb0)
[#1] 0x7ffff6731a83 → Name: JBIG2Stream::readGenericBitmap(this=0x612000000340, mmr=0x0, w=0x33676, h=0x17, templ=0x2, tpgdOn=0x0, useSkip=0x0, skip=0x0, atx=0x7fffffffbee0, aty=0x7fffffffbf20, mmrDataLength=0x0)
[#2] 0x7ffff6722b0f → Name: JBIG2Stream::readSymbolDictSeg(this=0x612000000340, segNum=0x686c73ac, length=0x7f41d7d0, refSegs=0x0, nRefSegs=0x0)
[#3] 0x7ffff671f5a2 → Name: JBIG2Stream::readSegments(this=0x612000000340)
[#4] 0x7ffff671e351 → Name: JBIG2Stream::reset(this=0x612000000340)
[#5] 0x7ffff68295a5 → Name: XRef::readXRefStream(this=0x6120000001c0, xrefStr=0x612000000340, pos=0x612000000278)
[#6] 0x7ffff68273d3 → Name: XRef::readXRef(this=0x6120000001c0, pos=0x612000000278, followedXRefStm=0x7fffffffc8a0, xrefStreamObjsNum=0x0)
[#7] 0x7ffff6824ab8 → Name: XRef::XRef(this=0x6120000001c0, strA=0x613000000040, pos=0x74, mainXRefEntriesOffsetA=0x0, wasReconstructed=0x7fffffffc970, reconstruct=0x0)
[#8] 0x7ffff676aba3 → Name: PDFDoc::setup(this=0x610000000040, ownerPassword=0x0, userPassword=0x0)
[#9] 0x7ffff676a492 → Name: PDFDoc::PDFDoc(this=0x610000000040, fileNameA=0x60300000e020, ownerPassword=0x0, userPassword=0x0, guiDataA=0x0)
```https://gitlab.freedesktop.org/poppler/poppler/-/issues/786TextOutputDev neglects the translation in the FontMatrix of type3 fonts2019-08-16T18:17:10ZsgerwkTextOutputDev neglects the translation in the FontMatrix of type3 fontsThe enclosed file uses the type3 font in the PDF spec changed by adding an x translation in the font matrix.
[type3.pdf](/uploads/f4a803c61d21e1aa16c903a81e819a92/type3.pdf)
Drawing the rectangles in the text layout atop of it produces...The enclosed file uses the type3 font in the PDF spec changed by adding an x translation in the font matrix.
[type3.pdf](/uploads/f4a803c61d21e1aa16c903a81e819a92/type3.pdf)
Drawing the rectangles in the text layout atop of it produces this:
[type3-boxes.pdf](/uploads/c57a666dcb1a249ca45c79d681e433bf/type3-boxes.pdf)
I grant that fonts with a translation in the font matrix are uncommon, yet the spec seems to allow them. Otherwise, the characters are placed incorrectly.https://gitlab.freedesktop.org/poppler/poppler/-/issues/364Arabic text in pdf forms cannot be saved or printed2019-08-05T19:51:12ZBugzilla Migration UserArabic text in pdf forms cannot be saved or printed## Submitted by Munzir Taha
Assigned to **poppler-bugs**
**[Link to original bug (#42944)](https://bugs.freedesktop.org/show_bug.cgi?id=42944)**
## Description
I can type Arabic in any pdf form fields but when trying to print to P...## Submitted by Munzir Taha
Assigned to **poppler-bugs**
**[Link to original bug (#42944)](https://bugs.freedesktop.org/show_bug.cgi?id=42944)**
## Description
I can type Arabic in any pdf form fields but when trying to print to PDF to save it or to a printer, Arabic text doesn't show!
You can test with:
http://launchpadlibrarian.net/11456651/f1040nre-2007.pdfhttps://gitlab.freedesktop.org/poppler/poppler/-/issues/810pdftocairo -paper crop2019-07-27T16:19:32Zvstepaniukpdftocairo -paper crop```
-paper size
Set the paper size to one of "letter", "legal", "A4", or "A3" (PS,PDF,SVG only). This can also be set to "match", which will set
the paper size of each page to match the size specifi...```
-paper size
Set the paper size to one of "letter", "legal", "A4", or "A3" (PS,PDF,SVG only). This can also be set to "match", which will set
the paper size of each page to match the size specified in the PDF file. If none the -paper, -paperw, or -paperh options are speci‐
fied the default is to match the paper size.
```
I suggest to add a `crop` value to the `pdftocairo -paper` option to mean the crop area dimensions, specified by the `-W` and `-H` options.https://gitlab.freedesktop.org/poppler/poppler/-/issues/807Font rendering issue unrelated to substituted fonts2019-07-24T22:59:14ZKrešimir ČoharFont rendering issue unrelated to substituted fontsHey guys, so we noticed something that might be a poppler (cairo) issue in https://gitlab.gnome.org/GNOME/evince/issues/1221
See "st udents" and "n ew" in Evince (left) vs Chromium (right, students and new, respectively):
![image](/upl...Hey guys, so we noticed something that might be a poppler (cairo) issue in https://gitlab.gnome.org/GNOME/evince/issues/1221
See "st udents" and "n ew" in Evince (left) vs Chromium (right, students and new, respectively):
![image](/uploads/ea37bb8d47c9b7832c0ca04906c8b7e1/image.png)
Using pdftocairo, this happens:
![image](/uploads/8db6e47fb9dc05961e445cc5787ca503/image.png)
So, while Evince's font smoothing exacerbates the problem, it doesn't seem to be the root cause of it.
The fonts in this PDF aren't substituted but embedded.
Is this fixable?
(Running Ubuntu 19.04, GNOME 3.32.1, Evince 3.32.0)https://gitlab.freedesktop.org/poppler/poppler/-/issues/785MacOS Mojave: pdftoppm removes bold fonts2019-06-27T20:50:05Zlaub blattMacOS Mojave: pdftoppm removes bold fontsI generate pdf files with R and then convert these into png.
Unfortunately the bold fonts (Helvetica-Bold) are not rendered and some other font is shown.
Conversion with Preview: everything looks good:
![testigureR_boldfont](/uploads/e...I generate pdf files with R and then convert these into png.
Unfortunately the bold fonts (Helvetica-Bold) are not rendered and some other font is shown.
Conversion with Preview: everything looks good:
![testigureR_boldfont](/uploads/ea6dfd97cb6c2247cc163ada63a47eb0/testigureR_boldfont.png)
Conversion with pdftoppm
`pdftoppm -singlefile -rx 100 -ry 100 -png testigureR_boldfont.pdf testigureR_boldfont.pdf`
![testigureR_boldfont.pdf](/uploads/136a4c2952198478458d2cb0cc45ceea/testigureR_boldfont.pdf.png)
pdftoppm version 0.77.0
On the most recent MacOS I installed poppler
brew upgrade poppler
On another machine with macOS 10.12 everythings is ok.
**Any suggestions why this happens and how to resolve this are welcome!**https://gitlab.freedesktop.org/poppler/poppler/-/issues/783Evince and other Poppler apps have trouble loading POPPLER_ANNOT_POLY_LINE fr...2019-06-26T19:49:32ZanarcatEvince and other Poppler apps have trouble loading POPPLER_ANNOT_POLY_LINE from Onyx Boox annotationsThis is a [bug that was originally submitted against Evince](https://gitlab.gnome.org/GNOME/evince/issues/1195) but that, after further inspection, affects other Poppler-related PDF readers.
The following PDF:
[about_empty-Exported.pdf...This is a [bug that was originally submitted against Evince](https://gitlab.gnome.org/GNOME/evince/issues/1195) but that, after further inspection, affects other Poppler-related PDF readers.
The following PDF:
[about_empty-Exported.pdf](/uploads/851e8812521859e4317a83c5c902e680/about_empty-Exported.pdf)
Was created from the following:
[about_empty.pdf](/uploads/2fe4a19aff752ee3dece9fd440c29222/about_empty.pdf)
to which was added the following text, in the appropriate tool, on a Onyx Boox Note Pro ebook reader:
```
light pen (2)
thick pen (10)
really thick pen (20)
pencil (light, thick, really)
line: [drawing of a line using the line tool]
square: [drawing of a square]
circle: [drawing of a circle]
triangle: [drawing of a triangle]
colors: [black scribbled square] black
[ ] red
[ ] green
[ ] blue
[ ] white <---- white
```
* The `pen` lines are drawn with the "pen" tool (or "brush"?) with varying intensity. The "really thick" is picked by manually selecting weight "20" that is not available by just choosing the presets.
* The `pencil` lines, and all remaining text, are drawn with the "pencil" tool (the one right of the "pen"), with varying intensity, similarly to the pen tool
* The line, square, circle and triangles have samples of those geometric shapes that can be created with the scribbling app
* the colors are all drawn with the pencil as well, and presumably affect other tools similarly.
This should give us a good basis covering almost all combinations. I think the only ones not covered are the colored pen and drawing tools, but i'd be suprised if they don't work right if they're black relatives do.
This is how it should render:
![image](/uploads/6023b11037c9d1199fbeabecf05bb424/image.png)
This is how it actually renders:
![image](/uploads/f97fea682771877f5f7c99ad334bcb3f/image.png)
Ie. the "brush" strokes do not render correctly. In Evince, we get the error:
```
** (evince:15296): WARNING **: 12:33:56.566: Unimplemented annotation: POPPLER_ANNOT_POLY_LINE, please post a bug report in Evince issue tracker (https://gitlab.gnome.org/GNOME/evince/issues) with a testcase.
```https://gitlab.freedesktop.org/poppler/poppler/-/issues/778Different behavior in Poppler when font is not found on FormFieldText2019-06-25T22:24:32ZEmil SedghDifferent behavior in Poppler when font is not found on FormFieldTextI have some PDF's (with form annotations) that when are written by Poppler (Okular, or any other) look different
than other editors (Tried Master PDF and Chrome so far).
I investigated and here are the findings:
Imagine a scenario wher...I have some PDF's (with form annotations) that when are written by Poppler (Okular, or any other) look different
than other editors (Tried Master PDF and Chrome so far).
I investigated and here are the findings:
Imagine a scenario where there is a:
* `FormFieldText` with `da = /Arial 10`
* `Form` with `da = /Helv 0`
Poppler tries to locate `Arial` font.
If failed, it will rely on Form's `da`, which is `/Helv 0`
Since the font size on `Form` is `0`, the text appears too big (As 0 means automatic sizing)
although the field is set to have size 10.
It seems that other generators will switch to Helv for font, but keep the font size as defined on field.https://gitlab.freedesktop.org/poppler/poppler/-/issues/775layout of graphics in the page2019-06-04T12:11:19Zsgerwklayout of graphics in the pageCurrently, poppler-glib only provides the layout of text (poppler_page_get_text_layout), images (poppler_page_get_image_mapping), etc. As far as I can see, there is currently no way to detect the position of graphics in the page, the kin...Currently, poppler-glib only provides the layout of text (poppler_page_get_text_layout), images (poppler_page_get_image_mapping), etc. As far as I can see, there is currently no way to detect the position of graphics in the page, the kind drawn by commands like m, l, v, etc.
For example, the box is not an image in the enclosed file. More generally, it seems not possible to detect the position of a diagram made of lines, rectangles, Bezier curves, etc.
[noimages.pdf](/uploads/c5611338f3c920d2b604256cf1e0a728/noimages.pdf)https://gitlab.freedesktop.org/poppler/poppler/-/issues/636Doesn't reproduce spacing between letters properly2019-05-28T21:40:31Zyuri@FreeBSDDoesn't reproduce spacing between letters properlyTestcase: download the pdf from here ("save" function): http://sci-hub.tw/10.1021/cr980401l#
Please observe how these letter combinations have too small space, and run on each other: "ch", "es", "ea".
The chrome browser doesn't have th...Testcase: download the pdf from here ("save" function): http://sci-hub.tw/10.1021/cr980401l#
Please observe how these letter combinations have too small space, and run on each other: "ch", "es", "ea".
The chrome browser doesn't have this problem.
OS: FreeBSD 11.2
poppler-0.57.0_1
Okular version: 1.5.0
The original okular bug report: https://bugs.kde.org/show_bug.cgi?id=397902https://gitlab.freedesktop.org/poppler/poppler/-/issues/773Missing text in PDF2019-05-27T22:43:35ZBastien NoceraMissing text in PDFThe PDF at https://panda-bg.com/datasheet/1582-256001-Illuminated-Push-Button-Switch-M12-LAS2-series.pdf shows text correctly in Firefox's PDF.js viewer, but not in the poppler-powered evince or GIMP.
Using `poppler-0.73.0-9.fc30.x86_64...The PDF at https://panda-bg.com/datasheet/1582-256001-Illuminated-Push-Button-Switch-M12-LAS2-series.pdf shows text correctly in Firefox's PDF.js viewer, but not in the poppler-powered evince or GIMP.
Using `poppler-0.73.0-9.fc30.x86_64`
Test file:
[1582-256001-Illuminated-Push-Button-Switch-M12-LAS2-series.pdf](/uploads/a64ba19444a8209fe7f248703c48a269/1582-256001-Illuminated-Push-Button-Switch-M12-LAS2-series.pdf)
Screenshot:
![pdf-comparison](/uploads/b6674ca653438aebddcfe7865bf63fc3/pdf-comparison.png)https://gitlab.freedesktop.org/poppler/poppler/-/issues/448poppler-glib: poppler_document_new_from_data() receives data as UTF-8 string ...2019-05-27T13:04:49ZBugzilla Migration Userpoppler-glib: poppler_document_new_from_data() receives data as UTF-8 string not binary## Submitted by okimoto
Assigned to **poppler-bugs**
**[Link to original bug (#104961)](https://bugs.freedesktop.org/show_bug.cgi?id=104961)**
## Description
Created attachment 137181
Add type annotation to poppler_document_new_fr...## Submitted by okimoto
Assigned to **poppler-bugs**
**[Link to original bug (#104961)](https://bugs.freedesktop.org/show_bug.cgi?id=104961)**
## Description
Created attachment 137181
Add type annotation to poppler_document_new_from_data()
In Poppler-0.18.gir poppler_document_new_from_data() is defined as following:
<constructor name="new_from_data"
c:identifier="poppler_document_new_from_data"
throws="1">
<doc xml:space="preserve">Creates a new #PopplerDocument. If %NULL is returned, then @error will be
set. Possible errors include those in the #POPPLER_ERROR and #G_FILE_ERROR
domains.`</doc>`
`<return-value transfer-ownership="full">`
<doc xml:space="preserve">A newly created #PopplerDocument, or %NULL`</doc>`
<type name="Document" c:type="PopplerDocument*"/>
`</return-value>`
`<parameters>`
`<parameter name="data" transfer-ownership="none">`
<doc xml:space="preserve">the pdf data contained in a char array`</doc>`
<type name="utf8" c:type="char*"/>
`</parameter>`
`<parameter name="length" transfer-ownership="none">`
<doc xml:space="preserve">the length of #data`</doc>`
<type name="gint" c:type="int"/>
`</parameter>`
<parameter name="password"
transfer-ownership="none"
nullable="1"
allow-none="1">
<doc xml:space="preserve">password to unlock the file with, or %NULL`</doc>`
<type name="utf8" c:type="const char*"/>
`</parameter>`
`</parameters>`
`</constructor>`
This definition validates data as UTF-8 string when read a PDF data using poppler_document_new_from_data() via gobject-introspection.
In general, PDF data is not UTF-8 string. So we should treat parameter data as binary.
I wrote tiny patch and confirm that the poppler_document_new_from_data() definition is updated after applied this patch.
However, I'm not familiar with gobject-introspection in honest.
**Patch 137181**, "Add type annotation to poppler_document_new_from_data()":
[add-type-annotation-to-poppler_document_new_from_data.diff](/uploads/fe45b6ab71ae1ee2b59848af99aa4f74/add-type-annotation-to-poppler_document_new_from_data.diff)https://gitlab.freedesktop.org/poppler/poppler/-/issues/770Watermark removal breaks PDF rendering in poppler2019-05-27T09:36:07ZbaerbockWatermark removal breaks PDF rendering in popplerI've removed the watermark from [this book PDF](https://www.peterlang.com/downloadpdf/title/17680.pdf) with a [script/PDFtk](https://github.com/agarden/remove-pdf-watermark/blob/master/removewatermark).
poppler renders the [resulting PD...I've removed the watermark from [this book PDF](https://www.peterlang.com/downloadpdf/title/17680.pdf) with a [script/PDFtk](https://github.com/agarden/remove-pdf-watermark/blob/master/removewatermark).
poppler renders the [resulting PDF](https://github.com/agarden/remove-pdf-watermark/files/3217023/x.scrubbed.pdf) only as white pages. Mupdf however is rendering correctly.