You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Draw Linux right-click menus in the app, so they follow the app's appearance
#33088
On Linux, Electron paints native menus with the GTK theme and ignores nativeTheme.themeSource (electron/electron#28887). Every right-click menu in the desktop app therefore uses the system GTK colors, even when T3 Code is set to an explicit Light or Dark appearance. That includes thread and project actions, the terminal, files, and the text-field menu with Cut, Copy, Paste and spelling suggestions. With a light GTK theme and a dark T3 Code theme, a cream menu opens over the dark app. #27464 reports this.
On macOS and Windows, native menus follow Light and Dark, so the problem is specific to Linux.
Proposal
On Linux only, draw right-click menus with the in-page menu the web app already uses:
App menus (localApi.contextMenu.show) use the in-page menu on Linux.
The main process still builds the shell's own menu (spelling, Copy Link, Copy Image, Cut, Copy, Paste and Select all) from Electron's context-menu event. On Linux, the main window sends those items to the page and gets back the item the user picked. The main process then runs the action, so editing keeps working as before.
macOS and Windows keep native menus. Preview browser pages and popup windows keep them too, because they have no app page to draw a menu in.
This is option 3 from #10997, limited to Linux, where native menus can't follow the app's appearance at all.
feat(web): add Styled Context Menu toggle for desktop #18103 adds an opt-in setting that is off by default, and it keeps text-field and spelling menus native. Linux users would still get GTK-colored menus by default, and in every text field even with the setting on.
Accessibility
The in-page menu already has menu and menuitem roles, navigation with the arrow keys, Home, End and Escape, and it puts focus back where it was when it closes. #10390, about screen-reader focus on native menus, affects only Windows, so this change leaves it alone. #18876 makes further improvements to the same in-page menu.
Status
My fork has a working Linux-only version, adapted from #28472. I tested it in a real Electron build on Linux with the composer, terminal and editing menus, and checked Cut, Copy, Paste, Select all and disabled items. I'll open a PR if this scope is approved.
🤖 Generated with Claude Code (Claude Opus 5.5), run from T3 Code.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Problem
On Linux, Electron paints native menus with the GTK theme and ignores
nativeTheme.themeSource(electron/electron#28887). Every right-click menu in the desktop app therefore uses the system GTK colors, even when T3 Code is set to an explicit Light or Dark appearance. That includes thread and project actions, the terminal, files, and the text-field menu with Cut, Copy, Paste and spelling suggestions. With a light GTK theme and a dark T3 Code theme, a cream menu opens over the dark app. #27464 reports this.On macOS and Windows, native menus follow Light and Dark, so the problem is specific to Linux.
Proposal
On Linux only, draw right-click menus with the in-page menu the web app already uses:
localApi.contextMenu.show) use the in-page menu on Linux.context-menuevent. On Linux, the main window sends those items to the page and gets back the item the user picked. The main process then runs the action, so editing keeps working as before.This is option 3 from #10997, limited to Linux, where native menus can't follow the app's appearance at all.
How this differs from earlier attempts
Accessibility
The in-page menu already has
menuandmenuitemroles, navigation with the arrow keys, Home, End and Escape, and it puts focus back where it was when it closes. #10390, about screen-reader focus on native menus, affects only Windows, so this change leaves it alone. #18876 makes further improvements to the same in-page menu.Status
My fork has a working Linux-only version, adapted from #28472. I tested it in a real Electron build on Linux with the composer, terminal and editing menus, and checked Cut, Copy, Paste, Select all and disabled items. I'll open a PR if this scope is approved.
🤖 Generated with Claude Code (Claude Opus 5.5), run from T3 Code.
All reactions