all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* customize-face + inherit
@ 2016-02-08 23:32 Yuri D'Elia
  2016-02-11  9:43 ` Alex Kost
  0 siblings, 1 reply; 13+ messages in thread
From: Yuri D'Elia @ 2016-02-08 23:32 UTC (permalink / raw)
  To: help-gnu-emacs

I'd like to customize a face so that it inherits *all* values from it's
parent. That is, I want the face to be an exact copy of the parent.

To do that, I can add the 'inherit' property to the desired parent face,
but I would also need to *clear* the rest of the attributes from the
face being customized, such as foreground.

How can I do that conveniently from the customize-face interface?
(how can I 'nil' a value?).

Thanks




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-02-08 23:32 customize-face + inherit Yuri D'Elia
@ 2016-02-11  9:43 ` Alex Kost
  2016-02-13 17:59   ` Yuri D'Elia
  0 siblings, 1 reply; 13+ messages in thread
From: Alex Kost @ 2016-02-11  9:43 UTC (permalink / raw)
  To: Yuri D'Elia; +Cc: help-gnu-emacs

Yuri D'Elia (2016-02-09 02:32 +0300) wrote:

> I'd like to customize a face so that it inherits *all* values from it's
> parent. That is, I want the face to be an exact copy of the parent.
>
> To do that, I can add the 'inherit' property to the desired parent face,
> but I would also need to *clear* the rest of the attributes from the
> face being customized, such as foreground.

Hm, I recall this was an issue in Emacs 24.3.1 and earlier versions,
but it is fixed in Emacs 24.4 (I believe).  What's your version?

-- 
Alex



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-02-11  9:43 ` Alex Kost
@ 2016-02-13 17:59   ` Yuri D'Elia
  2016-02-13 20:24     ` Alex Kost
  0 siblings, 1 reply; 13+ messages in thread
From: Yuri D'Elia @ 2016-02-13 17:59 UTC (permalink / raw)
  To: help-gnu-emacs

On 11/02/16 10:43, Alex Kost wrote:
>> I'd like to customize a face so that it inherits *all* values from it's
>> parent. That is, I want the face to be an exact copy of the parent.
>>
>> To do that, I can add the 'inherit' property to the desired parent face,
>> but I would also need to *clear* the rest of the attributes from the
>> face being customized, such as foreground.
> 
> Hm, I recall this was an issue in Emacs 24.3.1 and earlier versions,
> but it is fixed in Emacs 24.4 (I believe).  What's your version?

I'm using 24.5.1 from debian/sid.

It seems to work for some faces, but not for others.

I'm trying to reset the message-header-subject face.

Removing the foreground attribute with customize-face doesn't do
anything at all, but setting it manually through (set-face-attribute) works.

The same goes for message-header-other.
Any idea of what could cause this?





^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-02-13 17:59   ` Yuri D'Elia
@ 2016-02-13 20:24     ` Alex Kost
  2016-03-06 20:52       ` Yuri D'Elia
  0 siblings, 1 reply; 13+ messages in thread
From: Alex Kost @ 2016-02-13 20:24 UTC (permalink / raw)
  To: Yuri D'Elia; +Cc: help-gnu-emacs

Yuri D'Elia (2016-02-13 20:59 +0300) wrote:

> On 11/02/16 10:43, Alex Kost wrote:
>>> I'd like to customize a face so that it inherits *all* values from it's
>>> parent. That is, I want the face to be an exact copy of the parent.
>>>
>>> To do that, I can add the 'inherit' property to the desired parent face,
>>> but I would also need to *clear* the rest of the attributes from the
>>> face being customized, such as foreground.
>>
>> Hm, I recall this was an issue in Emacs 24.3.1 and earlier versions,
>> but it is fixed in Emacs 24.4 (I believe).  What's your version?
>
> I'm using 24.5.1 from debian/sid.

I use the same version.

> It seems to work for some faces, but not for others.
>
> I'm trying to reset the message-header-subject face.
>
> Removing the foreground attribute with customize-face doesn't do
> anything at all, but setting it manually through (set-face-attribute) works.

Hm, I don't have this problem.  So what I did:

- I disabled all themes with "M-x customize-themes";

- "M-x customize-face RET message-header-subject";

- "uncheck" Foreground field;

- press "C-c C-c"

and the subject color changes from "navy blue" (for the light
background) to a default (black).

> The same goes for message-header-other.
> Any idea of what could cause this?

No idea, but if you have a reproducible recipe, I suggest
"M-x report-emacs-bug".

--
Alex



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-02-13 20:24     ` Alex Kost
@ 2016-03-06 20:52       ` Yuri D'Elia
  2016-03-06 21:33         ` Drew Adams
  2016-03-07 13:08         ` Alex Kost
  0 siblings, 2 replies; 13+ messages in thread
From: Yuri D'Elia @ 2016-03-06 20:52 UTC (permalink / raw)
  To: Alex Kost; +Cc: help-gnu-emacs

On Sat, Feb 13 2016, Alex Kost <alezost@gmail.com> wrote:
>>> Hm, I recall this was an issue in Emacs 24.3.1 and earlier versions,
>>> but it is fixed in Emacs 24.4 (I believe).  What's your version?
>>
>> I'm using 24.5.1 from debian/sid.
>
> I use the same version.

So I had some time to burn on this and it turns out the face in question
is themed (via `color-theme')

In this case customization mostly works, except when I want to set some
themed definition to nil.

I guess this is an "issue" in color-theme?



^ permalink raw reply	[flat|nested] 13+ messages in thread

* RE: customize-face + inherit
  2016-03-06 20:52       ` Yuri D'Elia
@ 2016-03-06 21:33         ` Drew Adams
  2016-03-06 21:53           ` Yuri D'Elia
  2016-03-07 13:08         ` Alex Kost
  1 sibling, 1 reply; 13+ messages in thread
From: Drew Adams @ 2016-03-06 21:33 UTC (permalink / raw)
  To: Yuri D'Elia, Alex Kost; +Cc: help-gnu-emacs

> I guess this is an "issue" in color-theme?

color-theme or custom-theme?

https://www.emacswiki.org/emacs/ColorThemes
https://www.emacswiki.org/emacs/CustomThemes



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-03-06 21:33         ` Drew Adams
@ 2016-03-06 21:53           ` Yuri D'Elia
  2016-03-06 22:46             ` Drew Adams
  0 siblings, 1 reply; 13+ messages in thread
From: Yuri D'Elia @ 2016-03-06 21:53 UTC (permalink / raw)
  To: help-gnu-emacs

On Sun, Mar 06 2016, Drew Adams wrote:
>> I guess this is an "issue" in color-theme?
>
> color-theme or custom-theme?
>
> https://www.emacswiki.org/emacs/ColorThemes
> https://www.emacswiki.org/emacs/CustomThemes

I'm still using color-theme.el
(https://www.emacswiki.org/emacs/ColorThemes)




^ permalink raw reply	[flat|nested] 13+ messages in thread

* RE: customize-face + inherit
  2016-03-06 21:53           ` Yuri D'Elia
@ 2016-03-06 22:46             ` Drew Adams
  2016-03-07 11:36               ` Yuri D'Elia
  0 siblings, 1 reply; 13+ messages in thread
From: Drew Adams @ 2016-03-06 22:46 UTC (permalink / raw)
  To: Yuri D'Elia, help-gnu-emacs

> color-theme.el (https://www.emacswiki.org/emacs/ColorThemes)

Just a shot in the dark, from scanning the code:
Can you customize `color-theme-illegal-faces' to exclude the
face in question, so color-theme does not affect it?

E.g., what happens if you change it from the default value of
"^w3-" to "^w3-\\|message-header-subject" or similar?



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-03-06 22:46             ` Drew Adams
@ 2016-03-07 11:36               ` Yuri D'Elia
  0 siblings, 0 replies; 13+ messages in thread
From: Yuri D'Elia @ 2016-03-07 11:36 UTC (permalink / raw)
  To: help-gnu-emacs

On Sun, Mar 06 2016, Drew Adams wrote:
>> color-theme.el (https://www.emacswiki.org/emacs/ColorThemes)
>
> Just a shot in the dark, from scanning the code:
> Can you customize `color-theme-illegal-faces' to exclude the
> face in question, so color-theme does not affect it?
>
> E.g., what happens if you change it from the default value of
> "^w3-" to "^w3-\\|message-header-subject" or similar?

I'd rather not disable theming for these faces.

In all the cases, when I'm happy with a theme, I just want to add minor
tweaks to an existing face while leaving existing attributes as-is.

I didn't read color-theme.el, but my guess is that it doesn't see nil as
an explicit value to set. You can see the same behavior while trying to
set :bold nil as opposed to :weight normal.

It's not such as a big problem for me, as after loading the theme I
generally override complex faces (that I want to change between
background modes, for example) directly with color-theme-install-faces
in cumulative mode.

But when I try out a new mode, my first go-to approach is to test the
face parameters with customize. In this case, you're baffled as
unchecking a parameter might will not override the theme.




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-03-06 20:52       ` Yuri D'Elia
  2016-03-06 21:33         ` Drew Adams
@ 2016-03-07 13:08         ` Alex Kost
  2016-03-07 13:21           ` Yuri D'Elia
  1 sibling, 1 reply; 13+ messages in thread
From: Alex Kost @ 2016-03-07 13:08 UTC (permalink / raw)
  To: Yuri D'Elia; +Cc: help-gnu-emacs

Yuri D'Elia (2016-03-06 23:52 +0300) wrote:

> On Sat, Feb 13 2016, Alex Kost <alezost@gmail.com> wrote:
>>>> Hm, I recall this was an issue in Emacs 24.3.1 and earlier versions,
>>>> but it is fixed in Emacs 24.4 (I believe).  What's your version?
>>>
>>> I'm using 24.5.1 from debian/sid.
>>
>> I use the same version.
>
> So I had some time to burn on this and it turns out the face in question
> is themed (via `color-theme')
>
> In this case customization mostly works, except when I want to set some
> themed definition to nil.
>
> I guess this is an "issue" in color-theme?

Sorry, I have no idea about "color theme", I use only "custom theme"
facilities.

-- 
Alex



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-03-07 13:08         ` Alex Kost
@ 2016-03-07 13:21           ` Yuri D'Elia
  2016-03-08  8:52             ` Alex Kost
  0 siblings, 1 reply; 13+ messages in thread
From: Yuri D'Elia @ 2016-03-07 13:21 UTC (permalink / raw)
  To: help-gnu-emacs

On Mon, Mar 07 2016, Alex Kost wrote:
>> So I had some time to burn on this and it turns out the face in question
>> is themed (via `color-theme')
>>
>> In this case customization mostly works, except when I want to set some
>> themed definition to nil.
>>
>> I guess this is an "issue" in color-theme?
>
> Sorry, I have no idea about "color theme", I use only "custom theme"
> facilities.

On a related note, does custom theme still suffers from performance
issues in emacs 24.5?




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-03-07 13:21           ` Yuri D'Elia
@ 2016-03-08  8:52             ` Alex Kost
  2016-03-08 10:57               ` Yuri D'Elia
  0 siblings, 1 reply; 13+ messages in thread
From: Alex Kost @ 2016-03-08  8:52 UTC (permalink / raw)
  To: Yuri D'Elia; +Cc: help-gnu-emacs

Yuri D'Elia (2016-03-07 16:21 +0300) wrote:

> On Mon, Mar 07 2016, Alex Kost wrote:
>>> So I had some time to burn on this and it turns out the face in question
>>> is themed (via `color-theme')
>>>
>>> In this case customization mostly works, except when I want to set some
>>> themed definition to nil.
>>>
>>> I guess this is an "issue" in color-theme?
>>
>> Sorry, I have no idea about "color theme", I use only "custom theme"
>> facilities.
>
> On a related note, does custom theme still suffers from performance
> issues in emacs 24.5?

I don't know what performance issues you mean, I have never noticed any
issues in 24.5 or earlier versions.

-- 
Alex



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: customize-face + inherit
  2016-03-08  8:52             ` Alex Kost
@ 2016-03-08 10:57               ` Yuri D'Elia
  0 siblings, 0 replies; 13+ messages in thread
From: Yuri D'Elia @ 2016-03-08 10:57 UTC (permalink / raw)
  To: Alex Kost; +Cc: help-gnu-emacs

On Tue, Mar 08 2016, Alex Kost <alezost@gmail.com> wrote:
>> On a related note, does custom theme still suffers from performance
>> issues in emacs 24.5?
>
> I don't know what performance issues you mean, I have never noticed any
> issues in 24.5 or earlier versions.

I remember theme switching was *quite* slow.

Since I switch between dark/light background variants of a theme quite
often depending on lightning conditions, at some point I stayed with
color-theme.el.



^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2016-03-08 10:57 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-08 23:32 customize-face + inherit Yuri D'Elia
2016-02-11  9:43 ` Alex Kost
2016-02-13 17:59   ` Yuri D'Elia
2016-02-13 20:24     ` Alex Kost
2016-03-06 20:52       ` Yuri D'Elia
2016-03-06 21:33         ` Drew Adams
2016-03-06 21:53           ` Yuri D'Elia
2016-03-06 22:46             ` Drew Adams
2016-03-07 11:36               ` Yuri D'Elia
2016-03-07 13:08         ` Alex Kost
2016-03-07 13:21           ` Yuri D'Elia
2016-03-08  8:52             ` Alex Kost
2016-03-08 10:57               ` Yuri D'Elia

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.