Future of Java UI #979
Replies: 4 comments 16 replies
-
I agree on swing, we used it so far and I see no explicit reason, why swing is no longer enough. What we could consider is using Radiance for Look-And-Feel and some nicer ways to handle actions. But that is rather maintenance, it alone does not provide new features or better usability. I think, the real question for the UI is, which goals we want to pursue with the UI in the future. Personally, I am not a fan of the classic Multiwindow approach, when it comes to usability. IMHO, better would be a good navigation breadcrump with a single main focus window and one or two detail windows at the sides or at one side, providing additional information. A bookmark UI component (tab? menu?) could be nice to save often used views (with their focus object, e.g. "Processes: Alpha Base") The views should be configureable to the needs of the player. Also possible: Saving an invocation context to a view configuration. Like, in prosa: User is clicking on a button next to a settlement in the event view for a medical emergency and the views are opened to a medical context with the settler mentioned by the event. The player could choose to open the settlements medical overview in the main view, while the medical data of the settler alone is displayer in a side view. It might be possible to select that a side view should show the view from which this view configuration is invoked, e.g. the event view. |
Beta Was this translation helpful? Give feedback.
-
Is it possible we use the mars-sim.com site for bouncing off JSON messages ? Say, I host mars-sim server version at home. It will listen in any JSON messages via the mars-sim.com site. In the mars-sim server, I may be running 2 different simulation sessions. The first session is an old build that's more stable. The other one is a newer, unstable build for testing features. Then you run mars-sim client version in your house and you log onto the new build to test it. At the same time, @Urwumpe runs mars-sim client in his house and log onto the old build to play mars-sim. Any networking library out there we may look into to achieve this ? |
Beta Was this translation helpful? Give feedback.
-
Thinking about #1149 I've realised that tools like the Science tool could be redesigned to be consistent with the Unit window approach. So Science studies become a tab in the Monitor Tool and they have a dedicated Window when selected.
The latter would be the central panel in the models above. |
Beta Was this translation helpful? Give feedback.
-
To move to a web UI the first step is to convert the current engine into a API service. Based on the graph nature GraphQL is a great choice. I propose we look to add an API as part of 3.9 with a roadmap of a simple web UI in 4.0. This is a long road so we need to support the Java UI inparallel |
Beta Was this translation helpful? Give feedback.
-
There have been a few mentions of what to do with the UI long term such as create a Web UI, move to JavaFX. These relate to the technology used but the first question is how should a user interact with the UI. @mokun & @Urwumpe
User Interaction
The current user experience with the simulation can be confusing as the user is presented with a desktop and a number of tools. What is the best way to interact with the simulation? It is not obvious although the UI is very information rich which is good. The current approach allows the user to interact in any way.
An alternative is to adapt a more structured experience, consider for example Eclipse or VSCode where the user has a layout pre-defined. This workbench style would be very suitable from mars-sim. There is a mock-up below.
The components are:
Missions, Science & Supply Missions are now rendered as standalone windows in this desktop. The Mission, Science and Transport tools are no longer used because the entities can be selected in the tree/table/event feed. The right panel viewing panels of these tools become the windows shown in the center panel.
The tree panel can also support a Favourites as well.
Implementation
The implementation is not as easy. With the above adopting the Eclipse workbench framework would be a good idea BUT this means adopt SWT which would need a total rebuild of all UI panels. So this would involve a lot of effort.
The same applies for JavaFX in that nothing can be re-used.
A web UI I feel is the ultimate goal and whilst this can adopt the workbench style it involved even more development effort and bigger question on how a web API should be developed.
Therefore the Swing implementation is likely to be our best opinion.
Beta Was this translation helpful? Give feedback.
All reactions