glyph-brush
glyph-brush copied to clipboard
Improve api document of Section's screen_position
Accroding to doc: https://docs.rs/glyph_brush/0.7.2/glyph_brush/struct.Section.html#structfield.screen_position, screen position is in pixels from top-left. Defaults to (0, 0). But in fact it's only true when the layout config in section is horizon: left, vertical: top. This position is actually anchor the alignment center, not the "top-left" position.
Yep good spot. It is explained a bit buried at https://docs.rs/glyph_brush/0.7.2/glyph_brush/enum.HorizontalAlign.html
This could definitely be clearer, we could say it's top-left for the default layout, see horizontal & vertical align docs. It could also be different for custom layouts.