Implanting mouse simulation need visual feed back that mouse is clicked - c#-3.0

Implanting mouse simulation application using c# and winApi to control other windows application , need to blink the cursor when I simulates Mouse click event. so that I will get a visual feed back that mouse is clicked.

You could use ControlPaint.DrawReversibleFrame() or ControlPaint.DrawReversibleLine() to draw a quick series of disappearing concentric shapes to give feedback. When you draw the exact same frame/line twice with these methods they erase themselves and restore whatever was there before.

Related

Remove ui square when many touches

I am coding a game on a Touchscreen with many players at the same time. The issue is, when there are 2 or more touches, a little square is appearing on the screen. It seems to be a unity built-in feature as it is still present in an empty project.
Is there a way to prevent this annoying little square to appear ? I already disabled magic touch shortcuts in windows. And this doesn't appear on the desktop home screen.
I am able to listen to the touches. It seems to be only a visual thing.
Even when I disable multitouch with Input.multiTouchEnabled = false; It still appears.
I also tried to remove the 18 default Axes in the Input Manager.
My goal is to handle every touch separately, without listening to pinch, long press, or scroll interactions. Each player has only to tap somewhere on the screen.
Thanks for you time
Solved it by myself. I completely disabled Touch feedback in the windows parameters. I don't think it is the only way to do that but it works.
Configuration Panel > Pen and Touch
Unmark "Show visual feedback when touching the screen"

Can a Matlab GUI (created in Guide) appear in or in front of a Psychtoolbox window?

I'm using psychtoolbox 3 with Matlab 2019b on a Mac running OSX 10.12.
I'm presenting static image stimuli using psychtoolbox (PTB) and would like to have a floating audio player gui object that I created using guide to appear on the screen as well. Importantly, the audio player has its own functions (slider bar to fastFWD and rewind the audio and a play/pause button) and I need to preserve the button's functionality. Rather than attempting to recreate the the player and buttons etc. within PTB, is it possible to display the gui above the window's screen content?
I've seen other threads about displaying a figure within a PTB window, but this was for graph rather than a gui. I don't believe PTB retains the functionality of the buttons when displaying the figure. I've also considered making the window smaller than the full screen in order to display the figure on the side, but I'd prefer to remain full screen if at all possible.
So to summarize, is there a way for a figure window appear in front of the PTB window? Alternatively, can a PTB window appear within a figure window (i.e., within the axes of a gui created in guide?
Thank you!
Unfortunately I don't believe what you want - to have a full screen Psychtoolbox window as well as a MATLAB GUI .fig as an overlay - is possible. Even if the Psychtoolbox window is less than full screen, you can't give the MATLAB .fig focus and have it overlay the Psychtoolbox window, it will be placed underneath the Psychtoolbox window. You also won't be able to plot the Psychtoolbox window inside of a MATLAB GUI window. What I think your options are:
Make the Psychtoolbox window less than full screen, place the player GUI next to it.
Use a secondary monitor to host the MATLAB GUI, so the Psychtoolbox screen can be full size on the main monitor.

Matlab: How to stop a spinning plot programmatically when the camera is in orbit mode

To see what I mean excatly please:
Run the code below
figure
plot(peaks)
cameratoolbar('SetMode','orbit');
cameratoolbar('Show');
Move mouse onto the plot. Hold down the left click, move the mouse to left ot right then release the click. You'll see the plot start sniping for ever.
Now if you click on the red, stop sign button it stops from spinning. However I would like to programmatically stop the spinning plot. Any thoughts?
Opening cameratoolbar in the editor reveals that orbiting is accomplished by setting the figure's WindowButton* callbacks temporarily to nested/sub functions within cameratoolbar.
Judging from the 1-minute diagonal read-through I did, the camera orbit itself is accomplished by calling a pan/zoom function orbitPangca, which recursively calls cameratoolbar. This recursion loop is controlled by flags which are toggled by the callbacks from the toolbar buttons. These flags alter the behaviour of each iteration in the recursion loop.
If this is indeed the case, it would imply that Matlab is not accepting commands from any source you have programmatic control over, while the plot is orbiting. It'll only respond to the button presses. This means that if you want to stop the motion programmatically, you'd have to hack cameratoolbar to allow for this - not the most portable option.
Another idea that just popped to mind, is figuring out which WindowButton* callback is used for the orbit, and define your own function there. You might just be lucky enough that the MathWorks implemented cameratoolbar such that both callbacks are called each iteration, which would give you programatic control over the flags. But -- you'd have to test this yourself.

How to find mouse position on click in GTK window using Perl?

In my GTK+ application, I want to show an image and let the user click on it to draw lines. I'm doing this by generating a new image, with lines, with ImageMagick. This is my problem: How can I find out where the user clicked?
There is no way to find coordinates of click, because that signal does not have them. You have to use the button-press-event and button-release-event signals. Than the second argument to the callback is GdkEventButton object and that has coordinates.
You may want to see the example for the GtkDrawingArea widget, it does just that.

How to change cursor style in android?

I have different views on my activity. I wanna change my cursor style when cursor is move to any view. How to do same in android.For example there is a normal cursor on the android activity when cursor moves to a button i wanna change cursor style normal to finger style.
The only cursor I know about in Android is used alongside SQLite databases. Seeing as Android phones/tablets are all touchscreen... there is no 'mouse' cursor, except in the emulator.
Of course, you could draw a cursor that followed finger movement, but I can't think of a lot of reasons you'd want do that in a standard UI.
actually there is a mouse cursor in Android 3.0 and later. The only way to see it is to connect a bluetooth mouse to the device and youll see the cursor once you move the mouse around. The only reason I found this site was because I wanted to change the cursor color so sorry I cant help you with that one.