arcade icon indicating copy to clipboard operation
arcade copied to clipboard

GUI Designer

Open eschan146 opened this issue 1 year ago • 2 comments

Modern GUI toolkits such as Qt have an application that allows users to develop a user interface without code, such as Qt Creator.

It helps users quickly create a user interface without typing a lot of code, which can be very redundant.

Arcade's GUI library is missing this. Does anyone know if one is in progress? If not, I will begin development of such a tool.

One major problem in the development of this would be exporting the design. I am thinking implementing a parameter in UIManager that would accept a file that would contain details of the GUI.

(I am the same person that owns the account eschan145, but it was locked out from MFA)

eschan146 avatar Apr 23 '24 22:04 eschan146

TL;DR: I agree with the spirit of this issue, but it's not happening in 3.0

This project is a lot more complicated than it seems:

  1. Arcade's project goals do not include being a full GUI desktop framework
  2. For most full desktop applications, It would be easier to get PySide or other desktop framework bindings to work with Arcade-renderered code inset in a window:
    • There are many missing & broken features in pyglet's desktop integrations, including
      • Non-text clipboard interactions
      • Integrations of copy and paste with the UI
      • Multiple caret / text bugs
    • People have integrated PySide2 (LGPL Qt bindings) with pyglet before
    • The same ideas should apply with later PySide bindings if they still have a GL view widget
    • You could probably port this to arcade as well
    • The scheduling in Arcade might need tweaks
  3. The layout helpers we'd want in pyglet + arcade aren't there yet, but they might be in the future

However, this is a cool idea. It's worth prototyping as a separate repo since I think you'll have a much easier time controlling breaking changes as cameras continue to evolve.

One major problem in the development of this would be exporting the design.

The best solution (imo) for any UI building features would be to include the following:

  1. A core UI building function which takes a nested dictionary
  2. A file loader function which calls the above after processing these arguments:
    1. a path, filename, or file-like object to read
    2. an optional decoder Callable which specifies how to parse the file into a dict
  3. Use JSON or YAML as the default format, not XML

pushfoo avatar Apr 24 '24 00:04 pushfoo

I agree too @pushfoo:

  • Not planned for 3.0
  • Complex
  • Best option would be a prototype in a separate repo

Something which loads a file and returns a UIManager might be enough and does not require UIManager changes.

eruvanos avatar May 21 '24 20:05 eruvanos

If someone wants to created an external library for this I'm all for it. We simply don't have the time and resources to create and maintain this now.

einarf avatar Jul 12 '24 16:07 einarf