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: Thu, 03 Jan 2008 20:32:54 +0100 Message-ID: <477D3866.4020702@gmx.at> References: <477616F3.8000003@gmx.at> <4777A62F.9080009@gmx.at> <4777E0F1.3080100@gmx.at> <4778CCC5.1080407@gmx.at> <477A14D2.3040909@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------000008050202060201090706" X-Trace: ger.gmane.org 1199388784 26251 80.91.229.12 (3 Jan 2008 19:33:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 3 Jan 2008 19:33:04 +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 Thu Jan 03 20:33:23 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 1JAVog-0003Tq-PH for ged-emacs-devel@m.gmane.org; Thu, 03 Jan 2008 20:33:23 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JAVoK-0005bG-Ip for ged-emacs-devel@m.gmane.org; Thu, 03 Jan 2008 14:33:00 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JAVoG-0005bB-Io for emacs-devel@gnu.org; Thu, 03 Jan 2008 14:32:56 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JAVoG-0005az-2t for emacs-devel@gnu.org; Thu, 03 Jan 2008 14:32:56 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JAVoF-0005aw-TL for emacs-devel@gnu.org; Thu, 03 Jan 2008 14:32:55 -0500 Original-Received: from mail.gmx.net ([213.165.64.20]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1JAVoE-0005ik-Lr for emacs-devel@gnu.org; Thu, 03 Jan 2008 14:32:55 -0500 Original-Received: (qmail invoked by alias); 03 Jan 2008 19:32:53 -0000 Original-Received: from N930P030.adsl.highway.telekom.at (EHLO [62.47.60.62]) [62.47.60.62] by mail.gmx.net (mp028) with SMTP; 03 Jan 2008 20:32:53 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19IOdApSDNIMcwbD7WqIh/6zi8H/SmTKMV4GX7qiJ v61KKMeoUVsvUk 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:86005 Archived-At: This is a multi-part message in MIME format. --------------000008050202060201090706 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit > That is true. It's somewhat of an annoyance. > Do you see any other solution? Not really. setqing and customizing are not compatible. > > 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'. > > Yes, that is the solution I am proposing. The problem is then that anyone who wants to know the current default settings can't tell them by just consulting `default-frame-alist' alone. Within Emacs currently just faces, fringe, cua-base, and erc do so, but there may exist packages beyond Emacs ... > I have to avoid an > > "Attempt to autoload customize-set-variable while preparing to dump" > > error here. > > Yes, but why would that error happen? It gets called by fringe.el. > > Hence setting `default-frame-alist' via > `customize-set-variable' would have to be forked by an optional argument > to `modify-all-frames-parameters'. > > I don't follow you there. Does `modify-all-frames-parameters' get called > during building Emacs? If so, maybe that is itself the bug. I suppose because there's no `fringe-mode-explicit' like there's a `scroll-bar-mode-explicit'. The attached patch (naively copied from scroll-bar) would handle this facet. --------------000008050202060201090706 Content-Type: text/plain; name="fringe.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="fringe.patch" *** fringe.el.~1.30.~ Wed Aug 29 08:28:06 2007 --- fringe.el Thu Jan 3 20:21:32 2008 *************** *** 93,98 **** --- 93,102 ---- (defvar fringe-mode) + (defvar fringe-mode-explicit nil + "Non-nil means `set-fringe-mode' should really do something. + This is nil while loading `fringe.el', and t afterward.") + (defun set-fringe-mode-1 (ignore value) "Call `set-fringe-mode' with VALUE. See `fringe-mode' for valid values and their effect. *************** *** 104,116 **** See `fringe-mode' for possible values and their effect." (setq fringe-mode value) ! (modify-all-frames-parameters ! (list (cons 'left-fringe (if (consp fringe-mode) ! (car fringe-mode) ! fringe-mode)) ! (cons 'right-fringe (if (consp fringe-mode) ! (cdr fringe-mode) ! fringe-mode))))) ;; For initialization of fringe-mode, take account of changes ;; made explicitly to default-frame-alist. --- 108,121 ---- See `fringe-mode' for possible values and their effect." (setq fringe-mode value) ! (when fringe-mode-explicit ! (modify-all-frames-parameters ! (list (cons 'left-fringe (if (consp fringe-mode) ! (car fringe-mode) ! fringe-mode)) ! (cons 'right-fringe (if (consp fringe-mode) ! (cdr fringe-mode) ! fringe-mode)))))) ;; For initialization of fringe-mode, take account of changes ;; made explicitly to default-frame-alist. *************** *** 159,164 **** --- 164,173 ---- :initialize 'fringe-mode-initialize :set 'set-fringe-mode-1) + ;; We just set fringe-mode, but that was the default. + ;; If it is set again, that is for real. + (setq fringe-mode-explicit t) + (defun fringe-query-style (&optional all-frames) "Query user for fringe style. Returns values suitable for left-fringe and right-fringe frame parameters. --------------000008050202060201090706 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --------------000008050202060201090706--