docs » cp.apple.finalcutpro.main.Playhead
Playhead Module.
Functions - API calls offered directly by the extension
find
matches
Constructors - API calls which return an object, typically one that offers API methods
Playhead
Fields - Variables which can only be accessed from an object returned by a constructor
center
currentViewer
frame
isPersistent
position
timecode
Methods - API calls which can only be made on an object returned by a constructor
hide
show
| Signature | cp.apple.finalcutpro.main.Playhead.find(containerUI, skimming) -> hs._asm.axuielement object | nil
|
| -----------------------------------------------------|---------------------------------------------------------------------------------------------------------|
| Type | Function |
| Description | Finds the playhead (either persistent or skimming) in the specified container. Defaults to persistent. |
| Parameters |
containerUI
- The container UIskimming
- Whether or not you want the skimming playhead as boolean. |
| Returns | The playhead hs._asm.axuielement
object or nil
if not found. |
Signature
cp.apple.finalcutpro.main.Playhead.matches(element) -> boolean
Type
Function
Description
Checks to see if a GUI element is the Playhead or not
Parameters
element
- The element you want to check
Returns
true
if the element
is the Playhead otherwise false
Signature
cp.apple.finalcutpro.main.Playhead(parent[, skimming[, containerFn[, useEventViewer]]]) -> Playhead
Type
Constructor
Description
Constructs a new Playhead
Parameters
parent - The parent object skimming - (optional) if true
, this links to the 'skimming' playhead created under the mouse, if present. containerUI - (optional) a cp.prop
which returns the container axuielement which contains the playheads. If not present, it will use the parent's UI element. useEventViewer - (optional) if true
, this will use the Event Viewer's timecode, when available.
Returns
The new Playhead
instance.
Signature
cp.apple.finalcutpro.main.Playhead.center <cp.prop: hs.geometry.point; read-only; live?>
Type
Field
Description
Gets the centre point ({x, y}
) of the playhead.
Signature
cp.apple.finalcutpro.main.Playhead.currentViewer <cp.prop: cp.apple.finalcutpro.viewer.Viewer; read-only; live>
Type
Field
Description
Represents the current viewer for the playhead. This may be either the primary Viewer or the Event Viewer,
Signature
cp.apple.finalcutpro.main.Playhead.frame <cp.prop: hs.geometry.frame; read-only; live?>
Type
Field
Description
Gets the frame of the playhead.
Signature
cp.apple.finalcutpro.main.Playhead.isPersistent <cp.prop: boolean; read-only>
Type
Field
Description
Is the playhead persistent?
Signature
cp.apple.finalcutpro.main.Playhead.position <cp.prop; number; read-only; live?>
Type
Field
Description
Gets the horizontal position of the playhead line, which may be different to the x
position of the playhead.
Signature
cp.apple.finalcutpro.main.Playhead.timecode <cp.prop: string; live?>
Type
Field
Description
Gets and sets the current timecode.
Signature
cp.apple.finalcutpro.main.Playhead:hide() -> Playhead object
Type
Method
Description
Hides the Playhead
Parameters
Returns
Signature
cp.apple.finalcutpro.main.Playhead:show() -> Playhead object
Type
Method
Description
Shows the Playhead
Parameters
Returns