18 votes

PySide vs .NET WinForms for a Desktop GUI App in 2023?

Topic removed by site admin

13 comments

  1. [2]
    knocklessmonster
    Link
    Why not PyQt? The Eric IDE has tight integration for it including a form builder, both are in PyPI and you can straight up just use the QT C++ library docs to help with methods I haven't use...

    Why not PyQt? The Eric IDE has tight integration for it including a form builder, both are in PyPI and you can straight up just use the QT C++ library docs to help with methods

    I haven't use PySide, but PyQt + Eric hit a want I had for a VS style Python+QT environment.

    9 votes
    1. akselmo
      Link Parent
      Seconded for PyQt, it's pretty nice.

      Seconded for PyQt, it's pretty nice.

      2 votes
  2. lux
    Link
    Newer .NET is fully cross platform and so is the GUI library Avalonia. I did a few projects with Avalonia in the past and like it. Especially in terms of performance .NET will be much better than...

    Newer .NET is fully cross platform and so is the GUI library Avalonia. I did a few projects with Avalonia in the past and like it. Especially in terms of performance .NET will be much better than Python. You wrote something about multithreading, while this is possible with Python it is natively ingrained into .NET and is a breeze to use. I love current gen .NET a lot. :)

    Another option would be to write a local webapi service and a website which you then wrap into Electron or Tauri or use React Native. Although I had a bad experience with React Native once I actually wanted to properly debug things or when the project simply got bigger.

    8 votes
  3. [3]
    Comment deleted by author
    Link
    1. [2]
      pyeri
      (edited )
      Link Parent
      I've looked up wxWidgets, guess it'd be a bit tedious to use that with a high level language such as Python bindings? How good is wxWidgets at drawing containers within containers? Things like...

      I've looked up wxWidgets, guess it'd be a bit tedious to use that with a high level language such as Python bindings? How good is wxWidgets at drawing containers within containers? Things like timer controls and multi-threading? Python does have support for multi-threading but implementing it in desktop GUI isn't a thrilling experience in most cases I think.

      1. kej
        Link Parent
        There is a wxPython project (https://wxpython.org/) that has done the work of wrapping wxWidgets in Python, but my impression as someone who has only scratched the surface of either one is that...

        There is a wxPython project (https://wxpython.org/) that has done the work of wrapping wxWidgets in Python, but my impression as someone who has only scratched the surface of either one is that PySide has a lot more momentum and mindshare in the Python world.

        1 vote
  4. brogeroni
    Link
    This isn't native, but IMO there's nothing easier than using modern ui frameworks, so I'd personally use something like electron / tauri + web framework of your choice

    This isn't native, but IMO there's nothing easier than using modern ui frameworks, so I'd personally use something like electron / tauri + web framework of your choice

    5 votes
  5. [3]
    Tupats
    Link
    Look up Flutter, Dart is not too far from C# so you'll feel good, and the developer experience is top notch, at least for me. What kind of performance are you looking for?

    Look up Flutter, Dart is not too far from C# so you'll feel good, and the developer experience is top notch, at least for me.

    What kind of performance are you looking for?

    3 votes
    1. [2]
      pyeri
      Link Parent
      It's a productivity tool/app with features like notes, brain-storming, tracking of milestones/hours being worked, etc. I will need multi-threading for things like showing reports or editing notes...

      It's a productivity tool/app with features like notes, brain-storming, tracking of milestones/hours being worked, etc. I will need multi-threading for things like showing reports or editing notes while the tracking is going on in the background timer, for example. This will also require a comprehensive widget library for text-areas, drop-downs, etc. Does Flutter/Dart have an IDE with widget library - which can also be ported across all platforms?

      2 votes
      1. Tupats
        Link Parent
        Sorry for the late reply - I think for these tasks, you would love Flutter. For multithreading Dart has isolates. For IDE, Android Studio and VSC are both first class citizens, and Flutter has all...

        Sorry for the late reply - I think for these tasks, you would love Flutter. For multithreading Dart has isolates. For IDE, Android Studio and VSC are both first class citizens, and Flutter has all the material design widgets built in, you can use them for all platforms. If you want native feel, there are 3rd party packages, but I don't have much experience with those.

        1 vote
  6. Greg
    Link
    Very strong recommendation for a declarative UI framework: React Native (which can render to native widgets per-OS, or directly at the pixel level using Skia) or Flutter (similar to React Native...

    Very strong recommendation for a declarative UI framework: React Native (which can render to native widgets per-OS, or directly at the pixel level using Skia) or Flutter (similar to React Native Skia) if you want native level performance, or any modern web UI in Electron if you can accept the memory overhead.

    React Native and Electron both use Typescript internally, but you can bundle a python “backend” in the same executable using something like zerorpc if you prefer. It sounds like you’re looking for non-blocking behaviour rather than threading specifically for CPU-heavy tasks, so either option should be fine there. Flutter uses Dart, which I’m not personally familiar with but as far as I know is also a solid choice!

    If it were me I’d be going with React Native and Typescript end to end for something UI focused like this, just to save on moving parts and dependency/runtime management. There are also bindings for C++ and Rust via JSI if you’re doing things that need real systems programming, but my experience is the vast majority of UI apps are more than fine using the wrapped native modules that already exist.

    3 votes
  7. Englerdy
    Link
    I have minimal experience with making a GUI for a program other than using Visual Basic for a class in highschool. I recently started working on a Python project that I wanted a front end for,...

    I have minimal experience with making a GUI for a program other than using Visual Basic for a class in highschool. I recently started working on a Python project that I wanted a front end for, however I don't want to have to learn a whole new language right now to accomplish the task. Programming isn't a core strength for me, however I've become proficient with Python and was hoping to leverage that. I'm familiar with Web design, but not enough to make a web front end for my app from scratch.

    I came across this project called NiceGUI for creating Python guis. It creates a web front end and server back end simulationsly, but you only have to write fairly pythonic code. This is what I've settled on for my project unless I come across something even easier to spin up a form based front end. A big draw to a web based front end for me is being able to make a GUI that can easily scale at different resolutions and window sizes. It sounds like NiceGUI might work well for your project too.

    1 vote
  8. babypuncher
    Link
    For Windows development, WinForms is old hat. I would at least move up to WPF. As far as cross-platform solutions go, I've never met one I actually loved. This is because at best they result in...

    For Windows development, WinForms is old hat. I would at least move up to WPF.

    As far as cross-platform solutions go, I've never met one I actually loved. This is because at best they result in software that only uses the lowest common denominator platform features, and at worst they feel very obviously not natively designed for the target platform. So it really boils down to what you're familiar with and what concessions you are willing to make.

    The cross-platform options that might best suit your existing .NET skillset would be MAUI, Avalonia, or Uno. All of these share strong similarities with the aforementioned WPF, specifically their use of XAML.

    1 vote
  9. adutchman
    Link
    If you are willing to learn something completely different, you could look into Rust UI frameworks. They work on litterally any platform, you can even run your desktop app in the browser with...

    If you are willing to learn something completely different, you could look into Rust UI frameworks. They work on litterally any platform, you can even run your desktop app in the browser with Webassembly. I don't have any personal experience with Rust UIs, but the language itseld is great.

    1 vote