开云体育

Bob Jacobsen suggested this as a collection of thoughts regarding this issue. This discussion was started In August of 2022 when JMRI was up to version 5.1.3 and had no undo functions.

Currently, if you are working on a graphics panel of your layout, in 'edit mode' and let's say right click on an object to see what its characteristics are. It shows let's say 'Turnout TOL432' and gives you the option of 'EDIT' in the dropdown. Perfect! If you, however, are working on the same panel, and miss the object's 'sweet spot' and grab an anchor point and inadvertently change its location, you may have a very difficult time retracing that movement. In that case, an UNDO button would be very handy. The larger and more complex the layout, the more difficult this problem becomes.

Any agreement on this?

  • AGREE - Not having an undo can be a pain. My feeling is it would be a "very nice to have feature." I am a fairly advanced LE user and computer user, so I am used to the "save often" school of thought. However, the undo would save time and aggravation. New users of JMRI, having been spoiled by other everyday computer and phone apps, might automatically expect an undo feature and be even more disappointed and dismayed that LE and many other parts of JMRI lack this. Having said that, I also know that implementing UNDO will be a *MAJOR* and perhaps nearly impossible undertaking. John B on the Delmarva Peninsula.
  • Would an undo of _just_ the last move operation be useful? Without handling undo of e.g. settings in menus (drop-down or others)?
    • I think it would be useful. I also suspect that once offered, there would be a request for a multi-level undo! There still might be a lot of "gotchas."
      • *IF* the last action was easily reversible, then an undo command could handle it. This would still require re-coding the app so that every action went through a capture step. *ALL* actions would set a property that recorded
        • a human-readable description of the action (to display on the undo menu offering),
        • The "easy undo" command if any. A lack of command would indicate that undo cannot be offered.
      • An issue is what if the user made some change outside the current app that would prevent the easy undo action from working as intended, such as a table object change. Then, before an undo was offered on the UI, the app would have to ensure that the undo action would still work, and then once the undo was requested, it would need to be rechecked (in case the system got changed between the moment the undo was offered and the user chose the undo).?
  • Agree. I think a single action undo, such as adding or moving an anchor point, track, etc., would be very useful. But I also think that because of the complexity and interactions between the panel, tables, etc. that anything beyond that is going to become unworkable very quickly. In that case the easiest solution might be to basically replicate how it’s being done manually now: Save the panel in a Temp folder and if an ‘oopsie’ is performed bring back the saved panel. How much that’s going to affect the computers overhead to be constantly saving the panels and tables is going to depend on the panel size and the individuals computer. It would be nice to have but the I think number of issues it generates will be staggering. Maybe in Settings offer a Simple and Advanced Undo option, or something like that.
    • An alternative to the "temp" file approach is to use the existing process to create snapshots. ?Every time Store is invoked with the same file name, the previous file is moved to the backupPanels directory with the date and time added to the file name. ?When a layout editor panel is the active window, it takes 2-3 seconds to do the store process using 4 key strokes: ?cntl-s; enter; enter. ?(cmd-s for Mac).
    • With either intermediate store process, it is not possible to safely load a snapshot file in the same PanelPro session. ?A load without a restart would be merge with very unpredictable results.

?