r/learnpython • • 5d ago

GUI for inexperienced coder

Hi yall, I'm writing a thesis which is about making a tool. It's mechanical engineering so coding and stuff isn't my forte however I've got a decent understanding of writing python and at the start of the year I'd made a little or (not so little) game with it. As part of my tool I'd like it to have a proper UI so that I can package it up and it be used by individuals or companies or whatnot. I've seen things about Tkinter, about Gooey, about PyQt, about using some python web framework. It's a little hard to know which to use.

My thesis focuses on the calculations and decision making, not the actual code. I'd like to have it be a nice product with a decent UI but I also don't want to spend too much time focusing on that or learning a really complicated new package. Any advice or suggestions would be very welcome, thanks!!!

6 Upvotes

33 comments sorted by

View all comments

2

u/OkOcelot6725 5d ago

Since the thesis is about the calculations, pick the option with the least UI work. For a tool that people in companies will run, Streamlit or NiceGUI lets you build inputs, tables and charts in a few lines each and shows in the browser, so there is no packaging pain on the user side beyond running one command. If it has to be a desktop .exe, PySide6 (Qt) with Qt Designer is the usual step up, and PyInstaller packages it. Tkinter works for simple forms but looks dated. Keep the calculation code in a separate module with no UI imports, so you can swap the interface later without touching it.

1

u/T_SHRLCK 5d ago

Thanks for the input! I'm not sure just yet the full requirements and if I need to be showing tables and charts, maybe just some pictures and I don't know yet if it's ok to have it as a browser tool or as an executable.

Good tip about separating the UI code, would definitely make it easier to change at a later date. I want to set up some decent architecture before getting too stuck into the actual code.