3

我想开发类似 Synaptics 触摸板手势应用程序的东西。Synaptics 设置显示 x 和 y 坐标。有什么软件可以用吗?像这样的代码:

$x_start = 300
$y_start = 300
While 1
   If $ontouch == True Then
     MouseMove($x_start + $x_touch, $y_start + $y_touch)
   EndIf
Wend

您可以建议任何语言,但最好使用 AutoIt 或 VBScript。一些用于澄清的图像:

点击输入

抽头输出

4

1 回答 1

0

Synaptics 设置显示 x 和 y 坐标。有什么软件可以用吗?

 

Global Const $g_iDelay     = 10
Global Const $g_sKeyExit   = 'q'
Global Const $g_sTooltip   = 'X = %i\nY = %i'

Global       $g_bStateExit = False

Main()

Func Main()
    Local $sTooltip = ''
    Local $aCoordinates

    HotKeySet($g_sKeyExit, 'SetStateExit')

    While Not $g_bStateExit

        $aCoordinates = MouseGetPos()
        $sTooltip     = StringFormat($g_sTooltip, $aCoordinates[0], $aCoordinates[1])

        ToolTip($sTooltip)
        Sleep($g_iDelay)

    WEnd

    Exit
EndFunc

Func SetStateExit()

    $g_bStateExit = True

EndFunc
于 2017-10-06T15:11:11.803 回答