Compare commits

..

2 Commits

Author SHA1 Message Date
6e3e288628 Change ReccomendedHeightFor -> RecommendedHeight
Closes #1
2024-09-06 00:23:44 -04:00
f2da861f1b Fix README.md 2024-09-06 00:23:36 -04:00
2 changed files with 4 additions and 4 deletions

View File

@ -5,4 +5,4 @@
Typeset provides utilities for text layout, wrapping, and rendering.
The state of a text layout is stored in a TypeSetter, and it can be drawn to any
image.Image using a Drawer which "extends" TypeSetter.
draw.Image using a Drawer which "extends" TypeSetter.

View File

@ -386,10 +386,10 @@ func (setter *TypeSetter) MinimumSize () image.Point {
return image.Pt(width.Round(), height.Round())
}
// ReccomendedHeightFor returns the reccomended max height if the text were to
// have its maximum width set to the given width. This does not alter the
// RecommendedHeight returns the reccomended max height if the text were to have
// its maximum width set to the given width. This does not alter the
// typesetter's state.
func (setter *TypeSetter) ReccomendedHeightFor (width int) (height int) {
func (setter *TypeSetter) RecommendedHeight (width int) (height int) {
setter.needLayout()
if setter.lines == nil { return }