<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: Настроить зажатие клавиш]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=12672&amp;type=atom" />
	<updated>2020-03-30T14:46:32Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=12672</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=138720#p138720" />
			<content type="html"><![CDATA[<p><strong>Greh</strong>, не надо обращаться к кому-то из участников лично за помощью (исключая случаи, когда делаете платный заказ). Не пишите в чужой теме, создайте свою, придумайте внятное название, оформите код тегом <a href="http://forum.script-coding.com/help.php?section=bbcode">как положено</a>, и кто-то обязательно ответит.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2020-03-30T14:46:32Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=138720#p138720</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=138718#p138718" />
			<content type="html"><![CDATA[<p><strong>teadrinker</strong><br />Здраствуйте, можете мне помочь?<br />Я использую ахк следующим образом, при зажатии лкм , лкм множество раз нажимаеться, мне жнужно чтоб скрипт отключался&nbsp; на клавишу и назад включался, какие клавиши значения неимеет, можете помочь?? вот скрипт:<br />*LButton::<br />&nbsp; &nbsp;Loop<br />&nbsp; &nbsp;{<br />&nbsp; &nbsp; &nbsp; Click<br />&nbsp; &nbsp; &nbsp; If !GetKeyState(&quot;LButton&quot;, &quot;P&quot;)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Break<br />&nbsp; &nbsp;}<br />&nbsp; &nbsp;Return</p>]]></content>
			<author>
				<name><![CDATA[Greh]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=40710</uri>
			</author>
			<updated>2020-03-30T14:23:04Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=138718#p138718</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115837#p115837" />
			<content type="html"><![CDATA[<p>Мм, параметр On лишний будет. Еще вы не предусмотрели случай быстрого последовательного нажатия q и w.<br />В остальном все как у меня с той разницей, что мой код можно без переделки использовать для любой клавиши, а также для нескольких клавиш одновременно.</p>]]></content>
			<author>
				<name><![CDATA[stealzy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=31937</uri>
			</author>
			<updated>2017-05-14T11:43:45Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115837#p115837</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115835#p115835" />
			<content type="html"><![CDATA[<p><strong>stealzy</strong><br /></p><div class="codebox"><pre><code>q::
send {e down}
sleep 450
SetTimer,ed,40,on
return
ed:
send {e down}
return
w::
SetTimer,ed,off
send {e up}
return</code></pre></div><p>Так?</p>]]></content>
			<author>
				<name><![CDATA[cahtbap1]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=34377</uri>
			</author>
			<updated>2017-05-14T10:58:57Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115835#p115835</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115834#p115834" />
			<content type="html"><![CDATA[<p><strong>cahtbap1</strong>, суть не в том, чтобы держать клавишу зажатой пальцем на клавиатуре, а разнести действия нажатия и отжатия по разным клавишам и сохранить системный автоповтор.</p>]]></content>
			<author>
				<name><![CDATA[stealzy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=31937</uri>
			</author>
			<updated>2017-05-14T10:45:36Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115834#p115834</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115833#p115833" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>user1 пишет:</cite><blockquote><p>Можно как то сделать чтобы при нажатии буквы «q» был эффект будто клавиша «e» физически зажата?</p></blockquote></div><p>Возможно вы имели ввиду:<br /></p><div class="codebox"><pre><code>q::e</code></pre></div>]]></content>
			<author>
				<name><![CDATA[cahtbap1]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=34377</uri>
			</author>
			<updated>2017-05-14T10:33:27Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115833#p115833</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115821#p115821" />
			<content type="html"><![CDATA[<p>Имитация системного автоповтора зажатой клавиши:<br /></p><div class="codebox"><pre><code>q::SendFn(&quot;e&quot;, 1) ; e down
w::SendFn(&quot;e&quot;, 0) ; e up

SendFn(key, state) {
	Static ARfn := {}, KeyboardDelay := 1000 ; = HKEY_CURRENT_USER\Control Panel\Keyboard\KeyboardDelay
	if (state &amp;&amp; !ARfn.key) {
		Send % &quot;{Blind}{&quot; key &quot; down}&quot;
		SetTimer(ARfn.key := Func(&quot;AutoRepeat&quot;).Bind(key, true), -KeyboardDelay)
	} else if (!state &amp;&amp; ARfn.key) {
		SetTimer(ARfn.key, &quot;Delete&quot;)
		AutoRepeat(key, false)
		Send % &quot;{Blind}{&quot; key &quot; up}&quot;
		ARfn.key := &quot;&quot;
	}
}
AutoRepeat(key, state) {
	Static ARfn := {}, KeyboardSpeed  := 20 - A_KeyDelay ; ~ 1000 / (HKEY_CURRENT_USER\Control Panel\Keyboard\KeyboardSpeed  +  2)
	if (state) {
		Send % &quot;{Blind}&quot; key
		SetTimer(ARfn.key := Func(&quot;AutoRepeat&quot;).Bind(key, true), -KeyboardSpeed)
	} else if (!state)
		SetTimer(ARfn.key, &quot;Delete&quot;)
}
SetTimer(l, p) {
	SetTimer % l, % p
}</code></pre></div>]]></content>
			<author>
				<name><![CDATA[stealzy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=31937</uri>
			</author>
			<updated>2017-05-13T20:18:21Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115821#p115821</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115820#p115820" />
			<content type="html"><![CDATA[<p>Попробуйте взять за основу такой пример: <a href="http://forum.script-coding.com/viewtopic.php?pid=59831#p59831">http://forum.script-coding.com/viewtopi … 831#p59831</a>.</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2017-05-13T19:41:48Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115820#p115820</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115818#p115818" />
			<content type="html"><![CDATA[<p>Можно как то сделать чтобы при нажатии буквы «q» был эффект будто клавиша «e» физически зажата?</p>]]></content>
			<author>
				<name><![CDATA[user1]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=37321</uri>
			</author>
			<updated>2017-05-13T19:13:18Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115818#p115818</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115816#p115816" />
			<content type="html"><![CDATA[<p>Конечно, нету. Скрипт посылает одиночное нажатие без отпускания. <br />Под зажатием обычно понимают физическое удержание клавиши на клавиатуре. При этом ОС имитирует повторное нажатие, параметры которого настраиваются через Панель управления Windows.</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2017-05-13T18:46:59Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115816#p115816</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115815#p115815" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>
q:: send, {e down}
</code></pre></div><p>При нажатии «q», «e» ставиться один раз. Нет, зажатия клавиши.</p>]]></content>
			<author>
				<name><![CDATA[user1]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=37321</uri>
			</author>
			<updated>2017-05-13T18:32:35Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115815#p115815</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115808#p115808" />
			<content type="html"><![CDATA[<p>У меня работает.</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2017-05-13T15:41:54Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115808#p115808</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Настроить зажатие клавиш]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115805#p115805" />
			<content type="html"><![CDATA[<p>Не подскажете, почему это не работает? И как сделать, чтобы работало?</p><div class="codebox"><pre><code>
q:: send, {e down}
w:: send, {e up}
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[user1]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=37321</uri>
			</author>
			<updated>2017-05-13T15:10:02Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115805#p115805</id>
		</entry>
</feed>
