Red Hat Bugzilla – Bug 1251754
default.el contains disruptive set of frame-title-format
Last modified: 2016-01-26 04:38:24 EST
Description of problem:
Emacs includes functionality to load a site-wide 'default.el' file on startup. This file has been configured by Fedora maintainers to include this line:
(setq-default frame-title-format (concat "%b - emacs@" (system-name)))
This causes the window title for my emacs to change as I change buffer contents. This is disruptive to my workflow as my window manager (twm - yes, ancient, I know) ends up re-ordering the window within its icon manager as the window name changes.
I have no problem with this setting as something that Fedora is trying to add to normalize the user experience (I guess lots of programs change their window titles dynamically to try to represent the current 'state' of the program), but I don't think this change should be in default.el, and here is why:
default.el is loaded *after* your own personal configuration files (.emacs) are loaded. Therefore, this change to frame-title-format cannot be controlled by the user because any change made in a .emacs file to try to defeat it, is undone when default.el is loaded.
It is true that I can disable the loading of default.el in emacs via the inhibit-default-init setting, but I don't want to set that just to avoid this particular issue, because if useful defaults appear in default.el, I don't want to miss them. I've been using emacs for about 25 years now and this is the first time I've ever encountered an environment where someone has made a change to default.el that requires such gynmastics on my part, which I think is pretty good evidence that this change is just not right.
I can think of two ways that this could be done differently:
1. Put the setting into site-start.el instead of default.el. site-start.el is loaded *before* my own personal .emacs file (instead of *after* like default.el is), which gives me an opportunity to overwrite the frame-title-format variable in my own .emacs and all is well. I think this is the best solution.
2. Add a variable to default.el called something like 'inhibit-default-frame-title-format' and only set frame-title-format if this variable is not set. Then I can set inhibit-default-frame-title-format in my .emacs and not get this undesired behavior.
Version-Release number of selected component (if applicable):
I run Fedora 20 still, but I suspect the problem is endemic to the emacs package regardless of Fedora version in use, as it only started occurring on a recent update to the emacs package, which is probably duplicated in all emacs packages for all fedora core versions.
Steps to Reproduce:
1. Run emacs
2. Find that window titles are suddenly changing with buffer contents
Window titles change and there is no way to disable this because the configuration setting was placed in default.el instead of site-start.el.
Able to disable this behavior by setting frame-title-format in my .emacs file and have this setting take effect instead of being overwritten by default.el.
This version is already closed. Please update to the latest one version.
If the bug is still present feel free to reopen it.
This line is still in default.el in Fedora 23 in emacs-24.5-6.fc23.x86_64