Support Apnea Board & OSCAR  

Difference between revisions of "LoudSnorer:Sandbox"

From Apnea Board Wiki
Jump to: navigation, search

Line 5: Line 5:
 
     <p style=\"color:black;\">  
 
     <p style=\"color:black;\">  
 
       <table >
 
       <table >
         <tr><td>Add<br><br>    </td><td> Creates a new saved Setting item. The default description is the current date. The description may be changed by the User. The Add button will be greyed out when maximum number of saved layouts is reached.</td></tr>
+
         <tr><td>Add<br><br><br><br>    </td><td> Creates a new saved Setting item. <br>The default description is the current date. <br>The description may be changed by the User. <br>The Add button will be greyed out when maximum number of saved layouts is reached.</td></tr>
 
         <tr><td><i><u>Other Buttons</u> </i></td>  
 
         <tr><td><i><u>Other Buttons</u> </i></td>  
 
                                     <td> These buttons will be greyed out when no items are selected</td></tr>
 
                                     <td> These buttons will be greyed out when no items are selected</td></tr>
Line 11: Line 11:
 
         <tr><td>Rename </td>        <td> Allows the user to modify the description of the selected saved session.
 
         <tr><td>Rename </td>        <td> Allows the user to modify the description of the selected saved session.
 
                                         Same as a double click on the item.</td></tr>
 
                                         Same as a double click on the item.</td></tr>
         <tr><td>Update </td>       <td> Saves the current graph layout setting to the selected saved settings.<br>Prompts for confirmation.</td></tr>
+
         <tr><td>Update <br><br></td><td> Saves the current graph layout setting to the selected saved settings.<br>Prompts for confirmation.</td></tr>
         <tr><td>Delete </td>       <td> Deletes  the selected graph layout setting. <br>Prompts for confirmation.</td></tr>
+
         <tr><td>Delete <br><br></td><td> Deletes  the selected graph layout setting. <br>Prompts for confirmation.</td></tr>
 
         <tr><td>Exit </td>          <td> (Red circle with a white \"X.\") Returns to OSCAR menu.</td></tr>
 
         <tr><td>Exit </td>          <td> (Red circle with a white \"X.\") Returns to OSCAR menu.</td></tr>
 
     </table>  
 
     </table>  

Revision as of 21:40, 10 January 2023

Cleanup.png


Button Description

Add



Creates a new saved Setting item.
The default description is the current date.
The description may be changed by the User.
The Add button will be greyed out when maximum number of saved layouts is reached.
Other Buttons These buttons will be greyed out when no items are selected
Restore Loads the current graph layout setting with the swlected saved settings then returns.
Rename Allows the user to modify the description of the selected saved session. Same as a double click on the item.
Update

Saves the current graph layout setting to the selected saved settings.
Prompts for confirmation.
Delete

Deletes the selected graph layout setting.
Prompts for confirmation.
Exit (Red circle with a white \"X.\") Returns to OSCAR menu.
Graph Layout Settings
* Name * Order * Pinning * Height
* Height Options * Event Flags * Plots Enabled * Dotted Lines
General Information
* Maximum description size = 80 characters.
* Maximum Saved Graph Layout Settings = 30
* Saved Graprhg Layout Setting are available for all user profiles
* Graph Layout Settings only impact how graphs are displayed.
They do not contains any other data.
* The Escape key \"esc\" will always exit a dialog menu - like this help or the layout menu
 </p>




User Backups for Overview and Daily settings.

The overview and daily tabs each have one session backup file for graph settings. When OSCAR starts the session backup file is read. and when OSCAR exits the current settings are saved to the session backup file.

Users can also save graph settings as a user backup file. Each tab (Daily and Overview) supports 10 user defined setting backups. Each backup supports a user defined description in any language.

Triggering

File:TriggerBackupFileManagement.jpg


The following picture illustrates a restore operation is almost executed. Notice:

  • The default description is the current time and date in the local format.
  • Support for multiple languages
  • Add button is greyed because the maximum backups have been reached.
File:BackupRestore.jpg
Backup File Management

The user can
1. Create Backup with current settings and user's description
2. Restore current graph settings from a Backup
3. Rename a Backup description
4. Update an existing Backup with current settings
5. Delete a Backup









This feature is called Backup File Management.


setting that is saved when OSCAR exits and is restored when OSCAR

starts.

The Backup File Management feature allows for multiple backups files. Each backup will have a user defined description.

User Requirements

1. Create Backup file with current settings and user's description 2. Restore current settings from Backup file 3. Rename Backup file description 4. Update an existing Backup file with current settings 5. Delete Backup file

User Interface

Trigger Backup File Management

There will be a new push Button at the bottom of the daily and overview

windows in the lower right hand corner - to the left of the graph combo

box.

Pressing the Backup push button will trigger all Backup File Management functionality.

Backup File Management

The Backup File Management remains uninitialized until triggered by Backup push Button.

When activate a dialog box will be displayed.

There are 5 push Buttons - add, restore, rename, update, and delete, each with its own icons and tool-tips.

When a new backup is added, it will be given a default description using the current date-time. The description will be put in an edit mode so that the user can rename the description. The description must be a single line in any language.

The UI can display up to 10 backups.

Pictures

The Backup File Management UI with no backups and a tooltip for the Add button.

Selecting a backup to be restored. Displays Unicode backup names.

Selecting a backup to be deleted. Notice the confirmation message box.

Detailed view of Icons created.

Button Actions

Add

The Add button saves the current graph settings into a new backup file. The file's description is also saved. The description field is highlighted. The user can then change the description.

When the backup file limit is reached, the the tooltip will be changed and the button will be greyed out. If the user presses the add button when full then an error message box will be displayed. The delete button frees up space so that new backup can be made.

Restore

The Restore button loads the saved graphs settings and then exits.

Update

The Update button save the current graph settings in the selected backup file.

The user is prompted to cancel or continue the update operation.

Rename

The Rename button puts the selected backup into the edit mode so that the description can be changed. This is the same as a double click on backup file.

Delete

The Delete button deletes the selected backup.

The user is prompted to cancel or continue the delete operation.

Details

All the code for the Backup File Management is contained in a new class BackupFiles.

The daily and overview menus are responsible for creating an instance of BackupFiles and calling a method when the Backup button is activated.

The backup files are created/read using loadSettings and saveSettings methods in gGraphView. The settings filename name is the only parameter. There are no changes made to gGraphView.

User Descriptions

The user description is a set of characters up to a maximum length of 60 characters.

It must be a single line.

White white space is trimmed from string.

Cut and paste work with QT so multi-line strings can be added. The first line of the multi-line string is used.

Empty descriptions (all white space) will not change the previous description.

Backup Files

The file name used is GraphTitle.backupNNN.

where GraphTitle is either "daily" or "overview"

and NNN is a 3 digit decimal integer - ( 0 <= NNN < limit ).

This description is NOT a part the real file name but is stored as name value pair (filename : description). This allows for the description independent from the file name.

Backup descriptions are saved in an descriptions.txt file where the backup file name is associated with the user description.

Each backup has a single line entry in the form

backupNNN:<Description>. The Description can use unicode characters.

backup name examples:

- backup001:My Primary layout - backup002:已成功删除 عذرا ، لا يمكن تحديد موقع ملف. 删除 - backup004:/ ? ~ : any character

Currently, the same description can be used for multiple backups.

If the description file is corrupted then the backup file name will be used.

"eg. backup002"

file name examples

- overview.backup008.shg file name used for 1st backup file - overview.descriptions.txt file name used descriptions.

Translations

Translations are required for button labels, tooltip, and message Boxes.

icons are used on pushButtons.

PushButton Labels

- Add - Restore - Rename - Update - Delete - Cancel - Yes

Tooltips

- Add has been inhibited. The maximum number of backups have been exceeded. - Adds new Backup with current settings. - Restores settings from the selected Backup. - Rename the selected Backup. Must edit existing name then press enter. - Update the selected Backup with current settings. - Delete the selected Backup. - Closes the dialog menu. Returns to previous menu.

Message Box

- Ok to Update? - Ok To Delete? - Maximum number of Backups exceeded.




Donate to Apnea Board