Unexpected request to save data on close after saving as default

If you have specific questions or problems with any of my Freeware applications, post them here.
Post Reply
zapta
Posts: 12
Joined: Tue Nov 07, 2023 9:19 am

Unexpected request to save data on close after saving as default

Post by zapta »

To replicate

1. Double click on the CoolTerm icon on the Windows desktop (to open it).
2. Select a different port than the default.
3. Perform a 'save as default'.
4. Close the Cool Term windows.

Actual:
Getting this request to save
Image

Expected:
Since the data was just saved, the need to save is counter intuitive.
User avatar
roger
Site Admin
Posts: 434
Joined: Fri Apr 24, 2009 12:41 am
Contact:

Re: Unexpected request to save data on close after saving as default

Post by roger »

Hi,

this functionality is used for custom settings. If all you ever use are the defaults, then you can disable this:
Go to Preferences-> Conn. Options and enable the "Skip save prompt for unsaved settings" check box.

Roger
zapta
Posts: 12
Joined: Tue Nov 07, 2023 9:19 am

Re: Unexpected request to save data on close after saving as default

Post by zapta »

The reminder to save it useful. What I meant was that once I save the current settings as defaults, there are no unsaved settings.
User avatar
roger
Site Admin
Posts: 434
Joined: Fri Apr 24, 2009 12:41 am
Contact:

Re: Unexpected request to save data on close after saving as default

Post by roger »

Ah, I see what you mean. This is actually intended behavior. Let me elaborate:
  • When you save the current settings as default, then you're actually saving a snapshot of the current settings rather than the settings themselves.
  • "unsaved settings" relates to the settings with the the name that is displayed in the title bar of the current window. In your case, these settings were probably called "Untitled_0" since that is the name CoolTerm chooses for the first terminal that opens when CoolTerm first starts. When saving as default, a new settings file called "default.stc" is created in the users "Application Data" location (this is the configuration CoolTerm applies to each new terminal window) rather than "Untitled_0" being saved anywhere.
  • Another scenario might be that a user opens a settings file (e.g. a file called "MySettings.stc") and makes a few changes. "MySettings.stc" now has unsaved changes. If the user now decides to save these changed settings as default, a new "default.stc" settings file is created, but the "MySettings.stc" file is not saved. This is intended as the changes should not be written to "MySettings.stc" simply by saving the current settings as default.
I hope this makes sense.

Roger
zapta
Posts: 12
Joined: Tue Nov 07, 2023 9:19 am

Re: Unexpected request to save data on close after saving as default

Post by zapta »

Thanks Roger, I think I understand now how it works internally. Below is a long suggestion for behavior, but please feel free to ignore Since CoolTerm is already a great tool as is.

Also, shouldn't 'unchanged' in the link below be 'changed' ? I may be missing something.

https://i.imgur.com/LPuEiKB.png

-----

I think that the use of CoolTerm fall into two modes, 'document centric' and 'independent'. In the document centric mode the user is aware and uses of the named .stc documents, e.g. by opening/saving/managing them. In the 'indepedent' mode the user just launch CoolTerm and uses and save the defaults without explicitly using named .stc documents.

The current behavior is intuitive for the 'document centric' mode and less for the independent mode. I would suggest not to introduce the document name (e.g. untitled_0) until the user opened a document or saved a document. Something along these lines

1. User open CoolTerm. Default are loaded and document name is not displayed.
2. User modifies parameters. Document name is still not displayed.
3. One of these happens:
A. If user try to close, the warning pops ups, and if the user saves the options as to a named file name that name is displayed at the top.
B. User saves the the defaults. File name is still not shown and all changes are considered saved.
C. User tries to exit and get the unsaved changes warning.

I think the change here is that CoolTerm has the notion (and name) of a file, only when the user performed a file operation (open, save, save_as).
User avatar
roger
Site Admin
Posts: 434
Joined: Fri Apr 24, 2009 12:41 am
Contact:

Re: Unexpected request to save data on close after saving as default

Post by roger »

zapta wrote: Thu Nov 16, 2023 12:20 pm Also, shouldn't 'unchanged' in the link below be 'changed' ? I may be missing something.
Actually, it should be "unsaved" instead of "unchanged". :D But thanks for bringing this to my attention. It will be fixed in the next release.

Roger
zapta
Posts: 12
Joined: Tue Nov 07, 2023 9:19 am

Re: Unexpected request to save data on close after saving as default

Post by zapta »

Thanks Roger.
Post Reply