Need Windows GUI for Python .exe script - python

I wrote a py .exe script and need to create a GUI for it with a file path input field, a 'cancel' and 'ok' buttons. How can I accomplish it best? Do I need to bind it with any C libraries? I know I could easily create a web based interface but I do not want a web app, I need a .exe app.
Please, help!

For such a simple GUI, Python comes with a built in library: TkInter. It's somewhat ugly, but it might be fine for your purposes - requires nothing 3rd party, so no additional installations. If you want something more full featured, I'd suggest PyQt

wxPython is the best thing I can think of.

Have a look at easydialogs for window http://www.averdevelopment.com/python/EasyDialogs.html

Related

How can i turn python to apk?

I am just a newbie on that things and I want to turn python to apk with android studio or whatever. I don't really need anything to complex, I just want to open my codes output gui (I used turtle) when I open the app. Nothing else, thats all. It is probably complex process so you can just give me where to look and learn if you can't explain it all in here. Thanks!
Turtle is built around TKinter, which is a library for making desktop apps. There doesn't seem to be a way to run programs built in TKinter within Android without using some other app to run them. If you're ok with that, then you could use the solution suggested by this answer to run your code by pasting it into an app that can run Python code.

Is wxPython Needed on the End User's Computer

I am making programs that solve and show work for math problems. I would like to add a GUI, and I think wxPython will be best. If I use wxPython for the GUI, will the end user need wxPython on their computer in order to use the program with the GUI? If not, what would should I use?
These apps will be used on mostly Windows, but I would also like them to work on Macs and Linux. I'm not for sure if any Python GUI elements will work on Android through SL4A, but if you know any, that would be appreciated.
Also, I know Tkinter is bundled with Python, but is it a dying technique, as I have read?
Thanks!
There are tools for packaging a python program and its libraries into an executable that can run on its own. I keep this list handy:
http://www.freehackers.org/Packaging_a_python_program
I'm sure at least one of those tools will handle wxPython, because I did it a few years ago. (Sorry, but I don't remember which one.)
Yes, tkinter's popularity has been waning for years. See this question for some more options:
higher level Python GUI toolkit, e.g. pass dict for TreeView/Grid
If your software is mostly about the complicated processing, with a fairly simple UI, tkinter is probably fine
I am using cx_freeze for this without any problems. Worked for me on Windows and Linux.
Tkinter comes with Python, so it can be handier in some respects just because of that. On the other hand, wxPython uses the native widgets of the OS (which has it's own set of pros and cons). I personally prefer wxPython. But no, Tkinter is not dead to my knowledge.
You can use py2exe to bundle up your app on Windows or you could use cx_freeze or bb_freeze. There's also PyInstaller, which I think can create some kind of Linux bundle, but the docs are kind of confusing. For Mac, see py2app.
I'm not aware of any specific Python GUI toolkits for Android.
PyInstaller.
install and run.
cmd -> python pyinstaller.py NAMEOFSCRIPT.py --onefile --noconsole.
easy as 123.

Python: Desktop UI for my python script

Im new to python and want to create a GUI front-end (desktop, rather than web) for my python script. The script essentially parses XML files and runs various searches over the contents (eg. accepts regex searches from the user, returns results etc).
It works well on the command line but I want to present a more user friendly interface.
There seems to be a lot of options out there - http://docs.python.org/faq/gui.html
Or should I look elsewhere?
Can someone recommend a GUI toolkit for Python?
Cheers.
I recommend using one of Tkinter, wxPython or PyQt. They are all equally suitable for a simple task. My personal favorite is Tkinter because I think it is the simplest way to get started. However, any of those would make a fine choice.
Here is a page on the Python wiki with some fifty options.
PyQt is great, although it's on GPL. There is also PySide alternative on LGPL.
You can also try wxPython or PyGTK if you don't like Qt for some reason. There is also gui library in python standard library called Tkinter, but I haven't used it and don't have any experience with it.

Help On Python program that can use to compile python coding into a standalone .exe file

I am currently working on a python program with the use of wxpython to make out a gui application. However, i wish to compile my application to be like a standalone application where people can just get the .exe file and run it without installing python and wxpython. I am not sure if it is possible, thus i hope that someone can give me some guidance on this. Also, if it is possible, please tell me what program should i use to accomplish that.
Thanks
You need to create a frozen binary. You can use py2exe for this purpose.
For what it's worth, if you ever need to make executables on a unix system, you can use Freeze, a utility that comes with Python.
For a nice cross-platform solution, I always recommend pyinstaller (actually, I find it better than py2exe even just for making a Windows-only executable -- it can do code signing, can seamlessly incorporate "big, hairy" libraries such as PyQt, etc;-).

Embedding a 3-D editor (such as Blender) in a wxPython application

Is it possible to embed a 3-D editor inside my wxPython application? (I'm thinking Blender, but other suggestions are welcome.)
My application opens a wxPython window, and I want to have a 3-D editor inside of it. Of course, I want my program and the 3-D editor to interact with each other.
Possible? How?
Blender has python plugins, you can write a plugin to interract with your program.
I second Luper Rouch's idea of Blender plugins. But if you must have your own window you need to fork Blender. Take a look at makehuman project. It used to have Blender as a platform. (I'm not sure but I think they have a different infrastructure now)
For Blender specifically, I doubt it. Blender uses a custom UI based on OpenGL, and I'm not sure you can force it to use a pre-existing window. I suggest browsing the code of "Ghost", which is Blender's custom adaption layer (responsible for interacting with the OS for UI purposes).
Perhaps this script might provide some context for your project. It integrates Blender, ActiveX, and wxPython.
Caveat: Windows only.
For Blender2.5 on linux you can use gtk.Socket, code example is here on pastebin

Categories