The syntax of variable definition in the configuration file have the following structure:
keyword = value[, value[, ...]]The '[]' notation means an optional argument. The format parameter have a similar syntax than printf(). Possible variable are :
appli.font.name = "Helvetica Bold" appli.system.path = C:\APPLI\system\ appli.window.size = 400,300 appli.window.sizer = 'S' appli.parameters.save = TRUE appli.parameters.bubble = TRUEIn the application:
void InitAppl( void) { char FontName[33], path[128]; int width, height; char car; # define PARAM_SAVE 0x1 # define PARAM_BUBBLE 0x2 int param; if( ConfInquire( "appli.font.name", "%s", FontName) != 1) strcpy( FontName, "Times"); if( ConfInquire( "appli.system.path", "%s", path) != 1) strcpy( path, ""); if( ConfInquire( "appli.window.size", "%d,%d", &width, &height) != 2) width = height = 200; if( ConfInquire( "appli.window.sizer", "%s", &car) != 1) car = 'S'; ConfInquire( "appli.parameters.save", "%B", ¶m, PARAM_SAVE); ConfInquire( "appli.parameters.bubble", "%B", ¶m, PARAM_BUBBLE); }