-
Notifications
You must be signed in to change notification settings - Fork 121
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
181 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
;#include FcnLib.ahk | ||
|
||
;FcnLib-Clipboard.ahk by camerb | ||
|
||
;This library contains a bunch of functions that make using the clipboard easier and more reliable | ||
|
||
copy() | ||
{ | ||
Send, {CTRL DOWN} | ||
Sleep, 500 | ||
Send, c | ||
Sleep, 500 | ||
Send, {CTRL UP} | ||
} | ||
|
||
paste() | ||
{ | ||
Send, {CTRL DOWN} | ||
Sleep, 500 | ||
Send, v | ||
Sleep, 500 | ||
Send, {CTRL UP} | ||
} | ||
|
||
;this is what I've got at the moment... it needs to be refined | ||
CopyWait() | ||
{ | ||
;number to verify that the clipboard was never assigned to | ||
null:=Random(100000,999999) | ||
Clipboard:=null | ||
|
||
Sleep, 100 | ||
Send, ^c | ||
Send, ^c | ||
Send, ^c | ||
Send, ^c | ||
Sleep, 100 | ||
;ClipWait, 2 | ||
;debug("silent log", "just copied to clipboard") | ||
count=0 | ||
Loop | ||
{ | ||
count++ | ||
if (Clipboard != null) | ||
{ | ||
;if (count >= 2) | ||
;debug("silent log yellow line", "clipboard is no longer null after # of tries:", count) | ||
break | ||
} | ||
Sleep, 100 | ||
} | ||
|
||
;TODO return false if error? | ||
} | ||
|
||
;rewrite of the clipwait command | ||
ClipWait(clipboardContentsToWaitFor, options="") | ||
{ | ||
|
||
} | ||
|
||
;TODO ClipWaitNull(), ClipWaitNotNull() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
P5 | ||
200 50 | ||
255 | ||
����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Į�����������������������������C�8����������������������������������������������������������������������������������������������������������������������������������������������������������皷���˺���������������������������������3���8����������������������������������������������������������������������������������������������������������������������������������������������������������瘶���˻����z����������������������������8���8����������������������������������������������������������������������������������������������������������������������������������������������������������痷���˻����z���������Z���(���8���3��8��8���8���)$��8�����Y���($��������������������������������������������������������������������������������������������������������������������������蓷���˻����z��������Y�����3���.��3[�$��8���8��8���8��8�緁�3[�$��Z�����8�緁�������������������������������������������������������������������������������������������������������������������������瓷���˻����t��������2�����1���w��8���8��8���8��8���8��([�8���8��1�����([�������������������������������������������������������������������������������������������������������������������������珷���˻����u��������2�����2���w��8���8��8���8��8���8��2�����8���8��2�����2�����������������������������������������������������������������������������������������������������������������������������珷���˻����t��������Y�����3���2��8���8��8���8��Y�� ��3�����8���8��Y�����3�����������������������������������������������������������������������������������������������������������������������������珷���˻����t���������3���( ���8���7��8���8��T8���([�8���8���3���([�������������������������������������������������������������������������������������������������������������������������熷���˻����i�������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������熲���˻����i��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������獞��˸���u����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������笗�{sy�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������羱����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������籿�����ȷ�������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������߁����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Į�����������������������������C�8�����������������������������������������(C���������������������������������������������������������������������������������������������������������皷���̻���������������������������������3���8�����������������������������������������$��2������������������������������������������������������������������������������������������������������������瘷���˻����y����������������������������8���8������������������������������������������<��2������������������������������������������������������������������������������������������������������������痷���˻����z���������Y���(���8���3��8��8���8���'$��8�����Y���($���������Z��( ����������������������������������������������������������������������������������������������������������瓷���˻����z��������Y�����3���.��3[�$��8���8��7���8��8�縁�4[�$��Y�����8�緁������Y[�����$���������������������������������������������������������������������������������������������������������蓷���˻����t��������2�����2���v��8���8��8���8��7���8��([�8���8��2�����([��������$�����8���������������������������������������������������������������������������������������������������������珷���˻����t��������2�����2���v��8���8��8���8��8���8��2�����8���8��2�����2�������������7�����8���������������������������������������������������������������������������������������������������������珷���˻����t��������Y�����3���2��8���8��8���8��Y�� ��3�����8���8��Y�����3������������C����vC���������������������������������������������������������������������������������������������������������珷���˻����t���������3���( ���8���8��8���8��T8���([�8���9���3���([�����Y$��YC����������������������������������������������������������������������������������������������������������熷���˻����i�������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������煱���˻����j������������������������������������������������������������������3$���������������������������������������������������������������������������������������������������������������������玝��˸���t����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������笗�zty�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������罰����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������豿�����ȷ�������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������߂����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Ů�����������������������������C�8�����������������������������������������(C������� �������Y����������������������������C�.������������������������������8�����������8��8�������皷���˻���������������������������������3���8�����������������������������������������$��1���������YT8�����综�$���������������������������3����������������������������������8�����������8��8�������瘷���˻����z����������������������������8���8������������������������������������������<��2�����������8����������8���������������������������8����������������������������������8�����������8��8�������痷���˻����z���������Y���(���9���3��8��8���8���(%��8�����Z���($���������[��( ���������8����������Q��������Y���(���8���3��8���(z8��8���8��8h$��($���(z8��������(z8��8�������瓷���˻����z��������Y�����2���.��3[�$��8���7��8���8��8�緁�3[�$��Y�����9�緂������Y[�����$��������8���������Y��������Y�����3���.��3[�$��8���8��3�� ��8���8��3���8�縁�3�� �������3�� ��3C������瓷���˻����t��������2�����2���v��8���8��8���8��8���8��(\�8���8��3�����'[��������%�����8��������8��������v[��������2�����2���v��8���8��8���8��R���8��8���8��8���([�Q���7�������Q���8��8�������珸���˻����t��������2�����2���v��9���8��8���8��8���8��2�����8���8��2�����2�������������8�����8��������8�������[���������1�����2���v��8���8��8���8��Q���8��8���8��8���2�����Q���8�������Q���8��8�������珷���˻����t��������Y�����3���2��8���8��8���8��X�� ��3�����8���8��Y�����3������������C����vC��������8����9��C����������X�����3���2��8���8��8���8��3�� ��Y�� ��8���4�����3�� �������3�� ��3�������珷���˻����t���������3���( ���8���8��8���8��T8���([�8���9���3���([�����X%��YC�������YC��8�Y��������3���' ���8���9��8���8��z8��T8��8����([�z8�������z8��8h������憷���˻����i��������������������������������������������������������������������������������������������������������������������������������������������2����������������������������������������������熱���˻����i������������������������������������������������������������������3$������������3$���������������3$�������������������������������vC�������������������������3$�����������������玞��˸���u�����������������������������������������������������������������������������������������������������������������������������������������Y$�������������������������������������������������欗�zty����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������� |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,19 @@ | ||
#include FcnLib.ahk | ||
|
||
SetFormat, float, 06.0 | ||
|
||
debug(zeropad2(31, 6)) | ||
;debug(11zeropad2(31, 6)) | ||
|
||
;this will probably have some ugly repercussions | ||
zeropad2(num, digits) | ||
{ | ||
prevFormat:=A_FormatFloat | ||
tempFormat=0%digits%.0 | ||
SetFormat, float, %tempFormat% | ||
;SetFormat, float, 06.0 | ||
;returned:=num | ||
returned:=num+1.0 | ||
SetFormat, float, %prevFormat% | ||
return returned | ||
} |