Page 1 of 1
touchscreen tablet utilities
Posted: Sat Oct 19, 2024 7:56 am
by stemsee
The title might not convey clearly what i have in mind. What I have in mind is to create some touch friendly panels for fatdog linux which makes it easy to use with a typical tablet. I mean on-screen keyboard toggle button, not a titchy icon in the corner of the tray where the bezel hampers activation. An alternative to the systray. Switching windows and desktops easily with one finger. Floating App menu with generously sized icons. Navigation pad for sending key-combos to activate app menus, and a common text input gui which serves most apps, probably using copy and paste in the backend with xdotool.
So that using fatdog in tablet mode should not simply be the normal desktop in minutae, it isn't suitable for such operation without hardware keyboard and mouse. This project's goal is to cover a limited use case. Browsing, camera, note taking, recording audio / video with big buttons, connecting to wifi APs, playing music/radio/movies and some networking. etc similar to what i do using my phone over scrcpy. Basically it means opening apps live guvcview with fixed objectives, snapshot, record video with/without audio ....
- xscreenshot-20241019T153543.png (53.53 KiB) Viewed 979 times
Browser should be chrome based which is pinch to zoom enabled already.
I made an effort towards this with several scripts, wifi-2-desktop, script-2-desktop, emoji-2-desktop, radio/media as desktop files. Did that and a fair bit more while experimenting with my yad file browser, in which dirs and files are represented as a desktop file. Desktop files seem to me to be ideal, also scripts with a suitable icon are similar in appearance and functionality.
Any thoughts?
Re: touchscreen tablet utilities
Posted: Sat Oct 19, 2024 10:48 pm
by step
Sounds good. To create your GUI you could also use Fatdog QuickApps (Menu > Personal > ).
Or you could add your own applets to the the Fatdog64 Control Panel. Create file ~/.fatdog/control-panel-applets and/or add files under ~/.fatdog/control-panel-applets.dir. Look at /etc/control-panel-applets and /etc/control-panel-applets.dir/applet-definition for short instructions and examples.
Either way, the applets are .desktop files, the same stuff that goes into your yad icon box.
Re: touchscreen tablet utilities
Posted: Sun Oct 20, 2024 5:35 am
by chiron
I use fatdog on my Thinkpad Yogas, also in tabletmode, and I created a quicklaunch on an extra lxqt panel with larger icons that is hidden and activated once you move your finger to the respective edge of the screen. Actually I liked it so much I configured all my lxqt panels to be that way. Swipe to the edge of the screen, panel appears, make your selection, panel vanishes. The quicklaunch also takes .desktop files, so you can add your own scripts and have control over the icons.
As keyboard I use the on-board qtvkbd that gets invoked as soon as the yoga goes into tabletmode (did some shell scripts to handle screen rotation, switching speakers etc...). you can place the keyboard dock anywhere you like on the desktop and it always stays on top even when the browser is in fullscreen, so you have easy access to the keyboard. Plus the keyboard actually looks nice and is resizeable.
Re: touchscreen tablet utilities
Posted: Mon Oct 21, 2024 4:04 am
by stemsee
@step
Yes, and /usr/share/applications ... the selections of which to make available in panels for tablet mode, and which cli arguments to use best suited for tablet mode. As i see it you set up tablet mode customisations in desktop mode, and just use the thing to consume in tablet mode: read epubs, browse web, watch videos, listen to music. But if you have speakers, bt earphones, bt speaker ... you don't want to invoke sound wizard, just replace /root/.asoundrc with a saved profile for that device etc which a desktopfile will do.
@chiron
Yes, exactly. Are you willing to share your work, configs scripts settings etc? I am sharing some scripts for making various files or settings as desktop files here
https://fatdog64-d88.taild4ecf9.ts.net/
Re: touchscreen tablet utilities
Posted: Mon Oct 21, 2024 2:03 pm
by Clarity
One of the missing elements of Linux distros with touchscreen that is missed, often in the community is "finger-tap on any open area of the desktop 'should' open the Menu for application selects...not the way it is currently implemented". Thus, it should acts as the current mouse right-click on open area of the desktop.
Probably a OOTB setup switching right click behavior when touchscreen is detected. Or some pop-up at boot-time to guide user behavior, OOTB>
This allows the Touch systems to behave more like what we would expect on a cell phone.
Re: touchscreen tablet utilities
Posted: Tue Oct 22, 2024 5:18 pm
by stemsee
Previously Jamesbond setup a wacom driver to provide two-finger right click. Somewhere along the upgrade path that stopped working. However in chrome based broswers two finger touch as right click is still available. Chrome takes over control of the actual touch hardware. So it seems JWP\Openbox only accidentally supported two finger right click. In fact two fingers and more do register, but some advanced configuration is needed I guess .... maybe touchegg, which I am just starting to get familiar with. And apart from that I created a tray icon which uses xdotool to generate a right click under the finger, with a small delay for positioning. It works, but not ideal. EDIT* improved floating button for delayed (4s) right-click.
- xscreenshot-20241023T073859.png (8.82 KiB) Viewed 659 times
depends on yad and xdotool
Code: Select all
#!/bin/sh
yad --on-top --button="🖱️!!Click then move cursor over the item you wish to right-click on":"bash -c 'sleep 2; xdotool click 3'" --geometry=48x48+100+100 --undecorated --skip-taskbar --fontname="Sans Bold 20" --title="Right-Click" &
Geany used to support pinch to zoom with the touchscreen well. Evince supports pinch to zoom and so does yad --print --add-preview, which can display text based documents and graphics images. Unfortunately that is the only yad gui option that does afaik! Evince and cr3 also offer page rotation for reading in landscape or portrait, without rotating the screen/WM. Libreoffice is also touch friendly but not a smooth experience. Maybe wps office would be better.
I need to find an image viewer/editor which has pinch to zoom. Chrome based browsers can be used for viewing I guess. I have made some good progress already. Bt and wifi desktop file connections work well. So too mediafiles, and playlists and epubs.
Edit: I have also scripted a simple alert/alarm/reminder. easily set year month day and hour, display text and an exec string which is to play an alarm, in fact a media file named alarm.mp3 e.g. 'vlc /root/media/alarm.mp3'
- xscreenshot-20241023T075333.png (29.01 KiB) Viewed 656 times
a few floating panels open
- xscreenshot-20241023T084315.png (447.84 KiB) Viewed 654 times
Re: touchscreen tablet utilities
Posted: Wed Oct 23, 2024 2:07 am
by stemsee
I am creating a navigation pad, but I am not sure what to use it for. Well, I can assign a config file for the nine commands for the nine 'user programmable' buttons. Initially I though it would be for sending key combos using xdotool.
- xscreenshot-20241023T100655.png (27.09 KiB) Viewed 652 times
Re: touchscreen tablet utilities
Posted: Wed Oct 23, 2024 9:07 am
by stemsee
two finger right-click solved using touchegg, also desktop change with 3 finger swipe. Just put the following in /root/.config/touchegg/touchegg.conf
Code: Select all
<gesture type="PINCH" fingers="4" direction="IN">
<action type="CLOSE_WINDOW">
<animate>true</animate>
<color>F84A53</color>
<borderColor>F84A53</borderColor>
</action>
</gesture>
<gesture type="SWIPE" fingers="4" direction="LEFT">
<action type="CHANGE_DESKTOP">
<direction>next</direction>
<animate>true</animate>
<animationPosition>right</animationPosition>
<color>3E9FED</color>
<borderColor>3E9FED</borderColor>
</action>
</gesture>
<gesture type="SWIPE" fingers="4" direction="RIGHT">
<action type="CHANGE_DESKTOP">
<direction>previous</direction>
<animate>true</animate>
<animationPosition>left</animationPosition>
<color>3E9FED</color>
<borderColor>3E9FED</borderColor>
</action>
</gesture>
<gesture type="SWIPE" fingers="4" direction="DOWN">
<action type="SHOW_DESKTOP">
<animate>true</animate>
<color>909090</color>
<borderColor>FFFFFF</borderColor>
</action>
</gesture>
<gesture type="DRAG" fingers="3" direction="RIGHT">
<action type="SEND_KEYS">Control+Alt+Left</action>
</gesture>
<gesture type="DRAG" fingers="3" direction="LEFT">
<action type="SEND_KEYS">Control+Alt+Right</action>
</gesture>
<gesture type="TAP" fingers="2">
<action type="MOUSE_CLICK">
<button>3</button>
<on>begin</on>
</action>
</gesture>
<gesture type="SWIPE" fingers="2" direction="LEFT">
<action type="SEND_KEYS">
<repeat>true</repeat>
<modifiers>Alt_L</modifiers>
<keys>Shift_L+Tab</keys>
<decreaseKeys>Tab</decreaseKeys>
</action>
</gesture>
<gesture type="SWIPE" fingers="2" direction="RIGHT">
<action type="SEND_KEYS">
<repeat>true</repeat>
<modifiers>Alt_L</modifiers>
<keys>Tab</keys>
<decreaseKeys>Shift_L+Tab</decreaseKeys>
</action>
</gesture>
<gesture type="TAP" fingers="3">
<action type="MOUSE_CLICK">
<button>8</button>
<on>begin</on>
</action>
</gesture>
<gesture type="TAP" fingers="4">
<action type="MOUSE_CLICK">
<button>9</button>
<on>begin</on>
</action>
</gesture>
<gesture type="SWIPE" fingers="3" direction="LEFT">
<action type="TILE_WINDOW">
<direction>left</direction>
<animate>true</animate>
<color>3E9FED</color>
<borderColor>3E9FED</borderColor>
</action>
</gesture>
<gesture type="SWIPE" fingers="3" direction="RIGHT">
<action type="TILE_WINDOW">
<direction>right</direction>
<animate>true</animate>
<color>3E9FED</color>
<borderColor>3E9FED</borderColor>
</action>
</gesture>
start touchegg as follows
three finger swipe down minimises. three finger tap desktop tasks. This is amazing!!!
- xscreenshot-20241023T173659.png (147.89 KiB) Viewed 621 times
That just took five minutes to find!
Re: touchscreen tablet utilities
Posted: Thu Oct 24, 2024 12:33 am
by stemsee
lxqt panel focus model gets confused easily between touchscreen and track-pad, and becomes unusable, even before adding touchegg gestures. Maybe necessary to disable track-pad in tablet mode
- lxqtpanel.png (18.52 KiB) Viewed 532 times
edit: disabling track-pad 'xinput disable 10' makes no difference. We have entered some unknown mode of operation. No, the trackpad/mouse is never confused, this is touchscreen only. Maybe xorg config for touchscreen needs tweaking.
yadu (yad gtk3) multi-touch, showing magnifier per text box per finger (3), in fact my thumb could simultaneously and independently select items in list on the left. So gtk3 is multitouch and multi focus.
- touch.png (49.61 KiB) Viewed 518 times
update:
Opening up my yad audio equaliser function, I am able to control sliders for each eq band simultaneously and independently, using yadu (gtk3) instead of yad (gtk2 on fd64). But this doesn't work with buttons.
Re: touchscreen tablet utilities
Posted: Thu Oct 24, 2024 8:56 pm
by step
@stemsee, Fatdog64 has three yad packages: yad_gtk2, yad_gtk3 and yadu. yad_gtk2 and yad_gtk3 use the same code base. The only difference is one uses the GTK2 library while the other one uses the GTK3 library. yadu, on the other hand, uses a different code base with the GTK3 library. Could you please try yad_gtk3 instead of yadu, to see whether the code base vs GTK3 is making the difference for pinching? No rush, I'm just curious.
Re: touchscreen tablet utilities
Posted: Fri Oct 25, 2024 6:27 am
by stemsee
I see no difference between using yad_gtk2, yad_gtk3 and yadu, using --print --add-preview ... all support pinch...btw what is the underlying gtk widget for print preview? But between gtk2 and the others none of the extra touch functionality exists with gtk2.... AND if I use --gtkrc theme for yadu and gtk3 they also lose extra touch functionality.
Do you have any yadu binary compiled with html?
Re: touchscreen tablet utilities
Posted: Sat Oct 26, 2024 3:39 pm
by stemsee
Honestly chrome based web browser does a great job as an epub/pdf /txt reader, and media player. Offering split screen graphic history, and rotations, tabbed pages are as many desktops, and perfectly touchable.
- xscreenshot-20241026T233743.png (428.11 KiB) Viewed 370 times
resources
https://sketch.io/sketchpad/ - online drawing and painting and text
https://products.aspose.app/ocr/en/handwriting-to-text - OCR get text from handwriting, or images etc.
https://www.canva.cn/?display-com-option=true - online content designer
https://www.musicca.com/drum-machine?da ... kmo6em7ai- - online drum machine
https://www.musicca.com/drums - online drums
https://www.musicca.com/piano - online piano
https://www.online-convert.com/ - many conversions avaialable
Re: touchscreen tablet utilities
Posted: Sat Oct 26, 2024 9:23 pm
by step
stemsee wrote: ↑Fri Oct 25, 2024 6:27 amwhat is the underlying gtk widget for print preview?
GtkUnixDialog.
Do you have any yadu binary compiled with html?
No, because the Fatdog64 package repository lacks WebkitGTK, which is a dependency for yadu --html.
Re: touchscreen tablet utilities
Posted: Sun Oct 27, 2024 4:32 am
by stemsee
Can GtkUnixDialog widget in yad --print preview be enabled to show columns and rows, 2 pages wide 6 pages length etc?
Re: touchscreen tablet utilities
Posted: Mon Oct 28, 2024 9:45 pm
by step
You mean a grid of page thumbnails? I don't think so.