/AppleScript

My AppleScript

Primary LanguagePython

AppleScript

AppleScript 相关

[TOC]

简介

Introduction to AppleScript Language Guide

使用

Record Screen QuickTimePlayer

菜单栏上的任意功能,你都可以用 LaunchBar 来控制

details
activate application "QuickTime Player"
tell application "System Events"
    tell process "QuickTime Player"
        set frontmost to true
        # 选择菜单栏上的文件「菜单」中的「新建屏幕录制」
        click menu item "新建屏幕录制" of menu "文件" of menu bar 1
        # 等待「屏幕录制」窗口出现
        repeat until exists window "屏幕录制"
        end repeat
        # 按下空格键
        tell application "System Events" to keystroke " "
    end tell
end tell

OSAX(Scripting Additions)

参考资料

details