Skip to content

Releases: leifgehrmann/pangocffi

v0.13.0

20 Jun 23:01
Compare
Choose a tag to compare

Additions

  • Added Font, FontMetrics, Language, and Context.load_font(). #55, #58, #59

Internal Improvements

  • Added .readthedocs.yaml for generating documentation. #54
  • Updated c-definition generation script for Pango CFFI. #55
  • Added tests. #58, #59
  • Fixed GitHub actions. #57
    • Codecov now requires a token.
    • The libraries for cairo, pango, and glib were no longer working for macOS.

v0.12.0

22 Oct 21:57
Compare
Choose a tag to compare

Breaking Changes

  • Support for Python 3.6 and 3.7 has been dropped. #51

Additions

  • Added the TabArray and TabAlign objects used for tab stops. #50, #52

Internal Improvements

  • Updated tox.ini to test Python 3.11 and 3.12. #51
  • Updated GitHub actions to use Python 3.12. #51
  • Updated GitHub action dependencies. #51
  • Fixed new linting issues highlighted by Flake8. #51
  • Fixed breaking changes made by Tox in tox.ini. #51
  • Added an acceptance test that demonstrates how tab stops work. #52

v0.11.0

07 Oct 19:27
Compare
Choose a tag to compare

Breaking Changes

  • Pango objects with matching setter and getter methods have been converted to properties. See #47. For example, with the Layout object:
    • layout.get_text() is now layout.text
    • layout.set_text('Hi from Παν語') is now layout.text = 'Hi from Παν語'
    • layout.get_pointer() is now layout.pointer
    • Note: For now, some computed properties are still named as layout.get_size() and layout.get_line_count().
  • layout.set_markup() has been renamed to layout.apply_markup(). #47

Bug Fixes

  • color.copy() now correctly copies the blue component, instead of resetting to 0. #47

Internal Improvements

  • Tests are now run for Python 3.10. #43, #45
  • Fixed GitHub Action tests for Windows. #45
  • Fixed linting issue in attr_list.py. #45
  • Added documentation on how to make contributions to pangocffi. #46
  • Added full dev dependencies to requirements.txt. #46
  • The GitHub Action for linting was extracted out of the build/test action to make contributions easier. #48
  • Updated GitHub Action dependency versions. #48
  • All Pango objects have been refactored as PangoObject. #47

v0.10.0

30 Dec 00:04
Compare
Choose a tag to compare

Breaking Changes

  • All from_pointer() methods in pangocffi by default will not apply a garbage collection callback. #42 If you are using pangocairocffi, you will need to update to the latest version (v0.6.0) to avoid any potential issues. This change is done mainly for consistency. If the original functionality is desired, adding gc=True should be enough (In other words, from_pointer(pointer, gc=True)). This affects the following methods:
    • Context.from_pointer()
    • Layout.from_pointer()

Additions

  • Added setter methods for the properties of Rectangle and adds arguments to __init__() for setting the properties individually. #42

Bug Fixes

  • Fixed an issue with Attribute in an AttrList causing segmentation faults when the list was being copied because the attribute was improperly being garbage collected. This was solved by simply removing the call to ffi.gc(pointer, pango.pango_attribute_destroy). If there are any issues with this change, please raise an issue in the issue tracker. #42
  • Fixed a mistake with Attribute where the end_index was incorrectly being set against the start_index. #42

v0.9.0

19 Dec 22:18
Compare
Choose a tag to compare

Breaking Changes

  • pangocffi now depends on GLib 2.0. It's very likely GLib is already installed since pangocffi already depended on GObject, but if not, pangocffi will raise an error on import. #28

Additions

  • Added the following new classes. #28, #30
    • Attribute
    • AttrList
    • Color
  • Added new methods to Layout. #28, #30
    • set_attributes
    • get_attributes
  • Added new enum Underline. #28
  • Added the ability to configure loading a specific library via the following environment variables. #32
    • PANGO_LOCATION
    • GLIB_LOCATION
    • GOBJECT_LOCATION

Bug Fixes

  • Fixed issue with Context.get_gravity_hint calling the wrong pango function. #31

v0.8.0

13 Nov 00:01
Compare
Choose a tag to compare

Breaking Changes

  • C-FFI bindings are now generated at runtime, rather than at installation. See #21. This was done to avoid common installation issues like ModuleNotFoundError: No module named 'pangocffi._generated'. This change does mean the bindings are re-compiled the first time import pangocffi is called in a python session, but it takes less than a second to do this. If there are any issues with this change, please raise an issue in the issue tracker.
  • Because of the aforementioned change, modules that depend on pangocffi's bindings being generated upon installation rather than at runtime, like pangocairocffi, will break. Either lock your version of pangocffi to 0.7.0 or upgrade the module to the latest version which is compatible with 0.8.0 of pangocffi.
  • Support for Python 3.5 has been dropped because it has reached end-of-life. #21

v0.7.0

17 Oct 18:40
Compare
Choose a tag to compare

Additions

  • Added new methods to Layout. #19
    • set_wrap
    • get_wrap

v0.6.0

17 Sep 20:15
Compare
Choose a tag to compare
  • Added new methods to Layout
    • set_ellipsize
    • get_ellipsize

v0.5.0

08 Oct 23:44
Compare
Choose a tag to compare
  • Added support for Win64 dynamic libraries.

v0.4.0

23 Mar 00:48
Compare
Choose a tag to compare
  • Added FFIInstanceBuilder to separate C FFI build logic from the actual C FFI builder.