AttorneyOnline / AO2-Client

An off-the-cuff courtroom drama simulator
https://aceattorneyonline.com
GNU General Public License v3.0
63 stars 58 forks source link

Explicitly set sane line spacing #981

Closed in1tiate closed 2 weeks ago

in1tiate commented 2 weeks ago

Fixes absurdly bad line spacing on some user-provided fonts due to Qt's adherence to their values instead of using a sane default. Examples:

Before change: image

After change: image

Related to (but not an explicit solution for) https://github.com/AttorneyOnline/AO2-Client/issues/733.

Salanto commented 2 weeks ago

Wouldn't this work better if its part of the chatbox configuration? Some fonts may look a bit goofy when the spacing is too close.

in1tiate commented 2 weeks ago

Wouldn't this work better if its part of the chatbox configuration? Some fonts may look a bit goofy when the spacing is too close.

This solution automatically decides line spacing based on the font's metrics, i.e. it will never decide to space lines too close together, because the font's own metrics will prevent this

Salanto commented 2 weeks ago

@in1tiate Please re-test if it still works as expected.

It was confirmed by the author to be working correctly still.