Bug 122436 - Writer can't display or export eps with preview correctly
Summary: Writer can't display or export eps with preview correctly
Status: RESOLVED NOTOURBUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.3 all versions
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Images-EPS
  Show dependency treegraph
 
Reported: 2019-01-03 01:02 UTC by medmedin2014
Modified: 2021-05-23 18:07 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments
eps file ugly in writer (149.29 KB, image/png)
2019-01-03 01:07 UTC, medmedin2014
Details
EPS bug in Writer (23.07 KB, application/x-xz)
2019-02-08 11:34 UTC, medmedin2014
Details
EPS bug inside Writer 6.3 dev (195.34 KB, image/png)
2019-02-28 16:16 UTC, medmedin2014
Details
I can't reproduce it in LibreOffice 6.3 master gtk3 (121.24 KB, image/png)
2019-04-03 14:13 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description medmedin2014 2019-01-03 01:02:59 UTC
Description:
I import some eps created by geogebra, but they are not displayed correctly. I found that eps without preview can be displayed and exported to pdf correctly but the ones with preview are badly displayed and looks ugly.

Steps to Reproduce:
1.Open Writer
2.Insert eps image
3.Export to pdf

Actual Results:
eps is displayed ugly inside Writer, and also inside exported pdf.

Expected Results:
eps should be displayed and exported correctly.


Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 medmedin2014 2019-01-03 01:07:55 UTC
Created attachment 147958 [details]
eps file ugly in writer
Comment 2 Xisco Faulí 2019-02-07 16:23:20 UTC
Thank you for reporting the bug. Please attach a sample document, as this makes it easier for us to verify the bug. 
(Please note that the attachment will be public, remove any sensitive information before attaching it. 
See https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F for help on how to do so.)

I have set the bug's status to 'NEEDINFO'. Please change it back to 'UNCONFIRMED' once the requested document is provided.
Comment 3 medmedin2014 2019-02-08 11:33:30 UTC
(In reply to Xisco Faulí from comment #2)
> Thank you for reporting the bug. Please attach a sample document, as this
> makes it easier for us to verify the bug. 
> (Please note that the attachment will be public, remove any sensitive
> information before attaching it. 
> See
> https://wiki.documentfoundation.org/QA/
> FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F for help
> on how to do so.)
> 
> I have set the bug's status to 'NEEDINFO'. Please change it back to
> 'UNCONFIRMED' once the requested document is provided.

I attached an eps simple figure generated using Geogebra, when I open the figure in Writer it's not displayed correctly, and also when exported to pdf it's not exported correctly.
But when imported into Inkscape it's displayed correctly and also the generated pdf displays the figure correctly.
In the zipped file you will find the eps + Writer file + generated pdf.
Comment 4 medmedin2014 2019-02-08 11:34:00 UTC
Created attachment 149021 [details]
EPS bug in Writer
Comment 5 raal 2019-02-27 19:48:44 UTC
I can not confirm  with Version: 6.3.0.0.alpha0+
Build ID: 465939feb0e9c382e5581b53b72008979ece4807
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 

Seems to be fixed with dev version. Please could you test it with
dev version?  You can download it here:
http://dev-builds.libreoffice.org/daily/master/
Thank you
Comment 6 medmedin2014 2019-02-28 11:59:13 UTC
(In reply to raal from comment #5)
> I can not confirm  with Version: 6.3.0.0.alpha0+
> Build ID: 465939feb0e9c382e5581b53b72008979ece4807
> CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
> 
> Seems to be fixed with dev version. Please could you test it with
> dev version?  You can download it here:
> http://dev-builds.libreoffice.org/daily/master/
> Thank you

Which version should I install ? and is It safe to use it for opening my old files ? I have only one old laptop wich I use for studies so I want to be sure not installing an earlier version, because now what I have with my Ubuntu Mate 18.04.2 is just version 6.1.5.2, and I alreay use libreoffice ppa to get latest versions.
Comment 7 Dieter 2019-02-28 12:11:59 UTC
(In reply to medmedin2014 from comment #6)

> Which version should I install ? and is It safe to use it for opening my old
> files ? I have only one old laptop wich I use for studies so I want to be
> sure not installing an earlier version, because now what I have with my
> Ubuntu Mate 18.04.2 is just version 6.1.5.2, and I alreay use libreoffice
> ppa to get latest versions.

Since I'm not using Linux, I don't know what will be the right file. Sorry. But versions from master will be installes parallel, so you won't loose LO 6.1.5.2
Comment 8 raal 2019-02-28 13:22:24 UTC
Hello, for ubuntu you can use for example https://dev-builds.libreoffice.org/daily/master/Linux-rpm_deb-x86_64@86-TDF/current/

file master~2019-02-27_23.42.10_LibreOfficeDev_6.3.0.0.alpha0_Linux_x86-64_deb.tar.gz
unpack and install with sudo dpkg -i *

this master version is installed in /opt directory
Comment 9 medmedin2014 2019-02-28 16:14:37 UTC
(In reply to raal from comment #8)
> Hello, for ubuntu you can use for example
> https://dev-builds.libreoffice.org/daily/master/Linux-rpm_deb-x86_64@86-TDF/
> current/
> 
> file
> master~2019-02-27_23.42.10_LibreOfficeDev_6.3.0.0.alpha0_Linux_x86-64_deb.
> tar.gz
> unpack and install with sudo dpkg -i *
> 
> this master version is installed in /opt directory

I installed LibreOffice Dev 6.3, and the same problem is persistent. See my attached image for more information.
Comment 10 medmedin2014 2019-02-28 16:16:02 UTC
Created attachment 149658 [details]
EPS bug inside Writer 6.3 dev
Comment 11 medmedin2014 2019-02-28 17:00:47 UTC
(In reply to raal from comment #8)
> Hello, for ubuntu you can use for example
> https://dev-builds.libreoffice.org/daily/master/Linux-rpm_deb-x86_64@86-TDF/
> current/
> 
> file
> master~2019-02-27_23.42.10_LibreOfficeDev_6.3.0.0.alpha0_Linux_x86-64_deb.
> tar.gz
> unpack and install with sudo dpkg -i *
> 
> this master version is installed in /opt directory

How can I remove all the packages that was installed from DEBs folder ?
The command "dpkg --purge *" is not working and I should type manually all those 42 packages names ?
Comment 12 raal 2019-03-03 16:52:10 UTC
(In reply to medmedin2014 from comment #11)
> 
> How can I remove all the packages that was installed from DEBs folder ?
> The command "dpkg --purge *" is not working and I should type manually all
> those 42 packages names ?

sudo apt-get purge libreofficedev6.3*
Comment 13 Xisco Faulí 2019-04-03 14:13:44 UTC
Created attachment 150509 [details]
I can't reproduce it in LibreOffice 6.3 master gtk3
Comment 14 Xisco Faulí 2019-04-03 14:16:09 UTC
Reproduced in

Version: 6.3.0.0.alpha0+
Build ID: 93f1c3665fcdc31c36078f179ac37fd69d3ebb00
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

but not in

Version 4.1.0.0.alpha0+ (Build ID: efca6f15609322f62a35619619a6d5fe5c9bd5a)
Comment 15 Xisco Faulí 2019-04-03 14:17:25 UTC
Also reproduced in

Version: 5.2.0.0.alpha1+
Build ID: 5b168b3fa568e48e795234dc5fa454bf24c9805e
CPU Threads: 4; OS Version: Linux 4.15; UI Render: default; 
Locale: ca-ES (ca_ES.UTF-8)
Comment 16 V Stuart Foote 2019-10-13 19:07:20 UTC
This is not a regression, bibisect is not needed.

All issues folks are having with EPS rendering is because of the freeware pstoedit installed to their distro. And while Windows users can upgrade to use the paid pstoedit EMF plugin [1], or in general remove pstoedit from your os and to not work with EPS as vector.

Using pstoedit (without the paid EMF plugin only available for Windows builds) will render EPS vector graphcs to canvas as EMF, but pstoedit will reduce the verticies of the paths pulled from the EPS degrading the resulting EMF import. While on export of vector data back to EPS, the reduced vertices will be apparent compared to the original source EPS.

Fortunately absent the pstoedit conversion [2], the EPS images will be rendered to canvas with ghostscript [3] or Imagemagik 'convert'[4] (which depends on a configured ghostscript for ps interpretation).

Over on Inkscape, a ghostscript installation with its .\lib on syspath routes conversion to ps2pdf--and from there the PDF is rendered by cairo/popler to canvas as vector.

Folks can use ps2pdf externally to convert from EPS to EMF or even SVG, but it is fiddly.

See also bug 67464 is open enhancement to provide a LibreOffice internal support for ps/eps rendering of vector graphics. Including possibility of the same ps2pdf filter that is used on Inkscape.

=-ref-=
[1] $50US shareware fee collected at https://secure.shareit.com/shareit/product.html?productid=103496
[2] https://opengrok.libreoffice.org/xref/core/filter/source/graphicfilter/ieps/ieps.cxx?#200
[3] https://opengrok.libreoffice.org/xref/core/filter/source/graphicfilter/ieps/ieps.cxx?#370
[4] https://opengrok.libreoffice.org/xref/core/filter/source/graphicfilter/ieps/ieps.cxx?#348
Comment 17 Tomaz Vajngerl 2019-10-13 21:50:40 UTC
I think we should start to look how to deprecate EPS support in LO. Best would be to try to convert EPS graphic to PDF for existing LO documents, but otherwise remove EPS graphic as an input filter for use in LO documents. Export can still be there (for printing).  

EPS is not really even a graphic format but a Turing complete language, which had some sense in the past to have that, but nobody writes complex vector graphic as a program by hand today. So having a super complex language to interpret as a input instead of declarative set of limited instructions just doesn't make sense.

As long as we have it in LO, the user will use it. Now that LO 7.0 is getting near, it is a great opportunity to drop it.
Comment 18 Jörn Schwarz 2019-10-14 06:28:30 UTC
I completely disagree with comment 17:
For scientific purposes Libre Office needs a way to import vector graphics. eps files offer a vector format that worked perfectly up to version 4.1.6.
– svg is currently the only format for complex graphics, but it still produces considerable errors. 
- odg files cannot be linked. 
- The import of pdf files is still deficient. 
From my point of view the program code of version 4.1.6 should simply be restored.