[Xiaomi Mix Fold 2] Shawnki91:
Hi all,

Reopening this topic as I finally had success in achieving split keyboard, with Gboard in

PORTRAIT

mode.

This was a recurring issue for me, as turning the device to landscape was impractical for a number of apps I use. Split keyboard was necessary for me given the size of my hands the the width of this device.

On to the good stuff (note: your mileage may vary - I am not a developer, and can't provide more than what i learned through trial and error over many hours)

I could not figure out how to load the .rboard file linked on the previous page by @AndroPlus to Rboard, and there was no information I could find which would help. However, I noted that it is ultimately a .xml file with a set of parameters. Google Drive unpacked the xml for me and displayed:

<?xml version='1.0' encoding='utf-8' standalone='yes' ?>
<!--RBOARD:FLAGS-->
<map>
<float name="foldable_aspect_ratio_max" value="3.5"/>
<boolean name="enable_foldable" value="true"/>
<float name="foldable_smallest_width_inches_max" value="9.3"/>
<string name="access_points_order_foldable_devices">sticker;gif_search;clipboard;settings;split;floating_keyboard;theme_setting;one_handed;textediting;share;translate</string>
<float name="foldable_smallest_width_inches_min" value="4.0"/>
<boolean name="enable_split_mode" value="true"/>
</map>

From my understanding, the "split" option is reliant on the screen size of the device, and is equally reliant on that device being either a foldable or a tablet (a tablet differing from a phone by exceeding a certain screen width). In looking at the Flag options in Rboard, it appeared to me that Rboard allows for the editing of the Gboard .xml file by changing values (TRUE or FALSE), and by setting parameters (boolean and floats). Again, not developer so my knowledge here is very basic. I determined that there needed to be a way to add the above mentioned values to the Gboard .xml file to make the split work.

I tried manually adding these values to Rboard, however even after force closing Gboard, the changes never seemed to apply.

I learned from the Rboard telegram channel (linked here) that there was an issue discovered in the applying of flags (albeit from October 10, 2022), and a file was linked in the chat which should be extracted to /data/data/com.google.android.inputmethod.latin/shared_prefs (you can find the file by searching for "shared_prefs.zip") to get flags working again. I used Mixplorer as my root browser, allowed root, and extracted the file as directed. Inside the folder was a .xml file called "flag_override.xml".

I opened "flag_override.xml" and found the nomenclature to resemble the code pasted above. I made the following changes to the file:

Added the following lines to the end of the file before </map>

<float name="foldable_aspect_ratio_max" value="3.5"/>

<float name="foldable_smallest_width_inches_max" value="9.3"/>

<float name="foldable_smallest_width_inches_min" value="4.0"/>

<boolean name="enable_split_mode" value="true"/>

I did not add <boolean name="enable_foldable" value="true"/> as it was already in the file (confirmed with search)

I modified <string name="access_points_order_foldable_devices"> to match the order of: sticker;gif_search;clipboard;settings;split;floating_keyboard;theme_setting;one_handed;textediting;share;translate

I saved the file, force closed Gboard, and when I relaunched it, I had portrait split keyboard!

I have probably explained this in a very amateur way, but it was through trial and error I was able to figure it out. Hoping it will help someone else achieve portrait split-ness for their device!