[AutoHotKey] 명령줄이 트위터에 이미지를 업로드할 때 첨부 파일 이미지를 미리 보는 함수

1328 단어 AutoHotkey
  • [AutoHotKey] 함수에 동적 핫키 - Qiita 정의
  • ↑의 계속도 있다.

    이런 느낌.SplashImage에서 화면 왼쪽 상단에서 4개로 배열한다.(트위터 최대 4개)
    그림은 길든 길든 배열할 수 있다.
    ahk
    SplashTile(img,length)
    {
        gui,add,picture,hwndmypic,%img%
        controlgetpos,,,width,height,,ahk_id %mypic%
        ; via https://autohotkey.com/board/topic/12001-finding-the-widthheight-of-a-picture/
        if (width > height)
        {
            zH = -1
            zW = %length%
            zX = 0
            ZY := (length - (height * (length / width))) / 2
        }
        Else
        {
            zH = %length%
            zW = -1
            zX := (length - (width * (length / height))) / 2
            ZY = 0
        }
        static X
        static Y
        static counts
        counts += 1
        If (counts = 1 or counts = 3)
            X = 0
        Else
            X := length + 5
        If (counts < 3)
            Y = 0
        Else
            Y := length + 25
        H := (length + 20)
        SplashImage, %counts%:%img%, A B2 W%length% H%H% X%X% Y%Y% ZH%zH% ZW%zW% ZX%zX% ZY%zY% CWBlack CTWhite, , %counts%,
    }
    

    좋은 웹페이지 즐겨찾기