editor.bookmark_properties#

The widget used to edit bookmark item properties.

Classes:

BookmarkPropertyEditor(server, job, root[, ...])

The widget containing all the UI elements used to edit bookmark item properties (such as frame-rate, resolution, or SG linking).

Functions:

close()

Shows the BookmarkPropertyEditor editor.

show(server, job, root)

Shows the BookmarkPropertyEditor editor.

Data:

SECTIONS

UI layout definition

class bookmarks.editor.bookmark_properties.BookmarkPropertyEditor(server, job, root, parent=None)[source]#

Bases: BasePropertyEditor

The widget containing all the UI elements used to edit bookmark item properties (such as frame-rate, resolution, or SG linking).

Methods:

applications_button_clicked()

Application Launcher add action.

db_source()

A file path to use as the source of database values.

init_data()

Initializes data.

link_button_clicked()

ShoGrid link button click action.

prefix_button_clicked()

Suggest a prefix based on the job's name.

save_changes()

Saves changes.

shotgun_domain_button2_clicked()

Check the validity of the ShotGrid token.

shotgun_domain_button_clicked()

Opens the shotgun base domain in the browser.

shotgun_properties()

Returns the properties needed to connect to shotgun.

slacktoken_button2_clicked()

Verifies the entered Slack API token.

slacktoken_button_clicked()

Slack token button action.

teamstoken_button_clicked()

Opens the webhook help url.

applications_button_clicked()[source]#

Application Launcher add action.

db_source()[source]#

A file path to use as the source of database values.

Returns:

The database source file.

Return type:

str

init_data()[source]#

Initializes data.

ShoGrid link button click action.

prefix_button_clicked()[source]#

Suggest a prefix based on the job’s name.

save_changes()[source]#

Saves changes.

shotgun_domain_button2_clicked()[source]#

Check the validity of the ShotGrid token.

shotgun_domain_button_clicked()[source]#

Opens the shotgun base domain in the browser.

shotgun_properties()[source]#

Returns the properties needed to connect to shotgun.

slacktoken_button2_clicked()[source]#

Verifies the entered Slack API token.

slacktoken_button_clicked()[source]#

Slack token button action.

teamstoken_button_clicked()[source]#

Opens the webhook help url.

bookmarks.editor.bookmark_properties.close()[source]#

Shows the BookmarkPropertyEditor editor.

bookmarks.editor.bookmark_properties.show(server, job, root)[source]#

Shows the BookmarkPropertyEditor editor.

Parameters:
  • server (str) – ‘server’ path segment.

  • job (str) – ‘job’ path segment.

  • root (str) – ‘root’ path segment.

Returns:

The editor instance.

bookmarks.editor.bookmark_properties.SECTIONS = {0: {'color': PySide2.QtGui.QColor.fromRgbF(0.254902, 0.254902, 0.254902, 1.000000), 'groups': {0: {0: {'button': 'Suggest', 'description': "A short name of the bookmark (or job) used when saving files.\n\ne.g. 'MYB_sh0010_anim_v001.ma' where 'MYB' is the prefix specified here.", 'key': 'prefix', 'name': 'Prefix', 'placeholder': "Custom prefix, e.g. 'MYB'", 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bce7f0)>, 'widget': <class 'bookmarks.ui.LineEdit'>}}, 1: {0: {'description': "A description of this bookmark, e.g. 'Character assets'.", 'key': 'description', 'name': 'Description', 'placeholder': "A short description, e.g. 'Character assets'", 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}, 2: {0: {'description': "The framerate of the bookmark, eg, '25.0'.\n\nUsed by Bookmarks to control the format of scenes inside hosts, e.g. Maya.", 'key': 'framerate', 'name': 'Framerate', 'placeholder': "Framerate, e.g. '23.976'", 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcd110)>, 'widget': <class 'bookmarks.ui.LineEdit'>}, 1: {'description': "The output width in pixels, e.g. '1920'", 'key': 'width', 'name': 'Width', 'placeholder': 'Width in pixels', 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcdb60)>, 'widget': <class 'bookmarks.ui.LineEdit'>}, 2: {'description': "The output height in pixels, e.g. '1080'", 'key': 'height', 'name': 'Height', 'placeholder': 'Height in pixels', 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcdb60)>, 'widget': <class 'bookmarks.ui.LineEdit'>}, 3: {'description': "A default start frame for all subsequent assets.\n\nThis can be useful when the project has a custom start frame, e.g. '1001' instead of '1' or '0'.", 'key': 'startframe', 'name': 'Default Start Frame', 'placeholder': "Start frame, e.g. '1001'", 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcdb60)>, 'widget': <class 'bookmarks.ui.LineEdit'>}, 4: {'description': "The default duration of an asset in frames, e.g. '150'", 'key': 'duration', 'name': 'Default Duration', 'placeholder': "Duration, e.g. '150'", 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcdb60)>, 'widget': <class 'bookmarks.ui.LineEdit'>}}, 3: {'identifier': {'description': "Only folders containing the file specified above will be read as assets.\n\nUsing the default Maya Workspace the identifier normally is 'workspace.mel', however any other arbitrary file can be used as long it is present in the root of an asset folder.\n\nWhen left empty all folders in the bookmark will be read.", 'help': "Only folders containing the file specified here will be read as assets.\nUsing the default Maya Workspace the identifier normally is 'workspace.mel', however any other arbitrary file can be used as long it is present in the root of an asset folder.\n\nWhen left empty, all folders in the bookmark will be interpreted as assets.", 'key': 'identifier', 'name': 'Asset Identifier', 'placeholder': "A file name, e.g. 'workspace.mel'", 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'bookmark', 'name': 'Settings'}, 1: {'color': PySide2.QtGui.QColor.fromRgbF(0.254902, 0.254902, 0.254902, 1.000000), 'groups': {0: {0: {'button': 'Visit', 'button2': 'Verify', 'description': 'A valid Slack App OAuth token', 'help': 'Paste a valid <a href="https://api.slack.com/apps"><span style="color:rgba(90,200,155,255)">Slack App OAuth token</span></a> above (usually starting with <span style="color:rgba(90,200,155,255)">xoxb</span>).\n\nMake sure the app has <span style="color:rgba(90,200,155,255)">users:read</span> and <span style="color:rgba(90,200,155,255)">chat:write</span> scopes enabled. To send messages to channels the bot is not part of, add <span style="color:rgba(90,200,155,255)">chat:write.public</span>. Scopes <span style="color:rgba(90,200,155,255)">channels:read</span> and <span style="color:rgba(90,200,155,255)">groups:read</span> are needed to list available Slack Channels.\n\nSee <a href="https://api.slack.com/apps"><span style="color:rgba(90,200,155,255)">Slack API</span></a> for more information. ', 'key': 'slacktoken', 'name': 'OAuth Token', 'placeholder': 'xoxb-01234567890-0123456', 'protect': True, 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'slack', 'name': 'Slack'}, 2: {'color': None, 'groups': {0: {0: {'button': 'Visit', 'description': 'Incoming Webhook URL', 'help': 'Paste a valid <a href="https://docs.microsoft.com/en-us/microsoftteams/platform/webhooks-and-connectors/how-to/add-incoming-webhook"><span style="color:rgba(90,200,155,255)">Microsoft Incoming Webhook url</span></a> above', 'key': 'teamstoken', 'name': 'Teams Incoming Webhook', 'placeholder': 'https://***.webhook.office.com/webhookb2/*', 'protect': True, 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'msteams', 'name': 'Teams Incoming Webhook'}, 3: {'color': None, 'groups': {0: {0: {'button': 'Visit', 'button2': 'Verify', 'description': "The domain, including http:// or https://, used by shotgun. e.g. 'https://mystudio.shotgunstudio.com'", 'key': 'shotgun_domain', 'name': 'Domain', 'placeholder': 'Domain, e.g. https://mystudio.shotgunstudio.com', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 1: {'description': 'A name of a ShotGrid Script.', 'key': 'shotgun_scriptname', 'name': 'Script Name', 'placeholder': 'my-sg-script', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 2: {'description': "A ShotGrid Script API Key, e.g. 'abcdefghijklmno3bqr*1'.\n\nA valid script has to be set up for your organisation for Bookmarks to be able to connect to ShotGrid. Consult the ShotGrid documentation for details on how to set this up.", 'help': 'Make sure ShotGrid has a valid API Script set up. This can be done from the ShotGrid Admin - Scripts option.', 'key': 'shotgun_api_key', 'name': 'API Key', 'placeholder': 'abcdefghijklmno3bqr*1', 'protect': True, 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'sg', 'name': 'ShotGrid Connection'}, 4: {'color': None, 'groups': {0: {0: {'button': 'Link with ShotGrid Entity', 'description': 'Link item with a ShotGrid Entity', 'key': 'link', 'name': 'Link', 'placeholder': None, 'validator': None, 'widget': None}, 1: {'description': "Select the item's ShotGrid type", 'key': 'shotgun_type', 'name': 'Type', 'placeholder': None, 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcdb60)>, 'widget': <class 'bookmarks.editor.base_widgets.SGProjectTypesWidget'>}, 2: {'description': "The ShotGrid ID number this item is associated with. e.g. '123'.", 'key': 'shotgun_id', 'name': 'ID', 'placeholder': "ShotGrid Project ID, e.g. '123'", 'validator': <PySide2.QtGui.QRegExpValidator(0x2a201bcdb60)>, 'widget': <class 'bookmarks.ui.LineEdit'>}, 3: {'description': 'The ShotGrid project name', 'key': 'shotgun_name', 'name': 'Name', 'placeholder': "ShotGrid project name, e.g. 'MyProject'", 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'sg', 'name': 'ShotGrid Entity'}, 5: {'color': PySide2.QtGui.QColor.fromRgbF(0.254902, 0.254902, 0.254902, 1.000000), 'groups': {0: {0: {'button': 'Visit', 'description': 'A custom url of the bookmarks, e.g. https://sheets.google.com/123', 'key': 'url1', 'name': 'Link 1', 'placeholder': 'https://my.custom-url.com', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 1: {'button': 'Visit', 'description': 'A custom url of the bookmarks, e.g. https://sheets.google.com/123', 'key': 'url2', 'name': 'Link 2', 'placeholder': 'https://my.custom-url.com', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'link', 'name': 'Links'}, 6: {'color': PySide2.QtGui.QColor.fromRgbF(0.254902, 0.254902, 0.254902, 1.000000), 'groups': {0: {0: {'button': 'Add Item', 'description': 'Edit the list of applications this bookmark item uses.', 'key': 'applications', 'name': 'Applications:', 'placeholder': None, 'validator': None, 'widget': <class 'bookmarks.launcher.main.LauncherListWidget'>}}}, 'icon': 'icon', 'name': 'Application Launcher'}, 7: {'color': PySide2.QtGui.QColor.fromRgbF(0.254902, 0.254902, 0.254902, 1.000000), 'groups': {0: {0: {'description': 'The time the database was created', 'key': 'created', 'name': 'Created on:', 'placeholder': 'The time the database was created', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 1: {'description': 'The user the database was created by', 'key': 'user', 'name': 'Created by user:', 'placeholder': 'The user the database was created by', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 2: {'description': 'The user the database was created by', 'key': 'host', 'name': 'Created by host:', 'placeholder': 'The user the database was created by', 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 3: {'description': "The bookmark's original server", 'key': 'server', 'name': 'Bookmark Server:', 'placeholder': "The bookmark's original server", 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 4: {'description': "The bookmark's original job", 'key': 'job', 'name': 'Bookmark Job:', 'placeholder': "The bookmark's original job", 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}, 5: {'description': "The bookmark's original job", 'key': 'root', 'name': 'Bookmark Root:', 'placeholder': "The bookmark's original job", 'validator': None, 'widget': <class 'bookmarks.ui.LineEdit'>}}}, 'icon': 'bookmark', 'name': 'Database'}}#

UI layout definition