Hot corners
Purpose
Hot corners let the pointer, pushed into a free corner of an output, run one action of a closed list; the top left corner starts as the Super action. This spec indexes the rules of the setting and of the trigger.
Requirements
Requirement: Only protected settings set hotCorners
Only the protected settings SHALL set the protected setting hotCorners (one action of a closed list for each corner; the top left corner is chat, a Super tap, by default) through /api/hot-corners. Full text: section Binding contract (from AGENTS.md).
Scenario: Only protected settings set hotCorners
- WHEN the user chooses an action for a corner in Configurações
- THEN the setting is saved through
/api/hot-corners
Requirement: Core owns the value, compositor starts with corners off
The core SHALL own the value and the default and send the compositor command hot_corners (capabilities.hotCorners). The compositor SHALL start with every corner off and read no file and no gsettings key for it. Full text: section Binding contract (from AGENTS.md).
Scenario: Core owns the value, compositor starts with corners off
- WHEN the compositor starts before the core connects
- THEN every corner is off
Requirement: Corner entry runs the key of the action
The compositor SHALL run the action on a pointer entry into a free corner of an output as the key of that action. Full text: section Binding contract (from AGENTS.md).
Scenario: Corner entry runs the key of the action
- WHEN the pointer enters a free corner mapped to an action
- THEN the compositor runs that action as its key does
Requirement: No agent or plugin access to hot corners
The system MUST NOT let any agent tool, MCP entry, scheduled turn, generated HTML or plugin panel reach the setting, the route or the command. Full text: section Binding contract (from AGENTS.md).
Scenario: No agent or plugin access to hot corners
- WHEN generated HTML tries to change a corner
- THEN it has no route or command to do so
Requirement: No corner runs while locked
No corner SHALL run while the session is locked. Full text: section Binding contract (from AGENTS.md).
Scenario: No corner runs while locked
- WHEN the pointer enters a corner while locked
- THEN nothing runs
Requirement: Closed action list
Each corner SHALL take one id of the closed list (none, chat, overview, terminal, screenshot, lock). No action that closes a window, ends the session or needs a target window is in the list, and a corner takes no command, no executable and no coordinates. Full text: section The protected setting.
Scenario: Closed action list
- WHEN a saved corner value is not in the list
- THEN that corner has no action
Requirement: Setting keys and defaults
The setting hotCorners SHALL have exactly the keys topLeft, topRight, bottomLeft and bottomRight. Without a saved value the core uses chat for the top left and none for the others. Full text: section The protected setting.
Scenario: Setting keys and defaults
- WHEN no value is saved
- THEN the top left corner is
chatand the other three arenone
Requirement: Route takes exactly four keys
POST /api/hot-corners SHALL take the shell token and exactly the four keys, each value from the list. Full text: section The protected setting.
Scenario: Route takes exactly four keys
- WHEN a request body lacks a key or has a value outside the list
- THEN it does not match the route contract
Requirement: Compositor command is refused while locked
The compositor SHALL refuse the hot_corners command while locked, and the core MUST NOT send the mapping while locked. Full text: section The protected setting.
Scenario: Compositor command is refused while locked
- WHEN the compositor receives
hot_cornerswhile locked - THEN it refuses the command
Requirement: Version skew keeps corners off
A core and a compositor of different versions SHALL stay safe through capabilities.hotCorners: an older core sends nothing so the corners stay off, and with an older compositor the core sends nothing and the settings section is hidden. Full text: section One place for the setting.
Scenario: Version skew keeps corners off
- WHEN the core is older than the compositor
- THEN the core sends nothing and the corners stay off
Requirement: Where a corner exists
A corner SHALL exist where the pointer stops on both axes: a corner of an output with no other output beside it or above or below it at that corner. Full text: section The trigger.
Scenario: Where a corner exists
- WHEN two monitors sit side by side
- THEN the two corners at the shared edge do not exist
Requirement: Entry threshold and rate
One entry SHALL run the action once; the next entry needs the pointer more than 32 logical pixels away from the corner on one axis first, and an entry less than 500 ms after the last action runs nothing. An entry into a different corner counts at once, also within the 32 pixels of the last one. Full text: section The trigger.
Scenario: Entry threshold and rate
- WHEN an entry comes less than 500 ms after the last action
- THEN nothing runs
Requirement: Entries that run nothing
An entry MUST run nothing while the session is locked, while a pointer button is down, during a pointer grab, while Super is held and while a panel is under the pointer. Such an entry is spent until the pointer leaves and comes back. Full text: section The trigger.
Scenario: Entries that run nothing
- WHEN a drag is released in a corner
- THEN nothing runs until the pointer leaves and comes back
Requirement: A corner takes no click
The motion SHALL still reach the client under the pointer, and a corner MUST take no click. Full text: section The trigger.
Scenario: A corner takes no click
- WHEN the pointer rests in a corner over a client
- THEN the client still gets the motion
Status
Doc status: current contract. Not proven live: two monitors. Checked 2026-11-10.
Status
Decided and built on 2026-11-04. The owner took the three recommendations of the section Decisions ("pode ser") and chose to keep the settings in state.json and not in gsettings. Publishing, the build, the next login and the check in the live session are separate steps; see the section Verification.
The owner's words (2026-11-04, Portuguese, quoted): "Adiciona hotcorners, de cara já deixa cadastrado que no topo esquerdo a gente abre o overview de janelas (Super), os outros podem ser configurados, essa ideia existe na configuração do gnome shell/ubuntu shell".
What it does
Pushing the pointer into a corner of the screen runs one action. The top left corner runs "Ver tudo e falar", which is what a tap of Super does (super-mode.md): the camera pans out to show every window and the composer box shows; the same corner again returns the camera and hides the box. The other three corners start with no action and the user picks one for each in Configurações.
One place for the setting
The settings screen is part of the shell. It is the React panel of the protected chat host (vendor/interface/ui-src/host/settings.jsx), it saves through authenticated routes of the core, and the core keeps the value in state.json of the profile. The compositor has no settings file for behavior: it starts with its defaults and takes each value from the core on the control connection, and the core sends it again while the compositor reports another value (the pattern of chatDockSide and canvasSharpZoom).
Hot corners follow this, with three rules that keep one source of truth:
- The core owns the value and the default. The compositor starts with every corner off and has no default of its own, so no corner fires with a mapping that the user changed. The cost is that no corner works before the core connects and sends the value, a moment at login when no chat exists to show anyway.
- GNOME keeps its switch in
org.gnome.desktop.interface enable-hot-corners, written by GNOME Settings, which is an application apart from GNOME Shell. This system reads a few values from that store (cursor theme, color scheme, icon theme, fonts) and does not read this one. A switch changed in GNOME Settings has no effect here, and nothing here writes it. - A core and a compositor of different versions stay safe through
capabilities.hotCorners: an older core sends nothing, so the corners stay off; with an older compositor the core sends nothing and the settings section is hidden.
The protected setting
hotCorners in state.json: exactly the keys topLeft, topRight, bottomLeft and bottomRight, each one action id. Without a saved value the core uses {topLeft: "chat", topRight: "none", bottomLeft: "none", bottomRight: "none"}. In a saved object each corner keeps a listed action and any other value means no action, so a broken value never turns a corner on and a profile that a newer core wrote loses only the actions that this core does not know. The core accepts a compositor report that names an action it does not know and then sends its own mapping.
The actions are a closed list, each one an existing user action of contextual-actions.md with the label and the key of web-shell/core/context-actions.js:
| Id | Label | Same as |
|---|---|---|
none |
Nenhuma ação | |
chat |
Ver tudo e falar | Super |
overview |
Abrir ou fechar visão dos workspaces | Super+S |
terminal |
Abrir terminal | Super+Enter |
screenshot |
Capturar região no monitor principal | |
lock |
Bloquear tela | Super+L |
No action that closes a window, ends the session or needs a target window is in the list. A corner takes no command, no executable and no coordinates.
- Route:
POST /api/hot-cornerswith the shell token, exactly the four keys, each value from the list./api/statereportshotCornersandhotCornerActions, the list above as{id, label, key}with the labels ofweb-shell/core/context-actions.js, so the host has no copy of them. The code isweb-shell/core/hot-corners.js. - Compositor command, on the control socket as
chat_dock_sideis (any client of that private same-user socket can send it; the core is the one that does):{"action": "hot_corners", "top_left": ..., "top_right": ..., "bottom_left": ..., "bottom_right": ...}, with the action ids of the table and all four keys. The compositor reportshotCorners(topLeft,topRight,bottomLeft,bottomRight) in its state andcapabilities.hotCorners, and refuses the command while locked. The core sends the mapping after each connect and while the compositor reports another one, never while locked; a mapping with every corner off sends nothing to a compositor that just started. The value stays for the life of the compositor process, with no lease: a corner does what a key already does there with the core gone. The code isnative/smithay/src/hot_corners.rs. - Settings: a section "Cantos da tela" in the Janelas tab, four selects placed as the four corners of a screen, each choice with its key in parentheses. The Início tab lists the corners that have an action. The section and the list show only on a compositor with the capability.
Only the protected settings change the mapping. No agent tool, MCP entry, scheduled turn, generated HTML or plugin panel reaches the setting, the route or the command.
The trigger
The compositor decides in the pointer motion path, since it owns the input. Nothing is drawn, so no web surface is needed.
- A corner exists where the pointer stops on both axes: a corner of an output with no other output beside it or above or below it at that corner. With two monitors side by side, the top left corner of the left monitor and the top right corner of the right one exist; the two corners at the shared edge do not, because the pointer crosses there. This is the rule of GNOME Shell.
- The pointer enters a corner when it reaches the last logical pixel of the corner on both axes. One entry runs the action once; the next entry needs the pointer more than 32 logical pixels away from the corner on one axis first. An entry less than 500 ms after the last action runs nothing.
- The action runs on the output of that corner, which becomes the focus output as for an action of the Actions menu of that output, and it does what its key does there, with the refusals of the key: a tap of Super in the workspace overview closes the overview, and a lock with no lock window waits for it.
- A corner on an extra output that shows no workspace of its own (no lease of the core, or nothing on it) runs the action as its key does, on the focus output.
- An entry into another corner counts at once, also within the 32 pixels of the last one (two outputs with a small gap between them).
- An entry runs nothing while the session is locked, while a pointer button is down (a drag, a window move or resize, a selection), during a pointer grab, while Super is held (the pointer then belongs to the hold of Super, super-mode.md) and while a panel is under the pointer (the capture UI covers the output, and a menu or the quick settings can stand in a corner; a bar is no panel). Touch input moves no pointer. Such an entry is spent too: the release of a drag in a corner, or the unlock, runs nothing until the pointer leaves and comes back.
- The motion still reaches the client under the pointer. A corner takes no click.
- The synthetic pointer of the nested QA session uses the same path, so the corner fires there too.
Out of scope
- A visual ripple at the corner. It would be a web surface, as every visual component is, and the action is its own feedback.
- A delay or pressure threshold, per-output mappings, hot edges and actions outside the list.
- Reading or writing the GNOME setting.
Parts
One phase, in either order of activation because of the capability:
- Compositor:
hot_corners.rs(the corner test, the tracker, the action) with its unit tests,hot_corners_tests.rson the harness (the Super tap of the top left corner, a held button, Super held, the lock, a panel in the corner), the command and the state field. - Core:
core/hot-corners.js, the route, the sync incore/smithay.js,/api/state;test/hot-corners.test.jsandtest/hot-corners-http.test.js. - Host: the part
hotCornersofhost/settings-state.js,renderHotCornersSettingandsetHotCornerinhost/host.js, the section and the Início list inui-src/host/settings.jsx. - Docs: the boundary line in AGENTS.md, the corner in contextual-actions.md and usability.md.
The compositor part takes effect at the next login; the host and core part at the next login or the documented host and core maintenance.
Verification
- Gates of 2026-11-04 on the branch:
cargo fmt --check, Clippy and the Rust tests (804 passed after the rebase onto main), and the web shell format check, lint, build check and tests (1316 passed). The Python suite has two failures that also fail on main in the same clean environment (test_interface_links,test_nested_qa.PanelSeedTests), in scripts this work does not touch. - Nested QA (nested-qa.md), one output, no provider: the default reached the compositor at the connect; the top left corner showed the box and the second push hid it; a move near the corner ran nothing; a choice in Configurações reached the compositor and the bottom right corner opened and closed the workspace overview; a drag into the corner ran nothing; a saved mapping reached the compositor at the start; the
screenshotcorner opened the capture UI, and under it the top left corner ran nothing. - Not proven: two monitors (only the Rust harness covers the shared corner and the corner of an extra output), the
lockandterminalcorners outside the Rust code path of their keys, and the live session, which gets the corners only at the next login after the publication and needs the user.
Decisions
Taken by the owner on 2026-11-04, as recommended:
- The action list above; each further action is one entry of a closed list.
- An immediate trigger, as GNOME does. A short dwell (for example 150 ms in the corner) comes only if the corner fires by accident in use.
- Corners on every output that has one free, each acting on its own view, not only on the primary output.
Also on 2026-11-04 the owner asked whether gsettings could hold these values ("podemos usar gsettings para salvar nossos dados também?") and kept state.json: dconf is one database for the user and not for the profile, so the nested QA run and the test cores would share the live values; a write needs the session bus, which the test environment does not have; a schema must be installed and compiled for each new setting; and dconf-editor or gsettings set would be a second settings screen past the protected routes. gsettings stays for what other applications must see (cursor theme, color scheme, icons, fonts).
Binding contract (from AGENTS.md)
This section holds, word for word, the rule that AGENTS.md kept for this feature until 2026-11-10,
when AGENTS.md was reduced to the short invariants (openspec/changes/audit-2026-11-10/design.md, F10). It binds
exactly as AGENTS.md does; AGENTS.md keeps the short invariant and points here. Change both in
the same commit.
- Hot corners (openspec/specs/hot-corners/spec.md): only the protected settings set the protected setting
hotCorners(one action of a closed list for each corner; the top left corner ischat, a Super tap, by default) through/api/hot-corners. The core owns the value and the default and sends the compositor commandhot_corners(capabilities.hotCorners); the compositor starts with every corner off, reads no file and no gsettings key for it, and runs the action on a pointer entry into a free corner of an output as the key of that action. No agent tool, MCP entry, scheduled turn, generated HTML or plugin panel reaches the setting, the route or the command, and no corner runs while locked.