The dup() method does a deep copy of the config config.
gnomeprint.Config.get
def get(key)
key :
string containing the path of key whose value is to be obtained.
Returns :
the value of the key, None indicates failure.
The get() method
gnomeprint.Config.set
def set(key, value)
key :
string containing the path of key whose value is to be set.
value :
string containing the value to set.
Returns :
TRUE on success, FALSE on failure.
The set() method sets the value of string key in the GnomePrintConfig object to value value
gnomeprint.Config.get_boolean
def get_boolean(key, val)
key :
string containing the path of key whose value is to be obtained.
val :
a boolean variable to store the value in. Should initially be None.
Returns :
TRUE if a value was retrieved, FALSE on failure.
The get_boolean() method gets the value of key key from the
gnomeprint.Config object. Converts values such as "true", "y", "yes", and their
opposites, to their boolean equivalent. The boolean value will be stored in the variable val.
gnomeprint.Config.get_int
def get_int(key, val)
key :
string containing the path of key whose value is to be obtained.
val :
an integer variable to store the value in. Should initially be None.
Returns :
TRUE if a value was retrieved, FALSE on failure.
The get_int() method gets the value of key key from the
gnomeprint.Config object. Converts values to their integer equivalent. The integer
value will be stored in the variable val.
gnomeprint.Config.get_double
def get_double(key, val)
key :
string containing the path of key whose value is to be obtained.
val :
a double variable to store the value in. Should initially be None.
Returns :
TRUE if a value was retrieved, FALSE on failure.
The get_double() method gets the value of key key from the
gnomeprint.Config object. Converts values to their double equivalent. The double
value will be stored in the variable val.
gnomeprint.Config.get_length
def get_length(key, val, unit)
key :
string containing the path of key whose value is to be obtained.
val :
a double variable to store the value in. Should initially be None.
unit :
pointer to an already allocated GnomePrintUnit struct.None.
Returns :
TRUE if a value was retrieved, FALSE on failure.
The get_length() method gets the value of key key from the
gnomeprint.Config object. Converts values to their double equivalent. The double
value will be stored in the variable val and the units will be stored in unit.
gnomeprint.Config.set_boolean
def set_boolean(key, val)
key :
string containing the path of key whose value is to be obtained.
val :
boolean containing the value to set.
Returns :
TRUE if a value was retrieved, FALSE on failure.
The set_boolean() method set a boolean value in the
gnomeprint.Config object.
gnomeprint.Config.set_int
def set_int(key, val)
key :
string containing the path of key whose value is to be set.
val :
integer containing the value to set.
Returns :
TRUE if a value was retrieved, FALSE on failure.
The set_int() method set an integer value in the
gnomeprint.Config object.
gnomeprint.Config.set_double
def set_double(key, val)
key :
string containing the path of key whose value is to be set.
val :
integer containing the value to set.
Returns :
TRUE on success, FALSE on failure.
The set_double() method set an integer value in the
gnomeprint.Config object.
gnomeprint.Config.set_length
def set_length(key, val, unit)
key :
string containing the path of key whose value is to be set.
val :
double containing the value to set.
unit :
units to use when setting value.
Returns :
TRUE on success, FALSE on failure.
The set_length() method sets a double value and the units it is using. This should be used in conjunction with
get_lenght
gnomeprint.Config.dump
def dump()
The dump() method print out the tree structure representing the
gnomeprint.Config. Output is to STDOUT and is limited to a depth of 20.