Questions tagged [highlighting]

is for changes to fonts and colors for highlighting text. Emacs uses highlighting extensively to set apart portions of visible text in a buffer. Highlighting can also apply to dynamic text during search and replace operations, syntax highlighting in programming modes, and for alerts for errors during debugging.

Filter by
Sorted by
Tagged with
0
votes
0answers
39 views

in Fundamental mode, give certain marked text a different face

I am trying to add a new comment character in fundamental mode, but I can't get it to work. Let me rephrase that, because I think it's an xy-problem. What I really would like to have is the ...
0
votes
0answers
14 views

Make mark color overlap highlight symbol at point

I use auto-highlight-symbol-mode package to auto highlight symbol on point. I found it annoying when I mark a text because the symbol highlight overlaps on my marked text, so I don't see if I marked ...
0
votes
1answer
73 views

Highlight parentesis in latex

the image is self explanatory, I recently switched to doom emacs and I'm still learning. How can I fix this problem? I tried to switch off anything related to checkers in the init.el file but it doesn'...
0
votes
0answers
27 views

Whitespace-mode: highlight hidden indentation of empty lines

I use whitespace-mode, intend with tabs (colored pale yellow, which is what I want) and I am wondering about the situation where there is an empty line inside an indented block (see image below). I ...
0
votes
1answer
56 views

Blinking Paren Mode

I'm trying to get Paren Mode to be a little more clear, cause I can hardly see the other matching pair of parenthesis. Is there any way I could make this blinking yellow?;) I'm in gnome-terminal. Here ...
0
votes
1answer
106 views

Make highlight-changes-mode untrack specific changes

I recently discovered highlight-changes-mode and I added it to my proofs-typesetting setup (LaTeX). I usually make some temporary changes to my buffer that I like not to be tracked (highlighted) when ...
0
votes
1answer
27 views

How to prevent highlighting when using ‘xref-pop-marker-stack’

I was using dumb-jump to get back from jump definition's location. I started to get following message: ‘dumb-jump-back’ is an obsolete command (as of 2020-06-26); ‘dumb-jump-back’ has been obsoleted ...
1
vote
2answers
883 views

Disable hl-line-mode at startup

Something turned hl-line-mode on, which is painful to look at with my color theme. I've added this to my .emacs (hl-line-mode -1) (global-hl-line-mode -1) to no avail. I've tried commenting out ...
13
votes
1answer
443 views

Is there a plugin that does color HTML matching tags like rainbow delimiters?

I would like some plugin which colors html tags with a corresponding color based on which tag they match. For example <div> <p></p></div> <div> and </div> would ...
5
votes
1answer
233 views

Why does mousing over one button also highlight adjacent buttons?

I'm using some buttons, and want to arrange them in a row. That is, some will be directly next to each other. I don't want whitespace between them. This is easy enough to do: However, when I do this, ...
6
votes
1answer
69 views

minor mode to display long integers?

I have to deal with long integers frequently, typically 9+ digits, and all of the digits matter (so scientific notation doesn't help me. Is there a minor mode that helps make it easier to visually ...
0
votes
0answers
27 views

How to highlight matching brackets when the cursor is behind or in front of starting or ending brackets?

I am using Emacs: Highlight Brackets ()[]{}. I want to highlight matching brackets when the cursor is behind and front of starting and ending brackets. How can I accomplish this? foo ( "hello&...
5
votes
2answers
279 views

Mysterious highlight in emacs

Recently, I change my laptop from old Thinkpad to newer laptop with much larger touchpad. I've found that I frequently touch the sensitive touchpad while I'm using emacs. And with some mysterious ...
0
votes
0answers
40 views

Is it possible to create a way to toggle showing/hiding/changing text following a pattern? (org-mode or generally)

I'd like to create a way to toggle showing/hiding/changing text following a pattern in org-mode, but if it works generally, that's fine also. A few examples of where this might be useful. Hiding #+...
0
votes
1answer
639 views

Color calendar day according to number of event in org-agenda

I would like to color the background of each day in calendar according to the number of events in my org-agenda. The idea is to have a quick and visual idea of what are the busiest days. The code from ...
1
vote
2answers
670 views

Spacemacs: How can I customize the highlight style of a matching parenthesis?

How do I change, in my .spacemacs, the style used to highlight the matching parenthesis?
1
vote
1answer
41 views

Connect open and close delimiters with a line

I wonder if emacs has something similar to this VSCode extension (Bracket Pair Colorizer 2) which does the following (screenshot below) which I find is a really helpful UI enhancement [ In the above ...
4
votes
1answer
234 views

How do I highlight the current line?

I am obviously not well versed in the world of Emacs so I was watching Casey Muratori's Emacs video and whenever he traversed any file in Emacs, the current line always had a different background ...
2
votes
1answer
118 views

Highlight a single visual line within a physical line

I want to have a single line in a long-word wrapped line highlighted. The default setting of hl-line seems to highlight the whole wrapped line as shown below. Which setting do I have to change to ...
0
votes
0answers
61 views

Change color of highlghted annotated text in pdf-view

I use pdf-tools to read pdf in emacs. You can highlight a text in the pdf and do C-c C-a h to highlight the text. In normal light mode, the text will be yellow and you can customize it via M-x ...
0
votes
0answers
33 views

Highlight matching parenthesis, only in Lisp mode (and maybe a few similar modes)

is there a way to have the global minor mode show-paren-mode functionality as a buffer-local minor mode? I love its behavior but only for Lisp. Searching for a package I can see a number of close ...
2
votes
0answers
34 views

Find and display duplicated regions of (org-mode) text across multiple files

What I'm trying to do I'm trying to condense a set of research notes consisting of over 250,000 words across 50+ files. I've converted these from previous file formats (mostly mind maps and OPML ...
1
vote
2answers
58 views

Highlighting Arbitrary text

I am trying to customize Emacs by adding a feature where I can select a block of text (like the region but not bound by mark and point). Currently I have implemented this by setting two variables ...
0
votes
1answer
42 views

How can I unhighlight everything highlighted by `highlight-regexp`?

If I do this: M-x highlight-regexp \cite{\(.+\)} then pick a color. Later, if want to unhiglight all previous higlights, I have to do them one by one, e.g. M-x unhighlight-regexp \cite{\(.+\)} ...
8
votes
2answers
559 views

Org mode quote block indentation (highlighting)

Can indentation of the Org mode quote block be configured? I would like to highlight quote blocks with indented margins, both left and right if possible: The example above demonstrates org-quote ...
0
votes
0answers
38 views

Permanently highlighting lines in differnt colours

I'm using the bm package to highlight lines of Code (bm-toggle). Now as I'm heavy debugging I'd like to use this feature more extensively and would like to add more different colours. Also when I'm ...
0
votes
1answer
32 views

Expiring search highlights in Evil

I'm using the evil-search module ((evil-select-search-module 'evil-search-module 'evil-search)). When I perform a search, the results remain highlighted until I call evil-ex-nohighlight. I'd prefer ...
0
votes
2answers
309 views

Highlight a specific phrase in any emacs buffer, regardless of mode

I would like to be able to highlight a particular phrase (in my case: @dakrone) in every emacs buffer, regardless of the mode (it's fine if it doesn't work in fundamental-mode). I know of something ...
13
votes
1answer
673 views

Change highlight color when window isn't in focus?

I'm using hl-mode as a minor mode for deft. How do I make the highlighted line change color (e.g. to gray) when the deft window isn't the current window, and then back to the default highlight color ...
1
vote
3answers
126 views

How to check if a region is selected by mouse?

Usually a mouse selected region is highlighted and a region set by (set-mark-command) is not highlighted. But I don't know a programmatic way to check it. Could anyone help?
2
votes
1answer
187 views

Disable lsp-mode symbol highlighting?

When using lsp server, symbol highlighting obscures the highlighting done by region selection. I can toggle this behavior per-buffer with lsp-toggle-symbol-highlight, but cannot permanently disable ...
0
votes
1answer
147 views

How to give background color to hl-todo-keywords?

I am using following setup in my .emacs file: (setq hl-todo-keyword-faces '(("TODO" . "#FF0000") ("FIXME" . "#FF0000") ("DEBUG" . "#A020F0") ("GOTCHA" . "#FF4500") ...
2
votes
1answer
89 views

AUCTeX: only use monospace for rendering macros?

I've been using the fontify features of AUCTeX, as well as magic-latex-buffer, to display my TeX code in a more readable way. But I'm wondering if I can crank this up to 11: is there a way to render ...
2
votes
1answer
110 views

column-marker skips blank lines; how to fix?

I installed column-marker.el. I like the highlighting style better than fci-mode. Unfortunately, column-marker does not highlight bits of the window where the actual line is not 80 chars or more (or ...
0
votes
1answer
71 views

Automatically highlight elements in an XML buffer

I spend a lot of time in XML buffers using nxml-mode (Emacs 26). Out of hundreds of XML elements, I am only interested in one or two. How can I have Emacs always show the XML elements I'm interested ...
1
vote
0answers
57 views

keymap (overlay / text property): how to create and modify?

I'd like to have certain keymap active when the cursor is in a particular highlighted area. For instance, I would like to bind hl-todo-next to some easy key combination, but only when the cursor is on ...
2
votes
1answer
114 views

Make pdf-tools highlight persist after searching

Is it possible to make the highlight of searched terms persist after pressing RET? I had liked very much the behavior of zathura in this aspect. My question is : Can pdf-tools be tweaked to have the ...
1
vote
1answer
98 views

How to make highlights persistent?

I don't want themes. I use bold,italics, and highlights. I also use background colors per file, so the code as in for background need to be embedded inside file. But when I Edit->Text Properties-&...
0
votes
0answers
51 views

How to highlight variable in scope?

assuming my cursor is going over a specific word in the text, I would like to highlight all occurrences of that variable in the scope. function sayHello () { const hello = 'hello world'// cursor is ...
2
votes
0answers
32 views

Different face for checked-off items in plain lists?

Q: how can I get a different face for checked-off items in org plain lists? I use org-mode's plain lists a lot: - [X] item 1 - [ ] item 2 - [ ] item 3 - [ ] item 4, with a whole lot of text that ...
8
votes
3answers
3k views

Highlight current line without changing colours

I use (global-hl-line-mode 1) in order to highlight the current line. This changes the text colours of the highlighted line. Is it possible to highlight while keeping the current syntax highlighting ...
1
vote
0answers
29 views

Massively long text boxes and yasnippet highlighting

Why are my text boxes and yasnippet field highlights so massively long? Is there a way to change this behavior? If so, what are the necessary steps that need to be taken to solve this issue? The ...
17
votes
4answers
7k views

How to unhighlight symbol highlighted with highlight-symbol-at-point

highlight-symbol-at-point is really useful however I could not find an easy way to un-highlight symbols. Currently I have to call unhighlight-regexp repeatedly for each highlighted symbol. Is there ...
1
vote
0answers
20 views

Highlighting the currently active org-Babel block

I want to do something similar to hl-line-mode but not sure if it has been implemented already and how it can be implemented. The goal would be to set two color schemes for the #+begin and #+end ...
0
votes
0answers
43 views

How to display a (basic) column indicator? [duplicate]

Since fill-column-indicator is no longer actively maintained, how can I visualize the fill-column? The fill-column-indicator package was quite heavy and had compatibility issues with other packages. ...
0
votes
1answer
377 views

Set different highlight-line color for emacs --no-window

How can I set a different color if I am using emacs on terminal (emacs --no-window)? I use a grey highlight line when using emacs with GUI because my background theme is white. Here is the code I use ...
2
votes
1answer
183 views

How to highlight 80 columns when it contains a single % at the start

How can I highlight 80 columns when a line has a single % at the very start? What I am looking for is that lines with a single % stand out by a colored rectangle 1 character high and 80 columns wide.
3
votes
1answer
184 views

regexp: exclude repeated characters for highlight - hi-lock-mode

I want to search using regexp to capture plain text. I want to capture passages that begin with opening quotation marks and end at the end of the paragraph, and even though the quote continues onto a ...
0
votes
1answer
44 views

Highlight some specific text in Emacs

I am using web-mode for my php files: http://web-mode.org/ And I call often a php function which looks like this: __lg('Some text here', 'Global', NULL, FALSE); This function can be call with only ...
2
votes
1answer
136 views

Highlight missing double-space between sentences?

For a while, I've been using sentence-end-double-space: nil. Now I want to get back into the habit of using two spaces to separate sentences. It is the convention for GNU documentation, and it ...