Index ¦ Archives ¦ RSS

My hack week at Collabora: improvements to gutter margin in Writer

Estimated read time: 3 minutes

As mentioned in a previous such report, a hack week is when we are allowed to hack on anything we want in LibreOffice / Collabora Office / Collabora Online for a few days at Collabora. I used this time to implement core support for RTL gutter margin in Writer.

Motivation

I posted about Writer gutter margin in general back in February, and two follow-up requests accumulated around this new feature since then.

First, the gutter margin could be on the left or at the top for non-mirrored documents, which initially sounded like a complete solution, but later it turned out that right-to-left (RTL) documents want it on the right.

Second, there was a request from the OASIS TC to to implement the ODF filter differently for gutter margin.

Neither of these is simple to do, so this hackweek was a good opportunity to address these problems.

Results so far

Here is the layout and user interface for RTL gutter looks like:

https://share.vmiklos.hu/blog/hackweek-2021/layout-ui.png
Figure 1. RTL gutter margin in Writer, layout and UI

You can see how the gutter is on the right (not the left) and you can alter this behavior with a dedicated checkbox on the UI.

How is this implemented?

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

Finally I had a little bit of remaining time, so I addressed a request from the OASIS ODF TC:

Want to start using this?

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 (7.2).

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