« Modified data » : différence entre les versions

De GENIUS
Aller à la navigation Aller à la recherche
(Page créée avec « TBW ... Return to the introduction ↑ Go to the next page → »)
 
Aucun résumé des modifications
Ligne 1 : Ligne 1 :
TBW ...
Sometimes, a " <font color=#FF0000>*</font> " character appears just after a label of an entry data widget. In fact, it occurs when the data has been modified by user by comparison to a “saved” value. More precisely, this “saved” value corresponds:
* either to the default value at the first display (the one used at the instantiation),
* or to the data loaded (resp. saved) when reading (resp. writing) a file => after reading (resp. writing) a file, the " <font color=#FF0000>*</font> " character disappears
 
When a unit is changed, as the data is not actually changed because the value stored in memory is <u>not changed</u> and no " <font color=#FF0000>*</font> " character appears.
 
Idem, if the user enter a “new” value which, in fact, corresponds to the "saved" value, the " <font color=#FF0000>*</font> " character will disappear :
 
For example, imagine that the initial value of an integer is 0.
 
[[File:ModifiedData1.jpg]]
 
Then, if the user will enter "1" as a new value => " <font color=#FF0000>*</font> " character appears
 
[[File:ModifiedData2.jpg]]
 
At last, if the same user will reenter "0", the " <font color=#FF0000>*</font> "character will disappear
 
[[File:ModifiedData1.jpg]]
 
It is possible to manage locally this mechanism using the following methods:
 
* <font color=#4169E1>setDisplayIsModifiedIndicator(DisplayIndicatorStatus)</font>, the status being « Automatic », « Always » or « Never »
* <font color=#4169E1>setSavedValue()</font> to change manually the saved value => if the saved value is the same as the current displayed one, the "*" character will disappear
 
=== Management with read/write and copy/paste functions ===
 
The "*" character could also appeared (or not) after reading or writing a configuration file (see [[.:greadwrite|GReadWrite interface and data files management]] topic). It is managed by using a flag set to true or false :
 
* when calling <font color=#4169E1>GFileManipulation.readConfig()</font> method, if the flag is set to false, an "*" will appear (of course, if the read value is different of the previous one)
* on the contrary, by using the <font color=#4169E1>GFileManipulation.writeConfig()</font> method, if the flag is set to true, the "*" will disappear after writing the configuration file (considering the reference configuration is then the one described in the file).
But of course, you may decide another way to run ...
 


[[WELCOME_TO_THE_GENIUS_WIKI|Return to the introduction ↑]]  
[[WELCOME_TO_THE_GENIUS_WIKI|Return to the introduction ↑]]  
[[Process_management|Go to the next page →]]
[[Process_management|Go to the next page →]]

Version du 5 mai 2017 à 09:28

Sometimes, a " * " character appears just after a label of an entry data widget. In fact, it occurs when the data has been modified by user by comparison to a “saved” value. More precisely, this “saved” value corresponds:

  • either to the default value at the first display (the one used at the instantiation),
  • or to the data loaded (resp. saved) when reading (resp. writing) a file => after reading (resp. writing) a file, the " * " character disappears

When a unit is changed, as the data is not actually changed because the value stored in memory is not changed and no " * " character appears.

Idem, if the user enter a “new” value which, in fact, corresponds to the "saved" value, the " * " character will disappear :

For example, imagine that the initial value of an integer is 0.

ModifiedData1.jpg

Then, if the user will enter "1" as a new value => " * " character appears

ModifiedData2.jpg

At last, if the same user will reenter "0", the " * "character will disappear

ModifiedData1.jpg

It is possible to manage locally this mechanism using the following methods:

  • setDisplayIsModifiedIndicator(DisplayIndicatorStatus), the status being « Automatic », « Always » or « Never »
  • setSavedValue() to change manually the saved value => if the saved value is the same as the current displayed one, the "*" character will disappear

Management with read/write and copy/paste functions

The "*" character could also appeared (or not) after reading or writing a configuration file (see GReadWrite interface and data files management topic). It is managed by using a flag set to true or false :

  • when calling GFileManipulation.readConfig() method, if the flag is set to false, an "*" will appear (of course, if the read value is different of the previous one)
  • on the contrary, by using the GFileManipulation.writeConfig() method, if the flag is set to true, the "*" will disappear after writing the configuration file (considering the reference configuration is then the one described in the file).

But of course, you may decide another way to run ...


Return to the introduction ↑ Go to the next page →