Index ¦ Archives ¦ RSS

Shadow for tables from PPTX in Impress

Estimated read time: 2 minutes

Impress now has much better support for the shadow of table shapes: not only shape styles can result in table shadows, but it’s also possible to add this as direct formatting. Also the shadow result is PowerPoint-compatible in the direct formatting case.

First, thanks to our partner SUSE for working with Collabora to make this possible.

Motivation

We got a PPTX document, which has a table shape with blurry shadow. The shadow was completely missing in Impress. It was discovered that in case you configure the default shape style to have shadow, then there is some initial table shadow support in Impress, but that was not used in the PPTX case.

The request was to improve the shadow rendering to be PowerPoint-compatible and in general support table shadows as direct formatting as a new feature.

Results so far

The table shadow now looks like this:

https://share.vmiklos.hu/blog/sd-table-shadow/new.png
Figure 1. New render result in Impress

Matching the reference rendering:

https://share.vmiklos.hu/blog/sd-table-shadow/ref.png
Figure 2. Reference render result

While shadow was just missing previously:

https://share.vmiklos.hu/blog/sd-table-shadow/old.png
Figure 3. Old render result in Impress

You can see that not only the shadow is there, but also the cell backgrounds and the blurry shadow is rendered properly.

How is this implemented?

If you would like to know a bit more about how this works, continue reading… :-)

As usual, the high-level problem was addressed by a series of small fixes:

With these, it’s now possible to add, edit, render and delete these table shadows, while preserving them during ODP and PPTX import/export.

Want to start using this?

You can get a snapshot / demo of Collabora Office and try it out yourself right now: try unstable snapshot. Collabora intends to continue supporting and contributing to LibreOffice, the code is merged so we expect all of this work will be available in TDF’s next release too (7.2).

© Miklos Vajna. Built using Pelican. Theme by Giulio Fidente on github.