-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Add tutorial file for Glade 3.16-GTK3.10-Python 3 #3088
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
Conversation
Is it a good thing the Travis-CI-build failed on Python 2.7? Afterall this is Python 3 code? |
The failure is un-related (and you didn't change anything that falls under the test coverage anyway). |
Can you make sure that this gets linked to from the documentation so that people can find it? Would it be worth writing some prose for the documentation? |
@tacaswell - Sorry for the question: What format should the documentation have? In which folder should I place it? And where should I insert the link? |
We use sphinx to generate the documentation website which uses restructured text. As to where in that folder, I am not sure. From http://matplotlib.org/examples/user_interfaces/mpl_with_glade.html it looks like this new file will get an auto-generated web-page, but the current example has no prose to go with it. If you are feeling ambitious add a new page it @farzia can you take a look at this? |
It will take me a few days to figure out how sphinx and rst files work, but I am intending to make a page in |
Can you do it in such a way that added prose about embedding in other frame works has an obvious place to go? |
I started on the documentation under 'advanced guides'. Can somebody check if the structure checks out? I was thinking that the pages could be separated by framework and in the case of GTK also in the pure-GTK and the GTK-Glade approach (e.g. doc/users/ui_glade.rst). All these pages could have gradually evolving tutorials, from a simple window to a interface with some buttons, plot manipulation, and cursor tracking. Would anybody like to do Qt, Wx, Tk or any of the other frameworks? |
- Qt4 | ||
- Qt5 | ||
- Tk | ||
- Wx |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also macos native (quartz?)
@tacaswell - I'm not sure what you mean. Is that another toolkit? I just included the toolkits that have an example in the example folder. There are a lot of toolkits (most of which I have never heard of). But which ones should we include? (https://en.wikipedia.org/wiki/List_of_widget_toolkits) |
Look at the files in |
Introduction | ||
============ | ||
|
||
Matplotlib can be placed as a widget into a variety of user-interface frameworks (or user-interface toolkits). This allows one to build custom applications that can display Matplotlib-plots. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please hard-wrap lines.
This looks like a good start to me. Hopefully this can make it in for 1.4.0, but I don't think that this issue is a blocker. One of my priorities for 1.5 is to make this whole process simpler ( #2624 ). |
I have a question about the backends. I don't have a good grasp on what all the different backends are. Shouldn't this section focus on gui-toolkits and make a separate page for web-toolkits and all those different backends-things? About the first pictures: Currently I only have a few Ubuntu+GTK screenshots as placeholders. I will try to mix them up a bit. We should try to pool screenshots from different operating systems. About the hardwrapping: What line length should I wrap to? |
I actually think embedding in the web is kind of a natural fit for this section. I have a couple of questions go by related to serving images directly back from either django or gae. The native osx backend is a first-class desktop gui. If the tools are there to make a figure window, the tools are there to embed plots in any gui window in that framework. I was mostly protesting to it's exclusion from your list of frame works supported. |
While I wouldn't want to discourage improvement in the docs, or anything else in mpl, I'm afraid this is getting out of hand and out of proportion. Do we really want all this detail about a peripheral issue in the core mpl docs? Everything that goes into the mpl distribution should be maintained and updated as needed with each release. As it is, the really central docs are woefully incomplete, messy, and in some cases badly outdated. (At the moment I am trying to fix some such basic problems in the FAQ.) |
@tacaswell - I have nothing against including web-interfaces. Will the structure still work with web interfaces included: docs --> user guides --> advanced guide --> user interfaces --> (...)? Or will people be confused finding web-stuff under UI? Can you make the macosx and django pages? I thought of doing wxWidgets or Qt next. But it will take me some time to learn how to use those toolkits. |
@efiring - I agree that it might overload the documentation. Although the user interface examples that go without any text might be confusing to a lot of new programmes, such as myself. Scipy seems to suffer under a lot of maintenance difficulties too (last update: 2013-08-17). Putting the tutorials there look fine, but I wonder if anyone will find them? |
Base key on the id of the transform. This maintains the old behavior and does not break the python hashable object model. changed the variable id -> pid so as to not shadow the method `id` Closes #2828
Added note to widget doc-strings that the user must maintain a reference to the widgets to keep them responsive (if they get gc'd the call backs go away). Some random conversion to numpyboc Closes #3105
- corrected docstring in Slider.__init__ - feedback on previous commit
closes #3117
I assume there was a reason for only putting the examples in the html docs, but I don't see it.
Removed example of how parse output from svn logs.
Parameter -> Parameters Example -> Examples
Added section on high-level plotting with seaborn and ggplot. Added mpldatacursor and prettyplotlib.
- use blurb suggest by @mwaskom - added links
It means exactly what it says, although stash might not be the right action Once you got the unstaged changes taken care of, then go ahead with the Cheers! On Wed, Jun 25, 2014 at 11:45 AM, Tobias Schönberg <[email protected]
|
@spiessbuerger - looks like you may have been merging upstream/master into your branch? Doing so messes up your git history (as you can see) and generally, if you need to update the branch point you should rebase. Luckily in this case it is fairly easy to fix since you are only proposing the addition of two new files. So, how to fix it? There are plenty of solutions to this, but I would be tempted to simply:
|
@pelson - I think I am doing something very wrong with git. I don't think I will be able to resolve this, as I am also not really sure what is going wrong. Also attempts at getting help online have failed, probably because I can't really articulate the problem well. |
Don't fret. Squashing isn't required. It just helps to keep everything nice My first experience with git was a bit of a learning curve, and I did have On Fri, Jun 27, 2014 at 9:11 AM, Tobias Schönberg [email protected]
|
Seconding @WeatherGod the git learning curve is an overhanging sheer wall, however once you get used to it it is very powerful. |
Closing this in favor of #3160 |
The two files are:
The two files show a possible way of embedding a matplotlib-widget into a GTK-3.10 interface that was build using the Glade 3.16 interface designer.
The existing tutorial is for an older version of Glade and GTK and should probably be kept for reference (a lot of people still develop for those older setups). Another tutorial builds the whole interface using GTK3-code (which is the approach for less complex user interfaces).
I will try to make a more complex example next, which will use a few buttons that manipulate the matplotlib-plot. But this tutorial shows the bare minimum required to get this to work.