REF XUserPreferences A. Schoter, August 1991 COPYRIGHT University of Sussex 1991. All Rights Reserved. >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<< >>>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<< X USER PREFERENCES >>>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<< >>>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< The data structures and procedure described in this REF file implement the equivalent C structures and functions for manipulating user preferences. --------------------- 1 List of procedures --------------------- The procedures below are made available by doing: uses xlib, XUserPreferences; For details see: Xlib - C Language X Interface, MIT X Consortium Standard, X Version 11, Release 4 Copyright (C) 1985, 1986, 1987, 1988, 1989 Massachusetts Institute of Technology, Cambridge, Massachusetts, and Digital Equipment Corporation, Maynard, Massachusetts. XKeyboardControl [typedef] This data structure is used by the XChangeKeyboardControl procedure. typedef struct { int key_click_percent; int bell_percent; int bell_pitch; int bell_duration; int led; int led_mode; int key; int auto_repeat_mode; } XKeyboardControl; auto_repeat_mode is one of On, Off or Default. XKeyboardState [typedef] This data structure is used by the XGetKeyboardControl procedure. typedef struct { int key_click_percent; int bell_percent; unsigned int bell_pitch, bell_duration; unsigned long led_mask; int global_auto_repeat; char auto_repeats[32]; } XKeyboardState; XAutoRepeatOff(DspPtr) [procedure] XAutoRepeatOn(DspPtr) [procedure] XAutoRepeatOff turns the keyboard's auto-repeat off. XAutoRepeatOn turns the keyboard's auto-repeat on. XGetDefault(DspPtr,string1,string2) -> CharPtr [procedure] The number of options that a program may need can be very large in the X environment. (Fonts of various sorts, colors of characters, mouse, background, text, cursor, etc.) If only command line options could be used to specify each of these, things quickly become unmanageable as your tastes in windows will often be drastically different from someone else's. XGetDefault makes it easy to find out what the user wants for his favorite font, colors, etc. Its use is highly encouraged. Defaults are read out of a file called "~/.Xdefaults" in the user's home directory. See the X manual page for details of its format. Typically, an entry in .Xdefaults will be of the form: program_name.variable: setting XGetDefault returns CharPtr, a pointer to a copy of the `setting' for program_name string1 and variable named string2. XBell(DspPtr,int) [procedure] XGetKeyboardControl(DspPtr,XKeybStatePtr) [procedure] XChangeKeyboardControl(DspPtr,ulong,XKeybControlPtr) [procedure] These procedure implement the equivalent C functions. --- C.x/x/pop/ref/XUserPreferences --- Copyright University of Sussex 1991. All rights reserved.