zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
49.03k stars 2.96k forks source link

Weird issue when using ligatured fonts #16386

Closed everdrone closed 2 months ago

everdrone commented 2 months ago

Check for existing issues

Describe the bug / provide steps to reproduce it

(see screen recording)

Using Monaspace Neon with some ligatures configured (see: https://monaspace.githubnext.com/#code-ligatures) settings.json

{
    "theme": {
        "mode": "system",
        "dark": "Rosé Pine",
        "light": "Rosé Pine Dawn"
    },
    "ui_font_size": 16,
    "buffer_font_family": "Monaspace Neon",
    "buffer_font_features": {
        "calt": true,
        "ss03": true,
        "ss04": true
    },
    "buffer_font_size": 12,
    "buffer_line_height": {
        "custom": 1.7
    },
    "vim_mode": true,
    "vim": {
        "use_system_clipboard": "always"
    },
    "vertical_scroll_margin": 3,
    "relative_line_numbers": true,
    "tab_size": 4,
    "remove_trailing_whitespace_on_save": true,
    "ensure_final_newline_on_save": true,
    "show_whitespaces": "selection",
    "show_wrap_guides": false,
    "indent_guides": { "enabled": false },
    "languages": {
        "Markdown": {
            "formatter": "prettier"
        }
    },
    "scrollbar": {
        "show": "auto"
    },
    "inlay_hints": {
        "enabled": false
    },
    "tabs": {
        "file_icons": true
    },
    "terminal": {
        "font_family": "SF Mono",
        "font_weight": 500,
        "font_size": 13,
        "dock": "bottom"
    },
    "assistant": {
        "default_model": {
            "provider": "copilot_chat",
            "model": "gpt-4"
        },
        "version": "2"
    },
    "features": {
        "inline_completion_provider": "none"
    },
    "telemetry": {
        "diagnostics": false,
        "metrics": false
    }
}

I'm assuming that liga is set to true by default, implicitly. Adding "liga": false makes the issue disappear

Environment

Zed: v0.148.1 (Zed) OS: macOS 14.6.1 Memory: 16 GiB Architecture: aarch64

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

https://github.com/user-attachments/assets/bea05f81-fada-4d23-859c-3ab5fce2d62d

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

Zed.log


everdrone commented 2 months ago

Other related bug: font is set to "SF Mono", same settings as previous comment. under the blinking cursor, the zero has a slash, under the rest of the buffer it doesn't

https://github.com/user-attachments/assets/7719ff6d-f847-46cb-8f04-57bfe32172e9

Moshyfawn commented 2 months ago

This seems to be a duplicate of another thread; I'll close this one in its favour. Make sure you +👍 the other thread. Feel free to let us know if you think this isn't the same issue, so we can reopen it.

Duplicate of: