qmk_firmware/assets/features_grave_esc.md.BQRa2ZXb.js

16 lines
3.7 KiB
JavaScript
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { _ as _export_sfc, c as createElementBlock, o as openBlock, a8 as createStaticVNode } from "./chunks/framework.Cauyuiy8.js";
const __pageData = JSON.parse('{"title":"Grave Escape","description":"","frontmatter":{},"headers":[],"relativePath":"features/grave_esc.md","filePath":"features/grave_esc.md","lastUpdated":null}');
const _sfc_main = { name: "features/grave_esc.md" };
const _hoisted_1 = /* @__PURE__ */ createStaticVNode('<h1 id="grave-escape" tabindex="-1">Grave Escape <a class="header-anchor" href="#grave-escape" aria-label="Permalink to &quot;Grave Escape&quot;"></a></h1><p>If you&#39;re using a 60% keyboard, or any other layout with no F-row, you will have noticed that there is no dedicated Escape key. Grave Escape is a feature that allows you to share the grave key (<code>`</code> and <code>~</code>) with Escape.</p><h2 id="usage" tabindex="-1">Usage <a class="header-anchor" href="#usage" aria-label="Permalink to &quot;Usage&quot;"></a></h2><p>Replace the <code>KC_GRV</code> key in your keymap (usually to the left of the <code>1</code> key) with <code>QK_GESC</code>. Most of the time this key will output <code>KC_ESC</code> when pressed. However, when Shift or GUI are held down it will output <code>KC_GRV</code> instead.</p><h2 id="what-your-os-sees" tabindex="-1">What Your OS Sees <a class="header-anchor" href="#what-your-os-sees" aria-label="Permalink to &quot;What Your OS Sees&quot;"></a></h2><p>If Mary presses <code>QK_GESC</code> on her keyboard, the OS will see an KC_ESC character. Now if Mary holds Shift down and presses <code>QK_GESC</code> it will output <code>~</code>, or a shifted backtick. Now if she holds GUI/CMD/WIN, it will output a simple <code>`</code> character.</p><h2 id="keycodes" tabindex="-1">Keycodes <a class="header-anchor" href="#keycodes" aria-label="Permalink to &quot;Keycodes&quot;"></a></h2><table><thead><tr><th>Key</th><th>Aliases</th><th>Description</th></tr></thead><tbody><tr><td><code>QK_GRAVE_ESCAPE</code></td><td><code>QK_GESC</code></td><td>Escape when pressed, <code>`</code> when Shift or GUI are held</td></tr></tbody></table><h3 id="caveats" tabindex="-1">Caveats <a class="header-anchor" href="#caveats" aria-label="Permalink to &quot;Caveats&quot;"></a></h3><p>On macOS, Command+<code>`</code> is by default mapped to &quot;Move focus to next window&quot; so it will not output a backtick. Additionally, Terminal always recognises this shortcut to cycle between windows, even if the shortcut is changed in the Keyboard preferences.</p><h2 id="configuration" tabindex="-1">Configuration <a class="header-anchor" href="#configuration" aria-label="Permalink to &quot;Configuration&quot;"></a></h2><p>There are several possible key combinations this will break, among them Control+Shift+Escape on Windows and Command+Option+Escape on macOS. To work around this, you can <code>#define</code> these options in your <code>config.h</code>:</p><table><thead><tr><th>Define</th><th>Description</th></tr></thead><tbody><tr><td><code>GRAVE_ESC_ALT_OVERRIDE</code></td><td>Always send Escape if Alt is pressed</td></tr><tr><td><code>GRAVE_ESC_CTRL_OVERRIDE</code></td><td>Always send Escape if Control is pressed</td></tr><tr><td><code>GRAVE_ESC_GUI_OVERRIDE</code></td><td>Always send Escape if GUI is pressed</td></tr><tr><td><code>GRAVE_ESC_SHIFT_OVERRIDE</code></td><td>Always send Escape if Shift is pressed</td></tr></tbody></table>', 13);
const _hoisted_14 = [
_hoisted_1
];
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return openBlock(), createElementBlock("div", null, _hoisted_14);
}
const grave_esc = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
export {
__pageData,
grave_esc as default
};