> <\body> Preferences are used to store any information you need to keep across different runs of , like window position and size, active menu bars, etc. Internally they are stored in the users home directory as a list of items like which therefore has in principle no structure. However, a good practice to avoid conflicts is to prefix your options by the name of the plugin or module you are creating, like in . The first step in defining a new preference is adding it with and assigning a call-back function to handle changes in the preference. This is important for instance in menus, where a click on an item simply sets some preference to some value and it's up to the call-back to actually take the necessary actions. <\warning*> One may not store the boolean values , directly into preferences. Instead one should use the strings and . This is due to the internal storage of default values for preferences using . <\explain> )> <|explain> Each element of is of the form where is a procedure taking two arguments like this: Remember to use the strings and instead of booleans , . <\unfolded-documentation> Example <|unfolded-documentation> <\session|scheme|default> <\input|Scheme] > (define (notify-test pref value) \ \ (display* "Hey! " pref " changed to " value) (newline)) <\input|Scheme] > (define-preferences ("test:pref" "off" notify-test)) <\unfolded-io|Scheme] > (get-preference "test:pref") <|unfolded-io> "off" <\input|Scheme] > (set-preference "test:pref" "on") <\unfolded-io|Scheme] > (preference-on? "test:pref") <|unfolded-io> #t <\input|Scheme] > \; <\explain> )> <|explain> Save preference with value . Then call the call-back associated to this preference, as defined in . Remember to use the strings and instead of booleans , . <\explain> )> <|explain> This convenience function appends to the list of values of preference , or creates a list with one element in case the preference didn't exist. The call-back associated to this preference, as defined in is called once the modification is done. <\explain> )> <|explain> Deletes preference from the user preferences. <\explain> )> <|explain> Returns the value of preference . If the preference is not defined the string is returned. <\explain> )> <|explain> Returns if the value of preference is . <\explain> )> <|explain> Toggles the value of preference between and . >