Describe difference between size and bbox

This commit is contained in:
Andrew Murray 2024-02-17 11:50:48 +11:00
parent d3b974b786
commit 617b9cbc00
2 changed files with 8 additions and 0 deletions

View File

@ -252,6 +252,10 @@ Use instead::
left, top, right, bottom = draw.multiline_textbbox((0, 0), "Hello\nworld", font)
width, height = right - left, bottom - top
Previously, the ``size`` methods returned a ``height`` that included the vertical
offset of the text, while the new ``bbox`` methods explicitly distinguish this as a
``top`` offset.
FreeTypeFont.getmask2 fill parameter
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -89,6 +89,10 @@ Use instead::
left, top, right, bottom = draw.multiline_textbbox((0, 0), "Hello\nworld", font)
width, height = right - left, bottom - top
Previously, the ``size`` methods returned a ``height`` that included the vertical
offset of the text, while the new ``bbox`` methods explicitly distinguish this as a
``top`` offset.
API Additions
=============