Every edit in Keynote that can be undone is an object in the document: a
command message. Apple has not published these messages; the definitions below
are those iWorkFileFormat recovered from Keynote 6.0 (2013), so later versions may add
fields. This page lists the command messages of four definition files:
KNCommandArchives (Keynote),
TSWPCommandArchives (text), TSDCommandArchives (drawing
objects) and the base commands of TSKArchives. The table commands are on
table undo commands and the
chart commands on
chart undo commands.
Notation as on the tables page:
req required, rep repeated, all others optional; a bracketed
number is the message type of the
message type numbers page. A message
shown without a number has none in the type registry that iWorkFileFormat read, so it is
nested in another message or its number is unknown. The source gives only the shape of
each command, not what it does; the descriptions here are read from the names and field
names and are not confirmed by Apple.
Base messages
Nearly every command starts with a TSK.CommandArchive in field 1, named
super. It is the only thing the commands share.
message TSK.CommandArchive {
1 TSP.Reference undoRedoState; 2 TSP.Reference undoCollection
}
message TSK.CommandGroupArchive { // type 202
req TSK.CommandArchive super = 1; rep TSP.Reference commands = 2;
3 TSP.IndexSet process_results
}
message TSK.CommandContainerArchive { // type 203
rep TSP.Reference commands = 1
}
message TSK.ReplaceAllChildCommandArchive { req TSK.CommandArchive super = 1 }
message TSK.ReplaceAllCommandArchive { // type 204
req TSK.CommandArchive super = 1; rep TSP.Reference commands = 2;
req string find_string = 3; req string replace_string = 4; req uint32 options = 5
}
message TSK.AddAnnotationAuthorCommandArchive { // type 214
req TSK.CommandArchive super = 1; 2 TSP.Reference document_root;
3 TSP.Reference annotation_author
}
message TSK.SetAnnotationAuthorColorCommandArchive { // type 215
req TSK.CommandArchive super = 1; 2 TSP.Reference annotation_author; 3 TSP.Color color
}
message TSS.ApplyThemeChildCommandArchive { // type 411
req TSK.CommandArchive super = 1; 2 TSP.Reference parent
}
A command group (202) is one undo step made of several commands. The history that
holds the groups, TSK.CommandHistory (201), and the selection behaviour
history are on document
messages. The drawing layer wraps the commands of one gesture in
TSD.DrawablesCommandGroupArchive and selection behaviour messages,
described below.
Keynote commands (KN)
Slides, builds, transitions, master slides, recordings and the soundtrack. Keynote
keeps its slides as a tree of slide nodes under a show; most commands name the node
or object they change and carry the old and new value so that undo needs no
recomputation. Many commands change a property chosen by a string name
(property); the source gives no list of the names, so those are unknown
here. The messages these commands change are on
slides, builds and transitions and
document messages.
Inserting, moving and removing slides
message KN.CommandShowInsertSlideArchive { // type 101
enum Kind { kKindInsertSlide = 0; kKindInsertSlideForPaste = 1;
kKindInsertSlideForDuplicate = 2 }
req TSK.CommandArchive super = 1; req TSP.Reference show = 2;
req TSP.Reference slideNode = 3; req uint32 childIndex = 4;
req TSP.Reference parentSlideNode = 5; 6 Kind kind [default = kKindInsertSlide]
}
message KN.CommandShowMoveSlideArchive { // type 102
req TSK.CommandArchive super = 1; req TSP.Reference show = 2;
req TSP.Reference slideNode = 3; rep TSP.Reference parentSlideNodes = 4;
rep uint32 childIndices = 5
}
message KN.CommandShowRemoveSlideArchive { // type 103
req TSK.CommandArchive super = 1; req TSP.Reference show = 2;
req TSP.Reference slideNode = 3; req TSP.Reference parentSlideNode = 4;
req uint32 childIndex = 5
}
message KN.SlideCollectionCommandSelectionBehaviorArchive { // type 147
enum Type { kKindSlideSelectionBehaviorTypeGeneral = 0;
kKindSlideSelectionBehaviorTypeInsertion = 1;
kKindSlideSelectionBehaviorTypeDeletion = 2; kKindSlideSelectionBehaviorTypeMove = 3 }
1 TSP.Reference archived_new_selection; 2 TSP.Reference archived_old_selection;
3 Type type [default = kKindSlideSelectionBehaviorTypeGeneral]
}
message KN.UIStateCommandGroupArchive { // type 115
req TSK.CommandGroupArchive super = 1; req TSP.Reference uiState = 2;
req string property = 3; rep TSP.Reference slideNodesToEdit = 4;
rep TSP.Reference masterSlideNodesToApply = 5; rep TSP.Size thumbnailSizes = 6;
rep TSP.Reference selectedSlideNodes = 7; rep TSP.Reference restoreSelectedSlideNodes = 8
}
The index fields (childIndex, childIndices) place a slide in
its parent’s list of children; a slide node can have child nodes (see
slides, builds and transitions). The
selection behaviour message records the selection before and after, so undo can
restore it. UIStateCommandGroup is a command group (type 202) that also
holds a user interface state object, a property name, the slide nodes to edit, the
master slide nodes to apply, thumbnail sizes and the selected nodes; the source does
not say more.
Drawables on slides
message KN.CommandSlideInsertDrawablesArchive { // type 104
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2;
rep TSP.Reference drawables = 3; 4 bool forDrag; 5 int32 atIndex;
req bool use_object_placeholder_geometry = 6
}
message KN.CommandSlideRemoveDrawableArchive { // type 105
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2;
rep TSP.Reference sortedDrawables = 3; req TSP.IndexSet drawableIndices = 4;
rep string placeholderTags = 5; 6 TSP.Reference info_using_object_placeholder_geometry;
7 bool did_match_object_placeholder_geometry
}
message KN.CommandSlideMoveDrawableZOrderArchive { // type 118
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2;
rep TSP.Reference infos = 3; rep TSP.Reference old_ordered_infos = 4;
req TSP.IndexSet indexes = 5
}
message KN.CommandSlidePasteDrawablesArchive { // type 116
req TSK.CommandArchive super = 1; rep TSP.Reference commands = 2;
req TSP.Reference slide = 3; rep TSP.Reference drawables = 4;
5 bool has_builds [default = false]
}
message KN.CommandSlideSetPlaceholdersForTagsArchive { // type 137
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
rep TSP.Reference infos = 3; rep string tags = 4; rep TSP.Reference old_infos = 6;
rep string old_tags = 5
}
message KN.ChartInfoGeometryCommandArchive { // type 148
req TSK.CommandArchive super = 1
}
A placeholder tag is the string that says which placeholder of the master
a drawable fills (title, body and so on); the values are not listed in the source.
ChartInfoGeometryCommandArchive has no fields beyond the base command.
Slide and show properties
message KN.CommandSlideNodeSetPropertyArchive { // type 106
message PropertyValue { 1 bool boolValue; 3 TSP.DataReference image;
2 TSP.Reference database_image }
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2; req string property = 3;
req PropertyValue oldValue = 4; req PropertyValue newValue = 5
}
message KN.CommandSlideSetValueArchive { // type 113
message PropertyValue { 1 bool boolValue; 2 TSP.Reference objectValue; 3 TSD.FillArchive fill }
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2; req string property = 3;
req PropertyValue oldValue = 4; req PropertyValue newValue = 5;
req TSP.Reference oldSlideStyle = 6
}
message KN.CommandSlideSetStyleArchive { // type 136
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
req TSP.Reference slide_style = 3; req TSP.Reference old_slide_style = 4
}
message KN.CommandShowSetValueArchive { // type 124
message PropertyValue { 1 bool bool_value; 2 double double_value;
3 ShowArchive.KNShowMode show_mode_value; 4 TSP.Size size_value }
req TSK.CommandArchive super = 1; req TSP.Reference show = 2; req string property = 3;
req PropertyValue old_value = 4; req PropertyValue new_value = 5
}
message KN.CommandShowSetSlideNumberVisibilityArchive { // type 123
req TSK.CommandArchive super = 1; req TSP.Reference show = 2;
req bool slideNumbersVisible = 3; 4 TSP.Reference providerUndo
}
message KN.CommandShowChangeThemeArchive { // type 143
req TSK.CommandArchive super = 1; req TSP.Reference show = 2; req TSP.Reference theme = 3;
req TSP.Reference old_theme = 4; 5 string template_identifier;
6 string old_template_identifier
}
message KN.CommandSlideApplyThemeArchive { // type 117
req TSS.ApplyThemeChildCommandArchive super = 1; req KN.MasterChangeBlobArchive blob = 2
}
KNShowMode is on the
document messages page. Which
properties these commands name (property) is not in the source: the
booleans, objects, fills and images in the value messages suggest background, skip,
thumbnail and similar settings, but that is a guess and the names are unknown.
Master slides
message KN.CommandInsertMasterArchive { // type 135
req TSK.CommandArchive super = 1; req TSP.Reference theme = 2;
req TSP.Reference master_slide_node = 3; req uint32 insertion_index = 4;
req bool was_inserted_with_drop = 5
}
message KN.CommandRemoveMasterArchive { // type 140
req TSK.CommandArchive super = 1; req TSP.Reference theme = 2;
req TSP.Reference master_slide_node = 3; req uint32 previous_index = 4;
5 TSP.Reference master_change_commands
}
message KN.CommandMoveMastersArchive { // type 134
req TSK.CommandArchive super = 1; req TSP.Reference theme = 2;
rep TSP.Reference master_slides = 3; rep TSP.Reference previous_indexes_keys = 4;
rep uint32 previous_indexes_values = 5; rep TSP.Reference final_master_arrangement = 6
}
message KN.CommandRenameMasterArchive { // type 141
req TSK.CommandArchive super = 1; req TSP.Reference master_slide = 2;
req string master_name = 3; req string old_master_name = 4
}
message KN.CommandMasterRescaleArchive { // type 133
req TSK.CommandArchive super = 1; req TSP.Reference master = 2
}
message KN.CommandMasterSetThumbnailTextArchive { // type 142
req TSK.CommandArchive super = 1; req TSP.Reference master = 2; req bool is_body = 3;
4 string new_text; 5 string old_text
}
message KN.CommandMasterSetBodyStylesArchive { // type 145
req TSK.CommandArchive super = 1; req TSP.Reference master = 2;
rep TSP.Reference new_paragraph_styles = 3; rep TSP.Reference new_list_styles = 4;
rep TSP.Reference old_paragraph_styles = 5; rep TSP.Reference old_list_styles = 6
}
message KN.CommandChangeMasterSlideArchive { // type 119
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
req TSP.Reference master = 3; req TSP.Reference placeholder_commands = 4
}
message KN.CommandSlidePrimitiveSetMasterArchive { // type 144
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
req TSP.Reference master = 3; req TSP.Reference old_master = 4
}
message KN.CommandSlideReapplyMasterArchive { // type 146
req TSK.CommandArchive super = 1; req TSP.Reference reapply_accumulated_command = 2
}
Builds, build chunks and transitions
message KN.CommandSlideInsertBuildArchive { // type 107
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2;
req TSP.Reference build = 3; req uint32 index = 4; 5 bool shouldCreateChunks
}
message KN.CommandSlideRemoveBuildArchive { // type 109
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2;
req TSP.Reference build = 3; req uint32 index = 4
}
message KN.CommandSlideMoveBuildWithoutMovingChunksArchive { // type 108
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2;
req uint32 index = 3; req uint32 oldIndex = 4
}
message KN.CommandSlideMoveBuildsArchive { // no number
req TSK.CommandArchive super = 1; rep TSP.Reference builds = 2; 3 uint32 toIndex
}
message KN.CommandSlideInsertBuildChunkArchive { // type 110
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
req BuildChunkArchive buildChunk = 3; req uint32 index = 4
}
message KN.CommandSlideRemoveBuildChunkArchive { // type 112
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
req BuildChunkArchive buildChunk = 3; req uint32 index = 4
}
message KN.CommandSlideMoveBuildChunkArchive { // type 111
req TSK.CommandArchive super = 1; req TSP.Reference slide = 2;
req uint32 index = 3; req uint32 oldIndex = 4
}
message KN.CommandSlideMoveBuildChunksArchive { // type 139
req TSK.CommandArchive super = 1; rep BuildChunkArchive buildChunks = 2; 3 uint32 toIndex
}
message KN.CommandBuildSetValueArchive { // type 100
req TSK.CommandArchive super = 1; req TSP.Reference build = 2; req string property = 3;
rep string effects = 4; rep string types = 5; rep string deliveries = 6;
rep uint32 directions = 7; rep double durations = 8; rep double delays = 9;
rep double delayAutomaticAfters = 10; rep double delayAutomaticWiths = 11;
rep bool eventTriggers = 12
}
message KN.CommandBuildChunkSetValueArchive { // type 138
req TSK.CommandArchive super = 1; req BuildChunkArchive buildChunk = 2;
req string property = 3; rep uint32 referents = 4; rep bool automatics = 5;
rep double durations = 6; rep double delays = 7; 8 bool oldOwnsValue
}
message KN.CommandTransitionSetValueArchive { // type 114
req TSK.CommandArchive super = 1; req TSP.Reference slideNode = 2; req string property = 3;
rep string effects = 4; rep string unused = 5; rep string unused2 = 6;
rep string unused3 = 7; rep double durations = 8; rep uint32 directions = 9;
rep bool isAutomatics = 10; rep double delays = 11
}
The set-value commands hold parallel lists: element n of each list belongs
to the same build, chunk or slide, which is how one command changes several at once.
The fields unused, unused2 and unused3 are
named so in the source. The effect, type and delivery lists are strings; the source
does not list the values, and neither does it name the codes in
directions (unknown).
Recordings and soundtrack
message KN.CommandShowMarkOutOfSyncRecordingArchive { // type 128
req TSK.CommandArchive super = 1; req TSP.Reference show = 2; 3 TSP.Reference old_recording
}
message KN.CommandShowRemoveRecordingArchive { // type 129
req TSK.CommandArchive super = 1; req TSP.Reference show = 2; 3 TSP.Reference old_recording
}
message KN.CommandShowReplaceRecordingArchive { // type 130
req TSK.CommandArchive super = 1; req TSP.Reference show = 2;
req TSP.Reference replacement_recording = 3; req double replacement_start_time = 4;
5 TSP.Reference old_recording
}
message KN.CommandShowSetSoundtrack { // type 131
req TSK.CommandArchive super = 1; 2 TSP.Reference show; 3 TSP.Reference soundtrack;
4 TSP.Reference old_soundtrack
}
message KN.CommandSoundtrackSetValue { // type 132
message PropertyValue { 1 double double_value; 2 Soundtrack.SoundtrackMode mode_value;
rep TSP.DataReference media_reference_values = 3 }
req TSK.CommandArchive super = 1; 2 TSP.Reference soundtrack; 3 string property;
4 PropertyValue old_value; 5 PropertyValue new_value
}
SoundtrackMode is on the
slides, builds and transitions
page.
Text commands (TSWP)
Commands of the text framework, used by Pages, Keynote and Numbers. Most carry a
TSWP.UndoTransaction (the record that undoes a text edit; its messages
are on text and styles) and the
storage the command changed.
Editing text
message TSWP.DummyCommandArchive { req uint32 foo = 1 }
message TSWP.TextCommandArchive { // type 2101
enum Kind {
kKindContained = 0; kKindReplaceText = 1; kKindPaste = 2; kKindParagraphStyle = 3;
kKindListStyle = 4; kKindIndentParagraphLevel = 5; kKindDragText = 6;
kKindPasteStyle = 7; kKindApplyChangesInRange = 8; kKindSetParagraphLevel = 9;
kKindInsertCitationField = 10; kKindInsertBibliographyEntry = 11;
kKindFormatCitationFields = 12; kKindInsertTOCSmartField = 13;
kKindInsertDateTimeField = 14; kKindUpdateDateTimeField = 15;
kKindSetParagraphFirstTopicNumber = 16; kKindCharacterStyle = 17;
kKindRevertStyles = 18; kKindSetParagraphBidi = 19
}
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 UndoTransaction undo_transaction;
4 uint32 restore_range_location; 5 uint32 restore_range_length;
6 uint32 redo_restore_range_location; 7 uint32 redo_restore_range_length;
9 uint32 text_command_flags; 10 Kind kind [default = kKindContained]
}
message TSWP.ReplaceAllTextCommandArchive { // type 2104
1 TSK.ReplaceAllChildCommandArchive super; 2 TSP.Reference storage;
3 UndoTransaction undo_transaction
}
message TSWP.FormatTextCommandArchive { // type 2105
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 UndoTransaction undo_transaction;
8 uint32 selection_range_location; 9 uint32 selection_range_length;
11 uint32 text_command_flags
}
message TSWP.InsertAttachmentCommandArchive { // type 2102
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 TSP.Reference attachment; 6 UndoTransaction undo_transaction;
7 uint32 text_command_flags; 8 uint32 redo_restore_range_location;
9 uint32 redo_restore_range_length
}
message TSWP.ApplyPlaceholderTextCommandArchive { // type 2107
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 UndoTransaction undo_transaction
}
message TSWP.ApplyHighlightTextCommandArchive { // type 2108
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 UndoTransaction undo_transaction; 6 bool remove
}
message TSWP.UpdateDateTimeFieldCommandArchive { // type 2119
1 TextCommandArchive super; 2 TSP.Reference date_time_field; 3 TSP.Date date;
4 DateTimeSmartFieldArchive.DateTimeFormatterStyle date_style;
5 DateTimeSmartFieldArchive.DateTimeFormatterStyle time_style
}
message TSWP.AnchorAttachmentCommandArchive { // type 2206
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 TSP.Reference attachment;
4 uint32 h_offset_type; 5 float h_offset; 6 uint32 v_offset_type; 7 float v_offset;
8 UndoTransaction undo_transaction; 9 bool is_html_wrap
}
message TSWP.TextApplyThemeCommandArchive { // type 2207
1 TSS.ApplyThemeChildCommandArchive super; 2 TSP.Reference storage;
6 UndoTransaction undo_transaction
}
text_command_flags is an unnamed bit field in the source (unknown). The
offset_type codes are not named either. The range fields are character
positions and lengths in the storage.
Hyperlinks, ruby text and contents
message TSWP.CreateHyperlinkCommandArchive { // type 2113
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 string url_ref; 6 UndoTransaction undo_transaction
}
message TSWP.RemoveHyperlinkCommandArchive { // type 2114
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 UndoTransaction undo_transaction; 6 bool is_remove_character_style [default = true]
}
message TSWP.ModifyHyperlinkCommandArchive { // type 2115
1 TSK.CommandArchive super; 2 TSP.Reference hyperlink; 3 string display_text;
4 string url_ref; 5 UndoTransaction undo_transaction
}
message TSWP.ApplyRubyTextCommandArchive { // type 2116
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 string ruby_text; 6 UndoTransaction undo_transaction
}
message TSWP.RemoveRubyTextCommandArchive { // type 2117
1 TSK.CommandArchive super; 2 TSP.Reference storage;
3 uint32 selection_range_location; 4 uint32 selection_range_length;
5 UndoTransaction undo_transaction
}
message TSWP.ModifyRubyTextCommandArchive { // type 2118
1 TSK.CommandArchive super; 2 TSP.Reference ruby_field; 3 string ruby_text;
4 string base_text; 5 UndoTransaction undo_transaction
}
message TSWP.ModifyTOCSettingsBaseCommandArchive { // type 2120
1 TSK.CommandArchive super; 2 TSP.Reference old_toc_settings;
3 TSP.Reference new_toc_settings
}
message TSWP.ModifyTOCSettingsForTOCInfoCommandArchive { // type 2121
1 ModifyTOCSettingsBaseCommandArchive super; 2 TSP.Reference toc_info
}
message TSWP.ModifyTOCSettingsPresetForThemeCommandArchive { // type 2122
1 ModifyTOCSettingsBaseCommandArchive super; 2 TSP.Reference theme; 3 uint32 preset_index
}
Text-owned grids (rows and columns inside a storage)
These commands have no type number in the registry that was read. Their fields name a storage plus a row or column index, so they probably edit a grid kept in a text storage; the source does not say which objects use them.
message TSWP.SetColumnStyleCommandArchive {
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 UndoTransaction undo_transaction
}
message TSWP.ReplaceAllUsesOfStyleCommandArchive {
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 UndoTransaction undo_transaction
}
message TSWP.InsertColumnsCommandArchive {
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 column_index;
4 uint32 column_count; 5 UndoTransaction undo_transaction
}
message TSWP.RemoveColumnsCommandArchive { // same fields as InsertColumns
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 column_index;
4 uint32 column_count; 5 UndoTransaction undo_transaction
}
message TSWP.InsertRowsCommandArchive {
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 row_index;
4 uint32 row_count; 5 UndoTransaction undo_transaction
}
message TSWP.RemoveRowsCommandArchive { // same fields as InsertRows
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 row_index;
4 uint32 row_count; 5 UndoTransaction undo_transaction
}
message TSWP.MergeCellsCommandArchive {
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 row; 4 uint32 column;
5 uint32 row_count; 6 uint32 column_count; 7 UndoTransaction undo_transaction
}
message TSWP.MoveColumnsCommandArchive {
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 src_index;
4 uint32 dst_index; 5 uint32 count; 6 UndoTransaction undo_transaction
}
message TSWP.MoveRowsCommandArchive { // same fields as MoveColumns
1 TSK.CommandArchive super; 2 TSP.Reference storage; 3 uint32 src_index;
4 uint32 dst_index; 5 uint32 count; 6 UndoTransaction undo_transaction
}
Styles
message TSWP.StyleBaseCommandArchive { // type 2400
1 TSK.CommandArchive super; 2 TSP.Reference theme; 3 TSP.Reference style
}
message TSWP.StyleCreateCommandArchive { // type 2401
1 StyleBaseCommandArchive super; 2 uint32 preset_index
}
message TSWP.StyleRenameCommandArchive { // type 2402
1 StyleBaseCommandArchive super; 2 string updated_name; 3 string old_name
}
message TSWP.StyleUpdateCommandArchive { // type 2403
1 StyleBaseCommandArchive super; 2 TSP.Reference original_style;
3 TSP.Reference updated_style
}
message TSWP.StyleDeleteCommandArchive { // type 2404
1 StyleBaseCommandArchive super; 2 uint32 old_preset_index
}
message TSWP.StyleReorderCommandArchive { // type 2405
1 StyleBaseCommandArchive super; 2 uint32 old_preset_index; 3 uint32 new_preset_index
}
message TSWP.StyleUpdatePropertyMapCommandArchive { // type 2406
req TSS.StyleUpdatePropertyMapCommandArchive super = 1
}
message TSWP.ShapeApplyPresetCommandArchive { // type 2231
req TSD.ShapeApplyPresetCommandArchive super = 1
}
message TSWP.ShapePasteStyleCommandArchive { // type 2232
req TSD.PasteStyleCommandArchive super = 1; 2 TSP.Reference paragraph_style;
3 TSP.Reference list_style; 4 TSP.Reference character_style
}
The preset_index fields locate a style in the theme’s preset list. The
theme-level commands (types 410 to 418, TSS) are listed by number on
message type numbers; their fields
are in TSSArchives.proto, which this page does not reproduce except for
the two it embeds.
Drawing commands (TSD)
Commands on shapes, images, movies, groups and lines; the same in every iWork
program. Fields typed TSD.…Archive are messages of the
drawables page.
Command groups and selection
message TSD.DrawablesCommandGroupArchive { // type 3020
enum DrawablesCommandGroupType { Constructive = 1; Destructive = 2; InPlace = 3 }
req TSK.CommandGroupArchive super = 1; 2 TSD.CanvasSelectionArchive obsolete_selection;
3 TSP.Reference modelforselection; 4 DrawablesCommandGroupType type; 5 bool forDrag;
6 TSP.Reference archivedselection
}
message TSD.CommandSelectionBehaviorArchive { // type 3046
enum CommandSelectionBehaviorType { Constructive = 1; Destructive = 2; InPlace = 3;
Replace = 4 }
2 TSP.Reference model_for_selection; 3 CommandSelectionBehaviorType type;
4 TSP.Reference archived_selection; 5 TSP.Reference archived_new_selection
}
Geometry, path and grouping
message TSD.InfoGeometryCommandArchive { // type 3021
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 GeometryArchive newGeometry;
4 GeometryArchive oldGeometry; 5 bool shouldClearObjectPlaceholderFlag;
6 bool didMatchObjectPlaceholderGeometry
}
message TSD.DrawablePathSourceCommandArchive { // type 3022
req TSK.CommandArchive super = 1; 2 TSP.Reference info;
3 PathSourceArchive oldpathsource; 4 PathSourceArchive newpathsource
}
message TSD.ShapePathSourceFlipCommandArchive { // type 3023
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 bool newHorizontalFlip;
4 bool newVerticalFlip; 5 bool oldHorizontalFlip; 6 bool oldVerticalFlip
}
message TSD.GroupDrawablesCommandArchive { // type 3038
req TSK.CommandArchive super = 1; rep TSP.Reference drawables = 2; 3 TSP.Reference group
}
message TSD.UngroupGroupCommandArchive { // type 3039
req TSK.CommandArchive super = 1; rep TSP.Reference drawables = 2; 3 TSP.Reference group
}
message TSD.ContainerRemoveChildrenCommandArchive { // type 3052
req TSK.CommandArchive super = 1; 2 TSP.Reference container;
rep TSP.Reference children = 3; 4 TSP.IndexSet children_indices
}
message TSD.ContainerInsertChildrenCommandArchive { // type 3053
req TSK.CommandArchive super = 1; 2 TSP.Reference container;
rep TSP.Reference children = 3; 4 uint64 index
}
message TSD.ContainerReorderChildrenCommandArchive { // type 3054
req TSK.CommandArchive super = 1; 2 TSP.Reference container;
rep TSP.Reference children = 3; 4 TSP.IndexSet children_indices
}
message TSD.ConnectionLineConnectCommandArchive { // type 3041
req TSK.CommandArchive super = 1; req TSP.Reference connection_line = 2;
3 TSP.Reference connect_to; 4 TSP.Reference connect_from;
5 TSP.Reference old_connect_to; 6 TSP.Reference old_connect_from
}
message TSD.ShapeSetLineEndCommandArchive { // type 3035
req TSK.CommandArchive super = 1; 2 TSP.Reference shape; 3 LineEndArchive line_end;
4 bool is_head_line_end
}
message TSD.ExteriorTextWrapCommandArchive { // type 3036
message InfoAndWrap { 1 TSP.Reference info; 2 ExteriorTextWrapArchive exterior_text_wrap }
req TSK.CommandArchive super = 1; rep InfoAndWrap info_and_wrap = 2
}
message TSD.GuideCommandArchive { // type 3050
enum GuideCommandMode { Add = 1; Replace = 2; Delete = 3 }
req TSK.CommandArchive super = 1; 2 TSP.Reference storage;
3 UserDefinedGuideArchive old_guide; 4 UserDefinedGuideArchive new_guide;
5 GuideCommandMode mode
}
Styles and properties
message TSD.StyledInfoSetStyleCommandArchive { // type 3048
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 TSP.Reference style
}
message TSD.ShapeStyleSetValueCommandArchive { // type 3028
req StyledInfoSetStyleCommandArchive super = 1;
4 ShapeStylePropertiesArchive shape_properties
}
message TSD.ShapeApplyPresetCommandArchive { // type 3031
req StyledInfoSetStyleCommandArchive super = 1; 10 TSP.Reference stylepreset;
11 TSP.Color colorpreset; 12 FillArchive fillpreset; 13 ShadowArchive shadowpreset
}
message TSD.MediaStyleSetValueCommandArchive { // type 3030
req StyledInfoSetStyleCommandArchive super = 1;
4 MediaStylePropertiesArchive media_properties
}
message TSD.MediaApplyPresetCommandArchive { // type 3032
req StyledInfoSetStyleCommandArchive super = 1; 10 TSP.Reference stylepreset;
11 ShadowArchive shadowpreset
}
message TSD.DrawableApplyThemeCommandArchive { // type 3033
req TSS.ApplyThemeChildCommandArchive super = 1; 2 TSP.Reference info;
3 TSP.Reference style
}
message TSD.DrawableShadowCommandArchive {
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 ShadowArchive oldshadow;
4 ShadowArchive newshadow
}
message TSD.PasteStyleCommandArchive { // type 3059
req TSK.CommandArchive super = 1; req TSP.Reference dest_info = 2;
3 TSP.Reference shape_style
}
Images and movies
message TSD.MovieSetValueCommandArchive { // type 3034
message PropertyValue {
1 double starttime; 2 double endtime; 3 double postertime;
4 TSP.DataReference posterimagedata; 5 bool autoplay; 6 LoopOption loopOption;
7 float volume; 8 TSP.DataReference media; 9 TSP.DataReference importedauxiliarymedia
}
enum LoopOption { None = 0; Repeat = 1; BackAndForth = 2 }
req TSK.CommandArchive super = 1; 2 TSP.Reference movie;
3 string deprecated_property; 4 int32 property; 5 PropertyValue value
}
message TSD.ImageMediaCommandArchive { // type 3025
req TSK.CommandArchive super = 1; 2 TSP.Reference info;
8 TSP.DataReference newImageData; 9 TSP.DataReference oldImageData;
10 TSP.DataReference oldOriginalImageData; 6 TSP.Size oldNaturalSize;
11 TSP.DataReference newOriginalImageData; 12 ImageAdjustmentsArchive oldImageAdjustments;
13 TSP.DataReference oldAdjustedImageData; 14 TSP.DataReference oldEnhancedImageData;
3 TSP.Reference database_newImageData; 4 TSP.Reference database_oldImageData;
5 TSP.Reference database_oldOriginalImageData; 7 TSP.Reference database_newOriginalImageData
}
message TSD.ImageReplaceCommandArchive { // type 3026
req TSK.CommandArchive super = 1
}
message TSD.MediaOriginalSizeCommandArchive { // type 3027
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 TSP.Size newOriginalSize;
4 TSP.Size oldOriginalSize
}
message TSD.ImageMaskCommandArchive { // type 3024
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 TSP.Reference newMaskInfo;
4 TSP.Reference oldMaskInfo
}
message TSD.InstantAlphaCommandArchive { // type 3042
req TSK.CommandArchive super = 1; 2 TSP.Reference image; 3 TSP.Path oldpath;
4 TSP.Path newpath
}
message TSD.ImageAdjustmentsCommandArchive { // type 3055
req TSK.CommandArchive super = 1; 2 ImageAdjustmentsArchive old_image_adjustments;
3 ImageAdjustmentsArchive new_image_adjustments; 4 TSP.DataReference adjustedImageData;
5 TSP.DataReference replacedAdjustedImageData; 6 TSP.DataReference enhancedImageData;
7 TSP.DataReference replacedEnhancedImageData
}
message TSD.MediaFlagsCommandArchive { // type 3037
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 uint32 flags
}
MovieSetValueCommandArchive.property is an integer code naming which
member of PropertyValue changed; the source does not list the codes
(unknown). MediaFlagsCommandArchive.flags is likewise an unnamed bit
field.
Other drawing commands
message TSD.DrawableHyperlinkCommandArchive { // type 3040
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 string oldhyperlink_url;
4 string newhyperlink_url
}
message TSD.DrawableLockCommandArchive { // type 3043
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 bool lock
}
message TSD.DrawableInfoCommentCommandArchive { // type 3049
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 TSP.Reference old_comment;
4 TSP.Reference new_comment
}
message TSD.CommentStorageApplyCommandArchive { // type 3060
req TSK.CommandArchive super = 1; req TSP.Reference comment_storage = 2;
req string comment_string = 3; req string old_comment_string = 4
}
message TSD.DrawableAspectRatioLockedCommandArchive { // type 3051
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 bool aspect_ratio_locked
}
message TSD.DrawableAccessibilityDescriptionCommandArchive { // type 3058
req TSK.CommandArchive super = 1; 2 TSP.Reference info; 3 string accessibility_description
}
The theme fill command is defined in TSDArchives.proto:
message TSD.ThemeReplaceFillPresetCommandArchive { // type 3057
req TSK.CommandArchive super = 1; req TSP.Reference theme = 2; req FillArchive fill = 3;
req FillArchive old_fill = 4; req uint32 index = 5
}