Key Binding To Insert Footnote at End of Text

Fletcher's Avatar

Fletcher

18 Dec, 2017 02:41 PM

The following key bindings require Composer 4.2.5 or above. (Or they can be implemented for any version in the Mac OS KeyBindings file).

To use them, type the desired label for a footnote, leaving the cursor before the closing ]. For example:

Text.[^foot|]

Trigger the first command and you will end up with:

Text.[^foot]

[^foot]: |

Type the desired footnote and trigger the second command to return to your initial position in the document.

(This only works for footnote labels that consist of a single word)

[{
        "key": "f",
        "modifiers": ["cmd", "shift"],
        "action": [
            "setMark:",
            "moveWordBackwardAndModifySelection:",
            "copy:",
            "moveToEndOfDocument:",
            "insertText:", "\n\n[^",
            "paste:",
            "insertText:", "]: ",
            "moveToEndOfDocument:"
        ]
    },
    {
        "key": "f",
        "modifiers": ["cmd", "shift", "opt"],
        "action": [
            "swapWithMark:",
            "moveForward:"
        ]
    }
]

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac