linebender / runebender

A font editor written in Rust.
Apache License 2.0
760 stars 36 forks source link

is monospaced #54

Open gilescope opened 4 years ago

gilescope commented 4 years ago

It seems visual studio code estabilshes if a font can be used by checking if the bounding box of 'i' = 'w'. If they're the same width then it will let you code with it.

Coding fonts is probably a big target market. Would be good to be able to check if a font meets the vscode criteria, and also maybe a way to force the widths to all be the same? (I've handmade audiowide mono with font forge so the widths are fairly monospaced, but font forge crashes on me so often it's hard for me to work with it anymore.)

madig commented 4 years ago

That is most likely a task for build scripts or scripts that assist the designer within Runebender, but not the base application. There are different requirements for different designs and targets and this can quickly get specific to a project and complex.

davelab6 commented 3 years ago

font forge crashes on me so often it's hard for me to work with it anymore

@gilescope I wonder what version you are using; it used to be extremely stable in the latest sources, last time I was using it daily (a few years ago)

davelab6 commented 3 years ago

@cmyr I suggest this might be retitled "Scripting methods to set sidebearings" and tucked away in a "scripting API" milestone :)

cmyr commented 3 years ago

Interesting that VSCode does this; I guess the isFixedPitch field in the post table is frequently wrong?

In any case fixed-pitch fonts are common enough that I think it's worth having some UI for this; along similar lines I was thinking that alongside ascent/descent and other metrics that are configurable, a 'default advance' would be helpful; this would be used for new glyphs.

Ultimately it does make sense to pass this off to a validation script, though, since even in a fixed-pitch font you might still support some variation in advance widths, at the very least due to double-width unicode characters? (I'm not sure how common it is to mix single-width & double-width, but it can't be impossible...)

davelab6 commented 3 years ago

Kindly, I am skeptical that it belongs as a "1p" (native) feature. Twiddling export config dialogs should be a scripted plugin in python. The ability to script the editor will enable a lot of people to contribute a lot of features like this, and the OP one.

madig commented 3 years ago

(I think it's faily common to have multiples of the fixed width in programming fonts for e.g. code ligatures, see Cascadia Code)