From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.devel Subject: Re: "CHANGED outside Customize" in frames customization group Date: Tue, 01 Jan 2008 11:24:18 +0100 Message-ID: <477A14D2.3040909@gmx.at> References: <477616F3.8000003@gmx.at> <4777A62F.9080009@gmx.at> <4777E0F1.3080100@gmx.at> <4778CCC5.1080407@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1199183077 9828 80.91.229.12 (1 Jan 2008 10:24:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 1 Jan 2008 10:24:37 +0000 (UTC) Cc: emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jan 01 11:24:51 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1J9eIi-0003Hq-Tx for ged-emacs-devel@m.gmane.org; Tue, 01 Jan 2008 11:24:49 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1J9eIM-00088v-VU for ged-emacs-devel@m.gmane.org; Tue, 01 Jan 2008 05:24:27 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1J9eII-00088q-Id for emacs-devel@gnu.org; Tue, 01 Jan 2008 05:24:22 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1J9eIG-00088e-Si for emacs-devel@gnu.org; Tue, 01 Jan 2008 05:24:21 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1J9eIG-00088b-MV for emacs-devel@gnu.org; Tue, 01 Jan 2008 05:24:20 -0500 Original-Received: from mail.gmx.net ([213.165.64.20]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1J9eIG-0002f7-6c for emacs-devel@gnu.org; Tue, 01 Jan 2008 05:24:20 -0500 Original-Received: (qmail invoked by alias); 01 Jan 2008 10:24:18 -0000 Original-Received: from N791P026.adsl.highway.telekom.at (EHLO [62.47.42.218]) [62.47.42.218] by mail.gmx.net (mp029) with SMTP; 01 Jan 2008 11:24:18 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18pYvlbWRgpAsdfT8cBZyjCafg/PDDW5t6dRna/i9 c01ZAxEXKg3qPe User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: de-DE, de, en-us, en In-Reply-To: X-Y-GMX-Trusted: 0 X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:85805 Archived-At: > Do I understand you correctly that `frame-notice-user-settings' and > `modify-all-frames-parameters' should set the `command-args-...' values > (one for the initial and one for the default frame)? > > Yes, that's what I've proposed. Do you see any flaws in the idea? > This would require > a non-trivial reorganization of frame.el. > > I think it should be pretty simple. Only 4 functions in frame.el > seem to refer to default-frame-alist or initial-frame-alist. > So I think that not much change would be needed. In addition I would have to change x-win.el, mac-win.el, pc-win.el, and w32-win.el for the x-handle-... stuff. > > Note that I was not looking into the command-line arguments and X > resources issues yet. > > Yes, but I think this same approach would work for x-win.el > and would be simple there too. So I would reflect any attempts to set `default-frame-alist' and `initial-frame-alist' via (1) command-line arguments, (2) x-resources, and (3) settings of `fringe-mode', `tool-bar-mode', `menu-bar-mode', and possibly `scroll-bar-mode' (I don't understand the latter yet) in the initial file, in two variables say `overriding-default-frame-alist' and `overriding-initial-frame-alist'. (I think the "command-" prefix is somewhat misleading for .emacs related settings, but I don't have a strong point here.) The final merging of parameters would then happen in `frame-initialize' for the initial and in `x-handle-named-frame-geometry' for additional frames where the "overriding-" parameters would be appropriately prepended. > > Customizing `fringe-mode' calls `modify-all-frames-parameters' which > > sets `default-frame-alist'. I'm now told that `default-frame-alist' was > > CHANGED outside Customize although all I actually did was _customizing_ > > some option. > > > > The solution to that is just to inform Custom about the change, so it > > will realize that the change to `default-frame-alist' was made within > > Custom. > > > > It's just a bug, it just needs to be fixed. > > I wouldn't know how. If I simply set `default-frame-alist' in some > "Custom" way I'll be told that there are unsaved changes. > > It looks like `customize-set-variable' does the right job. > > So I think this won't be very hard. Want to give it a try? I have to avoid an "Attempt to autoload customize-set-variable while preparing to dump" error here. Hence setting `default-frame-alist' via `customize-set-variable' would have to be forked by an optional argument to `modify-all-frames-parameters'. Such an optional argument would then have to be passed down by `set-fringe-mode-1' to `set-fringe-mode', for example, and similarly for the others. Correct?