Search | Sailfish OS | Running | PineTime | All Posts

How to get a larger space bar on SailfishOS

February 10, 2021 — Nico Cartron

A very quick one today: bored of mistyping all the time because of this tiny space bar in SailfishOS?
Look no further, here's how to fix that!


What's the issue?

Which SailfishOS user has not mistyped a text or an email because of that bloody space bar?
And it's true: look at that, it really is super small, especially given estate available on today's smartphones screens:

How to fix it

The Telegram SailfishOS Fan Club group is pretty active and there are many folks willing to help.
This week, while discussing things around SFOS 4, a question was asked about how folks were dealing with the keyboard's space bar, since Coderus' Patchmanager 3.0 and its many patches had not been yet updated to support SFOS 4. This includes the popular Wider Spacebar (for SailfishOS 3).

The user Miklos mentioned that he's usually not using patches for the keyboard, but is rather amending the keyboard files manually, right after a SFOS update.
He shared how he's doing it, and the below tip is thanks to him! So thank you Miklos!

Enlarge the space bar a little

As super-user (devel-su), go into the directory /usr/share/maliit/plugins/com/jolla and edit the file EnterKey.qml.
/!\ As usual, it's highly recommended to make a copy of the original file /!\

devel-su
cd /usr/share/maliit/plugins/com/jolla
cp EnterKey.qml EnterKey.qml.orig
vi EnterKey.qml

then look for the string implicitWidth: functionKeyWidth and add * 0.7 to the end of the line:

implicitWidth: functionKeyWidth * 0.7

Save and exit (:x or :wq)

For the change to take effect, you either have to reboot the phone, or more conveniently, go into Settings > Utilities > Restart Home screen (provided you have SailfishOS Utilities installed).

The space bar will now be slightly larger:

Enlarge it even more

That's nice but the difference is not massive. Let's improve that.
Still in the same directory, and still as super-user, edit the file SymbolKey.qml:

cp SymbolKey.qml SymbolKey.qml.orig
vi SymbolKey.qml

then look for the string property string symbolCaption: "ABC", and 2 lines below that, you should see: implicitWidth: functionKeyWidth.

Replace it with:
implicitWidth: functionKeyWidth * 0.7

then save and exit, and restart the home screen or reboot the phone.

You now have a proper large space bar!

What happens after a SFOS update?

Those modifications will be overwritten, so you'll have to do it again :)

Want more SailfishOS content?

Look at the SailfishOS tag on that blog, or ping me on Twitter if there's a topic you'd like me to write about.

By then, happy SFOS sailing!


Tags: SailfishOS, Tips


I don't have any commenting system, but email me (nicolas at ncartron dot org) your comments!
If you like my work, you can buy me a coffee!