How to keep mouse keys around - linux

My platform is Linux, and there is a shortcut Alt + Left Shift + Num Lock to enable mouse keys TEMPORARILY. They say this feature is provided by X server, so it can be used on all desktop environments based on X. The problem is that the effect doesn't last long. The keypad will switch back to normal keypad automatically, and cannot be used to emulate a mouse. Therefore, whenever I want to move the cursor, the result may become scrolling to the bottom of the current document, which is annoying. Is there any way to prevent X from switching the keypad back to its original keypad function automatically? Thanks.

Related

Simulating keypress with mouse movement using DirectInput (dinput.dll)

I have been trying to play Omikron: The Nomad Soul, but I found it incredibly difficult to do so without using the mouse. I have been trying to use dinput.dll to simulate keyboard presses using mouse movement, but nothing I tried so far worked. I am a complete amateur at this, so I thought I should ask how to do this properly.
What I am trying to do is to edit dinput.dll source code from github, create a dinput.dll file with configurable ini file, where you can assign key presses to mouse movement. This would be beneficial in many old games.
For example;
Mouse moving up = press up arrow key
Mouse moving down = press down arrow key
Mouse moving left = press left arrow key
Mouse moving right = press right arrow key
Reason why I want to use dinput instead of something like autohotkey is because stuff like autohotkey doesn't always get along well with old games. For example Omikron: The Nomad Soul.
Thank you for any help in advance.

How can I change the keyboard shortcuts of Unity desktop (Ubuntu 14.04)?

I want to change the default shorcuts for some touchpad events and key combinations, for example swiping left or right with three fingers for switching workspaces, using Super + K for opening the terminal and so on. What can I do?
Thanks!
click on
shutdown button --> system setting --> keyboard-->shortcut
, choose one element from the left list then modify what you want

In Linux, what piece of software is responsible for drawing the mouse cursor?

As the title states it: what software actually draws the mouse cursor? Is there a programmatic way for modifying the visual appearance?
The mouse cursor (or mouse pointer) is drawn by the X server. Each application that the cursor moves over may be able to modify the appearance of the mouse cursor.
Since there are different applications and those are built over different toolkits, each could use a different method for changing the cursor's appearance.
xterm uses the X library for manipulating this:
XDefineCursor
XRecolorCursor
XCreateFontCursor
xterm may choose a cursor-font which is small enough to hide the mouse pointer, but the X server continues to "draw" it.
Like other applications, xterm may also use cursor themes, which (in desktop systems such as GNOME, KDE, XFCE), may be configured in a desktop-settings.
But ultimately it is the X server which draws the mouse cursor. The application does not have to do anything to allow it to move around the screen. Rather, each application listens for X events to keep track of the mouse cursor.
Further reading:
How do I change the cursor from an arrow to a watch?
Cursor themes (Arch)
How do you hide the mouse pointer under Linux/X11?

How can add space-key to jump for Platform behavior in construct 2?

I'm using the Platform Behavior in Construct 2 for a Windows 10 game. In addition to the arrow key, I would like to use the Space bar to get the sprite to jump. Can I tell it to call into the Platform behavior somehow or get it to let me map space bar as well as up arrow to 'jump'?
You certainly can. You can use an action called "Simulate Control" to simulate pressing left, right, or up. So as your event, use Keyboard->on Key Pressed (Space Bar). Then for the action Player->Simulate Control (Up Arrow). This will allow you to press space bar to have your character jump. Additionally, you can turn off default controls for the platform behavior and do custom controls for left, right, and up using the same strategy.
The best way to go about doing this is by adding an event that handles the Space Button. Make sure to add the keyboard object in your layout, and in the event sheet, you want to make an event that handles the keyboard -> on key pressed (choose the spacebar when asked) -> choose whatever object you want to jump with the Platform behavior -> Set Vector Y to whatever increment you'd like to jump. Be sure to list this value as negative. The y-axis in C2 is inverted, so negative numbers mean up.
Hope this helps!

WPF Screen should show hotkeys alltime without pressing Alt key

I want to show the hotkeys for label, button on screen without pressing Alt Key. For example
Alt + N opens new dialog where N is hot key so I want underline always appears below N.
I am not sure how we can achieve this without Pressing alt key. After pressing Alt Key hot key is shown but we want to show the corresponding hot key all the time till the screen is open.
I answered in this nearly identical question that
If you have any control over the operating system on which the program is being deployed, apparently you can force the underlined shortcut letter to always be displayed by going to Control Panel -> Display -> Appearance -> Effects -> Hide underlined letters for keyboard navigation.
If you can't do that, some of the other answers mentioned using a System.Windows.Forms.SendKeys class.

Resources