michaelrommel / nvim-silicon

neovim plugin to create code images using the external silicon tool.
MIT License
147 stars 9 forks source link

No font found for character `ỏ`[warning] #19

Closed ugotuan closed 4 months ago

ugotuan commented 4 months ago

When copying the image, the character 'ỏ' is missing because it cannot be recognized. How can this be fixed, Michael?

image
l9devz commented 4 months ago

When copying the image, the character 'ỏ' is missing because it cannot be recognized. How can this be fixed, Michael?

same issue here.

michaelrommel commented 4 months ago

Hello both,

it can be fixed by installing a font that contains a glyph for that character. I have tested this with a simple example rust code:

fn main() {
    println!("No font found for character ỏ[warning]")
}

and with my patched font Victor Mono it worked out of the box.

image

I think you just need to find a font with a large glyph range and reference that in your silicon configuration file, like as

{
    "michaelrommel/nvim-silicon",
    lazy = true,
    cmd = "Silicon",
    main = "nvim-silicon",
    opts = {
        -- Configuration here, or leave empty to use defaults
        font = "VictorMono NF=34;Noto Emoji",
    }
},
michaelrommel commented 4 months ago

Dear all,

has installing a complete font solved your problem? E.g. https://rubjo.github.io/victor-mono/

If so, would you mind closing the issue?

Thanks!

Michael.

ugotuan commented 4 months ago

It's worked. Thank you very much