* Color of new window C-x 5 2?
@ 2020-03-17 21:33 Nicholas Papadonis
2020-03-17 22:17 ` Stephen Berman
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Nicholas Papadonis @ 2020-03-17 21:33 UTC (permalink / raw)
To: help-gnu-emacs
Does anyone know how to use (set-foreground-color) commands when the new
window is created? At the moment, these settings do not effect the new
window created with C-x 5 2. Thank you
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Color of new window C-x 5 2?
2020-03-17 21:33 Nicholas Papadonis
@ 2020-03-17 22:17 ` Stephen Berman
2020-03-17 22:39 ` Drew Adams
2020-03-18 3:28 ` Eli Zaretskii
2 siblings, 0 replies; 8+ messages in thread
From: Stephen Berman @ 2020-03-17 22:17 UTC (permalink / raw)
To: Nicholas Papadonis; +Cc: help-gnu-emacs
On Tue, 17 Mar 2020 17:33:16 -0400 Nicholas Papadonis <nick.papadonis.ml@gmail.com> wrote:
> Does anyone know how to use (set-foreground-color) commands when the new
> window is created? At the moment, these settings do not effect the new
> window created with C-x 5 2. Thank you
Since set-foreground-color only affects the selected frame, you could do this:
(dolist (f (frame-list))
(select-frame f)
(set-foreground-color "green"))
Steve Berman
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: Color of new window C-x 5 2?
2020-03-17 21:33 Nicholas Papadonis
2020-03-17 22:17 ` Stephen Berman
@ 2020-03-17 22:39 ` Drew Adams
2020-03-18 3:28 ` Eli Zaretskii
2 siblings, 0 replies; 8+ messages in thread
From: Drew Adams @ 2020-03-17 22:39 UTC (permalink / raw)
To: Nicholas Papadonis, help-gnu-emacs
> Does anyone know how to use (set-foreground-color) commands when the new
> window is created? At the moment, these settings do not effect the new
> window created with C-x 5 2.
If you use library `frame-cmds.el', and
you bind `C-x 5 2' to command `clone-frame',
then you can customize option
`clone-frame-parameters' to include frame
parameter `background-color' with the color
you want. For example, this uses a light
blue background:
((background-color . "LightBlue"))
`frame-cmds.el' requires `frame-fns.el'.
Both are on Emacs Wiki's Elisp Area:
https://www.emacswiki.org/emacs/download/frame-cmds.el
https://www.emacswiki.org/emacs/download/frame-fns.el
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Color of new window C-x 5 2?
2020-03-17 21:33 Nicholas Papadonis
2020-03-17 22:17 ` Stephen Berman
2020-03-17 22:39 ` Drew Adams
@ 2020-03-18 3:28 ` Eli Zaretskii
2020-03-18 15:52 ` Nicholas Papadonis
2 siblings, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2020-03-18 3:28 UTC (permalink / raw)
To: help-gnu-emacs
> From: Nicholas Papadonis <nick.papadonis.ml@gmail.com>
> Date: Tue, 17 Mar 2020 17:33:16 -0400
>
> Does anyone know how to use (set-foreground-color) commands when the new
> window is created?
Did you try to change default-frame-parameters?
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: Color of new window C-x 5 2?
[not found] ` <<83pndafijl.fsf@gnu.org>
@ 2020-03-18 14:48 ` Drew Adams
0 siblings, 0 replies; 8+ messages in thread
From: Drew Adams @ 2020-03-18 14:48 UTC (permalink / raw)
To: Eli Zaretskii, help-gnu-emacs
> Did you try to change default-frame-parameters?
I meant to mention that `clone-frame', as
opposed to `make-frame', lets you, in effect,
have two different sets of frame parameters
for `C-x 5 2': `default-frame-alist' and
`clone-frame-parameters': If you use a prefix
arg with `clone-frame' then it just uses the
`default-frame-alist' parameters.
That's the purpose of `clone-frame'. You
don't need to redefine `default-frame-alist',
which affects all frames; you can use a
different set of parameters when you make a
new frame. (And you can auto-select the new
frame.)
---
clone-frame is an interactive compiled Lisp function in
'frame-cmds.el'.
It is bound to C-x 5 2, menu-bar frames make-frame.
(clone-frame &optional FRAME NO-CLONE)
Make and select a new frame with the same parameters as FRAME.
With a prefix arg, don't clone - just call 'make-frame-command'.
Return the new frame.
FRAME defaults to the selected frame. The frame is created on the
same terminal as FRAME. If the terminal is a text-only terminal then
also select the new frame.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Color of new window C-x 5 2?
2020-03-18 3:28 ` Eli Zaretskii
@ 2020-03-18 15:52 ` Nicholas Papadonis
2020-03-18 16:37 ` Robert Pluim
0 siblings, 1 reply; 8+ messages in thread
From: Nicholas Papadonis @ 2020-03-18 15:52 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: help-gnu-emacs
Not yet. How should I use default-frame-parameters?
On Tue, Mar 17, 2020 at 11:28 PM Eli Zaretskii <eliz@gnu.org> wrote:
> > From: Nicholas Papadonis <nick.papadonis.ml@gmail.com>
> > Date: Tue, 17 Mar 2020 17:33:16 -0400
> >
> > Does anyone know how to use (set-foreground-color) commands when the new
> > window is created?
>
> Did you try to change default-frame-parameters?
>
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Color of new window C-x 5 2?
2020-03-18 15:52 ` Nicholas Papadonis
@ 2020-03-18 16:37 ` Robert Pluim
2020-03-18 18:21 ` Eli Zaretskii
0 siblings, 1 reply; 8+ messages in thread
From: Robert Pluim @ 2020-03-18 16:37 UTC (permalink / raw)
To: Nicholas Papadonis; +Cc: help-gnu-emacs
>>>>> On Wed, 18 Mar 2020 11:52:45 -0400, Nicholas Papadonis <nick.papadonis.ml@gmail.com> said:
Nicholas> Not yet. How should I use default-frame-parameters?
I think Eli meant default-frame-alist.
Put something like
(add-to-list 'default-frame-alist '(foreground-color . "green"))
in your .emacs file. Although this is the equivalent of customizing
the colour of the default face to "green".
Robert
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Color of new window C-x 5 2?
2020-03-18 16:37 ` Robert Pluim
@ 2020-03-18 18:21 ` Eli Zaretskii
0 siblings, 0 replies; 8+ messages in thread
From: Eli Zaretskii @ 2020-03-18 18:21 UTC (permalink / raw)
To: help-gnu-emacs
> From: Robert Pluim <rpluim@gmail.com>
> Cc: Eli Zaretskii <eliz@gnu.org>, help-gnu-emacs@gnu.org
> Date: Wed, 18 Mar 2020 17:37:50 +0100
>
> >>>>> On Wed, 18 Mar 2020 11:52:45 -0400, Nicholas Papadonis <nick.papadonis.ml@gmail.com> said:
>
> Nicholas> Not yet. How should I use default-frame-parameters?
>
> I think Eli meant default-frame-alist.
Yes, sorry. Too many twisty little passages, all alike.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2020-03-18 18:21 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <<CAKD0t1JO9X06G8zY1601UAFExA4Dn5eZ5QbyrCaBA2boOS0nuQ@mail.gmail.com>
[not found] ` <<83pndafijl.fsf@gnu.org>
2020-03-18 14:48 ` Color of new window C-x 5 2? Drew Adams
2020-03-17 21:33 Nicholas Papadonis
2020-03-17 22:17 ` Stephen Berman
2020-03-17 22:39 ` Drew Adams
2020-03-18 3:28 ` Eli Zaretskii
2020-03-18 15:52 ` Nicholas Papadonis
2020-03-18 16:37 ` Robert Pluim
2020-03-18 18:21 ` Eli Zaretskii
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).