diff --git a/apps/desktop/src/electron-main.ts b/apps/desktop/src/electron-main.ts index 8a9ebae03..c8c28ac77 100644 --- a/apps/desktop/src/electron-main.ts +++ b/apps/desktop/src/electron-main.ts @@ -22,6 +22,12 @@ async function main() { electron.app.commandLine.appendSwitch("enable-experimental-web-platform-features"); electron.app.commandLine.appendSwitch("lang", options.getOptionOrNull("formattingLocale") ?? "en"); + // Electron 36 crashes with "Using GTK 2/3 and GTK 4 in the same process is not supported" on some distributions. + // See https://github.com/electron/electron/issues/46538 for more info. + if (process.platform === "linux") { + electron.app.commandLine.appendSwitch("gtk-version", "3"); + } + // Quit when all windows are closed, except on macOS. There, it's common // for applications and their menu bar to stay active until the user quits // explicitly with Cmd + Q.