Because my soon-to-be-China-like country will probably soon impose using QRcode to go anywhere
I thought about doing a nice and practical QRcode reader for librem5
I downloaded the last qcow2 image of the librem5 and run it with qemu
I tried a webcam with mpv /dev/video0 : it successfuly get the video stream inside the L5 VM
Then I tried zbarcam to read QRcode : it works !
But then i found and installed the app qtqr , which didn’t start because I’m a dumbass who forgot to set DISPLAY=:0 when ssh-ing
After setting the DISPLAY variable, I found this very odd behavior :
If I execute qtqr from ssh it fails with the error : qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in ""
I have same error/behavior with an other app
if I open the terminal inside the VM and execute qtqr : it fails with the same error
if I use the nice shortcut in the GUI application launcher : it fails to start, probably with the same error, but I can’t see it, I only see the desktop wallpaper
if I use zsh inside the current bash and execute qtqr : it fails with the same error
But then if I reboot with zsh as my default shell instead of bash, it works perfectly from ssh (but fails from terminal or GUI app launcher)
Anyone has a clue why ?
@amarok : did you tried qtqr (if not can you test it plz ? ) or any other QRcode reader ? (edit: hum, this request is kind of stupid, the cameras are not yet working…)
The first screenshot has it running via XWayland. The second one shows it running on Wayland natively. You can use the previously mentioned
AFAIK qtwayland5 is in Qt’s recommended packages, and currently we don’t install recommended dependencies. This is supposed to change before Byzantium becomes the default (right now it’s still Amber).
I tested changing QT_QPA_PLATFORM=wayland to QT_QPA_PLATFORM=xcb in /etc/profile.d/librem5-wayland.sh
now I have the same behavior in all cases because it uses XWayland all the time
I understand the change I made is not a good long term tweak
The QT_QPA_PLATFORM=xcb should be set case by case in the launcher or alias of the app you want working with XWayland
For those who could be interested, here an exemple for qtqr :
You need to edit the file /usr/share/applications/qtqr.desktop and modify the line Exec=qtqr %F
to Exec=env QT_QPA_PLATFORM=xcb qtqr %F
I wonder if qtqr would work much better on small screens when by dividing the window horizontaly instead of vertically so that the text input field is abhove the area which displays the qrcode, or vice versa. Would it be worth to talk with qtqr developers about that?