Questions tagged [faces]

A 'face' in Emacs is the visual presentation of text using fonts and highlighting. A default face, for example, specifies both the font and the foreground and background colors.

Filter by
Sorted by
Tagged with
1 vote
1 answer
28 views

How to describe all faces at point?

When I do M-x describe-face, the default face is, according to the doc, "the faces of the character after point" However, looking at the *Fancy Diary Entries* buffer, I see many different ...
  • 5,539
0 votes
1 answer
63 views

Change minibuffer color when NOT in minibuffer AND minibuffer active

I frequently click on another application when I'm doing something in the minibuffer, and then I've forgotten I was in the minibuffer when I come back to emacs. I would like to highlight the ...
  • 169
0 votes
0 answers
15 views

change fringe face height

This increases the buffer text height: (face-remap-add-relative 'default :height 1.5) This has no effect on the fringe continuation mark heights: (face-remap-add-relative 'fringe :height 1.5) So how ...
  • 113
1 vote
0 answers
22 views

Major mode to colour fragments such as tables

I would like to define a major mode for some class of documents, a few faces, and fontification rules that find fragments users would want colored and apply those faces. The user will be able to ...
  • 77
0 votes
1 answer
32 views

How to set heading and TODO fonts?

I use spacemacs theme on Emacs 28.2. My config for faces is: (custom-theme-set-faces 'user '...
0 votes
1 answer
35 views

`buffer-face-mode` does not work with custom fontset

I can not change family and size of a custom fontset in buffer-face-mode. Below is the minimal test config (create-fontset-from-fontset-spec (font-xlfd-name (font-spec :registry "fontset-mine&...
0 votes
1 answer
31 views

Adding alternative for a face or face name

I am using this function interactively, where the string from completing-read is passed to intern to convert it into a symbol suitable for describe-face. Currently, I want to handle the non-...
  • 383
0 votes
0 answers
21 views

Passing face to function non-interactively

With the following function executed non-interactively, would it be sensible to pass the face name or a string? (defun laxy-descface (facenm) "Describe the typeface properties of face name ...
  • 383
0 votes
1 answer
42 views

Calling describe-face at current point

With the following, how can I call the function interactively so that I can also call describe-face at current point? (defun laxy-descface (face) "Describe the typeface properties of FACE."...
  • 383
0 votes
0 answers
27 views

Pass face to describe-face when using function interactively

How can I pass the face to describe-face when using the function interactively? (defun laxy-describe-face (face) "TODO" (interactive (list (let* ( (cseq '("mode-line-...
  • 383
0 votes
0 answers
20 views

Printing face attributes for mode-line and mode-line-inactive

How can I print the face attributes for mode-line and mode-line-inactive?
  • 383
0 votes
1 answer
10 views

Change background colour of the mode line in window

How can I change the background colour of the mode line of a window when not in use?
  • 383
2 votes
1 answer
65 views

Use echo area to show which faces are applied to text at point?

When writing a color theme, it would be helpful if the echo area showed which faces are applied to the text at point. I know I could use C-u C-x = to call what-cursor-position, but that requires ...
  • 1,878
0 votes
1 answer
39 views

How to use fonts for normal text for org-mode tables?

Since the Emacs version upgrade to version 28 org-mode tables have become very small in size. Their font size has been reduced. Is there a way to tell Emacs to use the default font for the tables? ...
  • 13
0 votes
0 answers
23 views

Access current theme face attributes in init.el

I have these lines in my init.el: (load-theme 'wombat) (deftheme wombat) ... (defvar my/default-cursor-color (face-attribute 'cursor :background t)) I want the variable my/default-cursor-color to be #...
0 votes
1 answer
44 views

Fallback font for specific face

I'm trying to set a fallback font for variable-pitch face. More specifically, my current setup is: Default font set to JuliaMono with size 15 via (set-frame-font "JuliaMono 15" nil t). ...
  • 121
0 votes
1 answer
52 views

`defface` and `custom-set-faces`

Noob here. In my .emacs.d/custom.el I have stuff like: (defface delim-mismatch `((t (:foreground "red")))) (custom-set-faces '(show-paren-mismatch delim-mismatch) ... ) But it throws ...
0 votes
0 answers
20 views

Installing minimap on vanilla Emacs gives "Invalid face attribute :foreground nil [xxx times]"

Installing minimap package-install [RET] minimap [RET] Enabling the minimap-mode M-x minimap-mode And opening ~/.emacs (or any file that enables minimap by default) Results in the Messages buffer ...
0 votes
2 answers
43 views

How to export all face settings to a elisp file?

Some custom themes use code to generate the face definitions programmatically, which uses other variables like this. I'd like to export all plain face settings as if they are shown in the buffer ...
0 votes
1 answer
21 views

Face properties fail to apply to parts of org-mode buffer

Parts of certain file-visiting org-mode buffers fail to display properly. Specifically, the text is not displayed with the faces appropriate for this mode. The issue usually disappears when I invoke ...
  • 190
0 votes
0 answers
20 views

display a tree of faces

Emacs faces can inherit from one (or more, but this is seldom the case) other faces. I would like to see a tree of all defined faces, with children displayed indented below their parents (or ...
  • 290
0 votes
1 answer
44 views

How to change the background color when running in the GNOME Terminal?

I have added (set-background-color "blue") to my ~/.emacs (just for test purposes). When I run Emacs in windowed mode this makes the background color blue (as expected), but when I run Emacs ...
0 votes
0 answers
14 views

Fix inconsistent background coloring of org-mode blocks with wrapped lines

When having a source block in a .org document, with line wrapping enabled, the continuation of an indented, long line, that is wrapped to the next line is naturally also indented. The problem is, that ...
0 votes
1 answer
39 views

Underline heading in org mode

I would like to customise the appearance of headings in org mode. The goal is to reduce the need for so many different colours. I used the function below to set colours for the headings. (custom-theme-...
0 votes
1 answer
52 views

Can't set bold weight for fonts

I trying make the variable-pitch font weight to be bold, as I find the variable-pitch font be very thin and almost not visible clearly, but it doesn't seem to work for neither default nor fixed-pitch ...
0 votes
1 answer
72 views

How to change appearance of inline comment in org mode?

I use inline comments in org mode using: @@comment: this is a comment@@ (see method here). I'd like to make @@comment: and @@ disappear and the text within appear greyed out. I set (setq org-hide-...
  • 154
0 votes
1 answer
50 views

How to highlight invisible text when using `visible-mode`?

I sometime use visible-mode to show hidden elements in buffers. For example, I have org-hide-emphasis-markersset to t, but I sometimes want to see them. This works very well with visible-mode, however ...
  • 1,795
0 votes
0 answers
21 views

Change bidi direction for specific characters in buffer

I use Emacs to write LaTeX, and ran into the same problem as in this question, and for now I do as suggested in the questions answer. I've created some macros for making the process of adding the ...
  • 11
1 vote
1 answer
124 views

Cannot enable FACE attributes with (custom-theme-set-faces!)

config.el (custom-theme-set-faces! 'doom-ir-black '(mode-line :foreground "blue") ;;'(mode-line :foreground t) ;; also doesn't work ;;'(mode-line :foreground "#000000&...
  • 90
0 votes
1 answer
46 views

How can I apply black color for bold text in highlighted region?

I am using dracula-theme. Only change I did is adding following line under (faces ': (faces '(;; default / basic faces (region :background ,dracula-yellow :foreground ,dracula-black :extend t) ...
  • 1,114
0 votes
1 answer
28 views

Conditionally Enable Face Attribute in a Terminal

I'm currently trying to conditionally change the face attributes of two faces related to dap-mode while running Emacs in server-mode inside a terminal (using -nw): (defun my-dap-terminal-hook () ...
  • 1,231
1 vote
1 answer
64 views

Face Attributes with Text Properties

Is there any way to have all text with a specific face also receive a specific text-property? As a concrete example, there is a special text-property, line-prefix, that I would like to use for some ...
  • 1,231
2 votes
1 answer
82 views

Region ("selection") background color doesn't show

Like most Emacs users I have a setup! But there's one thing I try not to set : faces etc. For one thing I'm not that good with color intuitions. Another: all previous experiences of doing this show it ...
  • 309
0 votes
0 answers
64 views

Inheritance of font-lock-comment-delimiter-face

How does inheritance of font-lock-comment-delimiter-face work with font-lock-comment-face? The following uses a different colour for the comment delimiter by setting the foreground colour to font-lock-...
  • 169
0 votes
1 answer
32 views

Customize face can use some theme faces, but not all

This is my theme config. I am trying to modify the face list-matching-lines-buffer-name-face, which is part of the result window of occur (see replace.el.gz). Using customize-option on list-matching-...
  • 387
1 vote
1 answer
26 views

Occur mode face for buffer names

The result buffer of occur displays the buffer name with some info: 69 matches in 65 lines for "use" in buffer: init.el It's alright when I run occur in only one buffer. I just started ...
  • 387
0 votes
2 answers
28 views

Customisation for comment delimiter colour based on light or dark theme

I would like to adapt the emacs customisation for comment delimiter colour to change according to light or dark background. How is this customarily done? (defun annot () "Customisation for ...
  • 169
0 votes
1 answer
111 views

Where to put custom-set-faces in the init.el in org-roam context?

I found a code snippet that can be used to have different colors for links and org-roam links on SystemCrafters (aka David Wilson). (custom-set-faces '((org-roam-link org-roam-link-current) :...
  • 599
0 votes
0 answers
11 views

How to change the face of only a text segment in org-agenda?

I am trying to do this on my org-agenda. In the example below, I want that the text [MY PROJECT] has a distinct face (nano-strong, for example) than the next line NEXT My next task. If I have a ...
1 vote
1 answer
70 views

How can I apply a user-defined fontset to a face?

Say I create a fontset and populate it with fonts: (create-fontset-from-fontset-spec (font-xlfd-name (font-spec :registry "fontset-mine"))) (set-fontset-font "fontset-mine" 'latin ...
  • 155
0 votes
0 answers
20 views

custom-set-faces common color variables [duplicate]

I want to fine-tune my syntax highlighting, and have created a separate colors.el file that gets loaded around the beginning of init.el. I often use the same color for multiple entries, and it gets ...
2 votes
1 answer
83 views

text-properties: How to add a face + additional face attributes

In this scenario, there exists one or more faces for a particular condition named "foo". When the condition changes to the name of "bar", the goal is to add an additional face ...
  • 18k
4 votes
1 answer
41 views

Variable for line-wide colouring in emacs org-mode source blocks

What org-mode variable determines whether or not the org-mode block-background applies line wide like so: instead of like so: I am using the gruvbox-dark theme. I will attach the defface as soon as ...
2 votes
1 answer
117 views

What is the name of the face that appears in this list of company completions?

If I have company-mode enabled, and I type in company like this. (company) I then see a list of completions that I can select. My question is - apart from the currently selected item, the word ...
0 votes
1 answer
119 views

Can TODO headings in org mode inherit part of the heading style, specifically fontsize?

Emacs initiate here, I've just now added different heading sizes for org-mode to my init file, according to the answer on this page: Setting for org-mode bullet font size (custom-set-faces '(org-...
  • 1
0 votes
1 answer
41 views

How can I fix vc-annotate colouring?

When I try to view the annotated text / code I can barely read it. Is there a way of changing the colouring or disabling it? See below.
  • 111
0 votes
1 answer
82 views

How can I make `font-latex-sedate-face` have precedence over `font-latex-math-face`?

In LaTeX mode, the face font-latex-sedate-face highlights commands of the form \foo which are not known by AUCTeX. I'd like commands of the form \foo which appear inside a math environment such as \(\...
  • 11
0 votes
0 answers
13 views

Highlighting cited text in notmuch messages

When composing a GNU's message, the cited text gets highlighted with different faces depending on the level. This doesn't seem to work in notmuch out-of-the-box. How do I configure this correctly? It ...
  • 1,469
0 votes
0 answers
29 views

Display link font face in same color as the surrounding face

I'd like to remove :foreground color specificity from link face so that it displays in the same color as the surrounding face. For example, in the below image, "link" should be brown and &...
  • 173
1 vote
1 answer
107 views

How to prevent the mode line color from changing after the buffer is switched?

like this: The mode line color of the current buffer is darker, I hope the color will not change.

1
2 3 4 5
8