XrmPutLineResource() XrmPutLineResource()
Name
XrmPutLineResource - add a resource specification to a resource database.
Synopsis
void XrmPutLineResource(database, line)
XrmDatabase *database;
char *line;
Arguments
database Specifies a pointer to the resource database. If database contains NULL, a new resource database is created and a pointer to it
is returned in database. If a database is created, it is created in the current locale.
line Specifies the resource name (possibly with multiple components) and value pair as a single string, in the format resource:value.
Description
XrmPutLineResource() adds a single resource entry to the specified database. The line string is parsed in the locale of the database. If
the resource name is not in the Host Portable Character Encoding the result is implementation-dependent. Note that comment lines are not
stored.
XrmPutLineResource() is similar to XrmPutStringResource(), except that instead of having separate string arguments for the resource and its
value, XrmPutLineResource() takes a single string argument (line) which consists of the resource name, a colon, then the value. Since the
value is a string, it is stored into the database with representation type String.
Any whitespace before or after the name or colon in the line argument is ignored. The value is terminated by a new-line or a NULL charac-
ter. The value may contain embedded new-line characters represented by the "" and "n" two-character pair (not the single "
" character),
which are converted into a single linefeed character. In addition, the value may run over onto the next line; this is indicated by a ""
character at the end of each line to be continued.
Null-terminated strings without a new line are also permitted. XrmPutResource(), XrmQPutResource(), XrmPutStringResource(), XrmQPut-
StringResource() and XrmPutLineResource() all store data into a database. See XrmQPutResource() for the most complete description of this
process.
For more information, see Volume One, Chapter 13, Managing User Preferences.
Structures
XrmDatabase is a pointer to an opaque data type.
See Also
XrmDestroyDatabase(), XrmGetFileDatabase(), XrmGetResource(), XrmGetStringDatabase(), XrmInitialize(), XrmMergeDatabases(), XrmParseCom-
mand(), XrmPutFileDatabase(), XrmPutResource(), XrmPutStringResource(), XrmQGetResource(), XrmQGetSearchList(), XrmQGetSearchResource(),
XrmQPutResource(), XrmQPutStringResource(), XrmQuarkToString(), XrmStringToBindingQuarkList(), XrmStringToQuarkList(), XrmStringToQuark(),
XrmUniqueQuark().
Xlib - Resource Manager XrmPutLineResource()