SilverScreen Solid Modeler

print_load_settings

print_load_settings

Previous topic Next topic  

print_load_settings

Previous topic Next topic JavaScript is required for the print function  

 

SilverScreenAPI

 

int print_load_settings(const char *filepath);

 

const char *filepath;   // Pointer to a null-terminated character string

 

 

 




Synopsis

#include "silver.h"

 

The print_load_settings function makes the current printer and page setup options conform with the  settings in a printer settings file.

 

 

Parameters

filepath is a path to a printer settings file created with print_save_settings.

 

 

Return Value

print_load_settings returns TRUE if the settings are successfully saved to the file and FALSE otherwise.

 

 

Remarks

The default file extension for a printer settings file is .pts. The default location for a printer settings file is the home directory. If there is an error loading the settings file the original settings will be maintained.

 

To restore the default system printer at any time, issue the following SilverScreen API command via ss_command:

C / C++ Code

 

 ss_command("print reset");

 

 

 

See Also

print_save_settings, printer_set_name, path_home, ss_command

 

 

Example

The following code will load the printer settings contained in default.pts from the home directory:

C / C++ Code

 

 #include "silver.h

 

 . . .

 

 if ( ! print_load_settings("default") )

    error_message("Printer settings could not be restored");