You can control SumatraPDF with commands:
- use command palette (
Ctrl + K) to invoke a command by its description - customize a keyboard shortcut to invoke a command by its id
- ver 3.5+: send a command via DDE e.g.
[CmdClose]to invokeClose Documentcommand - ver 3.6+: some commands accept arguments
Find command:
| Command IDs | Keyboard shortcuts | Command Palette |
|---|---|---|
File #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdClose
|
Ctrl + W, Ctrl + F4
|
Close Document | |
CmdCloseCurrentDocument
|
q
|
Close Current Document | |
CmdCommandPalette
|
Ctrl + K
|
Command Palette | |
CmdCommandPaletteTOC
|
Shift + F12
|
Command Palette: Table Of Contents | Jump to a table of contents entry of the current document, ver 3.7+ |
CmdDuplicateInNewWindow
|
Shift + Ctrl + N
|
Open Current Document In New Window | |
CmdDuplicateInNewTab
|
Open Current Document In New Tab | ver 3.6+ | |
CmdExit
|
Ctrl + Q
|
Exit Application | |
CmdMoveFrameFocus
|
F6
|
Move Frame Focus | |
CmdNewWindow
|
Ctrl + N
|
Open New SumatraPDF Window | |
CmdOpenFile
|
Ctrl + O
|
Open File... | |
CmdOpenNextFileInFolder
|
Shift + Ctrl + Right
|
Open Next File In Folder | |
CmdOpenPrevFileInFolder
|
Shift + Ctrl + Left
|
Open Previous File In Folder | |
CmdOpenSelectedDocument
|
Open Selected Document | ||
CmdPinSelectedDocument
|
Pin Selected Document | ||
CmdPrint
|
Ctrl + P
|
Print Document... | |
CmdProperties
|
Ctrl + D
|
Show Document Properties... | |
CmdReloadDocument
|
r
|
Reload Document | |
CmdRenameFile
|
F2
|
Rename File... | |
CmdReopenLastClosedFile
|
Shift + Ctrl + T
|
Reopen Last Closed | |
CmdSaveAs
|
Ctrl + S
|
Save File As... | |
CmdToggleCursorPosition
|
m
|
Toggle Cursor Position | |
CmdShowInFolder
|
Show File In Folder... | ||
CmdToggleBookmarks
|
F12
|
Toggle Bookmarks | |
CmdToggleTableOfContents
|
Toggle Table Of Contents | ver 3.6+ | |
CmdCollapseAll
|
Collapse All | ||
CmdExpandAll
|
Expand All | ||
CmdExpandToCurrentPage
|
Expand TOC to Current Page | In the Bookmarks (table of contents) sidebar, expand the tree down to the entry for the current page and select it, ver 3.7+ | |
CmdOpenEmbeddedPDF
|
Open Embedded PDF | ||
CmdSaveEmbeddedFile
|
Save Embedded File... | ||
CmdCreateShortcutToFile
|
Create .lnk Shortcut | ||
CmdSelectAll
|
Ctrl + A
|
Select All | |
CmdCopyComment
|
Copy Comment | ||
CmdCopyImage
|
Copy Image | ||
CmdCopyLinkTarget
|
Copy Link Target | ||
CmdCopySelection
|
Ctrl + C, Ctrl + Insert
|
Copy Selection | |
CmdCopyFilePath
|
Copy File Path | ver 3.5+ | |
CmdDeleteFile
|
Delete Currently Opened File | ver 3.6+ |
Search #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdFindFirst
|
Ctrl + F
|
Find | |
CmdFindToggleMatchCase
|
Find: Toggle Match Case | ||
CmdFindNext
|
F3
|
Find Next | |
CmdFindNextSel
|
Ctrl + F3
|
Find Next Selection | |
CmdFindPrev
|
Shift + F3
|
Find Previous | |
CmdFindPrevSel
|
Shift + Ctrl + F3
|
Find Previous Selection |
Viewing #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdBookView
|
Ctrl + 8
|
Book View | |
CmdFacingView
|
Ctrl + 7
|
Facing View | |
CmdInvertColors
|
Shift + I
|
Invert Colors | was `i` before 3.6 |
CmdRotateLeft
|
[, Shift + Ctrl + Subtract
|
Rotate Left | |
CmdRotateRight
|
], Shift + Ctrl + Add
|
Rotate Right | |
CmdSinglePageView
|
Ctrl + 6
|
Single Page View | |
CmdToggleContinuousView
|
c
|
Toggle Continuous View | |
CmdToggleFullscreen
|
f, Shift + Ctrl + L, F11
|
Toggle Fullscreen | |
CmdToggleMangaMode
|
Toggle Manga Mode | ||
CmdToggleMenuBar
|
F9
|
Toggle Menu Bar | |
CmdTogglePageInfo
|
i
|
Show / Hide Current Page Number | was Shift + i before 3.6 |
CmdChangeScrollbar
|
Change Scrollbar | Opens dialog to choose scrollbar mode (windows/smart/overlay/hidden) | |
CmdChangeBackgroundColor
|
Change Background Color | Opens color picker to change document background color | |
CmdToggleToolbar
|
F8
|
Toggle Toolbar | |
CmdToggleChmUI
|
Toggle CHM UI | Toggle dedicated CHM UI for CHM documents, reloading the current CHM document, ver 3.7+ | |
CmdAIChatWithClaudeCode
|
AI Chat with document using Claude Code | Toggle Claude Code chat sidebar, ver 3.7+. See AI-Chat-with-document.md | |
CmdAIChatWithGrokBuild
|
AI Chat with document using Grok Build | Toggle Grok Build chat sidebar, ver 3.7+. See AI-Chat-with-document.md#grok-build | |
CmdAIChatWithOpenAICodex
|
AI Chat with document using OpenAI Codex | Toggle OpenAI Codex chat sidebar, ver 3.7+. See AI-Chat-with-document.md#openai-codex | |
CmdToggleUseTabs
|
Toggle Use Tabs | Toggle UseTabs setting, only affects new windows, ver 3.7+ | |
CmdToggleTabsMru
|
Toggle Tabs MRU Order | Toggle TabsMru setting: Ctrl+Tab switches tabs in most recently used order, ver 3.7+ | |
CmdToggleFrequentlyRead
|
Toggle Frequently Read | ver 3.5+ | |
CmdSelectNextTheme
|
Select Next Theme | ver 3.5+ | |
CmdToggleLinks
|
Toggle Show Links | Toggle drawing blue rectangle around links, ver 3.6+ |
Tabs #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdCloseAllTabs
|
Close All Tabs | ver 3.6+ | |
CmdCloseTabsToTheLeft
|
Close Tabs To The Left | ver 3.6+ | |
CmdCloseTabsToTheRight
|
Close Tabs To The Right | ver 3.6+ | |
CmdCloseOtherTabs
|
Close Other Tabs | ver 3.6+ | |
CmdNextTab
|
Ctrl + PageUp
|
Next Tab | |
CmdPrevTab
|
Ctrl + PageDown
|
Previous Tab | |
CmdMoveTabRight
|
Ctrl + Shift + PageUp
|
Move Tab Right | ver 3.6+ |
CmdMoveTabLeft
|
Ctrl + Shift + PageDown
|
Move Tab Left | ver 3.6+ |
CmdNextTabSmart
|
Ctrl + Tab
|
Smart tab Switch | ver 3.6+ |
CmdPrevTabSmart
|
Ctrl + Shift + Tab
|
Smart tab Switch | ver 3.6+ |
CmdTabGroupSave
|
Save Tab Group | ver 3.7+ | |
CmdTabGroupRestore
|
Restore Tab Group | ver 3.7+ |
Navigation #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdScrollUp
|
k, Up
|
Scroll Up | |
CmdScrollDown
|
j, Down
|
Scroll Down | |
CmdScrollLeft
|
h, Left
|
Scroll Left | |
CmdScrollRight
|
l, Right
|
Scroll Right | |
CmdScrollUpHalfPage
|
Shift + Up
|
Scroll Up By Half Page | |
CmdScrollDownHalfPage
|
Shift + Down
|
Scroll Down By Half Page | |
CmdStartAutoScroll
|
Start Auto-Scroll | Start (or stop) middle-click-style auto-scroll anchored at the cursor, without needing a middle mouse button; move the cursor away from the anchor to scroll. Invoke again (or middle-click) to stop, ver 3.7+ | |
CmdScrollUpPage
|
Ctrl + Up, PageUp, Shift + Return, Shift + Space
|
Scroll Up By Page | |
CmdScrollDownPage
|
Ctrl + Down, PageDown, Return, Space
|
Scroll Down By Page | |
CmdScrollLeftPage
|
Shift + Left
|
Scroll Left By Page | |
CmdScrollRightPage
|
Shift + Right
|
Scroll Right By Page | |
CmdGoToFirstPage
|
Ctrl + Home, Home
|
First Page | |
CmdGoToLastPage
|
Ctrl + End, End
|
Last Page | |
CmdGoToPrevPage
|
p
|
Previous Page | |
CmdGoToNextPage
|
n
|
Next Page | |
CmdGoToPage
|
g, Ctrl + G
|
Go to Page... | |
CmdNavigateBack
|
Alt + Left, Backspace
|
Navigate Back | |
CmdNavigateForward
|
Alt + Right, Shift + Backspace
|
Navigate Forward |
Favorites #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdFavoriteAdd
|
Ctrl + B
|
Add Favorite | |
CmdFavoriteDel
|
Delete Favorite | ||
CmdFavoriteToggle
|
Toggle Favorites |
Presentation #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdTogglePresentationMode
|
Ctrl + L, Shift + F11, F5
|
View: Presentation Mode | |
CmdPresentationBlackBackground
|
.
|
Presentation Black Background | |
CmdPresentationWhiteBackground
|
w
|
Presentation White Background |
Annotations #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdCreateAnnotCaret
|
Create Caret Annotation | ||
CmdCreateAnnotCircle
|
Create Circle Annotation | ||
CmdCreateAnnotFileAttachment
|
Create File Attachment Annotation | ||
CmdCreateAnnotFreeText
|
Create Free Text Annotation | ||
CmdCreateAnnotHighlight
|
a, A
|
Create Highlight Annotation | |
CmdCreateAnnotInk
|
Create Ink Annotation | ||
CmdCreateAnnotLine
|
Create Line Annotation | ||
CmdCreateAnnotLink
|
Create Link Annotation | ||
CmdCreateAnnotPolygon
|
Create Polygon Annotation | ||
CmdCreateAnnotPolyLine
|
Create Poly Line Annotation | ||
CmdCreateAnnotPopup
|
Create Popup Annotation | ||
CmdCreateAnnotRedact
|
Create Redact Annotation | ||
CmdCreateAnnotSquare
|
Create Square Annotation | ||
CmdCreateAnnotSquiggly
|
Create Squiggly Annotation | ||
CmdCreateAnnotStamp
|
Create Stamp Annotation | ||
CmdCreateAnnotStrikeOut
|
Create Strike Out Annotation | ||
CmdCreateAnnotText
|
Create Text Annotation | ||
CmdCreateAnnotUnderline
|
u, U
|
Create Underline Annotation | |
CmdDeleteAnnotation
|
Delete
|
Delete Annotation | |
CmdEditAnnotations
|
Edit Annotations | ||
CmdSaveAnnotations
|
Shift + Ctrl + S
|
Save Annotations to existing PDF | |
CmdSaveAnnotationsNewFile
|
Save Annotations to new PDF | ver 3.6+ | |
CmdShowAnnotations
|
Show Annotations | ver 3.6+, for current document | |
CmdHideAnnotations
|
Hide Annotations | ver 3.6+, for current document | |
CmdToggleShowAnnotations
|
Toggle Showing Annotations | ver 3.6+, for current document |
Zoom #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdToggleZoom
|
z
|
Toggle Zoom | |
CmdZoomActualSize
|
Ctrl + 1
|
Zoom: Actual Size | |
CmdZoomCustom
|
Ctrl + Y
|
Zoom: Custom... | |
CmdZoomFitContent
|
Ctrl + 3
|
Zoom: Fit Content | |
CmdZoomShrinkToFit
|
Zoom: Shrink To Fit | Shows at 100% if page is smaller than view area, otherwise fits page | |
CmdZoomFitPage
|
Ctrl + 0
|
Zoom: Fit Page | |
CmdZoomFitPageAndSinglePage
|
Zoom: Fit Page and Single Page | ||
CmdZoomFitWidth
|
Ctrl + 2
|
Zoom: Fit Width | |
CmdZoomFitByOrientation
|
Zoom: Fit Page or Width by Orientation | Fit width when the view is wider than tall (landscape), fit page otherwise (portrait); re-evaluated as the window/screen is resized or rotated | |
CmdZoomFitWidthAndContinuous
|
Zoom: Fit Width And Continuous | ||
CmdZoomIn
|
Ctrl + Add
|
Zoom In | |
CmdZoomOut
|
Ctrl + Subtract
|
Zoom Out | |
CmdZoom100
|
Zoom: 100% | ||
CmdZoom12_5
|
Zoom: 12.5% | ||
CmdZoom125
|
Zoom: 125% | ||
CmdZoom150
|
Zoom: 150% | ||
CmdZoom1600
|
Zoom: 1600% | ||
CmdZoom200
|
Zoom: 200% | ||
CmdZoom25
|
Zoom: 25% | ||
CmdZoom3200
|
Zoom: 3200% | ||
CmdZoom400
|
Zoom: 400% | ||
CmdZoom50
|
Zoom: 50% | ||
CmdZoom6400
|
Zoom: 6400% | ||
CmdZoom8_33
|
Zoom: 8.33% | ||
CmdZoom800
|
Zoom: 800% |
File information / conversion #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdPdShowInfo
|
Show PDF Info | shows information about currently opened PDF file | |
CmdDocumentShowOutline
|
Show Document Outline | shows the outline (table of contents) of currently opened document | |
CmdPdfBake
|
Bake PDF File | bakes interactive form and annotation content into static graphics; saves to a new PDF file and opens it | |
CmdDocumentExtractText
|
Extract Text From Document | extract text from document pages to a .txt file, with configurable page ranges, ver 3.7+ |
External app #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdOpenWithExplorer
|
Open Directory In Explorer | ver 3.5+ | |
CmdOpenWithDirectoryOpus
|
Open Directory In Directory Opus | ver 3.5+ | |
CmdOpenWithTotalCommander
|
Open Directory In Total Commander | ver 3.5+ | |
CmdOpenWithDoubleCommander
|
Open Directory In Double Commander | ver 3.5+ | |
CmdOpenWithAcrobat
|
Open in Adobe Acrobat | ||
CmdOpenWithFoxIt
|
Open in Foxit Reader | ||
CmdOpenWithFoxItPhantom
|
Open in Foxit Phantom | ||
CmdOpenWithHtmlHelp
|
Open in Microsoft HTML Help | ||
CmdOpenWithPdfDjvuBookmarker
|
Open in Pdf&Djvu Bookmarker | ||
CmdOpenWithPdfXchange
|
Open in PDF-XChange | ||
CmdOpenWithXpsViewer
|
Open in Microsoft Xps Viewer | ||
CmdTranslateSelectionWithDeepL
|
Translate Selection With DeepL | ||
CmdTranslateSelectionWithGoogle
|
Translate Selection with Google | ||
CmdTranslateSelectionWithGrokBuild
|
Translate Selection with Grok Build | ||
CmdTranslateSelectionWithClaudeCode
|
Translate Selection with Claude Code | ||
CmdTranslateSelectionWithOpenAICodex
|
Translate Selection with OpenAI Codex | ||
CmdSearchSelectionWithBing
|
Search Selection with Bing | ||
CmdSearchSelectionWithGoogle
|
Search Selection with Google | ||
CmdSearchSelectionWithWikipedia
|
Search Selection with Wikipedia | ver 3.6+ | |
CmdSearchSelectionWithGoogleScholar
|
Search Selection with Google Scholar | ver 3.6+ | |
CmdSendByEmail
|
Send Document By Email... | ||
CmdInvokeInverseSearch
|
Invoke Inverse Search | ver 3.6+ |
System #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdAdvancedOptions
|
Advanced Options (Settings)... | ||
CmdAdvancedSettings
|
Advanced Options (Settings)... | ||
CmdChangeLanguage
|
Change Language... | ||
CmdCheckUpdate
|
Check For Updates | ||
CmdClearHistory
|
Clear History | Clears history of opened files (for recently opened list in home page) | |
CmdRemoveDeletedFilesFromHistory
|
Remove Deleted Files From History | ver 3.7+, removes from history entries for files that no longer exist on disk | |
CmdContributeTranslation
|
Contribute Translation | ||
CmdForgetSelectedDocument
|
Remove Selected Document From History | ||
CmdListPrinters
|
List Printers | ver 3.7+ | |
CmdOptions
|
Options... | ||
CmdScreenshot
|
Take Screenshot | ver 3.7+, requires Shortcuts entry (e.g. Key = PrtSc) to register global hotkey | |
CmdCropImage
|
Crop Image | ver 3.7+ | |
CmdResizeImage
|
Resize Image | ver 3.7+ | |
CmdSaveImage
|
Save Image | Save image from context menu, ver 3.7+ | |
CmdConvertImageToPdf
|
Convert Image To PDF | Save the image under the cursor (or the current image document) as a new PDF, ver 3.7+ | |
CmdPasteClipboardImage
|
Paste Image From Clipboard | Paste image from clipboard and open it, ver 3.7+ | |
CmdShowErrors
|
Show Errors | Show mupdf warnings/errors in right-click context menu, ver 3.7+ | |
CmdShowLog
|
Show Logs |
Help #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdHelpOpenManual
|
F1
|
Help: Manual | |
CmdHelpOpenKeyboardShortcuts
|
Help: Keyboard Shortcuts | ||
CmdHelpAbout
|
Help: About SumatraPDF | ||
CmdHelpOpenManualOnWebsite
|
Help: Manual On Website | ||
CmdHelpVisitWebsite
|
Help: SumatraPDF Website |
Misc #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdToggleInverseSearch
|
Toggle Inverse Search | temporarily disable TeX inverse search on left mouse click, ver 3.6+ | |
CmdToggleAntiAlias
|
Toggle Anti-Alias Rendering | Toggle anti-alias rendering in pdf and epub documents, ver 3.6+ | |
CmdToggleSmoothScroll
|
Toggle Smooth Scroll | Toggle SmoothScroll advanced setting, ver 3.7+ | |
CmdToggleScrollbarInSinglePage
|
Toggle Scrollbar In Single Page | Toggle ScrollbarInSinglePage advanced setting, ver 3.7+ | |
CmdToggleLazyLoading
|
Toggle Lazy Loading | Toggle LazyLoading advanced setting, ver 3.7+ | |
CmdToggleEscToExit
|
Toggle Esc to Exit | Toggle EscToExit advanced setting, ver 3.7+ | |
CmdToggleTips
|
Toggle Tips | Toggle ShowTips advanced setting, ver 3.7+ | |
CmdToggleReuseInstance
|
Toggle Reuse Instance | Toggle ReuseInstance advanced setting, ver 3.7+ | |
CmdToggleWindowsPreviewer
|
Register / Un-register Windows Previewer | Only available when SumatraPDF is installed. Registers or un-registers the PDF preview handler for Windows Explorer preview pane, ver 3.7+ | |
CmdToggleWindowsSearchFilter
|
Register / Un-register Windows Search Filter | Only available when SumatraPDF is installed. Registers or un-registers the PDF search filter for Windows Search indexing, ver 3.7+ | |
CmdSetTabColor
|
Set Tab Color | Set a custom color for the tab of the current document, available from tab context menu, ver 3.7+ | |
CmdPdfCompress
|
Compress PDF | Compress a PDF file using aggressive garbage collection and optimization, ver 3.7+ | |
CmdPdfDecompress
|
Decompress PDF | Decompress a PDF file for easier inspection, ver 3.7+ | |
CmdPdfDeletePages
|
Delete Pages From PDF | Delete pages from a PDF file using page ranges like 1,3-8,13-N where N is the last page, ver 3.7+ | |
CmdPdfExtractPages
|
Extract Pages From PDF | Extract pages from a PDF file using page ranges like 1,3-8,13-N where N is the last page, ver 3.7+ | |
CmdPdfEncrypt
|
Encrypt PDF | Encrypt a PDF file with a password using AES-256 encryption, ver 3.7+ | |
CmdPdfDecrypt
|
Decrypt PDF | Decrypt an encrypted PDF file, removing password protection, ver 3.7+ | |
CmdSetScreenshotHotkey
|
Set Screenshot Hotkey | Open dialog to set or remove a global hotkey for taking screenshots, ver 3.7+ | |
CmdToggleHoverPreview
|
Toggle Hover Preview | Toggle the citation / reference hover preview by setting CitationHoverDelay to -1 (disabled) or 300 (the default delay), ver 3.7+ | |
CmdReadAloud
|
Read Aloud | Read selected text (or from the viewport if no selection) through the end of the document using Windows text-to-speech. Invoking again pauses reading. Voice is chosen in the Read Aloud Voice submenu and remembered in ReadAloudVoiceId, ver 3.7+ | |
CmdPauseReadAloud
|
Pause Reading | Pause reading text aloud; resume with CmdContinueReadAloud, ver 3.7+ | |
CmdContinueReadAloud
|
Continue Reading | Continue reading text aloud from where it was paused, ver 3.7+ | |
CmdStopReadAloud
|
Stop Reading | Stop reading text aloud and clear the resume position, ver 3.7+ | |
CmdReadAloudFromTopPage
|
Start Reading From Top | Read from the first visible text in the viewport through the end of the document, ver 3.7+ | |
CmdReadAloudSelection
|
Start Reading Selection | Read the current text selection aloud, ver 3.7+ |
Debug #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdDebugCrashMe
|
Debug: Crash Me | ||
CmdDebugDownloadSymbols
|
Debug: Download Symbols | ||
CmdDebugShowNotif
|
Debug: Show Notification | ||
CmdDebugStartStressTest
|
Debug: Start Stress Test | ||
CmdDebugTestApp
|
Debug: Test App | ||
CmdDebugTogglePredictiveRender
|
Debug: Toggle Predictive Rendering | ||
CmdDebugToggleRenderInfo
|
Debug: Toggle Render Queue Info | ||
CmdDebugToggleRtl
|
Debug: Toggle Rtl | ||
CmdNone
|
Do nothing |
Deprecated or internal #
| Command IDs | Keyboard shortcuts | Command Palette | Notes |
|---|---|---|---|
CmdDebugCorruptMemory
|
don't use | ||
CmdOpenWithKnownExternalViewerFirst
|
don't use | ||
CmdOpenWithKnownExternalViewerLast
|
don't use | ||
CmdSelectionHandler
|
use SelectionHandlers advanced setting instead | ||
CmdSetTheme
|
don't use | ||
CmdViewWithExternalViewer
|
don't use | ||
CmdSaveAttachment
|
don't use | ||
CmdOpenAttachment
|
don't use | ||
CmdExec
|
don't use | ||
CmdFindMatch
|
since 3.6 it's called CmdFindToggleMatchCase |
Commands with arguments #
Ver 3.6+: some commands accept arguments which provides more capabilities when creating custom keyboard shortcut.
For example:
Shortcuts [
[
Cmd = CmdCreateAnnotHighlight #00ff00 openedit
Key = a
]
]
By default
a invokes CmdCreateAnnotHighlight with default yellow color.You can over-ride
a shortcut to create green (#00ff00) highlight annotation instead and automatically open annotations edit window (openedit boolean argument).You can create multiple keyboard shortcuts for multiple colors.
Arguments can be: strings, numbers, booleans, colors (
#rrggbb or #aarrggbb format).Arguments have names. For example
CmdCreateAnnotHighlight has color argument of type color and optional openedit boolean argument.The format of providing arguments is:
CmdCreateAnnotHighlight color: #fafafa openedit: true.For boolean arguments name is the same as
true value i.e. openedit is the same as openedit: true.For default arguments you can skip the name. For example:
color is a default CmdCreateAnnotHighlight argument so CmdCreateAnnotHighlight #fafafa is the same as CmdCreateAnnotHighlight color: #fafafaYou can combine those rules:
CmdCreateAnnotHighlight #fafafa openedit is the same as CmdCreateAnnotHighlight color: #fafafa openedit: true.CmdScrollUp, CmdScrollDown #
Ver 3.6+
Arguments:
n: default, integer, how many lines to scroll up or down (default: 1)
Use case: if you want to speed up scrolling with
j, k keys, you can re-assign them:Shortcuts [
[
Cmd = CmdScrollDown 5
Key = j
]
[
Cmd = CmdScrollUp n: 5
Key = k
]
]
CmdGoToNextPage, CmdGoToPrevPage #
Ver 3.6+
Arguments:
n: default, integer, how many pages to advance by (default: 1)
Use case: if you want to go forward, back by more than 1 page
CmdCreateAnnotHighlight and other CmdCreateAnnot* #
Arguments:
color: default, coloropenedit: boolean,falseif not givencopytoclipboard: boolean,falseif not given. For highlight/underline/squiggly/strikeout annotations, copies the selection (text of annotation) to clipboard. This used to be default behavior for built-inaetc. keyboard shortcuts but now it has to be explicitly chosen.setcontent: boolean, false if not given. For highlight/underline/squiggly/strikeout sets content of annotation to the selection (text of annotation)
Use cases:
- change default color for annotations
- create multiple shortcuts for different colors
Example: change
a to create green highlight annotation:Shortcuts [
[
Cmd = CmdCreateAnnotHighlight #00ff00 openedit
Key = a
]
]
Other CmdCreateAnnot* arguments #
Ver 3.6+
Arguments for
CmdCreateAnnotHighlight plus:color: default, color of text and border, black if not givenbgcolor: background color of annotation, fully transparent if not giventextsize: size of annotation text, 12 if not givenborderwidth: border width, 1 if not givenopacity: opacity of annotation, 0 - fully transparent (i.e. invisible), 100 - fully opaque (default if not given)interiorcolor: interior color for circle, square etc. annotations, fully transparent if not givenfocusedit: boolean, when annotation edit window opens, focus the contents edit controlfocuslist: boolean, when annotation edit window opens, focus the annotations list
CmdZoomCustom #
Ver 3.6+
Arguments:
level: default, string or integer, zoom level
level can be:- a number describing zoom level in percent e.g.:
50or50%means 50% zoom125means 125% zoom
- a virtual zoom level:
actual size(100% zoom level)fit pagefit widthfit content
Example:
Shortcuts [
[
Cmd = CmdZoomCustom 50%
Key = z
]
]
CmdCommandPalette #
Ver 3.6+
Argument:
mode: default, optional string, Values:@for opened files (tabs)#for history of files>for commands
Without an argument it defaults to
>.Example:
Shortcuts [
[
Cmd = CmdCommandPalette #
Key = Ctrl + h
]
]
Toggle commands (force an on/off state) #
Ver 3.7+
These toggle commands accept an optional
state boolean argument that forces an explicit state instead of flipping the current one. This is useful for automation (e.g. via DDE) where you want to set a known state rather than toggle blindly:CmdToggleFullscreenCmdTogglePresentationModeCmdToggleToolbarCmdToggleMenuBarCmdToggleContinuousViewCmdToggleTableOfContents,CmdToggleBookmarks
Arguments:
state: default, boolean.on/true/1/yesforces the feature on,off/false/0/noforces it off. If the document is already in the requested state, nothing happens. If omitted, the command toggles (the original behavior).
Examples (DDE):
[CmdToggleFullscreen on]
[CmdToggleToolbar off]
[CmdToggleContinuousView state: on]
Debugging #
If a custom shortcut defined in
Shortcuts doesn’t work it could be caused by invalid command name or invalid command arguments.We log information about unsuccessful parsing of a shortcut so check the logs if things don’t work as expected.