LoginSignup
0
0

More than 1 year has passed since last update.

QLab AppleScript: cueListの切り替え <next cue list-II>

Last updated at Posted at 2020-04-01

QLab4でscript cueを使って指定したcue listをアクティブにする.

はじめにお読みください→About Qlab AppleScript

Release Note: 2020/4/2
・ アルゴリズムの変更により動作を高速化しました ・ 高速化に伴い, 変数の設定条件を変更しています。

AppleScript

Scriptはscript cueのscriptタブに直接書き込む.

next_cue_list_hso.scpt
set nextcueList to "Target_cueList"
set selectcueNumber to "Select_CueNumber"

tell application id "com.figure53.QLab.4" to tell front workspace
	set selected to item 1 of (get every cue of (every cue list whose q name is nextcueList) whose q number is selectcueNumber)
	
	go
	
end tell

Setting

  1. [Inspecta]内の[Script]タブにスクリプトを入力する.
  2. スクリプトに変数を指定する.
  3. アクティブにしたいcue listの名前をset nextcueList to "Target_cueList"
    Target_cueListに指定する.
  4. "Compile Script"でスクリプトをコンパイルする.
    Successfully compiled. と表示されると実行可能です.
    Qiita_next_cue_list_img01.png

Variable

  • Target_cueList

  • 必須

  • 目的とするcueListの名前を指定する.

  • 指定できるcueListの名前は日本語も文字列もOK.

  • 指定する名前に""を含む場合はバックスラッシュ(\)でエスケープする.
    例) cue listの名前が***BGM "Monday"***の場合: set nextcueList to "BGM \"Monday\""

  • Select_CueNumber

  • 必須

  • 選択するcue numberを指定する.

  • 指定できるcue numberは日本語も文字列もOK.

Option

  • script cueを実行時にアクティブにしたcue listのcueをGoするにはset selected to item 1 of (get every cue of (every cue list ~の下にgoを追加する.
    選択状態で待機にする場合にはgoをコメントアウト(--go)する.

Environment

  • macOS Mojave (10.14.6)[Intel]
  • QLab 4.6.11

Reference

A CUE LIST A DAY - The QLab Cook Book

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0