Actions Reference

Actions are command codes that can be dispatched to perform operations in MuseScore. They can be invoked via the cmd() function.

Source File

src/notation/internal/notationuiactions.cpp

Using Actions

// Via MuseScore QML API cmd("action-code"); // Example cmd("note-input"); // Toggle note input mode cmd("note-c"); // Enter note C

Navigation Actions

Score Navigation

Action CodeDescription
next-elementSelect next element in score
prev-elementSelect previous element in score
notation-move-rightNext chord / shift text right
notation-move-leftPrevious chord / shift text left
notation-move-right-quicklyNext measure / shift text right quickly
notation-move-left-quicklyPrevious measure / shift text left quickly
first-elementGo to first element in score
last-elementGo to last element in score

Chord Navigation

Action CodeDescription
up-chordSelect note/rest above
down-chordSelect note/rest below
top-chordSelect top note in chord
bottom-chordSelect bottom note in chord

Staff/Voice Navigation

Action CodeDescription
move-upMove to staff above
move-downMove to staff below
next-trackGo to next staff or voice
prev-trackGo to previous staff or voice

Frame/System Navigation

Action CodeDescription
next-frameGo to next frame
prev-frameGo to previous frame
next-systemGo to next system
prev-systemGo to previous system

Note Input Actions

Note Input Mode

Action CodeDescription
note-inputToggle note input mode
note-input-steptimeStep-time note input
note-input-rhythmRhythm note input
note-input-repitchRe-pitch note input
note-input-realtime-autoReal-time (automatic) input
note-input-realtime-manualReal-time (manual) input
note-input-timewiseTimewise (insert) input

Enter Notes (by name)

Action CodeDescription
note-cEnter note C
note-dEnter note D
note-eEnter note E
note-fEnter note F
note-gEnter note G
note-aEnter note A
note-bEnter note B

Add Notes to Chord

Action CodeDescription
chord-cAdd C to chord
chord-dAdd D to chord
chord-eAdd E to chord
chord-fAdd F to chord
chord-gAdd G to chord
chord-aAdd A to chord
chord-bAdd B to chord

Insert Notes

Action CodeDescription
insert-cInsert C
insert-dInsert D
insert-eInsert E
insert-fInsert F
insert-gInsert G
insert-aInsert A
insert-bInsert B

Rests

Action CodeDescription
restEnter rest
rest-TABEnter rest (tablature)

Duration

Action CodeDescription
pad-note-1Set duration: whole note
pad-note-2Set duration: half note
pad-note-4Set duration: quarter note
pad-note-8Set duration: eighth note
pad-note-16Set duration: 16th note
pad-note-32Set duration: 32nd note
pad-note-64Set duration: 64th note
pad-note-128Set duration: 128th note
pad-note-256Set duration: 256th note
pad-note-512Set duration: 512th note
pad-note-1024Set duration: 1024th note
pad-dotToggle dot
pad-dotdotToggle double dot
pad-dot3Toggle triple dot
pad-dot4Toggle quadruple dot
double-durationDouble selected duration
half-durationHalve selected duration
inc-duration-dottedDouble duration (dotted)
dec-duration-dottedHalve duration (dotted)

Tablature Frets

Action CodeDescription
fret-0 through fret-14Enter TAB fret 0-14

Pitch Modification Actions

Action CodeDescription
pitch-upMove pitch up (semitone)
pitch-downMove pitch down (semitone)
pitch-up-octaveMove pitch up an octave
pitch-down-octaveMove pitch down an octave
pitch-up-diatonicMove pitch up (diatonic)
pitch-down-diatonicMove pitch down (diatonic)

Accidentals

Action CodeDescription
flatAdd flat
flat2Add double flat
sharpAdd sharp
sharp2Add double sharp
naturalAdd natural

Intervals

Action CodeDescription
interval1Enter unison
interval2Enter second above
interval3Enter third above
interval4Enter fourth above
interval5Enter fifth above
interval6Enter sixth above
interval7Enter seventh above
interval8Enter octave above
interval9Enter ninth above
interval10Enter tenth above
interval-2Enter second below
interval-3Enter third below
interval-4Enter fourth below
interval-5Enter fifth below
interval-6Enter sixth below
interval-7Enter seventh below
interval-8Enter octave below
interval-9Enter ninth below
interval-10Enter tenth below

Voice Actions

Action CodeDescription
voice-1Enter notes in voice 1
voice-2Enter notes in voice 2
voice-3Enter notes in voice 3
voice-4Enter notes in voice 4
voice-x12Exchange voice 1-2
voice-x13Exchange voice 1-3
voice-x14Exchange voice 1-4
voice-x23Exchange voice 2-3
voice-x24Exchange voice 2-4
voice-x34Exchange voice 3-4

Tuplets

Action CodeDescription
dupletEnter duplet
tripletEnter triplet
quadrupletEnter quadruplet
quintupletEnter quintuplet
sextupletEnter sextuplet
septupletEnter septuplet
octupletEnter octuplet
nonupletEnter nonuplet
tuplet-dialogOpen tuplet dialog

Grace Notes

Action CodeDescription
acciaccaturaAdd acciaccatura
appoggiaturaAdd appoggiatura
grace4Add grace note: quarter
grace16Add grace note: 16th
grace32Add grace note: 32nd
grace8afterAdd grace note: 8th after
grace16afterAdd grace note: 16th after
grace32afterAdd grace note: 32nd after

Articulations and Ornaments

Action CodeDescription
add-marcatoAdd marcato
add-sforzatoAdd sforzato (accent)
add-tenutoAdd tenuto
add-staccatoAdd staccato
toggle-visibleToggle element visibility

Ties and Slurs

Action CodeDescription
tieAdd tie
chord-tieAdd tied note to chord
add-slurAdd slur
add-laissez-vibAdd laissez vibrer
add-hammer-on-pull-offAdd hammer-on/pull-off

Lines and Spanners

Action CodeDescription
add-8vaAdd ottava 8va alta
add-8vbAdd ottava 8va bassa
add-hairpinAdd crescendo
add-hairpin-reverseAdd diminuendo
add-notelineAdd note-anchored line

Text Elements

Action CodeDescription
title-textAdd title
subtitle-textAdd subtitle
composer-textAdd composer
poet-textAdd lyricist
part-textAdd part name
system-textAdd system text
staff-textAdd staff text
expression-textAdd expression text
rehearsalmark-textAdd rehearsal mark
instrument-change-textAdd instrument change
fingering-textAdd fingering
sticking-textAdd sticking
chord-textAdd chord symbol
roman-numeral-textAdd Roman numeral analysis
nashville-number-textAdd Nashville number
lyricsAdd lyrics
figured-bassAdd figured bass
tempoAdd tempo marking
add-dynamicAdd dynamic

Measures and Structure

Action CodeDescription
insert-measureInsert one measure before selection
insert-measuresInsert measures before selection
append-measureInsert one measure at end
append-measuresInsert measures at end
time-deleteDelete selected measures
split-measureSplit measure before selected note
join-measuresJoin selected measures

Frames

Action CodeDescription
insert-hboxInsert horizontal frame
insert-vboxInsert vertical frame
insert-textframeInsert text frame
insert-fretframeInsert fretboard diagram legend
append-hboxAppend horizontal frame
append-vboxAppend vertical frame
append-textframeAppend text frame

Breaks

Action CodeDescription
system-breakAdd/remove system break
page-breakAdd/remove page break
section-breakAdd/remove section break
apply-system-lockAdd/remove system lock

Beaming

Action CodeDescription
beam-autoAuto beam
beam-noneNo beam
beam-break-leftBreak beam left
beam-break-inner-8thBreak inner beams (8th)
beam-break-inner-16thBreak inner beams (16th)
beam-joinJoin beams
beam-feathered-decelerateFeathered beam decelerate
beam-feathered-accelerateFeathered beam accelerate

Selection Actions

Action CodeDescription
notation-select-allSelect all
notation-select-sectionSelect section
select-similarSelect similar elements
select-similar-staffSelect similar on same staff
select-similar-rangeSelect similar in range
select-next-chordAdd next chord to selection
select-prev-chordAdd previous chord to selection

Clipboard Actions

Action CodeDescription
action://notation/copyCopy selection
action://notation/cutCut selection
action://notation/pastePaste
action://notation/deleteDelete selection
notation-paste-halfPaste half duration
notation-paste-doublePaste double duration
notation-paste-specialPaste special
notation-swapSwap with clipboard

Layout and View

Action CodeDescription
view-mode-pagePage view
view-mode-continuousContinuous view (horizontal)
view-mode-singleContinuous view (vertical)
zoominZoom in
zoomoutZoom out
zoom100Zoom to 100%

Reset Actions

Action CodeDescription
resetReset shapes and positions
reset-stretchReset layout stretch
reset-beammodeReset beams to default
reset-to-default-layoutReset entire score to default layout

Tools

Action CodeDescription
transposeOpen transpose dialog
explodeExplode (distribute to staves)
implodeImplode (combine staves)
realize-chord-symbolsRealize chord symbols
slash-fillFill with slashes
slash-rhythmToggle rhythmic slash notation
pitch-spellOptimize enharmonic spelling
reset-groupingsRegroup rhythms
resequence-rehearsal-marksResequence rehearsal marks
unroll-repeatsUnroll repeats

Undo/Redo

Action CodeDescription
undoUndo last action
redoRedo last undone action

Legacy/Compatibility Commands

Some legacy commands are mapped to new action codes:

Legacy CommandMaps To
escapeaction://notation/cancel
cutaction://notation/cut
copyaction://notation/copy
pasteaction://notation/paste
paste-halfnotation-paste-half
paste-doublenotation-paste-double
select-allnotation-select-all
deleteaction://notation/delete
next-chordnotation-move-right
prev-chordnotation-move-left
prev-measurenotation-move-left-quickly