zed icon indicating copy to clipboard operation
zed copied to clipboard

Font weight does not change if set under a value of 500

Open motherboardMage opened this issue 1 year ago • 9 comments

Check for existing issues

  • [X] Completed

Describe the bug / provide steps to reproduce it

The bug:

As can be seen in the attached screen recording, Zed does not change font weight unless the values under the "ui_font_weight" or "buffer_font_weight" properties is set to a number higher than 500.

https://github.com/zed-industries/zed/assets/170600677/fca292ba-7354-4d37-a005-9301cae836a1

Steps to reproduce:

  1. In the settings.json file, add "ui_font_weight" and "buffer_font_weight" properties
  2. Set one or both of them to a value less than or equal to 500. The font weight in the editor should not change.
  3. Set one or both of them to a value greater than 500. The font, as expected should become quite bold.

Environment

Zed: v0.143.6 (Zed) OS: macOS 14.5.0 Memory: 8 GiB Architecture: x86_64

If applicable, add mockups / screenshots to help explain present your vision of the feature

No response

If applicable, attach your Zed.log file to this issue.

Zed.log

[Zed.log](https://github.com/user-attachments/files/16174401/Zed.log)

motherboardMage avatar Jul 11 '24 09:07 motherboardMage

I could replicate it with the default font, however after switching ui_font_family to Noto Sans for the sake of experimenting with the font weight, I could finally notice a difference when switching from 400 to 500.

Screencast_20240711_132727.webm

ghost avatar Jul 11 '24 10:07 ghost

Same issue on Linux too

Zed: v0.143.7 OS: Fedora Linux 40 Memory: 16 GiB

rajeevtapadia avatar Jul 13 '24 08:07 rajeevtapadia

Same. Zed: v0.146.5 Font: JetBrains Mono OS: Ubuntu 24.04 LTS Memory: 16 GiB

kamil-kubiczek avatar Aug 04 '24 16:08 kamil-kubiczek

For my font of choice (Ubuntu Mono), setting buffer_font_weight to any value (100 or 900) in settings.json has no effect at all. Likewise, changing font_weight or font_style in the theme JSON shows no effect.

Same with most other fonts (Droid Sans Mono, Noto Mono, ...), although some, such as Zed Plex Mono, exhibit a binary behaviour: they look too thin at "buffer_font_weight": 500 and any other value below, but too thick at "buffer_font_weight": 501 and any other value above.

Switching between Wayland and Xorg doesn't make a difference.

Zed: v0.152.3 Font: Ubuntu Mono OS: Ubuntu 24.04.1 LTS Memory: 16 GiB Architecture: x86_64

donjan avatar Sep 16 '24 09:09 donjan

This actually seems to be a duplicate of https://github.com/zed-industries/zed/issues/13564

donjan avatar Dec 03 '24 16:12 donjan

Hi there! 👋 We're working to clean up our issue tracker by closing older issues that might not be relevant anymore. If you are able to reproduce this issue in the latest version of Zed, please let us know by commenting on this issue, and we will keep it open. If you can't reproduce it, feel free to close the issue yourself. Otherwise, we'll close it in 7 days. Thanks for your help!

github-actions[bot] avatar Apr 09 '25 07:04 github-actions[bot]

@github-actions nope

andreymal avatar Apr 09 '25 09:04 andreymal

It's really a dupe of #13564 though.

lnicola avatar Apr 09 '25 09:04 lnicola

I think this is a broader issue with font rendering. I use a variable font (PragmataPro VF) and Zed doesn't accept arbitrary font weights - instead there are random discrete "jumps" at certain weights.

The following show that the font renders identically at weights of 301 and 399 (when there should be a clearly perceptible difference), but there's a noticeable jump from 399 to 400 (which should look the same for all intents and purposes):


Image Image Image

(Zed 0.185.16 on macOS 15.4.1, haven't tested on Linux yet)

csutter avatar May 15 '25 10:05 csutter

I'am facing the same issue:

Zed: v0.196.6 Font: Ubuntu Mono OS: Ubuntu 24.04 LTS Memory: 16 GiB

IronOnet avatar Jun 20 '25 12:06 IronOnet

Hi there! 👋 We're working to clean up our issue tracker by closing older issues that might not be relevant anymore. If you are able to reproduce this issue in the latest version of Zed, please let us know by commenting on this issue, and we will keep it open. If you can't reproduce it, feel free to close the issue yourself. Otherwise, we'll close it in 7 days. Thanks for your help!

github-actions[bot] avatar Oct 22 '25 07:10 github-actions[bot]

Nooooo!

lnicola avatar Oct 22 '25 07:10 lnicola