About Site Map Submit Contact Us Log in | Create an account
Create an account Log In
Average Rating
User Rating:
Visitors Rating:
My rating:

Write review
See full specifications

scripts default iconjMouseEmu: Mouse Emulator (Scripts) Publisher's description

JMOOUSEEMU emulates the mouse cursor positioning and clicking

JMOOUSEEMU emulates the mouse cursor positioning and clicking. It supports either single- or multiple-command modes.

UPDATE (8/31/2010):
INPUTEMU utility (linked below) supersedes this function (without HG handle support). If your program does not use the HG handle (i.e., H=0), consider using INPUTEMU instead.

The function utilizes the java.Robot class to control mouse.

Single-Command Mode:

JMOUSEEMU(H,POS,CLICK) mouse cursor to POS = [X,Y] (in pixels) with respect to (the lower left hand corner of) the graphics object H. Mouse click option is one of 'none' | 'normal' | 'extend' | 'alternate' | 'open', according to Figure's SelectionType property. If only mouse click without cursor movement is desired, set H = 0 and leave POS empty.

The arguments H and CLICK may be omitted. See the help text for more details.

Example. Martin Weber's setfocus(H) function can be implemented using this function:

mpos = get(0,'PointerLocation');

Multiple-Command Mode (new in v.2.0):

JMOUSEEMU(CMDS,T) performs the sequence of mouse commands using a MATLAB timer with interval T seconds. CMDS is an N-by-3 cell array specifying N mouse commands. The n-th row consists of {H_n, POS_n, CLICK_n} to define the mouse command at nT-th second. Alternatively, each interval between successive commands can be specified with size-N vector T.

In addition to the CLICK options for Single-Command Mode, two additional CLICK options are introduced to support mouse dragging: 'drag_on' and 'drag_off'. Also, there are 2 not-so-CLICK options: 'delay' and 'wheel'. The 'delay' option causes a momentary pause (duration in POS in seconds) and the 'wheel' option turns the mouse wheel (notches to turn in POS: positive-towards, negative-away).

If jMouseEmu is used to trigger multiple mouse callbacks within MATLAB, call jMouseEmu for each callback trigger. Moreover, set the last jMouseEmu command to trigger the callback. Not following this may cause undesirable behavior (i.e., delayed callback execution and erroneous figure's SelectionType property value during the callback).

Example. Circular mouse movement:

Ts = 0.01; % update interval
T = 2; % emulation duration

% plot a circle
t = (0:Ts:T)';
mpos = [100*sin(2*pi*t/T)+pos(3)/2 100*cos(2*pi*t/T)+pos(4)/2];

% show button down activity

% adjust axis so its data = pixels
pos = get(gcf,'Position');
set(gca,'Units','pixels','Position',[0 0 pos([3 4])],'XLim',[0 pos(3)],'YLim',[0 pos(4)]);

% generate commands to follow the cirle & make it to drag
N = size(mpos,1);
cmds = [cell(N,1) mat2cell(mpos,ones(N,1),2) cell(N,1)];
cmds{1,3} = 'drag_on';
cmds{N,3} = 'drag_off';

% emulate!

System Requirements:

MATLAB 7.10 (2010a)
Program Release Status: New Release
Program Install Support: Install and Uninstall

jMouseEmu: Mouse Emulator (Scripts) Tags:

Click on a tag to find related softwares

Is jMouseEmu: Mouse Emulator (Scripts) your software?

Manage your software

Most Popular

scripts default icon ADP Forum (Scripts) 2.0.3
ADP Forum is a discussion board system that doesn't use any database, but instead stores all the data in... Read more
scripts default icon Soraxdesign PHP Guestbook (Scripts) 3.2.5
The Soraxdesign PHP Guestbook is a simple PHP Guestbook with no MySQL database required, which offers a... Read more
scripts default icon PHPizabi (Scripts) 0.848b-C1
PHPizabi is one of the most powerful social networking platforms on the planet
scripts default icon my little forum 2.0RC1
my little forum is a simple web-forum that supports classical thread view (message tree) as well as... Read more
scripts default icon Tobi's Download Server for Download Managers 0.9
Tobi's Download Server is a PHP/MySQL solution for providing Document and/or Data downloads in a... Read more

Related Category

» Auctions (36)
» Blog (217)
» Books (75)
» Calculators (17)
» Calendars (50)
» Chat Scripts (162)
» Countdowns (1)
» Counters (2)
» Database Tools (1345)
» Date and Time (14)
» Development (1506)
» Documents (3)
» E Commerce (72)
» Education (127)
» Email Systems (202)
» Guestbooks (42)
» Healthcare (2)
» Link Checking (12)
» Link Indexing (46)
» Match Making (7)
» Miscellaneous (201)
» Modules (9734)
» Multimedia (126)
» Networking (113)
» Organizers (4)
» PHP Classes (7)
» Real Estate (1)
» Security (1)
» Top Sites (6)
» Web Fetching (1)
» Web Sites (3)
» Wikis (73)
» XML and PHP (2)