how to move your mouse’s cursor without mouse ????
can you ?
so the answer is,… using some application. What kind application ?
Google said … ???? no answer
so you have to make your own application, using C programming and XLIB from Linux so you can control your mouse cursor.
so this is the source code :
=====
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <X11/Xlib.h>
#include <X11/Xutil.h>
void mouseMove(int x, int y)
{
Display *displayMain = XOpenDisplay(NULL);
if(displayMain == NULL)
{
fprintf(stderr,”Error”);
exit(EXIT_FAILURE);
}
XWarpPointer(displayMain, None, None, 0,0,0,0, x, y);
XCloseDisplay(displayMain);
}
void mouseClick(int button)
{
Display *display = XOpenDisplay(NULL);
XEvent event;
if(display == NULL)
{
fprintf(stderr, “Errore nell’apertura del Display !!!\n”);
exit(EXIT_FAILURE);
}
memset(&event, 0×00, sizeof(event));
event.type = ButtonPress;
event.xbutton.button = button;
event.xbutton.same_screen = True;
XQueryPointer(display, RootWindow(display, DefaultScreen(display)), &event.xbutton.root, &event.xbutton.window, &event.xbutton.x_root, &event.xbutton.y_root, &event.xbutton.x, &event.xbutton.y, &event.xbutton.state);
event.xbutton.subwindow = event.xbutton.window;
while(event.xbutton.subwindow)
{
event.xbutton.window = event.xbutton.subwindow;
XQueryPointer(display, event.xbutton.window, &event.xbutton.root, &event.xbutton.subwindow, &event.xbutton.x_root, &event.xbutton.y_root, &event.xbutton.x, &event.xbutton.y, &event.xbutton.state);
}
if(XSendEvent(display, PointerWindow, True, 0xfff, &event) == 0) fprintf(stderr, “Errore nell’invio dell’evento !!!\n”);
XFlush(display);
usleep(100000);
event.type = ButtonRelease;
event.xbutton.state = 0×100;
if(XSendEvent(display, PointerWindow, True, 0xfff, &event) == 0) fprintf(stderr, “Errore nell’invio dell’evento !!!\n”);
XFlush(display);
XCloseDisplay(display);
}
int main(int argc, char** argv )
{
mouseMove(atoi(argv[1]),atoi(argv[2]));
mouseClick(atoi(argv[3]));
return 0;
}
=======
save this source code into some file, example mouse.c
you can compile this sourcecode using gcc :
# gcc -o mouse mouse.c -lX11
and run this program with
# ./mouse 100 100 0
with this application you can move x = 100 and y = 100 pixel without click
# ./mouse 0 0 1
with this application you can click on the spot






KLo ga pake mouse pake apa pak ????
“with this application you can click on the spot”
maksudnya…..
weeeeehhhh
emang ga pake moues,… tapi cursornya kan masih ada,… jadi walaupun ga ada mousenya, kita tetep bisa klik sana sini
misal buat virtual mouse,… gerakin mouse pake tangan kita dengan di capture pake webcam
zaki kamu sekarang kerja dimana oe ????
Bukane wis ngerti pak…..
Posennng pak…kerjone shift2-pan….libur e ga tentu pisan…isok senen,selasa,rabu…hari libur malah masuk…. Bisa Gila…..
Tp dilakoni sik ae…kabeh onok hikmah e….bener ga pak….:-D
yo wis pak aq mole sik, turu …
( hbs shift malam )
lo kerjo nang endi ???
heheh nikmati ae wes… selamat bekerja ya…
eh salah,… met bobok wekekekek
nek Indosat pak…..perasaan wis tak kandani dech…..
yek opo pak..ga enek proyekan maneh…
Thank you for this cool program.
It helped me a lot.