This file contains hidden or 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
; 修改自 NepteR 的 Clipboard Monitor | |
#SingleInstance force | |
#NoEnv | |
SetBatchLines -1 | |
Gui, Add, ListView, w600 h200 AltSubmit gLV_Events, Format ID|Format Name|Size|Address|Index | |
For idx, width in [85, 216, 111, 102, 53] | |
LV_ModifyCol(idx, width) | |
Gui, Add, Edit, xm wp h200 vData ReadOnly, |
This file contains hidden or 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
/* 函数: RegExMatchAll | |
* 正则匹配所有结果,返回数组。 | |
* 用法: | |
* RegExMatchAll(Haystack, NeedleRegEx, SubPat="") | |
* 参数: | |
* Haystack - 被搜索的字符 | |
* NeedleRegEx - 正则表达式 | |
* SubPat - (可选) 获取子匹配N,而非整个匹配 | |
* 返回: | |
* 成功返回数组,失败返回空。 |
This file contains hidden or 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
FixIE(Version=0, ExeName="") | |
{ | |
static Key := "Software\Microsoft\Internet Explorer" | |
. "\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION" | |
, Versions := {7:7000, 8:8888, 9:9999, 10:10001, 11:11001} | |
if Versions.HasKey(Version) | |
Version := Versions[Version] | |
if !ExeName |
This file contains hidden or 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
class http { | |
static o := ComObjCreate("WinHttp.WinHttpRequest.5.1") | |
get(args*) { | |
return this._request("GET", args*) | |
} | |
post(args*) { | |
return this._request("POST", args*) |
This file contains hidden or 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
psTool_get() { ; http://stackoverflow.com/questions/29109677/photoshop-javascript-how-to-get-set-current-tool | |
app := ComObjActive("Photoshop.Application") | |
actRef := ComObjCreate("Photoshop.ActionReference") | |
actRef.putEnumerated( app.charIDToTypeID("capp") | |
, app.charIDToTypeID("Ordn") | |
, app.charIDToTypeID("Trgt") ) | |
ActionDescriptor := app.executeActionGet(actRef) | |
tool_id := ActionDescriptor.getEnumerationType( app.stringIDToTypeID("tool") ) |
This file contains hidden or 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
; Create Imgurl ClientID -- https://api.imgur.com/oauth2/addclient | |
UploadToImgur(FileName, ClientID = "fbf77ff49c42c8a") { | |
return UploadToImgur.DoIt(FileName, ClientID) | |
} | |
Class UploadToImgur { | |
DoIt(FileName, ClientID) { | |
postData := this.FileToStream(FileName) |
This file contains hidden or 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
; Create your ClientID at https://api.imgur.com/oauth2/addclient | |
Imgur_Upload(FileName, ClientID = "fbf77ff49c42c8a") { | |
return Imgur.Upload(FileName, ClientID) | |
} | |
Imgur_Delete(DeleteHash, ClientID = "fbf77ff49c42c8a") { | |
return Imgur.Delete(DeleteHash, ClientID) | |
} |
This file contains hidden or 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
/* | |
; Holding down left Control key to lock, release to unlock. | |
~LControl:: | |
LockCursorToPrimaryMonitor(true) | |
KeyWait, LControl | |
LockCursorToPrimaryMonitor(false) | |
return | |
*/ | |
LockCursorToPrimaryMonitor(lock = true) { |
This file contains hidden or 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
font := FileOpen("C:\Users\Jonny\Downloads\blasad\ACaslonPro-BoldItalic.otf", "r") | |
otf := 1 ; set to 1 if using otf file, 0 for ttf | |
if !font ; error catching | |
MsgBox % "Error " A_LastError | |
while font.ReadUInt() != 0x656D616E ; "name" table | |
continue | |
;font.seek(0xCC) | |
;msgbox % font.ReadUInt() |
This file contains hidden or 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
; CreateFormData() by tmplinshi, AHK Topic: https://autohotkey.com/boards/viewtopic.php?t=7647 | |
; Thanks to Coco: https://autohotkey.com/boards/viewtopic.php?p=41731#p41731 | |
; Modified version by SKAN, 09/May/2016 | |
CreateFormData(ByRef retData, ByRef retHeader, objParam) { | |
New CreateFormData(retData, retHeader, objParam) | |
} | |
Class CreateFormData { |