Skip to content

QLab Multi Toggle (Armed, Flagged, Autoload).applescript

antoniondc edited this page Oct 29, 2025 · 1 revision

description: author: Antonio Nunes version: "1.0" source: testedqlab: "4.7" testedmacos: 10.15.7 separateprocess: "true"

Overview

Brief description of the script’s purpose, what problem it solves, and its context in QLab workflow.


Usage

How to Run

  1. Script Library:
    Add this script to ~/Library/Script Libraries/QLab/Cue/Inspector/Basic

  2. Script Cue:
    Paste the script contents into a Script Cue in your QLab project.

set CUE_PROPERTY to "armed" -- "armed", "flagged", "autoload"
set RELATIVE_MODE to false


set utils to getScriptFromLibrary("Applescript Utilities.scpt")
utils's initGlobals()
run getScriptFromLibrary("Cue:Inspector:Basics:QLab Multi Toggle (Armed, Flagged, Autoload).scpt")

on getScriptFromLibrary(relativeSubPath)
	return load script file ((path to library folder from user domain as text) & "Script Libraries:Qlab:" & relativeSubPath)
end getScriptFromLibrary

Parameters / User Variables

Variable Type Default Description
CUE_PROPERTY string armed chose property "armed", "flagged", "autoload"
RELATIVE_MODE bolean false false= cycle all cue to arm or desarm. true= cycle relative do estado atual do cue
  • Where and how to set these (via Memo Cues, global variable, etc).

What It Does

  • List out the steps the script takes or the operations performed.

  • Point out any QLab features used (e.g., "Modifies all selected cues", "Creates a fade cue with specified parameters", etc).

  • Mention any limitations or known issues.


Related Scripts


Credits

If adapted, credit the source/original author here.

#todo

  • Add uma funcionalidade que aceita uma string dentro de Note para armar ou desarmar o cue
set userDefaultSearchString to "REHEARSAL" -- Use this to specify the default search string

-- Declarations

global dialogTitle
set dialogTitle to "Batch disarm"

-- Get the search string

set {theText, theButton} to {text returned, button returned} of (display dialog ¬
	"Arm/disarm cues whose name contains (return an empty string to cancel):" with title dialogTitle with icon 1 ¬
	default answer userDefaultSearchString buttons {"Toggle", "Arm", "Disarm"} default button "Disarm")

-- Check for cancel

if theText is "" then
	error number -128
end if

-- Copy the search string to the Clipboard and arm/disarm the cues

set the clipboard to theText

tell front workspace
	set foundCues to cues whose q list name contains theText
	set foundCuesRef to a reference to foundCues
	repeat with eachCue in reverse of foundCuesRef -- Reversed so as to do a Group Cue's children before it
		if theButton is "Arm" then
			set armed of eachCue to true
		else if theButton is "Disarm" then
			set armed of eachCue to false
		else
			set armed of eachCue to not armed of eachCue
		end if
	end repeat
end tell

Menu

=================== < Back To Repo > ===================

Clone this wiki locally