try press and hold middle mouse button on mozilla
you will get this
and on my desktop:
In this image you can view the sensible areas. Where you release the mouse,this is the area relative to the action to be performed.
In this sense if you draw a "c" with middle mouse button, it is important only where you release the button(a little different from gestures,but for direction up,up+left,left,left+down,down,... it is the same).
Tell me what do you think about!!
:wink:
compile and place them all in the same folder
the script:
;author: Salvatore Romeo vuota= MButton:: MouseGetPos,,,idn WinGetClass, class, ahk_id %idn% IniRead, nloop, conf.ini, num_el, num, 20 Sleep,300 mb:=GetKeyState("MBUTTON","P") if(mb="0") MouseClick,M else { Loop,%nloop% { indice_attuale=%A_Index% IniRead, classe, conf.ini, pg%A_Index%, ahkclass if(class=classe) { gosub,cleanvar IniRead, up, conf.ini, pg%A_Index%, up IniRead, ud, conf.ini, pg%A_Index%, ud IniRead, dx, conf.ini, pg%A_Index%, dx IniRead, dd, conf.ini, pg%A_Index%, dd IniRead, dn, conf.ini, pg%A_Index%, dn IniRead, ds, conf.ini, pg%A_Index%, ds IniRead, sx, conf.ini, pg%A_Index%, sx IniRead, us, conf.ini, pg%A_Index%, us StringSplit, up, up, | StringSplit, ud, ud, | StringSplit, dx, dx, | StringSplit, dd, dd, | StringSplit, dn, dn, | StringSplit, ds, ds, | StringSplit, sx, sx, | StringSplit, us, us, | break } } MouseGetPos,x,y ToolTip,%up1%,x-20,y-100,1 ToolTip,%ud1%,x+50,y-70,2 ToolTip,%dx1%,x+80,y,3 ToolTip,%dd1%,x+50,y+70,4 ToolTip,%dn1%,x-20,y+100,5 ToolTip,%ds1%,x-90,y+70,6 ToolTip,%sx1%,x-120,y,7 ToolTip,%us1%,x-90,y-70,8 SetTimer, dove, 400 } return dove: xb1:=GetKeyState("MBUTTON","P") if(xb1=1) { return } else { ToolTip,,,,1 ToolTip,,,,2 ToolTip,,,,3 ToolTip,,,,4 ToolTip,,,,5 ToolTip,,,,6 ToolTip,,,,7 ToolTip,,,,8 SetTimer, dove, Off ; i.e. the timer turns itself off here. MouseGetPos,xd,yd if(xd>x-50 and xd<x+50 and yd>y-1000 and yd<y-20) ;up { Send,%up2% Run,%up3% } else if(xd>x+60 and yd<y-60) ;ud { Send,%ud2% Run,%ud3% } else if(xd>x+20 and xd<x+1000 and yd>y-50 and yd<y+50) ;dx { Send,%dx2% Run,%dx3% } else if(xd>x+60 and yd>y+60) ;dd { Send,%dd2% Run,%dd3% } else if(xd>x-50 and xd<x+50 and yd>y+20 and yd<y+1000) ;dn { Send,%dn2% Run,%dn3% } else if(xd<x-60 and yd>y+60) ;ds { Send,%ds2% Run,%ds3% } else if(xd>x-1000 and xd<x-20 and yd>y-50 and yd<y+50) ;sx { Send,%sx2% Run,%sx3% } else if(xd<x-60 and yd<y-60) ;us { Send,%us2% Run,%us3% } } return cleanvar: up=%vuota% ud=%vuota% dx=%vuota% dd=%vuota% dn=%vuota% ds=%vuota% sx=%vuota% us=%vuota% up1=%vuota% ud1=%vuota% dx1=%vuota% dd1=%vuota% dn1=%vuota% ds1=%vuota% sx1=%vuota% us1=%vuota% up1=%vuota% ud1=%vuota% dx1=%vuota% dd1=%vuota% dn1=%vuota% ds1=%vuota% sx1=%vuota% us1=%vuota% up2=%vuota% ud2=%vuota% dx2=%vuota% dd2=%vuota% dn2=%vuota% ds2=%vuota% sx2=%vuota% us2=%vuota% up3=%vuota% ud3=%vuota% dx3=%vuota% dd3=%vuota% dn3=%vuota% ds3=%vuota% sx3=%vuota% us3=%vuota% return #c:: MouseGetPos,,,idn WinGetClass, class, ahk_id %idn% msgbox,ahk: %class% `n Salvata negli appunti Clipboard=%class% return #x:: Run,gesture.exe return
the conf.ini file:
[num_el] num=4 [pg1] nomec=Xplorer2 ahkclass=ATL:ExplorerFrame up=Doppio Pannello|^o| ud=Anteprima|^q| dx=Cambia Tipo|^{F2}| dd=Nuova Scheda|^{Ins}| dn=Cartelle Recenti|!{F2}| ds=Chiudi Scheda|^{F4}| sx=Seleziona Tutto|^a| us=Aggiorna|^r| [pg2] nomec=PsPad ahkclass=TfPSPad up=Salva|^s| ud=Salva Come|{F12}| dx=Run|{F9}| dd=Help di AHK||E:\programmi\AutoHotkey\AutoHotkey.chm dn=Nuovo|^n| ds=Apri|^o| sx=Stampa|^p| us=Trova|^f| [pg3] nomec=Desktop ahkclass=progman up=E:\||e:\ ud=Incoming||e:\programmi\emule\incoming dx=Blocco Note||notepad.exe dd=Help di AHK||E:\programmi\AutoHotkey\AutoHotkey.chm dn=xplorer||e:\programmi\xplorer2_lite\xplorer2.exe ds=firefox||d:\Programmi\Mozilla firefox\firefox.exe sx=Cartella programmi||e:\programmi us=kiu||E:\programmi\kiu_theme [pg4] nomec=Firefox ahkclass=MozillaUIWindowClass up=Schermo Intero|{F11}| ud=Segnalibri|^b| dx=ScrapBook|!k| dd=Estensioni|^+e| dn=Barra Laterale|{F4}| ds=Stampa|^p| sx=Ricarica|^r| us=Downloads|^+d|
the gui:
;Author: Salvatore Romeo dir0=8 dir1=up dir2=ud dir3=dx dir4=dd dir5=dn dir6=ds dir7=sx dir8=us gosub,creaGui Return GuiClose: ExitApp lista: Loop,%nloop% { temp=obj%A_Index% if(A_GuiControl=%temp%) ind=%A_Index% } Loop,8 { dir_att=%A_Index% di:=dir%A_Index% IniRead, t%di%, conf.ini, pg%ind%, %di% StringSplit, t%di%, t%di%, | Loop,3 { tem:=t%di%%A_Index% GuiControl,,%di%%A_Index%, %tem% } } IniRead, nC, conf.ini, pg%ind%, ahkclass GuiControl,,nClass, %nC% GuiControl,,className,%A_GuiControl% return ButtonNew: msgbox,Click with "left win" button on the program you want KeyWait, LWin ,D MouseGetPos,,,idn WinGetClass, class, ahk_id %idn% Loop,%nloop% { t:=objc%A_Index% if(t=class) { IniRead, clas, conf.ini, pg%A_Index%, nomec msgbox,This class already exist with name "%clas%"".Change the existing one return } } msgbox,ok next:=nloop+1 IniWrite, %next%, conf.ini, num_el,num IniWrite, %class% , conf.ini, pg%next%,ahkclass InputBox, nomeClasse, Insert Name, Insert the name of the program, , , , , , , , IniWrite, %nomeClasse% , conf.ini, pg%next%,nomeC Loop,8 { dix:=dir%A_Index% IniWrite, %A_Space%, conf.ini, pg%next%, %dix% } Gui,destroy gosub,creaGui return ButtonUpdate: Loop,%nloop% { temp=obj%A_Index% if(A_GuiControl=%temp%) ind=%A_Index% } if(ind=) return Gui, Submit, NoHide Loop,8 { dix:=dir%A_Index% dix1:=%dix%1 dix2:=%dix%2 dix3:=%dix%3 valore=%dix1%|%dix2%|%dix3% IniWrite,%valore% , conf.ini, pg%ind%, %dix% } IniWrite,%nClass% , conf.ini, pg%ind%, ahkclass IniWrite,%className% , conf.ini, pg%ind%, nomec return creaGui: oggettiLista= IniRead, nloop, conf.ini, num_el, num, 20 Loop,%nloop% { IniRead, classe, conf.ini, pg%A_Index%, nomec IniRead, objclass, conf.ini, pg%A_Index%, ahkclass oggettiLista=%oggettiLista%|%classe% obj%A_Index%=%classe% objc%A_Index%=%objclass% } Gui, Add, DropDownList, gLista x1 y1 , %oggettiLista% Gui,add,Edit,x200 y1 w40 h20 vclassName Gui,add, Edit,x400 y1 vnClass,%nClass% Gui, add,Text,x350 y5 ,Class Gui, Add, Text, x186 y24 w40 h20, Nome Gui, Add, Text, x36 y84 w40 h20, Nome Gui, Add, Text, x6 y184 w40 h20, Nome Gui, Add, Text, x36 y284 w40 h20, Nome Gui, Add, Text, x186 y334 w40 h20, Nome Gui, Add, Text, x346 y274 w40 h20, Nome Gui, Add, Text, x386 y184 w40 h20, Nome Gui, Add, Text, x346 y84 w40 h20, Nome Gui, Add, Text, x36 y104 w40 h20, Send Gui, Add, Text, x6 y204 w40 h20, Send Gui, Add, Text, x36 y304 w40 h20, Send Gui, Add, Text, x186 y354 w40 h20, Send Gui, Add, Text, x346 y294 w40 h20, Send Gui, Add, Text, x386 y204 w40 h20, Send Gui, Add, Text, x346 y104 w40 h20, Send Gui, Add, Text, x186 y44 w40 h20, Send Gui, Add, Text, x36 y124 w40 h20, Run Gui, Add, Text, x6 y224 w40 h20, Run Gui, Add, Text, x36 y324 w40 h20, Run Gui, Add, Text, x186 y374 w40 h20, Run Gui, Add, Text, x346 y314 w40 h20, Run Gui, Add, Text, x386 y224 w40 h20, Run Gui, Add, Text, x346 y124 w40 h20, Run Gui, Add, Text, x186 y64 w40 h20, Run Gui, Add, Edit, x226 y24 w100 h20 vup1 ,%tup1% Gui, Add, Edit, x226 y44 w100 h20 vup2 ,%tup2% Gui, Add, Edit, x226 y64 w100 h20 vup3 ,%tup3% Gui, Add, Edit, x386 y84 w100 h20 vud1 ,%tud1% Gui, Add, Edit, x386 y104 w100 h20 vud2 ,%tud2% Gui, Add, Edit, x386 y124 w100 h20 vud3 ,%tud3% Gui, Add, Edit, x426 y184 w100 h20 vdx1 ,%tdx1% Gui, Add, Edit, x426 y204 w100 h20 vdx2 ,%tdx2% Gui, Add, Edit, x426 y224 w100 h20 vdx3 ,%tdx3% Gui, Add, Edit, x386 y274 w100 h20 vdd1 ,%tdd1% Gui, Add, Edit, x386 y294 w100 h20 vdd2 ,%tdd2% Gui, Add, Edit, x386 y314 w100 h20 vdd3 ,%tdd3% Gui, Add, Edit, x226 y334 w100 h20 vdn1 ,%tdn1% Gui, Add, Edit, x226 y354 w100 h20 vdn2 ,%tdn2% Gui, Add, Edit, x226 y374 w100 h20 vdn3 ,%tdn3% Gui, Add, Edit, x76 y284 w100 h20 vds1 ,%tds1% Gui, Add, Edit, x76 y304 w100 h20 vds2 ,%tds2% Gui, Add, Edit, x76 y324 w100 h20 vds3 ,%tds3% Gui, Add, Edit, x46 y184 w100 h20 vsx1 ,%tsx1% Gui, Add, Edit, x46 y204 w100 h20 vsx2 ,%tsx2% Gui, Add, Edit, x46 y224 w100 h20 vsx3 ,%tsx3% Gui, Add, Edit, x76 y84 w100 h20 vus1 ,%tus1% Gui, Add, Edit, x76 y104 w100 h20 vus2 ,%tus2% Gui, Add, Edit, x76 y124 w100 h20 vus3 ,%tus3% Gui, Add, Button,x240 y170 h30 w60 ,&New Gui, Add, Button,x210 y202 h30 w120 ,&Update Gui, Show, x300 y110 h400 w550, Gestures Generator return:wink: :wink: :wink: :roll: :roll: :roll: