# cp.apple.finalcutpro

Represents the Final Cut Pro application, providing functions that allow different tasks to be accomplished.

Generally, you will require the cp.apple.finalcutpro module to import it, like so:

local fcp = require "cp.apple.finalcutpro"

Then, there are the UpperCase files, which represent the application itself:

  • MenuBar - The main menu bar.
  • prefs/PreferencesWindow - The preferences window.
  • etc...

The fcp variable is the root application. It has functions which allow you to perform tasks or access parts of the UI. For example, to open the Preferences window, you can do this:

fcp.preferencesWindow:show()

In general, as long as Final Cut Pro is running, actions can be performed directly, and the API will perform the required operations to achieve it. For example, to toggle the 'Create Optimized Media' checkbox in the 'Import' section of the 'Preferences' window, you can simply do this:

fcp.preferencesWindow.importPanel:toggleCreateOptimizedMedia()

The API will automatically open the Preferences window, navigate to the 'Import' panel and toggle the checkbox.

The UpperCase classes also have a variety of UI methods. These will return the axuielement for the relevant GUI element, if it is accessible. If not, it will return nil. These allow direct interaction with the GUI if necessary. It's most useful when adding new functions to UpperCase files for a particular element.

This can also be used to 'wait' for an element to be visible before performing a task. For example, if you need to wait for the Preferences window to finish loading before doing something else, you can do this with the just library:

local just = require "cp.just"

local prefsWindow = fcp.preferencesWindow

local prefsUI = just.doUntil(function() return prefsWindow:UI() end)

if prefsUI then
	-- it's open!
else
	-- it's closed!
end

By using the just library, we can do a loop waiting until the function returns a result that will give up after a certain time period (10 seconds by default).

Of course, we have a specific support function for that already, so you could do this instead:

if fcp.preferencesWindow:isShowing() then
	-- it's open!
else
	-- it's closed!
end

Delegates to: app, menu

Notes: All values/methods/props from delegates can be accessed directly from the cp.apple.finalcutpro instance. For example:

fcp.app:UI() == fcp:UI() -- the same `cp.prop` result.

# Submodules


# API Overview

Constants - Useful values which cannot be changed

  • ALLOWED_IMPORT_AUDIO_EXTENSIONS
  • ALLOWED_IMPORT_EXTENSIONS
  • ALLOWED_IMPORT_IMAGE_EXTENSIONS
  • ALLOWED_IMPORT_VIDEO_EXTENSIONS
  • EARLIEST_SUPPORTED_VERSION
  • EVENT_DESCRIPTION_PATH
  • FLEXO_LANGUAGES
  • PASTEBOARD_UTI
  • preferences
  • WORKSPACES_PATH

Variables - Configurable values

  • activeCommandSet
  • customWorkspaces
  • openAndSavePanelDefaultPath
  • selectedWorkspace

Functions - API calls offered directly by the extension

  • commandSet
  • matches
  • matches
  • userCommandSetPath
  • workflowExtensionNames

Constructors - API calls which return an object, typically one that offers API methods

  • Color
  • TranscodeMedia

Fields - Variables which can only be accessed from an object returned by a constructor

  • activeCommandSetPath
  • alert
  • audioEnhancements
  • audioLanes
  • audioMeters
  • backgroundTasksDialog
  • browser
  • changePosition
  • color
  • colorBoard
  • colorCorrection
  • commandDescriptions
  • commandEditor
  • commandNames
  • commandPostWorkflowExtension
  • contentUI
  • contentUI
  • deselectAll
  • effects
  • effects
  • eventViewer
  • exportDialog
  • findAndReplaceTitleText
  • fullScreenPlayer
  • generators
  • inspector
  • inspectorUnits
  • isAudioScrubbingEnabled
  • isFrontmost
  • isInstalled
  • isModalDialogOpen
  • isPlaying
  • isPlaying
  • isRunning
  • isShowing
  • isSkimmingEnabled
  • isSupported
  • isUnsupported
  • keywordEditor
  • libraries
  • media
  • mediaImport
  • pan
  • playButton
  • playFullScreen
  • playImage
  • preferencesWindow
  • preset
  • primaryWindow
  • resetDialogWarnings
  • secondaryWindow
  • textArea
  • textLayerLeft
  • textLayerRight
  • timecodeField
  • timeDisplay
  • timeline
  • toolbar
  • transcodeMedia
  • transitions
  • UI
  • validateAudioUnits
  • viewer
  • volume

Methods - API calls which can only be made on an object returned by a constructor

  • activeLibraryPaths
  • closeLibrary
  • defaultCommandSetPath
  • doShortcut
  • getCommandShortcuts
  • getPath
  • importXML
  • keysWithString
  • openLibrary
  • plugins
  • recentLibraryNames
  • recentLibraryPaths
  • scanPlugins
  • selectLibrary
  • string
  • userCommandSets

# API Documentation

# Constants

# ALLOWED_IMPORT_AUDIO_EXTENSIONS

Signature cp.apple.finalcutpro.ALLOWED_IMPORT_AUDIO_EXTENSIONS -> table
Type Constant
Description Table of audio file extensions Final Cut Pro can import.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 236

# ALLOWED_IMPORT_EXTENSIONS

Signature cp.apple.finalcutpro.ALLOWED_IMPORT_EXTENSIONS -> table
Type Constant
Description Table of all file extensions Final Cut Pro can import.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 246

# ALLOWED_IMPORT_IMAGE_EXTENSIONS

Signature cp.apple.finalcutpro.ALLOWED_IMPORT_IMAGE_EXTENSIONS -> table
Type Constant
Description Table of image file extensions Final Cut Pro can import.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 241

# ALLOWED_IMPORT_VIDEO_EXTENSIONS

Signature cp.apple.finalcutpro.ALLOWED_IMPORT_VIDEO_EXTENSIONS -> table
Type Constant
Description Table of video file extensions Final Cut Pro can import.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 231

# EARLIEST_SUPPORTED_VERSION

Signature cp.apple.finalcutpro.EARLIEST_SUPPORTED_VERSION -> string
Type Constant
Description The earliest version of Final Cut Pro supported by this module.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 206

# EVENT_DESCRIPTION_PATH

Signature cp.apple.finalcutpro.EVENT_DESCRIPTION_PATH -> string
Type Constant
Description The Event Description Path.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 221

# FLEXO_LANGUAGES

Signature cp.apple.finalcutpro.FLEXO_LANGUAGES -> table
Type Constant
Description Table of Final Cut Pro's supported Languages for the Flexo Framework
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 226

# PASTEBOARD_UTI

Signature cp.apple.finalcutpro.PASTEBOARD_UTI -> string
Type Constant
Description Final Cut Pro's Pasteboard UTI
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 211

# preferences

Signature cp.apple.finalcutpro.preferences <cp.app.prefs>
Type Constant
Description The cp.app.prefs for Final Cut Pro.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 161

# WORKSPACES_PATH

Signature cp.apple.finalcutpro.WORKSPACES_PATH -> string
Type Constant
Description The path to the custom workspaces folder.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 216

# Variables

# activeCommandSet

Signature cp.apple.finalcutpro.activeCommandSet <cp.prop: table; live>
Type Variable
Description Contins the 'Active Command Set' as a table. The result is cached, but
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1058

# customWorkspaces

Signature cp.apple.finalcutpro:customWorkspaces <cp.prop: table; live>
Type Variable
Description A table containing the display names of all the user created custom workspaces.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 616

# openAndSavePanelDefaultPath

Signature cp.apple.finalcutpro:openAndSavePanelDefaultPath <cp.prop: string>
Type Variable
Description A string containing the default open/save panel path.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 943

# selectedWorkspace

Signature cp.apple.finalcutpro.selectedWorkspace <cp.prop: string; live>
Type Variable
Description The currently selected workspace name. The result is cached, but updated
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 584

# Functions

# commandSet

Signature cp.apple.finalcutpro.commandSet(path) -> string
Type Function
Description Gets the Command Set at the specified path as a table.
Parameters
  • path - The path to the Command Set.
Returns
  • The Command Set as a table, or nil if there was a problem.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1040

# matches

Signature cp.apple.finalcutpro.main.CommandEditor.matches(element) -> boolean
Type Function
Description Checks to see if an element matches what we think it should be.
Parameters
  • element - An axuielementObject to check.
Returns
  • true if matches otherwise false
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/main/LibrariesList.lua line 30

# matches

Signature cp.apple.finalcutpro.viewer.TranscodeMedia.matches(element) -> boolean
Type Function
Description Checks if the element is an TranscodeMedia instance.
Parameters
  • element - The axuielement to check.
Returns
  • true if it matches the pattern for a Viewer TranscodeMedia.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/main/TranscodeMedia.lua line 21

# userCommandSetPath

Signature cp.apple.finalcutpro.userCommandSetPath() -> string or nil
Type Function
Description Gets the path where User Command Set files are stored.
Parameters
  • None
Returns
  • A path as a string or nil if the folder doesn't exist.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 984

# workflowExtensionNames

Signature cp.apple.finalcutpro.workflowExtensionNames() -> table
Type Function
Description Gets the names of all the installed Workflow Extensions.
Parameters
  • None
Returns
  • A table of Workflow Extension names
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 645

# Constructors

# Color

Signature cp.apple.finalcutpro.main.Color(app) -> Color
Type Constructor
Description Creates a new Color instance.
Parameters
  • app - The Final Cut Pro app instance.
Returns
  • The new Color.
Notes None
Examples None
Source src/extensions/cp/blackmagic/resolve/color/Tracker.lua line 34

# TranscodeMedia

Signature cp.apple.finalcutpro.viewer.TranscodeMedia(viewer)
Type Constructor
Description Creates a new TranscodeMedia instance.
Parameters
  • parent - The parent object.
Returns
  • The new TranscodeMedia.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/main/TranscodeMedia.lua line 42

# Fields

# activeCommandSetPath

Signature cp.apple.finalcutpro.activeCommandSetPath <cp.prop: string>
Type Field
Description Gets the 'Active Command Set' value from the Final Cut Pro preferences
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1033

# alert

Signature cp.apple.finalcutpro.alert <cp.ui.Alert>
Type Field
Description Provides basic access to any 'alert' dialog windows in the app.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 907

# audioEnhancements

Signature cp.apple.finalcutpro.inspector.color.VideoInspector.audioEnhancements <cp.prop: PropertyRow>
Type Field
Description Audio Enhancements
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/audio/AudioInspector.lua line 139

# audioLanes

Signature cp.apple.finalcutpro.timeline.audioLanes <cp.prop: boolean>
Type Field
Description Indicates if audio lanes are currently showing. May be set to ensure it is showing or hidden.
Notes None
Source src/extensions/cp/apple/finalcutpro/timeline/IndexRoles.lua line 103

# audioMeters

Signature cp.apple.finalcutpro.viewer.audioMeters <cp.ui.Button>
Type Field
Description Audio Meters button.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 93

# backgroundTasksDialog

Signature cp.apple.finalcutpro.backgroundTasksDialog <cp.apple.finalcutpro.main.BackgroundTasksDialog>
Type Field
Description The BackgroundTasksDialog dialog window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 790

# browser

Signature cp.apple.finalcutpro.browser <cp.apple.finalcutpro.main.Browser>
Type Field
Description The Browser instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 844

# changePosition

Signature cp.apple.finalcutpro.viewer.changePosition <cp.ui.Button>
Type Field
Description Change Position Button.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 236

# color

Signature cp.apple.finalcutpro.color <ColorInspector>
Type Field
Description The ColorInspector instance from the primary window
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 900

# colorBoard

Signature cp.apple.finalcutpro.colorBoard <ColorBoard>
Type Field
Description The ColorBoard instance from the primary window
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 893

# colorCorrection

Signature cp.apple.finalcutpro.presfs.GeneralPanel.colorCorrection <cp.ui.PopUpButton>
Type Field
Description The "Color Correction" PopUpButton.
Notes None
Source src/extensions/cp/apple/finalcutpro/prefs/GeneralPanel.lua line 116

# commandDescriptions

Signature cp.apple.finalcutpro.commandDescriptions <cp.strings>
Type Field
Description The table of all available command descriptions, with keys mapped to human-readable descriptions in the current locale.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1135

# commandEditor

Signature cp.apple.finalcutpro.commandEditor <CommandEditor>
Type Field
Description The Final Cut Pro Command Editor
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 755

# commandNames

Signature cp.apple.finalcutpro.commandNames <cp.strings>
Type Field
Description The table of all available command names, with keys mapped to human-readable names in the current locale.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1114

# commandPostWorkflowExtension

Signature cp.apple.finalcutpro.commandPostWorkflowExtension <CommandPostWindow>
Type Field
Description The CommandPost Workflow Extension window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 714

# contentUI

Signature cp.apple.finalcutpro.inspector.color.TextInspector.contentUI <cp.prop: hs.axuielement; read-only>
Type Field
Description The axuielement containing the properties rows, if available.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/text/TextInspector.lua line 438

# contentUI

Signature cp.apple.finalcutpro.inspector.color.ShareInspector.contentUI <cp.prop: hs.axuielement; read-only>
Type Field
Description The axuielement containing the properties rows, if available.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/share/ShareInspector.lua line 105

# deselectAll

Signature cp.apple.finalcutpro.inspector.color.TextInspector.deselectAll <cp.ui.Button>
Type Field
Description The left text layer arrow at the bottom of the Inspector.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/text/TextInspector.lua line 473

# effects

Signature cp.apple.finalcutpro.effects <cp.apple.finalcutpro.main.EffectsBrowser>
Type Field
Description The EffectsBrowser instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 872

# effects

Signature cp.apple.finalcutpro.inspector.color.VideoInspector.effects <cp.prop: PropertyRow>
Type Field
Description Effects
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/audio/AudioInspector.lua line 153

# eventViewer

Signature cp.apple.finalcutpro.eventViewer <cp.apple.finalcutpro.viewer.Viewer>
Type Field
Description The Event Viewer instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 837

# exportDialog

Signature cp.apple.finalcutpro.exportDialog <cp.apple.finalcutpro.main.ExportDialog>
Type Field
Description The Final Cut Pro Export Dialog Box
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 776

# findAndReplaceTitleText

Signature cp.apple.finalcutpro.findAndReplaceTitleText <cp.apple.finalcutpro.main.FindAndReplaceTitleText>
Type Field
Description The FindAndReplaceTitleText dialog window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 783

# fullScreenPlayer

Signature cp.apple.finalcutpro.fullScreenPlayer <FullScreenPlayer>
Type Field
Description Returns the Final Cut Pro Full Screen Window (usually triggered by Cmd+Shift+F)
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 748

# generators

Signature cp.apple.finalcutpro.generators <cp.apple.finalcutpro.main.GeneratorsBrowser>
Type Field
Description The GeneratorsBrowser instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 865

# inspector

Signature cp.apple.finalcutpro.inspector <cp.apple.finalcutpro.inspector.Inspector>
Type Field
Description The Inspector instance from the primary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 886

# inspectorUnits

Signature cp.apple.finalcutpro.presfs.GeneralPanel.inspectorUnits <cp.ui.PopUpButton>
Type Field
Description The "Inspector Units" PopUpButton.
Notes None
Source src/extensions/cp/apple/finalcutpro/prefs/GeneralPanel.lua line 125

# isAudioScrubbingEnabled

Signature cp.apple.finalcutpro.isAudioScrubbingEnabled <bool; live>
Type Field
Description Returns true if the audio scrubbing is enabled for the application.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1163

# isFrontmost

Signature cp.apple.finalcutpro:isFrontmost <cp.prop: boolean; read-only; live>
Type Field
Description Is Final Cut Pro Frontmost?
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 288

# isInstalled

Signature cp.apple.finalcutpro.isInstalled <cp.prop: boolean; read-only>
Type Field
Description Is any version of Final Cut Pro Installed?
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 281

# isModalDialogOpen

Signature cp.apple.finalcutpro:isModalDialogOpen <cp.prop: boolean; read-only>
Type Field
Description Is a modal dialog currently open?
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 295

# isPlaying

Signature cp.apple.finalcutpro.main.ControlBar.isPlaying <cp.prop: boolean>
Type Field
Description The 'playing' status of the viewer. If true, it is playing, if not it is paused.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 254

# isPlaying

Signature cp.apple.finalcutpro.main.Viewer.isPlaying <cp.prop: boolean>
Type Field
Description The 'playing' status of the viewer. If true, it is playing, if not it is paused.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/Viewer.lua line 336

# isRunning

Signature cp.apple.finalcutpro.isRunning <cp.prop: boolean; read-only>
Type Field
Description Is Final Cut Pro Running?
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 263

# isShowing

Signature cp.apple.finalcutpro.isShowing <cp.prop: boolean; read-only; live>
Type Field
Description Is Final Cut visible on screen?
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 274

# isSkimmingEnabled

Signature cp.apple.finalcutpro.isSkimmingEnabled <bool; live>
Type Field
Description Returns true if the skimming playhead is enabled for the application.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1156

# isSupported

Signature cp.apple.finalcutpro.isSupported <cp.prop: boolean; read-only; live>
Type Field
Description Is a supported version of Final Cut Pro installed?
Notes
  • Supported version refers to any version of Final Cut Pro equal or higher to cp.apple.finalcutpro.EARLIEST_SUPPORTED_VERSION
Source src/extensions/cp/apple/finalcutpro/init.lua line 302

# isUnsupported

Signature cp.apple.finalcutpro.isUnsupported <cp.prop: boolean; read-only>
Type Field
Description Is an unsupported version of Final Cut Pro installed?
Notes
  • Supported version refers to any version of Final Cut Pro equal or higher to cp.apple.finalcutpro.EARLIEST_SUPPORTED_VERSION
Source src/extensions/cp/apple/finalcutpro/init.lua line 315

# keywordEditor

Signature cp.apple.finalcutpro.keywordEditor <KeywordEditor>
Type Field
Description The Final Cut Pro Keyword Editor
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 762

# libraries

Signature cp.apple.finalcutpro.libraries <cp.apple.finalcutpro.main.LibrariesBrowser>
Type Field
Description The LibrariesBrowser instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 851

# media

Signature cp.apple.finalcutpro.media <cp.apple.finalcutpro.main.MediaBrowser>
Type Field
Description The MediaBrowser instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 858

# mediaImport

Signature cp.apple.finalcutpro.mediaImport <MediaImport>
Type Field
Description The Final Cut Pro Media Import Window
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 769

# pan

Signature cp.apple.finalcutpro.inspector.color.VideoInspector.pan <cp.prop: PropertyRow>
Type Field
Description Pan
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/audio/AudioInspector.lua line 146

# playButton

Signature cp.apple.finalcutpro.viewer.playButton <cp.ui.Button>
Type Field
Description Play Button.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 245

# playFullScreen

Signature cp.apple.finalcutpro.viewer.playFullScreen <cp.ui.Button>
Type Field
Description Play Full Screen Button.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 84

# playImage

Signature cp.apple.finalcutpro.viewer.playImage <cp.ui.Image>
Type Field
Description Play Image.
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 279

# preferencesWindow

Signature cp.apple.finalcutpro.preferencesWindow <PreferencesWindow>
Type Field
Description The Final Cut Pro Preferences Window
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 727

# preset

Signature cp.apple.finalcutpro.inspector.color.TextInspector.preset <cp.ui.PopUpButton>
Type Field
Description The preset popup found at the top of the inspector.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/text/TextInspector.lua line 483

# primaryWindow

Signature cp.apple.finalcutpro.primaryWindow <cp.apple.finalcutpro.main.PrimaryWindow>
Type Field
Description The Final Cut Pro Primary Window
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 734

# resetDialogWarnings

Signature cp.apple.finalcutpro.presfs.GeneralPanel.resetDialogWarnings <cp.ui.Buton>
Type Field
Description The "Reset Dialog warnings" Button.
Notes None
Source src/extensions/cp/apple/finalcutpro/prefs/GeneralPanel.lua line 98

# secondaryWindow

Signature cp.apple.finalcutpro.secondaryWindow <cp.apple.finalcutpro.main.SecondaryWindow>
Type Field
Description The Final Cut Pro Preferences Window
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 741

# textArea

Signature cp.apple.finalcutpro.inspector.color.TextInspector.textArea <cp.ui.TextArea>
Type Field
Description The Text Inspector main Text Area.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/text/TextInspector.lua line 493

# textLayerLeft

Signature cp.apple.finalcutpro.inspector.color.TextInspector.textLayerLeft <cp.ui.Button>
Type Field
Description The left text layer arrow at the bottom of the Inspector.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/text/TextInspector.lua line 451

# textLayerRight

Signature cp.apple.finalcutpro.inspector.color.TextInspector.textLayerRight <cp.ui.Button>
Type Field
Description The left text layer arrow at the bottom of the Inspector.
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/text/TextInspector.lua line 462

# timecodeField

Signature cp.apple.finalcutpro.viewer.timecodeField <cp.ui.StaticText>
Type Field
Description Timecode Field
Notes None
Source src/extensions/cp/apple/finalcutpro/viewer/ControlBar.lua line 102

# timeDisplay

Signature cp.apple.finalcutpro.presfs.GeneralPanel.timeDisplay <cp.ui.PopUpButton>
Type Field
Description The "Time Display" PopUpButton.
Notes None
Source src/extensions/cp/apple/finalcutpro/prefs/GeneralPanel.lua line 89

# timeline

Signature cp.apple.finalcutpro.timeline <Timeline>
Type Field
Description The Timeline instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 823

# toolbar

Signature cp.apple.finalcutpro.toolbar <cp.apple.finalcutpro.main.PrimaryToolbar>
Type Field
Description The Primary Toolbar - the toolbar at the top of the Primary Window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 816

# transcodeMedia

Signature cp.apple.finalcutpro.transcodeMedia <cp.apple.finalcutpro.main.TranscodeMedia>
Type Field
Description The TranscodeMedia sheet.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 803

# transitions

Signature cp.apple.finalcutpro.transitions <cp.apple.finalcutpro.main.EffectsBrowser>
Type Field
Description The Transitions EffectsBrowser instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 879

# UI

Signature cp.apple.finalcutpro.UI <cp.prop: hs.axuielement; read-only; live>
Type Field
Description The Final Cut Pro axuielement, if available.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 270

# validateAudioUnits

Signature cp.apple.finalcutpro.presfs.GeneralPanel.validateAudioUnits <cp.ui.Buton>
Type Field
Description The "Validate Audio Units" Button.
Notes None
Source src/extensions/cp/apple/finalcutpro/prefs/GeneralPanel.lua line 107

# viewer

Signature cp.apple.finalcutpro.viewer <cp.apple.finalcutpro.viewer.Viewer>
Type Field
Description The Viewer instance, whether it is in the primary or secondary window.
Notes None
Source src/extensions/cp/apple/finalcutpro/init.lua line 830

# volume

Signature cp.apple.finalcutpro.inspector.color.VideoInspector.volume <cp.prop: PropertyRow>
Type Field
Description Volume
Notes None
Source src/extensions/cp/apple/finalcutpro/inspector/audio/AudioInspector.lua line 132

# Methods

# activeLibraryPaths

Signature cp.apple.finalcutpro:activeLibraryPaths() -> table
Type Method
Description Gets a table of all the active library paths.
Parameters
  • None
Returns
  • A table containing any active library paths.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 400

# closeLibrary

Signature cp.apple.finalcutpro:closeLibrary(title) -> boolean
Type Method
Description Attempts to close a library with the specified title.
Parameters
  • title - The title of the FCP Library to close.
Returns
  • true if successful, or false if not.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 505

# defaultCommandSetPath

Signature cp.apple.finalcutpro:defaultCommandSetPath([locale]) -> string
Type Method
Description Gets the path to the 'Default' Command Set.
Parameters
  • locale - The optional locale to use. Defaults to the current locale.
Returns
  • The 'Default' Command Set path, or nil if an error occurred
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1019

# doShortcut

Signature cp.apple.finalcutpro:doShortcut(whichShortcut[, suppressPrompt]) -> Statement
Type Method
Description Perform a Final Cut Pro Keyboard Shortcut
Parameters
  • whichShortcut - As per the Command Set name
  • suppressPrompt - If true, and no shortcut is found for the specified command, then no prompt will be shown and an error is thrown Defaults to false.
Returns
  • A Statement that will perform the shortcut when executed.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1173

# getCommandShortcuts

Signature cp.apple.finalcutpro.getCommandShortcuts(id) -> table of hs.commands.shortcut
Type Method
Description Finds a shortcut from the Active Command Set with the specified ID and returns a table of hs.commands.shortcuts for the specified command, or nil if it doesn't exist.
Parameters
  • id - The unique ID for the command.
Returns
  • The array of shortcuts, or nil if no command exists with the specified id.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 1088

# getPath

Signature cp.apple.finalcutpro:getPath() -> string or nil
Type Method
Description Path to Final Cut Pro Application
Parameters
  • None
Returns
  • A string containing Final Cut Pro's filesystem path, or nil if Final Cut Pro's path could not be determined.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 357

# importXML

Signature cp.apple.finalcutpro:importXML(path) -> boolean
Type Method
Description Imports an XML file into Final Cut Pro
Parameters
  • path = Path to XML File
Returns
  • A boolean value indicating whether the AppleScript succeeded or not
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 920

# keysWithString

Signature cp.apple.finalcutpro:keysWithString(string[, locale]) -> {string}
Type Method
Description Looks up an application string and returns an array of keys that match. It will take into account current locale the app is running in, or use locale if provided.
Parameters
  • key - The key to look up.
  • locale - The locale (defaults to current FCPX locale).
Returns
  • The array of keys with a matching string.
Notes
  • This method may be very inefficient, since it has to search through every possible key/value pair to find matches. It is not recommended that this is used in production.
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 340

# openLibrary

Signature cp.apple.finalcutpro:openLibrary(path) -> boolean
Type Method
Description Attempts to open a file at the specified absolute path.
Parameters
  • path - The path to the FCP Library to open.
Returns
  • true if successful, or false if not.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 467

# plugins

Signature cp.apple.finalcutpro:plugins() -> cp.apple.finalcutpro.plugins
Type Method
Description Returns the plugins manager for the app.
Parameters
  • None
Returns
  • The plugins manager.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 552

# recentLibraryNames

Signature cp.apple.finalcutpro:recentLibraryNames() -> table
Type Method
Description Gets a table of all the recent library names (that are accessible).
Parameters
  • None
Returns
  • A table containing any recent library names.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 446

# recentLibraryPaths

Signature cp.apple.finalcutpro:recentLibraryPaths() -> table
Type Method
Description Gets a table of all the recent library paths (that are accessible).
Parameters
  • None
Returns
  • A table containing any recent library paths.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 421

# scanPlugins

Signature cp.apple.finalcutpro:scanPlugins() -> table
Type Method
Description Scan Final Cut Pro Plugins
Parameters
  • None
Returns
  • A MenuBar object
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 565

# selectLibrary

Signature cp.apple.finalcutpro:selectLibrary(title) -> axuielement
Type Method
Description Attempts to select an open library with the specified title.
Parameters
  • title - The title of the library to select.
Returns
  • The library row axuielement.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 492

# string

Signature cp.apple.finalcutpro:string(key[, locale[, quiet]]) -> string
Type Method
Description Looks up an application string with the specified key. If no locale value is provided, the current locale is used.
Parameters
  • key - The key to look up.
  • locale - The locale code to use. Defaults to the current locale.
  • quiet - Optional boolean, defaults to false. If true, no warnings are logged for missing keys.
Returns
  • The requested string or nil if the application is not running.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 325

# userCommandSets

Signature cp.apple.finalcutpro:userCommandSets() -> table
Type Method
Description Gets the names of all of the user command sets.
Parameters
  • None
Returns
  • A table of user command sets as strings.
Notes None
Examples None
Source src/extensions/cp/apple/finalcutpro/init.lua line 997