GeoGen Development snapshot a3
Functions

ggen_progress.h File Reference

Go to the source code of this file.

Functions

void GGen_IncreaseProgress ()
void GGen_InitProgress (uint32 max_progress)
void GGen_SetProgress (uint32 current_progress)

Detailed Description

Scripts might sometimes take a lot of time to process. Showing some sort of progress to the user may help to mitigate the "what is happening in the magic box?" effect. Progress in GeoGen is defined by two integers: the max_progress and the current_progress. The max_progress represents the total length of the "progress bar" while the current_progress represents its finished portion.


Function Documentation

void GGen_IncreaseProgress ( )

Increases the current progress value by 1.

Note:
The GGen_InitProgress function must be called before calling GGen_IncreaseProgress.
void GGen_InitProgress ( uint32  max_progress)

Sets the maximum progress value.

Parameters:
max_progressNew maximum progress value.
void GGen_SetProgress ( uint32  current_progress)

Sets the current progress value.

Parameters:
current_progressNew current progress value.
Note:
The GGen_InitProgress function must be called before calling GGen_SetProgress.