From: martin rudalics <rudalics@gmx.at>
To: rms@gnu.org
Cc: emacs-devel@gnu.org
Subject: Re: "CHANGED outside Customize" in frames customization group
Date: Thu, 03 Jan 2008 20:32:54 +0100 [thread overview]
Message-ID: <477D3866.4020702@gmx.at> (raw)
In-Reply-To: <E1JAMj0-0000fE-Uy@fencepost.gnu.org>
[-- Attachment #1: Type: text/plain, Size: 1573 bytes --]
> 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.
[-- Attachment #2: fringe.patch --]
[-- Type: text/plain, Size: 1847 bytes --]
*** 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.
[-- Attachment #3: Type: text/plain, Size: 142 bytes --]
_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel
next prev parent reply other threads:[~2008-01-03 19:32 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-29 9:44 "CHANGED outside Customize" in frames customization group martin rudalics
2007-12-29 15:51 ` Drew Adams
2007-12-29 16:14 ` Luc Teirlinck
2007-12-29 17:33 ` martin rudalics
2007-12-29 18:14 ` Drew Adams
2007-12-30 1:36 ` Richard Stallman
2007-12-29 17:48 ` Richard Stallman
2007-12-30 14:07 ` martin rudalics
2007-12-30 15:42 ` Richard Stallman
2007-12-30 18:18 ` martin rudalics
2007-12-30 22:58 ` Richard Stallman
2007-12-31 11:04 ` martin rudalics
2008-01-01 3:18 ` Richard Stallman
2008-01-01 10:24 ` martin rudalics
2008-01-03 9:50 ` Richard Stallman
2008-01-03 19:32 ` martin rudalics [this message]
2008-01-05 5:54 ` Richard Stallman
2008-01-05 10:14 ` martin rudalics
2008-01-06 18:10 ` Richard Stallman
2008-01-06 19:00 ` martin rudalics
2008-01-07 11:31 ` Richard Stallman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=477D3866.4020702@gmx.at \
--to=rudalics@gmx.at \
--cc=emacs-devel@gnu.org \
--cc=rms@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.