Linux - Any way to configure or create a script/program to make right click not select menu item? - linux

The default behavior for right-clicking on most recent Linux distros is to select a menu item in a right-click menu upon releasing the right mouse button. While this saves some mouse presses, it is driving some of my Windows-trained (and rather vocal) coworkers completely bonkers, and a lot of searching has told me that there is no option to change this behavior in the distros they are using (mostly RHEL 6).
To make my work environment a little less volatile I would like to try to program a fix or patch for their systems to make right clicking work like they are used to (the menu does not even appear until the right mouse button is released), but I don't know what kinds of tutorials I should be looking for (shell scripts? C? etc.) in order to do this.
If I could be pointed in the right direction that would be lovely! (or if someone by chance already knows of a fix, that would work too, though a lot of Googling has told me that there does not appear to be one currently)

Follow the directions here:
https://unix.stackexchange.com/questions/20550/how-to-disable-the-forward-back-buttons-on-my-mouse
But instead of disabling the forward and back buttons, disable the right click mouse button. You can easily dump the resulting command into a shell script which calls xmodmap. Then you can make icons that disable and enable the right mouse button, for the times where they will need it.

Related

The Godot Engine Editor's IDE/GUI seems to be slow and to ignore mouse interaction

I'm using Godot_v3.2.1-stable_win64.exe(current Godot version) on my Windows 10. When running a project everything seems to work fine but when using the actual IDE of the Godot engine it seems like the IDE screen doesn't update fluidly on every mouse interaction but like only every 5 seconds instead (as like FPS would be low).
So mostly on hovering or clicking something it would light up or be triggered after you clicked on some other thing elsewhere (which is stupid of course).
This makes it even impossible to hit a button sometimes in the IDE.
E.g. when renaming a file a Window/Box for renaming pops up but you do not see it, because the IDE screen isn't updated. So if you don't blindly click on the box (which you don't see) the option for renaming is lost, because the box closes when clicking anywhere else. See what I mean?
Thank you for listening. Have a great day.
This is a known issue. Try updating your graphics driver to the latest version provided by Intel (not your OEM).

Can I disable autocomplete with Alt+Tab on Qt Creator under Linux?

For the most part I very much like Qt Creator, but a few projects I'm working on require me to switch between my editor and my web browser for reference. Qt Creator is currently interpreting Alt+Tab to autocomplete, and then switching my window focus; this is a mild problem but it's really starting to get to me.
I've tried going to Tools→Options→Keyboard and searching for Alt+Tab, but found nothing. Is there a way to get it to selectively ignore the key combination without disabling autocomplete on the whole?
To complete the picture, I'm on Linux Mint 19.04 using XFCE desktop environment; or occasionally Maté. If I need to access something in system settings to do this I'm happy to; I just don't want to keep excessively second-guessing my code when I return to it.
Auto-complete is bound to Ctrl+Space by default, not Alt+Tab. In tools/options/keyboard, search for "CompleteThis" to see what it's bound to.
Maybe what you want is to disable auto-complete and use only manual-complete? That is, have the auto-complete list only show when you press ctrl+space, but never automatically. You can do that in options/text editor/completion.

Creating a floating menu that pops like normal menu but appears at mouse position

Some context
I've recently switched to ubuntu budgie (from unity), and I am really tired of the Plank/panel menu combo. I cannot find a setting that suits me, because depending on my screen setup, there's always something in the wrong place.
I am literally unable to show the menu on certain edges if I activate auto-hide, and if I don't activate it, it's not nice at all, to the point that I have removed the plank thing altogether. (Am I having strange bugs on this OS, or is it really messy?)
My idea
With great frustrations come new ideas. I thought again about one I had in the past. I would like to have a circle menu that pops around my mouse cursor when I press a given key combination (very much the kind of thing you would find in some games).
The main use case is to get "pined" application shortcuts easily when I need them, but perhaps other things would fit well with them (commands ...).
Questions
So my questions are:
Does such a thing already exist?
If it doesn't, is it difficult to realize? (How much time, complexity, ...)
What tools/libraries are needed for such a project? I know I'll find plenty of explanations on the gnome developer website but I could really use some more help.
Since you mention a buggy behaviour on Plank, depending on the screen configuration, I suspect you are suffering from this bug. In short: Plank's returned values for the space it needs are not always correct in multi monitor setup.
A neat option to replace at least part of the functionality is Ulauncher, by default called from a shortcut, but you could trigger it from anything that is capable of running its command.
Since Ulauncher's window simply identifies in the window list, you can easily write a script to move it to the current mouse position.
In case you'd need any help in that, just leave a comment.
Not sure if you are also referring to quick access of the window list, but for that you could use the Window Previews applet, or even the Workspace Overview applet, so life without Plank is possible.

How to set up the apps key in conemu so it doesn't open the mintty menu

I use Conemu and Cygwin at home and at work, and I was trying to get the keyboard and highlighting to behave the same way in both places, so I imported my home Conemu settings file into my work Conemu, and now I've lost my ability to use Apps+PgDn/PgUp to scroll the backbuffer. Instead, when I press the Apps key, the mintty menu pops up.
How do I get that back?
I finally figured out that the problem is mintty.exe. I think they changed it in Windows 10 so the Apps/Menu key makes the context menu pop up, and there doesn't seem to be any way to disable that. I'm using Windows 8 at work and Windows 10 at home, hence the disparity.
If you just set your task to run bash.exe, everything seem to work fine.
Now that I figured it out, I can see why running mintty.exe in ConEmu doesn't make much sense, since they're kind of competing products, both designed to be better alternatives to cmd.exe.
There are only a couple of differences:
bash.exe has no way to specify an icon, but that easily fixed by putting /icon "C:\cygwin\Cygwin-Terminal.ico" (or whatever your cygwin icon path is) in ConEmu's task parameters.
The color scheme is also different, but appending -new_console:P:"<Standard VGA>" to the task command makes it the same as mintty.exe's (I want ConEmu to run Far Manager with the <Solarized> color scheme).

How to change focus in X-Windows?

I am working on old Motif-based application for Linux. I want to be able to programmatically change the active window of our application. I can redirect the input by using XSetInputFocus() function and the keyboard input start to go there, but XReconfigureWMWindow() and XRaiseWindow() functions just don't work.
I've read that Window Managers try to stop this behaviour, so tried to disable configure redirection, but this doesn't work either. Any ideas how to make one of my own windows on top of the window stack?
There is a tiny program called wmctrl available (at least in Debian/Ubuntu it is in standard distribution) which is able to perform many operations on windows and desktops, and handles plenty of window managers. I'd suggest testing whether it works in your environment, and if so, peeking at its sources.
You may find the answer to this is dependent on the Window Manager the user is using, or even what settings they've given to the Window Manager. I like to set my Window Managers to do "focus follows mouse", which means you can't send the focus to a window that I haven't put my mouse on, unless you also warp the mouse there (is that function called XWarpMouse?).

Resources