<p></p>
<p>You set a custom command (<code>Edit->Format->Send Selection To->Set Custom Commands</code>) and then when you activate it, it takes the selection and then sends it to the standard input of the command (in this case <code>rustfmt</code>) which does its thing (in this case formats Rust code) and then sends the result out of its standard output, which Geany then replaces the current selection with.</p>
<p>For example if you set <code>rustfmt</code> as the first custom command, the key sequence <kbd>Ctrl</kbd>+<kbd>a</kbd> <kbd>Ctrl</kbd>+<kbd>1</kbd> would format the entire current document.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/geany/geany/issues/2603#issuecomment-702846569">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAIOWJZSB24PSHLS552WAXDSIYBNHANCNFSM4R7X34BQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AAIOWJ2XQYZI5QDA4DVFACDSIYBNHA5CNFSM4R7X34B2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOFHSJM2I.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/geany/geany/issues/2603#issuecomment-702846569",
"url": "https://github.com/geany/geany/issues/2603#issuecomment-702846569",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>