Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Highlight font-lock-number-face as highlight-numbers-number #451

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

imustafin
Copy link

We already support highlight-numbers (by highlighting highlight-numbers-number). This PR uses the same font for font-lock (highlighting font-lock-number-face).

This fixes the inconsistency if you use both highlight-numbers and something which uses font-lock. For example, ruby-mode and ruby-ts-mode. For example, notice how the numbers are not highlighted only in the top-left cell in the following table:

BeforeAfter

image

image

image

image

-----------------

Before submitting a PR make sure the following things have been done (and denote this
by checking the relevant checkboxes):

  • You've added a before/after screenshot illustrating visually your changes.
  • You've updated the readme (if adding/changing configuration options)

Thanks!

@thomasf
Copy link
Collaborator

thomasf commented Jan 24, 2025

This theme aims to be minimalist, I don't think anything that could enable different colors for numbers unless the user opts in to it by enabling a specific mode or customization is a good fit.

Having said that, I just took a quick look at a couple of programming modes and the font-lock-number-face wasn't applied to numbers in either one of them.

In any case, if you really think it's important, add a defcustom that defaults to being off for it.

@thomasf
Copy link
Collaborator

thomasf commented Jan 24, 2025

This is a very similar kind of customization

(defcustom solarized-distinct-doc-face nil
  "Make `font-lock-doc-face' stand out more.
Related discussion: https://github.com/bbatsov/solarized-emacs/issues/158"
  :type 'boolean
  :group 'solarized)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants