Christoph Reiter
f3342173c1
meson support. Fixes #114
2018-06-23 21:31:31 +02:00
Christoph Reiter
b61e3c7704
version bump
2018-04-15 12:18:55 +02:00
Christoph Reiter
910ee82a5c
release
2018-04-15 12:15:22 +02:00
Christoph Reiter
064571b9dd
update .gitignore
2018-04-15 12:14:59 +02:00
Christoph Reiter
2131602d7e
setup.py: default to setuptools
2018-04-15 11:10:21 +02:00
Christoph Reiter
1786acfe70
travis-ci: add 3.7-dev
2018-04-15 10:39:13 +02:00
Christoph Reiter
cb35d86263
Implement PEP 561 (added a py.typed marker)
2018-04-15 10:12:03 +02:00
Christoph Reiter
55ea24fb6b
Use -fvisibility=hidden
2018-04-13 18:39:44 +02:00
Christoph Reiter
ffee6475dd
Merge pull request #112 from lazka/pycairo-c-no-import
...
c-api: Make it possible to use the C API with Python 3 outside of the CU doing the import. Fixes #110
2018-04-13 18:31:34 +02:00
Christoph Reiter
9215412954
c-api: Make it possible to use the C API with Python 3 outside of the CU doing the import. Fixes #110
...
In case PYCAIRO_NO_IMPORT is defined we declare the api struct as extern and hide the
import function. Also don't make the API struct static so we can access it from outside.
2018-04-13 17:11:32 +02:00
Christoph Reiter
3f55438298
Merge pull request #111 from lazka/tests-capi
...
tests: add a simple C API test
2018-04-13 16:37:22 +02:00
Christoph Reiter
023bc45fdf
tests: add a simple C API test
...
build a C module and use the C API
2018-04-13 16:12:59 +02:00
Christoph Reiter
b893898c8d
setup.py: always use -fno-strict-aliasing
...
pypy3 also doesn't set it by default, might as well force it always now that
we can check if the compiler supports it.
2018-04-12 09:49:41 +02:00
Christoph Reiter
e9cc184bb3
Update NEWS and docs for the next release
2018-04-09 19:59:36 +02:00
Christoph Reiter
c04e32eb07
surface: override the __exit__() handle for mapped images
...
With the context manager support for surfaces this also has started to
work for mapped images but finishing a mapped one is undefined.
Add a new __exit__() which unmaps the image instead and makes this valid:
with surface.map_to_image(None) as image:
pass
2018-03-27 20:59:39 +02:00
Christoph Reiter
5d2fe236ee
Fix a leak when a mapped surface gets GCed instead of unmapped
...
missing unref of the base surface
2018-03-27 19:35:59 +02:00
Christoph Reiter
9274b90a15
Fix a leak when creating an exception
...
The status enum leaked
2018-03-27 19:35:59 +02:00
Christoph Reiter
1f7b6d2a9d
Merge pull request #109 from lazka/contextmanager
...
Make cairo.Surface and cairo.Device context managers. Fixes #103
2018-03-27 17:24:25 +02:00
Christoph Reiter
6d3b0addb2
Make cairo.Surface and cairo.Device context managers. Fixes #103
...
calls finish() in __exit__()
2018-03-27 16:51:07 +02:00
Christoph Reiter
77d17ed80e
Merge pull request #108 from lazka/compiler-warn-flags
...
setup.py: add detection of supported compiler warning options
2018-03-16 20:00:34 +01:00
Christoph Reiter
8637672c8a
setup.py: add detection of supported compiler warning options
...
This allows us to get rid of the PYCAIRO_WARN env var and always
use warning options.
This is a copy of what I added on pygobject.
2018-03-16 19:18:25 +01:00
Christoph Reiter
cd1a6a6d93
mypy: enable strict_optional
2018-03-06 15:42:24 +01:00
Christoph Reiter
8694cd82bb
typing stubs: add Win32PrintingSurface, Win32Surface
2018-03-03 17:49:46 +01:00
Christoph Reiter
520c3e006e
travis: adjust for homebrew package name changes
2018-03-02 20:40:41 +01:00
Christoph Reiter
67575800b8
Merge pull request #102 from lazka/appveyor-msvc-cairo-1.15.10
...
appveyor: update MSVC cairo
2018-03-02 20:36:49 +01:00
Christoph Reiter
0d6ebba745
appveyor: update MSVC cairo
2018-03-02 15:57:14 +01:00
Christoph Reiter
cb1626a7f4
version bump
2018-02-27 12:15:39 +01:00
Christoph Reiter
5751aae1df
release
2018-02-27 12:14:21 +01:00
Christoph Reiter
8e78c5fa49
stubs: fix tuple element types, oops..
2018-02-26 12:22:13 +01:00
Christoph Reiter
b4b9dcaac9
flake8
2018-02-26 11:03:18 +01:00
Christoph Reiter
6852114d0e
Add a default mypy config and enable more warnings.
...
This makes calling "mypy ." in the root directory work.
The added warnings pointed out that the tuple subclasses were
missing type information for their elements, so add them.
2018-02-26 10:57:30 +01:00
Christoph Reiter
99e2ae53f0
Merge pull request #101 from lazka/typing-stubs
...
Typing stubs
2018-02-25 18:03:03 +01:00
Christoph Reiter
fa667febd4
Add PEP 484 annotation stubs. See #99
2018-02-25 17:07:45 +01:00
Christoph Reiter
4ad2228488
tuple subclasses: use tp_getset instead of tp_getattro for member access
...
With tp_getset things will show up in the class __dict__ which helps
with auto completion and also allows us to compare things with
the annotation stubs.
2018-02-25 16:03:45 +01:00
Christoph Reiter
de7e156ec1
docs: sphinx 1.7 no longer allows non-class refs as param types
2018-02-22 09:42:02 +01:00
Christoph Reiter
cd4c3c7994
docs: call the sphinx __main__ instead of using sphinx-build
...
It has stopped working in a --user install, not sure..
2018-02-22 09:37:50 +01:00
Christoph Reiter
d26442d853
Merge pull request #100 from danyeaw/fix-example-formatting
...
Fix formatting to PEP8
2018-02-22 09:23:51 +01:00
Dan Yeaw
3b4e189f56
Fix formatting to PEP8
...
Signed-off-by: Dan Yeaw <dan@yeaw.me>
2018-02-21 21:48:39 -05:00
Christoph Reiter
417c8afd8a
version bump
2018-02-10 18:20:38 +01:00
Christoph Reiter
c74dc1e358
release
2018-02-10 18:14:55 +01:00
Christoph Reiter
cd8642d62f
appveyor: pacman, yes to everything
2018-02-10 18:02:32 +01:00
Christoph Reiter
8965abb899
setup.py: don't include paths containing parts of the python library path, debian renames it after installation. See #98
...
Debian doesn't pass an alternative installation layout to setup.py but instead just renames
things afterwards. Since we now write relative paths containing the python library directory name
this breaks things and we can't do anything about it.
So instead of installing one header and referencing it from the other one just install it twice.
And reference the /usr/include one in the .pc file.
2018-02-10 17:49:50 +01:00
Christoph Reiter
b04a67bb18
tests: add links to upstream pypy bugs for the remaining skipped tests
2018-02-07 17:07:44 +01:00
Christoph Reiter
ff4c33f0fc
travis-ci: try newer pypy releases
2018-02-07 16:50:36 +01:00
Christoph Reiter
0e3906005e
tests: unskip test_fspaths under pypy
...
I can't reproduce the error any more, let's give it a try on CI
2018-02-07 16:38:52 +01:00
Christoph Reiter
95ecefd5b1
tests: fix offbyone in slice assignment, slowing things down
...
This made the array resize which is slow in PyPy
https://bitbucket.org/pypy/pypy/issues/2750
The test is still skipped as it now fails with
"TypeError: expected a writeable buffer object"
2018-02-07 15:20:54 +01:00
Christoph Reiter
23bc5cf6a9
version bump
2018-02-06 13:39:55 +01:00
Christoph Reiter
ed67cc29d7
release
2018-02-06 13:38:20 +01:00
Christoph Reiter
c9172639a7
setup.py: switch .pc file back to /usr/lib
...
We now have platform specific paths in the .pc file and can no longer
install it to /usr/share. Switch back to /usr/lib*.
The initial bug in jhbuild motivating the move is still there, so we
need to fix this in jhbuild.
2018-02-06 12:12:09 +01:00
Christoph Reiter
2a51f92dde
version bump
2018-02-05 16:55:36 +01:00