User Tools

Site Tools


Crossfire Client configuration file defaults

The defaults file is usually located inside the .crossfire directory.
This file applies to the very old X11 client for crossfire,
The newer gtk clients are using the gdefaults file as configuration file.

At the top of the file one reads :

# This file is generated automatically by cfclient.
# Manually editing is allowed, however cfclient may be a bit finicky about
# some of the matching it does.  all comparissons are case sensitive.
# 'True' and 'False' are the proper cases for those two values

The code in function load_defaults() in file client/x11/x11.c parses as follows :

        if (inbuf[0]=='#') continue;
	/* IF no colon, then we certainly don't have a real value, so just skip */
	if (!(cp=strchr(inbuf,':'))) continue;
	cp+=2;	    /* colon, space, then value */

Meaning, that lines starting with # are ignored,
lines need to contain a colon : or are ignored,
and may have any content.
The code then uses strcmp for the keyword and True and False , which is case sensitive; as in

            if (!strcmp(inbuf,"cacheimages")) {
	    if (!strcmp(cp,"True")) want_config[CONFIG_CACHE]=TRUE;
	    else want_config[CONFIG_CACHE]=FALSE;


  • cacheimages: False
  • command_window: 10
  • font: -misc-fixed-bold-*-normal-*-18-120-100-100-c-90-iso8859-1
  • foodbeep: False
  • noautorepeat: False
  • port: 13327
  • scrollinfo: True
  • scrolllines: 36
  • server: localhost
  • showicon: False
  • sound: True
  • split: False
client/defaults.txt · Last modified: 2018/04/15 14:36 by karl