Ignore:
Timestamp:
Jan 13, 2012 9:17:01 PM (3 years ago)
Author:
alxf
Message:

Add support for python3 to python bindings.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/python/caca/font.py

    r4770 r4802  
    1818import errno
    1919
    20 from caca import _lib
     20from caca import _lib, _PYTHON3, _str_to_bytes
    2121
    2222class _Font(object):
     
    6565        _lib.caca_load_font.restype = ctypes.c_int
    6666
     67        if _PYTHON3:
     68            font = _str_to_bytes(font)
     69
    6770        self._font = _lib.caca_load_font(font, size)
    6871        if self._font == 0:
Note: See TracChangeset for help on using the changeset viewer.