teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

5

追記したコードの説明を追記

2021/06/30 14:44

投稿

slimat
slimat

スコア57

title CHANGED
File without changes
body CHANGED
@@ -27,7 +27,8 @@
27
27
  環境 OS : Windows10, AutoHotKey : Version 1.1.33.02
28
28
  よろしくお願いいたします.
29
29
 
30
+ ーーーー追記①(2021/6/30)ーーーー
30
- ーーー追記①ーーーー
31
+ 現在のコドの状態です.
31
32
  ```AHK
32
33
  #Persistent
33
34
 

4

現時点でのコードの追記

2021/06/30 14:44

投稿

slimat
slimat

スコア57

title CHANGED
File without changes
body CHANGED
@@ -25,4 +25,35 @@
25
25
  }
26
26
  ```
27
27
  環境 OS : Windows10, AutoHotKey : Version 1.1.33.02
28
- よろしくお願いいたします.
28
+ よろしくお願いいたします.
29
+
30
+ ーーーー追記①ーーーー
31
+ ```AHK
32
+ #Persistent
33
+
34
+ #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
35
+ ; #Warn ; Enable warnings to assist with detecting common errors.
36
+ SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
37
+ SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
38
+
39
+ myFunc := RegisterCallback("textSelectedHandler")
40
+
41
+ myHook := DllCall("SetWinEventHook"
42
+ , "UInt", 0x8014 ; eventMin : EVENT_SYSTEM_FOREGROUND
43
+ , "UInt", 0x8014 ; eventMax : EVENT_SYSTEM_FOREGROUND
44
+ , "UInt", 0 ; hModule : self
45
+ , "UInt", myFunc ; hWinEventProc :
46
+ , "UInt", 0 ; idProcess : All process
47
+ , "UInt", 0 ; idThread : All threads
48
+ , "UInt", 0x0003 ; dwFlags : WINEVENT_SKIPOWNTHREAD | WINEVENT_SKIPOWNPROCESS
49
+ , "UInt")
50
+
51
+ textSelectedHandler() { ; 引数を全消ししても動いた
52
+ WinActive("A") ; sets last found window
53
+ ControlGetFocus, ctrl
54
+ if (RegExMatch(ctrl, "A)Edit\d+")) { ; attempt copying without clipboard
55
+ ControlGet, text, Selected,, %ctrl%
56
+ clipboard := text
57
+ }
58
+ }
59
+ ```

3

タグの追加

2021/06/30 14:33

投稿

slimat
slimat

スコア57

title CHANGED
File without changes
body CHANGED
File without changes

2

タグの追加

2021/01/20 10:05

投稿

slimat
slimat

スコア57

title CHANGED
File without changes
body CHANGED
File without changes

1

初心者マークの追加と

2021/01/20 06:05

投稿

slimat
slimat

スコア57

title CHANGED
File without changes
body CHANGED
@@ -24,5 +24,5 @@
24
24
  Tooltip, 「%title% ahk_class %class%」がアクティブになった
25
25
  }
26
26
  ```
27
- 環境 : OS : Windows10, AutoHotKey : Version 1.1.33.02
27
+ 環境 OS : Windows10, AutoHotKey : Version 1.1.33.02
28
28
  よろしくお願いいたします.