Which GUI lib should i start with? | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
0

Which GUI lib should i start with?

I tried RenPy (a visual novel engine), made some turn based text games and such. But even a simple Guess Game has more than 30 MB Data without any images or so. It also uses its own coding mechanism and makes me struggle in it. Would you suggest any lighter editor for me to start with?

16th Sep 2018, 8:51 PM
ilker
ilker - avatar
12 Respostas
+ 2
This has nothing to do with the editor, but the libraries. Ren'Py will have a "base minimum" so a simple guess game will be similar to a large CYOA in file size. Just remember it's built on top of PySDL or PyGame or one of the forking forks. Whatever editor you use is not relevant when you're linking to a ton of stuff (probably an entire SDL or SDL2.0 DLL or SO). And I'm not even sure how it's implemented (can Python call C libs directly or is a third-party involved?) etc. Bottom line is that it's not your editor. Python is just text. Your editor helps you write text. Even if we were talking a compiled language, it would be down to the compiler and libraries.
17th Sep 2018, 12:10 AM
non
+ 2
Yeah i will keep working on Renpy too, but not for creating a calculating app or for some useful tools. Just because RenPy was the only GUI Lib i knew, i tried to build everything i wanted on it but i spent a lot of time changing its pre defined GUI to make a simple guess game which was only 50 lines of codes and most of them are RenPy functions. It is not useful for simple applications like these, but of course a lot better for creating a novel. I was just reading on PySimpleGUI and i think it is what i needed from the start. Simplicity is the key for me. Less struggle with the interface means more time left to think about the mechanism and many others.
18th Sep 2018, 12:06 AM
ilker
ilker - avatar
+ 1
maybe tkinter (installed by default) can help. Or PySimpleGUI, but it's built over tkinter...
17th Sep 2018, 11:56 AM
Amaras A
Amaras A - avatar
+ 1
Remember, your Python source is < 1k but all the libs it calls may be large (a few MB per lib). Add dependencies and it's gonna grow. Sure, not to 30MB, but it's easier for the developers to include everything in 1 or 2 files. I guarantee your test project's end result would barely be any bigger if you write a full Choose Your Own Adventure novel. For code size, it's big, but you've gotta think three-dimensionally here. And when I said 30MB was small by today's standards, I meant storage. You can't find an hdd under 500GB, an SSD under 120GB, or a thumbdrive under 8GB -- at least not easily. The only reason I criticize bloat is when it's inefficient code. In your case you're using an interpreted language and an "engine built on an engine" so I'd already say performance is not critical here. Your goal here is Rapid Deployment (based on your tool choice). So focus on that and get your project done or you'll end up like me: 4 lifetimes of goals to complete and 0.5 lifetimes left.
17th Sep 2018, 11:32 PM
non
+ 1
That's a good outlook. Simplicity is a great ally!
18th Sep 2018, 12:23 AM
non
+ 1
Actually talking with you made me more aware about what i really want. Thanks for that šŸ‘ Also i will use 'GUI lib' instead of 'GUI editor' from now on if it is the right one? šŸ˜…
18th Sep 2018, 12:37 AM
ilker
ilker - avatar
+ 1
Yes, that's the correct term.
18th Sep 2018, 9:48 AM
non
0
Oh, i totally asked a different question. I am aware of almost everything you told. I use Atom or Notepad++ for text editing even on RenPy too. But a GUI editor i was trying to imply is a library full of codes like gui.text.size="30" as renpy has in its library. I just want to find a smaller one. So i am looking for a library which can help me edit GUI with less text editing.
17th Sep 2018, 12:35 AM
ilker
ilker - avatar
0
I certainly will give PySimpleGUI a try now. Thanks. edit: sorry for bad typing before :)
17th Sep 2018, 12:39 PM
ilker
ilker - avatar
0
welcome. the problem with that mountain is that it might be too smoke for things...
17th Sep 2018, 12:45 PM
Amaras A
Amaras A - avatar
0
Ah, I see. Well I don't know about size. Just remember there's gonna be a minimum size and 30MB isn't that big by modern standards. Have you looked at using PyGTK directly?
17th Sep 2018, 12:48 PM
non
0
It is pretty big for a simple guess game which can not be longer than 100lines of raw codes. So i just want that GUI Library can screen this on a tkinter-like frame.
17th Sep 2018, 2:47 PM
ilker
ilker - avatar