I don’t know much about Gmail but I’m quite certain, that you only have to enable IMAP/SMTP in Gmail settings.
protonmail.
Install the Proton Mail Bridge and connect to the IMAP/SMTP server on localhost (ports 1143 and 1025).
Does anyone have a simple way of solving this problem?
I had only minor problems getting the above to work. Anyway., for Protonmail there is ElectronMail. It’s available as Flatpak too and it minimizes/starts to tray.