Prior to updating to Ubuntu 17.04, opening new text documents always opened them in a new tab. But since updating, new text documents are always opening in a new window (even when a gedit window is already open). This is resulting in tons of windows being open which is terrible.
I have gsettings set at default (auto) for tab mode.
How do I make Gedit always open documents in a TAB?
This did the job in Ubuntu 18.04:
ref. configure gedit to always open in new window
Update: I updated changed .desktop files for gedit, and now it opens in new tab by default!
.desktop files in question:
/usr/share/applications/gedit.desktop
/usr/share/applications/org.gnome.gedit.desktop
(There are two of them; and since I don't know which one is used by default, I simply did the following on both files:)
Exec
line under[Desktop Entry]
looks likeExec = gedit %U
DBusActivatable
, ensure it is set tofalse
.(Answer is loosely based on this answer)
I have sidestepped the problem by opening text/code files using Ctrl+O :
From the help menu of
gedit
: gedit Text Editor › Working With Files » File basics: Open, close, and save files »Open a file or set of files