Sorry for the somewhat noob question, but how do you pick a library for making a GUI for your apps? My background is in physics, so most of my programming is perfectly find with a CLI that outputs a graph as a ps file or some csv. I am looking to learn about making some neat little GUIs. I was thinking it would be a good idea to try and build my GUI out of the browser so that my app can be as portable as possible, but does this mean it has to be in Javascript or can the backend be done in anything else?

I am not really sure what I am asking, but wanted to get a feel for how people approach front ends.

Thanks :)

  • @FizzyOrange
    link
    22 hours ago

    What language are your apps written in? Generally the best options are:

    1. Qt (C++) or PyQt (Python wrapper if you hate yourself). Old school desktop GUI. Works extremely well though.
    2. Web based, then you can pick from a gazillion frameworks, most popular is React. You generally have a Typescript based frontend and a backend in whatever language you want. The downside is you have to deal with the frontend/backend communication which can be a pain.

    There’s also Flutter which is pretty nice, but again you have to use Dart for the GUI so if the rest of your app is in another language you’ll have some friction.

    But yeah, I would say the language you want to write your “business logic” in is the biggest factor to choosing. Also if you care about exposing your app over the web.

    • @[email protected]OP
      link
      fedilink
      11 hour ago

      I’m a bit if a python guy but I’m split between java and up and coming rust for employment purposes.

      • @FizzyOrange
        link
        143 minutes ago

        For Python PyQt is the obvious choice. For Rust there isn’t really a mature option yet. Egui is decent, but it’s immediate mode which isn’t to everyone’s taste. Dioxus is pretty popular too but I haven’t used it.

        No idea for Java. Is Swing still the standard?