I really don’t like that all ambiances has these bright colored keyboards, I find them very distracting, I wish there was and option to choose keyboard color so I could have black or gray one. Also there should be an option for number row on the keyboard.
1 Like
If you are brave you can do this:
BIG FAT WARNING
Messing with the keyboard may lead to Lipstick (the graphical UI), or worse, the unlock screen to not work.
If this happens, it will become hard (but not impossible) to recover.
BIG FAT WARNING ENDS
Create a backup:
mkdir -p ~/modified_system_files//usr/lib64/qt5/qml/Sailfish/Silica/Background/
cp /usr/lib64/qt5/qml/Sailfish/Silica/Background/KeyboardBackground.qml ~/modified_system_files//usr/lib64/qt5/qml/Sailfish/Silica/Background/
Become root:
devel-su
Create a second backup (makes it easier to access from recovery mode):
mkdir -p /root/modified_system_files//usr/lib64/qt5/qml/Sailfish/Silica/Background/
cp /usr/lib64/qt5/qml/Sailfish/Silica/Background/KeyboardBackground.qml /rootmodified_system_files//usr/lib64/qt5/qml/Sailfish/Silica/Background/
Edit the file:
$EDITOR /usr/lib64/qt5/qml/Sailfish/Silica/Background/KeyboardBackground.qml
… and edit it to look like this (only the parts marked as modifications):
Background {
id: background
property string backgroundMaterial: Theme._backgroundMaterial
property alias pattern: glassImage.source
/**** modifications start here ****/
/*
property color color: palette.colorScheme === Theme.LightOnDark
? palette.highlightDimmerColor
: Qt.lighter(palette.highlightDimmerColor, 1.7)
property color highlightColor: palette.highlightColor
property color highlightBackgroundColor: palette.highlightBackgroundColor
*/
property color color: "black"
property color highlightColor: "grey"
property color highlightBackgroundColor: "dimgrey"
palette.primaryColor: "white"
palette.secondaryColor: "#b0ffffff"
/**** modifications end here ****/
material: KeyboardMaterials[backgroundMaterial] || KeyboardMaterials.glass
patternItem: glassImage
transformItem: __silica_applicationwindow_instance._rotatingItem || null
[... the rest of the file ...]
You can find a list of color names to use here, or you can use standard hex codes as you can see.
Also note that this modification should not be used with Light Ambiences, as the whole keyboard becomes black with those (I think palette.primaryColor is not actually used).
After saving the file making very very sure there are no mistakes, you reboot, or
systemctl --user restart lipstick
7 Likes
Thanks, but I think I will skip that for now
, not worth to risk bricking the phone just to change keyboard color
