Today we ship our first supported release of LibreOffice for Android and iOS phones. Of course, there is some serious engineering work under the hood there over a long period. You can read all of the nice marketing and pretty screenshots but how did this happen ?
LibreOffice & SUSE
SUSE was a foundational supporter of LibreOffice, and it was clear that smartphones were becoming a thing, and something needed to be done here. Also Apache OpenOffice was being used (without anything being contributed back) by AdrOpen Office - which looked like 'X on Android', so we needed a gap plugging solution, and fast.
Luckily a chunk of the necessary work: cross-compiling was dual-purpose. Getting to work was part of our plan inside SUSE to build our Windows LibreOffice with MINGW under SLES. That would give us a saner & more reliable, and repeatable build-system for our problem OS: Windows.
Of course we used that to target Android as well, you can see Tor's first commit. We had a very steep learning curve; imagine having to patch the ARM assembler of your system libraries to make STL work for example.
FOSDEM as always provided a huge impetus (checkout my slides) to deliver on the ambitious "On-line and in your pocket" thing. I have hazy visions of debugging late at night in a hotel room with Kendy to get our first working screenshot there:
Interestingly the 'online' piece was (at that time) gtk-broadway based. Anyhow, while we couldn't do a huge amount of work at SUSE on Android (it was too obviously far away from our core market), we did valuable prototyping.
We also discovered that the modular architecture of LibreOffice - whereby there is a shared library for everything (even loading shared libraries), is not only a Linux / linking performance disaster-area, but also Android had a hard-coded 96 .so library loading limit; with no clear view of how many are used by the system; oh - and it is not as if dlopen fails, you just hard crash: another cute-ness of the 'droid of the time
LibreOffice on iOS; CloudOn
After SUSE spun us out to form Collabora's new Productivity division - we worked hard on this problem. A key investor there was the VC funded CloudOn who worked with Collabora to build a native iOS app for iPad as an alternative to their cloud-hosted, H264 video streaming of a remote VM containing MS Office.
This investment helped Tor (once again) to bring his existing prototype iOS version into a much better shape. It also let us fund Matúš Kukan to start the epic task of re-working all UNO components entry-points to allow us to link them into a single binary, and better by splitting them, to get the linker to garbage collect any bits we didn't need.
CloudOn built a proprietary product from the LibreOffice base, that was rather slick, and then got acquired by DropBox & vanished; making funding tight.
A LibreOffice viewer on Android; Smoose
Thankfully, in 2014 we had a visionary funding from Smoose and with their help we could work on the problems again now at Collabora and drive to getting a 'real' viewer working - built on exposing the LibreOffice core through a simple shared-library interface: LibreOfficeKit.
The write-up has all manner of detailed credits there also to Kendy, Tor and for the document browser to Ian Billet's GSOC project, with Jacobo Perez (Igalia).
Fundamentally this was built on re-using the Java Fennec tiled-rendering code from Firefox for Android - Tomaz 'Quikee' Vajngel did that heavy lift.
So now we had a tiled-rendering mobile document editor for a FLOSS mobile platform - with much of the power of LibreOffice. Problem is - it was not editable, although we had done a chunk of work on editability for CloudOn in the past so we knew it could be done.
The Document Foundation: base framework for basic editing
TDF posted a tender to "develop the base framework for an Android version of LibreOffice with basic editing capabilities".
Collabora won part of that for the core work for Eur 84k (an important 'angel' investment into tiled editing, although well under 5% of the total investment here, valuable - thanks to TDF's Donors). Igalia won the piece to implement an ownCloud integration. The intention was to build basic functionality that could be built on by the community, or by using a crowd-funding campaign.
For the next five years, the Android app has been maintained by the community, with editing as an experimental / advanced feature. Christian Lohmaier did some excellent work of fighting bit-rot, and keeping the viewer working for TDF.
Collabora invested the time to mentor several GSOC students doing smaller feature pieces for the viewer like Gautam Prajapati, and reviewed patches & fixed things here and there, and evangelized.
TDF published calls for people to volunteer and participate - some of them incredibly pretty, recently in 2018:
Unfortunately, the net result of all this hard work, didn't attract significant numbers of people to develop and sustain the Android app. This continued not to deliver a product that people wanted to use. In recent times, TDF marketing suggested removing it, since it hadn't been updated for nearly two years with lots of negative reviews, and this was done.
Meanwhile ... LibreOffice Online arrives
Meanwhile, while the Java based Android solution was not going anywhere fast, in parallel (from 2015) - Collabora and Icewarp started Working on an Open Source alternative to Apps, Office 365.
Building on the foundational work above, and extending this hugely, ultimately releasing COllabora OnLine COOL 1.0 and iterating this rapidly for our customers.
Adfinis Sygroup help us move to iOS
Many years of extraordinarily hard work primarily from Collabora's growing team of engineers working on Collabora Online - improving interactivity, latency, responsiveness, usability etc. gave us a growing number of happy users in PC web browsers.
Then in early 2018, having jointly sold a (clearly labelled) 'Online' solution for use with iPads, using a remote browser based responsive UI that we had been working hard on, it was decided that, independent of the clarity of the product description, contract etc. this should work off-line.
Thus started an incredible sprint to deliver a great iPad app. Clearly it was not possible to reuse the old Fennec approach, so starting from scratch we re-used the core code, and re-purposed the native browser / web-view to talk to a local Online instance directly. In addition - polished lots of native touch interactions.
We announced this with Adfinis in late December 2018.
And provided a lot more lush functionality, including custom widget theming, bringing the sidebar to mobile, and more in late 2019.
Nextcloud & Collabora
In a remarkable deja-vu, a joint customer of Nextcloud & Collabora also procured an on-line product, and wanted an off-line native editor, this time on Android. Thus started another amazing sprint.
Luckily, Kendy had a prototype to bring Tor's iOS work to Android from a Collabora Hackweek (allowing our engineers to work on anything LibreOffice-related they want for a week) from the early 2019 and then Florin Ciornei ported much of the functionality from the fennec-based app to this one.
During his Google Summer of Code, Kaishu Sahu then finished the porting and added more functionality - like inserting local images or printing.
Throught the year, many people from the Collabora team have improved various aspects of the Android app, let me list them in the alphabetical order:
- Andras Timar took care of various l10n peculiarities.
- Aron Budea has spent a lot of time testing, reporting bugs and fixing regressions.
- Ashod Nakashian was heads-down improving the focusing and showing / hiding the keyboard, fixed crashes, exposed sidebar (reused for the Szymon's work) & lots of related fixing.
- Dennis Francis has done many fixes all over the place in the UI - crashes, panning, context menus additions, zooming, ...
- Florin Ciornei has ported most of the shell functionality from the old app (as mentioned above), and created a separate Notice and License Activity.
- Gülşah Köse has implemented the initial WebView app and improved the files association.
- Grzegorz Araminowicz has fixed zoom and reworked the hyperlink dialog.
- Henry Castro has implementated the image or shape preview when dragging or rotating, read-only mode handling, context menus improvements, scrolling, toolbars, and many more.
- Marco Cecchetti has reworked the formula input bar in Calc work via dialog tunneling and list of formulas.
- Mert Tumer has added features even to the old, fennec-based app, and later decreased the size of the APK, improved the usability by adding progress bars to some events that take a lot of time.
- Muhammet Kara added text box insertion, page setup menu, various chart-related work, and line formatting.
- Pedro Pinto Silva has done huge amount of work to make the app beautiful.
- Pranam Lashkari has implemented the inertia and smooth scrolling, row/columns improvements in Calc, sheet renaming, and various smaller things.
- Szymon Kłos has repurposed the sidebar as a single-finger-controllable menu representation; more on that below.
- Tamás Zolnai has prototyped a new unit testing framework via Cypress.
- Tomaž Vajngerl has co-mentored the Android GSoC, improved language setting, implemented export / save as functionality, hugely improved the clipboard handling
- Yunusemre Şentürk: Fixed build errors & implemented the CI.
Our responsive UI from Feb 2019 provided lots of our rich functionality including dialogs on mobile - although the UX there was not ideal:
It was then decided that having all this powerful functionality made the app hard to use with one hand, and that a more limited set of features would make for a more compelling single-touch UI. Again, we changed direction and worked hard on that with a first beta release in late 2019.
Another thing that we created was the expandable bottom palette of simple, frequently used tools created by Szymon Klos, which effectively re-purposes the LibreOffice sidebar tools for mobile devices (with some tweaks).
Further work here targetted the native platform's storage provider interface on Android, which allows much richer, built-in integration with lots of providers: ownCloud, Nextcloud, Seafile - even OneDrive or DropBox if unavoidable. This retired Igalia's native Java integration, that pre-dated those APIs.
Collabora Office 4.2.0
All of this wrapped together, with thirty-five Collabora committers contributing to Online over many years with 10100, of 10500 commits brings us to today's release, and we're excited about it:
Of course, this is just the start, we will continue to build on and receive feedback from our paying customers, and direction as to where to improve and fix the product over time; stay tuned.
Success has a thousand parents, but there is great credit to those named above, and many more who have enabled the evolution of LibreOffice to the full set of platforms. In particularly, StarDivision and Sun laid the foundations and fought the good fight for many years. After them, SUSE, Collabora, CloudOn, Smoose, TDF, Adfinis-Sygroup, Google (via GSOC), and of course the whole LibreOffice Community on whose work we build: thank you !
We finally have a solution in every space: phones, tablets, in your browser, and native on PC. Now we just need to incrementally improve everything, everywhere.
How to get involved
While thanking everyone who contributed, it is important to note that it could be you ! How can you do that ? well - lots of ways. Why not checkout the Android README and get stuck in ? It's easy to develop and debug some of the features on PC in Chrome's web-view too if you want to avoid the development cycle of Android Studio & up-loading. If you're less of a developer there are still lots of ways to get involved with LibreOffice.