libinput | Fork of libinput with my own hacks | Video Utils library
kandi X-RAY | libinput Summary
kandi X-RAY | libinput Summary
libinput is a library that handles input devices for display servers and other applications that need to directly deal with input devices. It provides device detection, device handling, input device event processing and abstraction so minimize the amount of custom input code the user of libinput need to provide the common set of functionality that users expect. Input event processing includes scaling touch coordinates, generating pointer events from touchpads, pointer acceleration, etc. libinput originates from [weston] the Wayland reference compositor.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of libinput
libinput Key Features
libinput Examples and Code Snippets
Community Discussions
Trending Discussions on libinput
QUESTION
I have heard its a conventional practice to store program dependent files in /usr/share/application-folder
in linux. So I'm trying to do it in my c program in a function called load_interface_files()
for example. I am not sure if this is a good practice or not, I've heard about creating configuration files for this kind of issues.
Anyways, here's the the code I wrote to make a directory in /usr/share
.
ANSWER
Answered 2020-Dec-01 at 04:25use ls -ld /usr/share
to see what the permissions on the directory are (without -d
, you get the contents and their permissions).
Use code like:
QUESTION
Please consider this Go code:
...ANSWER
Answered 2020-Aug-06 at 05:27As discussed in comments, this isn't a Go issue at all, but rather just needs the use of the stdbuf
command on GNU/Linux systems. See also this unix.stackexchange.com question and answer. The general idea is to make sure that the program you run using exec.Command
does not buffer its own output inappropriately.
(The stdbuf programs generally use LD_PRELOAD
to insert alternative I/O buffering for stdin, stdout, and stderr, or may be built into the standard libraries on the OS.)
QUESTION
I'm trying to write an application that sends different dBus signals to different applications depending on what application is active. The idea is to pair it with Libinput-gestures, and allow per application gesture response. Problem is, it's impossible to tell which application is active on the client side.
I've been doing some research into detecting if an application has focus on any particular window manager under Wayland. Consensus is, Wayland doesn't know if an application has focus, and will not give that information. However the window manager itself does know.
So is there a way of creating an entirely server side routine for gnome, to send the title of the active window client side, to a select number of applications. In other words, we still have the "security" of not letting arbitrary applications know everything about the environment, but still allow some accessibility minded software retrieve that information and use it.
...ANSWER
Answered 2020-Feb-14 at 22:29Almost 2 years old, but here it goes!! I don't know for sure if Mutter may have a way to do this as well, or if there is a better way to do the following. I suspect with better knowledge of gdbus and further research you can also convert this into some sort of official gdbus monitoring that can communicate with other apps so you do not have to ping for the status.
This is specific to Gnome and I suspect works on at least 3.15+. Tested on Ubuntu 19.10 Wayland. (Gnome 3.34.2)
QUESTION
This command here:
...ANSWER
Answered 2019-Oct-21 at 00:31This should do it:
QUESTION
I write my pet project. At first, it was based on cmake and I set the path to qt libs from the console, e.g. cmake -DPATH_TO_QT:STRING=/home/user/Qt/5.11.1/gcc_64/
The variable PATH_TO_QT
was declared as set(PATH_TO_QT "/path/to/your/Qt/" CACHE STRING "Path to Qt")
With this configuration, my project worked very well.
However, I wanted to add in my project Conan Package Manager and I did it. My conanfile.txt:
...ANSWER
Answered 2018-Dec-04 at 11:06I solved the problem myself. So if you have the same problem you can try to install the next dev-libs:
QUESTION
On wayland there is no configuration file for libinput. This is not usually a problem because desktop environments (such as Gnome) often offer a way to configure the devices. However, there is no way to enable middle click emulation for a clickpad device. By default (using button areas so that I can right click with the bottom right of the touchpad) a middle button area is also created. This often results in me clicking the middle button when I try to left click and middle click instead (causing something to be pasted). This middle click area can be disabled if middle emulation is enabled, however because Gnome does not provide a way to configure this I decided to try to build my own program to do so.
I have looked through libinput's API docs and examples (unfortunately I can't seem to find any examples of device configuration). The following code is what I have put together (compiled with command in comment).
...ANSWER
Answered 2019-Jun-25 at 14:25It looks like this would require a preload library to work as intended. The solution here: https://github.com/gaul/libinput-force-middle-click-emulation works for me.
QUESTION
I am trying to cross compile Raspberry pi3 B+; stretch software 2018-06-27 release, using Qt5.10.1, through Linux ubuntu 64bit according to this steps: https://wiki.qt.io/RaspberryPi2EGLFS
For sure I pay attention to this steps: https://bugreports.qt.io/browse/QTBUG-62216 and even try to edit make space also like this Error while cross compiling Qt for a raspberry pi3 on another time. I tried different arms pi/pi2/pi3/vc4, and even different Qt versions, although I was able to do it with Jessie, However with stretch I cannot get rid of this error;
...ANSWER
Answered 2018-Dec-11 at 20:04Maybe you've missed the flags "-opengl es2 -eglfs" when running configure.
QUESTION
I am deploying a Qt application to a beaglebone black that is running Stretch. I am attempting to use linuxfb with libinput to handle touch events. The touch screen input was inverted, so I set the Coordinate Transformation Matrix with a .conf file. The touch works correctly on the desktop, but is still inverted in my Qt app.
Here are my environment settings for Qt:
...ANSWER
Answered 2018-Oct-17 at 21:00The solution ended up being to use evdev touch in my app and use QT_QPA_EVDEV_TOUCHSCREEN_PARAMETERS
to fix the input events.
My final run environment ended up being:
QUESTION
Quite a few people encounter this issue, especially those who want to use Gym and Mujoco for reinforcement learning. The installation process is frustrating, but luckily some people spot part of the issue
I want to post this problem, so hopefully the Ubuntu developers could see, as the instruction doesn't lead me to any dialog box to write something.
The problem is happened as followed:
I want to use Mujoco, so I follow the installation instruction, but when I implement import mujoco_py in python3.5/3.6, it gives the following error:
>>> import mujoco_py
Import error. Trying to rebuild mujoco_py.
running build_ext
building 'mujoco_py.cymj' extension
...
/home/username/.local/lib/python3.6/site-packages/mujoco_py/gl/osmesashim.c:1:10: fatal error: GL/osmesa.h: No such file or directory
#include ^~~~~~~~~~~~~
Quite a few people suggest to install libosmesa-dev by running sudo apt-get install libosmesa6-dev, so I tried it. But the error is:
The following packages have unmet dependencies: libosmesa6-dev : Depends: libosmesa6 (= 18.0.0~rc5-1ubuntu1) but it is not going to be installed E: Unable to correct problems, you have held broken packages.
Then I think this sudo apt-get install libosmesa6 would solve it, but unfortunately:
The following packages have unmet dependencies: libosmesa6 : Depends: libglapi-mesa (= 18.0.0~rc5-1ubuntu1) but 18.0.5-0ubuntu0~18.04.1 is to be installed E: Unable to correct problems, you have held broken packages.
It looks like it's the version of current libglapi-mesa (18.0.5-0ubuntu0~18.04.1) is incompatible with what mesa really needs(18.0.0~rc5-1ubuntu1)
I am confused about how to downgrade it, because it seems like there are tons of packages depending on the current version of libglapi-mesa. For example, when I tried to correct the version, using sudo apt-get install libglapi-mesa=18.0.0~rc5-1ubuntu1 , the warning is going crazy:
The following additional packages will be installed: policykit-1-gnome The following packages will be REMOVED: apturl cheese deja-dup gdm3 gir1.2-gst-plugins-base-1.0 gir1.2-mutter-2 gir1.2-rb-3.0 gir1.2-totem-1.0 gir1.2-webkit2-4.0 gnome-calendar gnome-control-center gnome-getting-started-docs gnome-initial-setup gnome-online-accounts gnome-session-bin gnome-shell gnome-startup-applications gnome-todo gnome-user-docs gnome-user-guide gstreamer1.0-clutter-3.0 gstreamer1.0-gl gstreamer1.0-vaapi gvfs gvfs-backends gvfs-daemons gvfs-fuse libcheese-gtk25 libcheese8 libclutter-1.0-0 libclutter-gst-3.0-0 libclutter-gtk-1.0-0 libcogl-pango20 libcogl-path20 libcogl20 libedataserverui-1.2-2 libgl1 libgl1-mesa-glx libglu1-mesa libglx-mesa0 libglx0 libgoa-backend-1.0-1 libgstreamer-gl1.0-0 libmutter-2-0 libtotem0 libwebkit2gtk-4.0-37 libyelp0 mutter nautilus nautilus-share rhythmbox-plugins shotwell totem totem-plugins ubuntu-desktop ubuntu-docs ubuntu-release-upgrader-gtk ubuntu-session update-manager update-notifier x11-utils xorg xserver-xephyr xserver-xorg xserver-xorg-core xserver-xorg-input-all xserver-xorg-input-libinput xserver-xorg-input-wacom xserver-xorg-video-all xserver-xorg-video-amdgpu xserver-xorg-video-ati xserver-xorg-video-fbdev xserver-xorg-video-intel xserver-xorg-video-nouveau xserver-xorg-video-qxl xserver-xorg-video-radeon xserver-xorg-video-vesa xserver-xorg-video-vmware xwayland yelp zenity
Now when I looked back to the Ubuntu 18.04 USB installation driver, I noticed that the version of current libglapi-mesa (18.0.5-0ubuntu0~18.04.1) is already there (pre-installed) on this Ubuntu 18.04 version. I am a newbie to Ubuntu, I already reinstall the system for few times due to following different people's post. I really hope Ubuntu team or MESA team could fix this issue soon. If you know how to solve this (other than install Ubuntu 14/16), please leave your comment, I really appreciate it!
ANSWER
Answered 2018-Sep-06 at 19:01I am very new to Ubuntu, knowing nothing about it, so my question looks a bit dump. But here is how I solved it for my situation when I could not proper install libosmesa6-dev due to package dependency:
1 Try to google libosmesa6=18.0.5-rc5-0ubuntu0
, download the deb file for your Ubuntu version, and cpu architecture(e.g. my case 0ubuntu0~18.04.1 (amd64 binary)), and install it manually. This is because in the current package repository, there is no libsomesa6=18.0.5-rc5-0ubuntu0
to match libglapi-mesa=18.0.5...
2 Now, I add repository for newer version of libosmesa6-dev to my repository, and install it with apt-get command:
sudo add-apt-repository ppa:ubuntu-x-swat/updates
sudo apt-get update
sudo apt-get install libosmesa6-dev
After this, the libosmesa6-dev, libosmesa6, libglapi-mesa would be automatically upgraded to a newer version.
3 Once it's installed, I have no issue to import mujoco_py under my environment
QUESTION
I'm having issues with the 'AlpsPS/2 ALPS GlidePoint' (HP zBook Studio G4). It is working but is treated as a mouse device, effectively resulting in all the settings I make in 'Mouse and Touchpad' > 'Touchpad' being ignored. E.g. I can disable 'Tap to click' but with no effect. I can even disable 'Enable touchpad' and it will still work.
These are the relevant lines from the Xorg log file:
...ANSWER
Answered 2018-Mar-01 at 21:53I had this same issue. Fixed it by doing:
sudo modprobe -r psmouse; sudo modprobe psmouse
Answer found here: https://askubuntu.com/a/625064
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install libinput
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page