Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New stlye qt calls #2382

Merged
merged 8 commits into from Sep 10, 2013
Merged

New stlye qt calls #2382

merged 8 commits into from Sep 10, 2013

Conversation

tacaswell
Copy link
Member

Changed all qt calls to 'new style' due to a bug in PySide (see #2378)

In the course of this I discovered that there was some funny merging/un-merging of the patches from @mspacek that resulted in there being no col2hex defined. It may be worth a separate issue to make sure nothing else got lost.

Everything seems to work, but I could not figure out how to get the font editor dialog to come up (I suspect that the italics and bold labels won't show up).

Also includes a bunch of pep8 cleanup

@mdboom
Copy link
Member

mdboom commented Sep 5, 2013

Sorry, that merge mistake is probably mine. It looks like we'll have to fix it on 1.3.x as well. I'll do it over there, and we'll leave this PR as-is to cover it on master.

@mdboom
Copy link
Member

mdboom commented Sep 5, 2013

Oops. Forget that. 1.3.x seems fine.

@mdboom
Copy link
Member

mdboom commented Sep 5, 2013

This seems like the right thing to do -- moderizing rather than putting band-aids that work around unicode_literals.

One thing, though -- I had to do the following, or I got a segfault at startup:

diff --git a/lib/matplotlib/backends/backend_qt4.py b/lib/matplotlib/backends/backend_qt4.py
index 6ae8083..991edc7 100644
--- a/lib/matplotlib/backends/backend_qt4.py
+++ b/lib/matplotlib/backends/backend_qt4.py
@@ -82,7 +82,7 @@ def _create_qApp():
                 if display is None or not re.search(':\d', display):
                     raise RuntimeError('Invalid DISPLAY variable')

-            qApp = QtGui.QApplication([" "])  # probably fine, not used by QT to resolve anything
+            qApp = QtGui.QApplication([str(" ")])  # probably fine, not used by QT to resolve anything
             qApp.lastWindowClosed.connect(qApp.quit)
         else:
             qApp = app

@tacaswell
Copy link
Member Author

There are many failures in travis from errors coming out of locale.py.

@tacaswell
Copy link
Member Author

@mdboom What OS are you testing on? I find it a bit worrying that I was not getting segfaults without that last change.

@mdboom
Copy link
Member

mdboom commented Sep 6, 2013

I'm on Fedora 19, which has pyside 1.1.0 installed from the standard package (and this is Python 2.7).

@tacaswell
Copy link
Member Author

Does this need anything else to get merged?

@mdboom
Copy link
Member

mdboom commented Sep 10, 2013

Nope. Merging.

@mdboom mdboom closed this Sep 10, 2013
@tacaswell
Copy link
Member Author

It doesn't look like this actually got merged, just closed.

@mdboom mdboom reopened this Sep 10, 2013
mdboom added a commit that referenced this pull request Sep 10, 2013
@mdboom mdboom merged commit b4c9ced into matplotlib:master Sep 10, 2013
@mdboom
Copy link
Member

mdboom commented Sep 10, 2013

Sorry about that. I think it's good now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants