From 8ae5524807484edbe54f6518d180e56d547b5531 Mon Sep 17 00:00:00 2001 From: Yann Bertrand <5855339+yannbertrand@users.noreply.github.com> Date: Mon, 25 Mar 2024 12:01:28 +0100 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20Add=20the=20Keyboard=20section=20(#?= =?UTF-8?q?352)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Alexander Momchilov --- docs/.vitepress/config.js | 21 +++++- docs/index.md | 8 +- docs/keyboard/applefnusagetype.md | 71 ++++++++++++++++++ .../applekeyboardfnstate.md | 4 +- .../applepressandholdenabled.md | 4 +- .../images/ApplePressAndHoldEnabled/false.png | Bin .../images/ApplePressAndHoldEnabled/true.png | Bin docs/keyboard/index.md | 21 ++++++ docs/misc/index.md | 2 - 9 files changed, 119 insertions(+), 12 deletions(-) create mode 100644 docs/keyboard/applefnusagetype.md rename docs/{misc => keyboard}/applekeyboardfnstate.md (91%) rename docs/{misc => keyboard}/applepressandholdenabled.md (92%) rename docs/{misc => keyboard}/images/ApplePressAndHoldEnabled/false.png (100%) rename docs/{misc => keyboard}/images/ApplePressAndHoldEnabled/true.png (100%) create mode 100644 docs/keyboard/index.md diff --git a/docs/.vitepress/config.js b/docs/.vitepress/config.js index 716bb1c1..80bc0b3f 100644 --- a/docs/.vitepress/config.js +++ b/docs/.vitepress/config.js @@ -355,6 +355,23 @@ export default defineConfig({ }, ], }, + { + text: 'Keyboard', + items: [ + { + text: 'Key held down behavior', + link: '/keyboard/applepressandholdenabled.md', + }, + { + text: 'Configure fn/🌐︎ key', + link: '/keyboard/applefnusagetype.md', + }, + { + text: 'Function keys behavior', + link: '/keyboard/applekeyboardfnstate.md', + }, + ], + }, { text: 'Mission Control', items: [ @@ -469,10 +486,6 @@ export default defineConfig({ text: 'Close confirm changes popup', link: '/misc/nsclosealwaysconfirmschanges.md', }, - { - text: 'Function keys behavior', - link: '/misc/applekeyboardfnstate.md', - }, ], }, ], diff --git a/docs/index.md b/docs/index.md index 00930b5f..04a339eb 100644 --- a/docs/index.md +++ b/docs/index.md @@ -147,6 +147,12 @@ defaults rename ${domain} ${old_key} ${new_key} - [Enable dragging without drag lock](./trackpad/dragging.md) - [Enable dragging with three finger drag](./trackpad/trackpadthreefingerdrag.md) +### Keyboard + +- [Key held down behavior](./keyboard/applepressandholdenabled.md) +- [Configure fn/🌐︎ key](./keyboard/applefnusagetype.md) +- [Function keys behavior](./keyboard/applekeyboardfnstate.md) + ### Mission Control - [Rearrange automatically](./mission-control/mru-spaces.md) @@ -191,9 +197,7 @@ defaults rename ${domain} ${old_key} ${new_key} - [Enable spring loading for all Dock items](./misc/enable-spring-load-actions-on-all-items.md) - [Show Music song notifications](./misc/userwantsplaybacknotifications.md) - [Disable application quarantine message](./misc/lsquarantine.md) -- [Key held down behavior](./misc/applepressandholdenabled.md) - [Close confirm changes popup](./misc/nsclosealwaysconfirmschanges.md) -- [Function keys behavior](./misc/applekeyboardfnstate.md) ## 🤔 How do I add a command? diff --git a/docs/keyboard/applefnusagetype.md b/docs/keyboard/applefnusagetype.md new file mode 100644 index 00000000..957dc7fc --- /dev/null +++ b/docs/keyboard/applefnusagetype.md @@ -0,0 +1,71 @@ +--- +title: Keyboard | Fn key usage +description: Choose what happens when you press the Fn or 🌐︎ key on the keyboard. +head: + - - meta + - property: 'og:title' + content: macOS defaults > Keyboard > Fn key usage + - - meta + - property: 'og:description' + content: Choose what happens when you press the Fn or 🌐︎ key on the keyboard. +--- + +# Function key usage + +Choose what happens when you press the Fn or 🌐︎ key on the keyboard. + +⚠️ A restart of your Mac is required to apply these changes. + + + +- **Tested on macOS**: + - Sonoma +- **Parameter type**: int + - 0 + - 1 + - 2 + - 3 + +## Set to: Do Nothing (default) + +Nothing happens. + +```bash +defaults write com.apple.HIToolbox AppleFnUsageType -int "0" +``` + +## Set to: Change input source + +Switches between keyboard layouts for writing in other languages (known as input sources). + +```bash +defaults write com.apple.HIToolbox AppleFnUsageType -int "1" +``` + +## Set to: Show Emoji & Symbols + +Opens the Character Viewer for entering emoji, symbols, and more. + +```bash +defaults write com.apple.HIToolbox AppleFnUsageType -int "2" +``` + +## Set to: Start Dictation + +Starts dictation when you press the key twice (you may be asked to enable dictation first). + +```bash +defaults write com.apple.HIToolbox AppleFnUsageType -int "3" +``` + +## Read current value + +```bash +defaults read com.apple.HIToolbox AppleFnUsageType +``` + +## Reset to default value + +```bash +defaults delete com.apple.HIToolbox AppleFnUsageType +``` diff --git a/docs/misc/applekeyboardfnstate.md b/docs/keyboard/applekeyboardfnstate.md similarity index 91% rename from docs/misc/applekeyboardfnstate.md rename to docs/keyboard/applekeyboardfnstate.md index 118cdefe..7552d59d 100644 --- a/docs/misc/applekeyboardfnstate.md +++ b/docs/keyboard/applekeyboardfnstate.md @@ -1,10 +1,10 @@ --- -title: Function keys behavior | Miscellaneous +title: Function keys behavior | Keyboard description: Allows you to change the behavior of the function keys. head: - - meta - property: 'og:title' - content: macOS defaults > Miscellaneous > Function keys behaviour + content: macOS defaults > Keyboard > Function keys behaviour - - meta - property: 'og:description' content: Allows you to change the behavior of the function keys. diff --git a/docs/misc/applepressandholdenabled.md b/docs/keyboard/applepressandholdenabled.md similarity index 92% rename from docs/misc/applepressandholdenabled.md rename to docs/keyboard/applepressandholdenabled.md index 7fec30d2..3b199498 100644 --- a/docs/misc/applepressandholdenabled.md +++ b/docs/keyboard/applepressandholdenabled.md @@ -1,10 +1,10 @@ --- -title: Key held down behavior | Miscellaneous +title: Key held down behavior | Keyboard description: Allows you to select the behavior when a key is held down for a long time. head: - - meta - property: 'og:title' - content: macOS defaults > Miscellaneous > Key held down behavior + content: macOS defaults > Keyboard > Key held down behavior - - meta - property: 'og:description' content: Allows you to select the behavior when a key is held down for a long time. diff --git a/docs/misc/images/ApplePressAndHoldEnabled/false.png b/docs/keyboard/images/ApplePressAndHoldEnabled/false.png similarity index 100% rename from docs/misc/images/ApplePressAndHoldEnabled/false.png rename to docs/keyboard/images/ApplePressAndHoldEnabled/false.png diff --git a/docs/misc/images/ApplePressAndHoldEnabled/true.png b/docs/keyboard/images/ApplePressAndHoldEnabled/true.png similarity index 100% rename from docs/misc/images/ApplePressAndHoldEnabled/true.png rename to docs/keyboard/images/ApplePressAndHoldEnabled/true.png diff --git a/docs/keyboard/index.md b/docs/keyboard/index.md new file mode 100644 index 00000000..bd6f21b1 --- /dev/null +++ b/docs/keyboard/index.md @@ -0,0 +1,21 @@ +--- +title: Keyboard +description: The hardware device to type on a computer. +head: + - - meta + - property: 'og:title' + content: macOS defaults > Keyboard + - - meta + - property: 'og:description' + content: The hardware device to type on a computer. +--- + +# Keyboard + +The hardware device to type on a computer. + +## Keys + +- [Key held down behavior](./applepressandholdenabled.md) +- [Configure fn/🌐︎ key](./applefnusagetype.md) +- [Function keys behavior](./applekeyboardfnstate.md) diff --git a/docs/misc/index.md b/docs/misc/index.md index 1cf813dd..b75d7381 100644 --- a/docs/misc/index.md +++ b/docs/misc/index.md @@ -20,6 +20,4 @@ All the others `defaults` that don't deserve their own category. - [Enable spring loading for all Dock items](./enable-spring-load-actions-on-all-items.md) - [Show Music song notifications](./userwantsplaybacknotifications.md) - [Disable application quarantine message](./lsquarantine.md) -- [Key held down behavior](./applepressandholdenabled.md) - [Close confirm changes popup](./nsclosealwaysconfirmschanges.md) -- [Function keys behavior](./applekeyboardfnstate.md)