<?php
// $Horde: imp/config/prefs.php.dist,v 1.49.2.22 2002/10/29 21:04:33 chuck Exp $

// Make sure that constants are defined.
require_once dirname(__FILE__) . '/../lib/constants.php';

// Changes you make to this file will not be reflected until the user
// logs out and logs in again.
//
// $prefGroups are for display purposes when you press the options button.
// The options choice will appear when you set your preferences driver
// in the horde/config/horde.php file.
// $prefGroups array definition:
//   column: What column head this group will go under
//    label: Label for the group of settings
//     desc: Description that will show under label
//  members: list of preferences supported by this group
//
// The $_prefs array's are listed in the same order as listed in the
// members element of $prefGroups

$prefGroups['personal'] = array(
    'column' => _("Your Information"),
    'label' => _("Personal Information"),
    'desc' => _("Change the name, address, and signature that people see when they read and reply to your email."),
    'members' => array('identityselect', 'default_identity', 'identity')
);

$prefGroups['server'] = array(
    'column' => _("Your Information"),
    'label' => _("Server Information"),
    'desc' => _("Change mail server settings."),
    'members' => array('subscribe')
);

$prefGroups['language'] = array(
    'column' => _("Your Information"),
    'label' => _("Language"),
    'desc' => _("Set the language that menu items, explanations, and help are in."),
    'members' => array('language')
);

$prefGroups['timezone'] = array(
    'column' => _("Your Information"),
    'label' => _("Time Zone"),
    'desc' => _("Set the current time zone."),
    'members' => array('timezone')
);

$prefGroups['filters'] = array(
    'column' => _("Mail Management"),
    'label' => _("Filters"),
    'desc' => _("Create filtering rules to organize your incoming mail, sort it into folders, and delete spam."),
    'members' => array('filters_link', 'filter_on_login', 'filter_on_refresh',
                       'show_filter_msg')
);

$prefGroups['viewing'] = array(
    'column' => _("Mail Management"),
    'label' => _("Message Viewing"),
    'desc' => _("Set preferences for filtering messages for unwanted content."),
    'members' => array('filtering')
);

$prefGroups['delmove'] = array(
    'column' => _("Mail Management"),
    'label' => _("Deleting and Moving Messages"),
    'desc' => _("Set preferences for what happens when you move and delete messages."),
    'members' => array('mailbox_return', 'use_trash', 'trashselect')
);

$prefGroups['monthlytasks'] = array(
    'column' => _("Mail Management"),
    'label' => _("Maintenance Operations"),
    'desc' => sprintf(_("Customize maintenance operations run upon login to %s."),
                      $GLOBALS['registry']->getParam('name')),
    'members' => array('do_maintenance', 'rename_sentmail_monthly',
                       'delete_sentmail_monthly',
                       'delete_sentmail_monthly_keep', 'purge_trash',
                       'purge_trash_interval', 'purge_trash_keep')
);

$prefGroups['display'] = array(
    'column' => _("Other Options"),
    'label' => _("Display Options"),
    'desc' => _("Change display options such as how many messages you see on each page and how messages are sorted."),
    'members' => array('sortby', 'sortdir', 'max_msgs', 'num_words',
                       'nav_expanded', 'show_legend',
                       'highlight_text', 'dim_signature')
);

$prefGroups['compose'] = array(
    'column' => _("Other Options"),
    'label' => _("Message Composition"),
    'desc' => _("Customize how you send mail and where drafts are saved."),
    'members' => array('wrap_width', 'reply_quote', 'quote_prefix', 'compose_popup',
                       'compose_confirm', 'folderselect', 'close_draft')
);

$prefGroups['logintasks'] = array(
    'column' => _("Other Options"),
    'label' => _("Login Tasks"),
    'desc' => sprintf(_("Customize tasks to run upon logon to %s."), $GLOBALS['registry']->getParam('name')),
    'members' => array('show_last_login', 'initialpageselect')
);

$prefGroups['newmail'] = array(
    'column' => _("Other Options"),
    'label' => _("New Mail"),
    'desc' => _("Control when new mail will be checked for, and whether or not to notify you when it arrives."),
    'members' => array('refresh_time', 'nav_popup')
);

$prefGroups['addressbooks'] = array(
    'column' => _("Other Options"),
    'label' => _("Addressbooks"),
    'desc' => _("Select addressbook sources for adding and searching for addresses."),
    'members' => array('sourceselect')
);


// If you change these preferences in a production system, you will need
// to delete any horde_prefs in your preferences database
//
// Descpription of the $_prefs arrays:
// value:  This entry will either hold a number or a text value based on the
//         preference type:
//      implicit:  See Preference type
//          text:  Text value
//        number:  Number value
//      checkbox:  Value should be 0 for unchecked, 1 for checked
//        select:  Value associated with that selection list
//
// locked: Allow preference to be changed from UI
//          true:  Do not show this preference in the UI
//         false:  Show this preference in the UI and allow changing
//
// shared: Share with other horde apps
//          true:  Share this pref with other Horde apps
//         false:  Keep this pref local to IMP
//
//   type: Preference type
//       special:  Provides a UI widget
//        select:  Provides a selection list in the UI
//      checkbox:  Provides a checkbox
//      implicit:  Provides storage for 'special' types
//          enum:  Use static list of elements...similar to 'select'
//
//   enum: Static list of elements.
//


// Personal Information preferences

// default identity selection widget
$_prefs['identityselect'] = array('type' => 'special');

// default identity
// Set locked to true if you don't want the users to have multiple identities.
$_prefs['default_identity'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// link to the identities ui
$_prefs['identity'] = array(
    'type' => 'link',
    'url' => 'identities.php',
    'img' => 'personal.gif',
    'desc' => _("Edit your identities")
);

// identities array
// Don't change anything here.
$_prefs['identities'] = array(
    'value' => 'a:0:{}',
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// user signature
$_prefs['signature'] = array(
    'value' => '',
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// precede the signature with dashes ('-- ')?
$_prefs['sig_dashes'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// signature before replies and forwards?
$_prefs['sig_first'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// user full name for From: line
// see also $conf['hooks']['fullname'] in conf.php
$_prefs['fullname'] = array(
    'value' => '',
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// user preferred email address for From: line
// see also $conf['hooks']['from'] in conf.php
$_prefs['from_addr'] = array(
    'value' => '',
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// user preferred email address for Reply-To:, if different from From:
$_prefs['replyto_addr'] = array(
    'value' => '',
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// save a copy of sent messages?
// a value of 0 = no, 1 = yes
$_prefs['save_sent_mail'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// sent mail folder
$_prefs['sent_mail_folder'] = array(
    'value' => 'sent-mail',
// For Exchange server uncomment the line below and delete the line above
//    'value' => 'Sent Items',
    'locked' => false,
    'shared' => true,
    'type' => 'implicit'
);

// End Personal Information preferences


// Server Information preferences

// use IMAP subscribe?
// value of 0 = no, 1 = yes
$_prefs['subscribe'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Use IMAP folder subscriptions?")
);

// End Server Information preferences


// Language Functions

// user language
// valid values can be found in horde/config/lang.php

$_prefs['language'] = array(
    'value' => '',
    'locked' => false,
    'shared' => true,
    'type' => 'select',
    'desc' => _("Select your preferred language:")
);

// End Language Functions


// Time Zone Functions

// user time zone
// valid values can be found in horde/config/lang.php

$_prefs['timezone'] = array(
    'value' => '',
    'locked' => false,
    'shared' => true,
    'type' => 'select',
    'desc' => _("Your current time zone:")
);

// End Timezone Functions


// Filter preferences

// Change this if you want to customize how filters.php works.
$_prefs['filters_link'] = array(
    'type' => 'link',
    'url' => 'filters.php',
    'img' => 'filters.gif',
    'desc' => _("Edit your filter rules")
);

// run filters on login?
// a value of 0 = no, 1 = yes
$_prefs['filter_on_login'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Apply filter rules upon logging on?")
);

// run filters with mail refresh?
// a value of 0 = no, 1 = yes
$_prefs['filter_on_refresh'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Apply filter rules when mailbox is refreshed?")
);

// Show filter status messages?
// a value of 0 = no, 1 = yes
$_prefs['show_filter_msg'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Display message when filters have been applied?")
);

// mail filter rules options
$_prefs['filters'] = array(
    'value' => '',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// End Filter preferences


// Message Viewing preferences

// filter message content?
// a value of 0 = no, 1 = yes
$_prefs['filtering'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Filter message content for profanity?")
);

// End Message Viewing preferences


// Deleting and Moving Messages preferences

// should we return to the mailbox listing after deleting a message?
// a value of 0 = no, 1 = yes
$_prefs['mailbox_return'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Return to the mailbox listing after deleting, moving, or copying a message?")
);

// should we move messages to a trash folder instead of just marking
// them as deleted?
// a value of 0 = no, 1 = yes
$_prefs['use_trash'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("When deleting messages, move them to your Trash folder instead of marking them as deleted?")
);

// trash folder selection widget. includes some javascript, so it's
// specific to IMP.
$_prefs['trashselect'] = array('type' => 'special');

// trash folder
$_prefs['trash_folder'] = array(
// for Exchange, uncomment the entry below and remove the default value entry
//    'value' => 'Deleted Items',
    'value' => 'trash',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// hide deleted
// a value of 0 = no, 1 = yes
$_prefs['delhide'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// End Deleting and Moving Messages preferences


// Maintenance preferences

// To disable maintenance entirely, set 'value' = 0 and
// 'locked' = true for all of these. To just turn it off by default,
// set 'value' 0 for do_maintenance.

// perform maintenance operations?
$_prefs['do_maintenance'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Perform maintenance operations on login?")
);

// rename sent-mail folder every month?
$_prefs['rename_sentmail_monthly'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Rename sent-mail folder at beginning of month?")
);

// purge sent-mail folders every month?
$_prefs['delete_sentmail_monthly'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Delete old sent-mail folders at beginning of month?")
);

// how many old sent-mail folders to keep every month?
$_prefs['delete_sentmail_monthly_keep'] = array(
    'value' => 12,
    'locked' => false,
    'shared' => false,
    'type' => 'number',
    'desc' => _("Number of old sent-mail folders to keep if deleting monthly.")
);

// purge Trash folder?
$_prefs['purge_trash'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Purge old message in the Trash folder?")
);

// how often to purge the Trash folder?
// 'value': yearly = 1, monthly = 2, weekly = 3, daily = 4, every login = 5
$_prefs['purge_trash_interval'] = array(
    'value' => '2',
    'locked' => false,
    'shared' => false,
    'type' => 'select',
    'desc' => _("Purge Trash how often:")
);

// when purging Trash folder, purge messages older than how many days?
$_prefs['purge_trash_keep'] = array(
    'value' => 30,
    'locked' => false,
    'shared' => false,
    'type' => 'number',
    'desc' => _("Purge messages in Trash folder older than this amount of days.")
);

// last login time of user
$_prefs['last_login'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// End Maintenance preferences


// Display Options preferences

// user preferred sorting column
$_prefs['sortby'] = array(
    'value' => SORTARRIVAL,
    'locked' => false,
    'shared' => false,
    'type' => 'enum',
    'enum' => array(SORTARRIVAL => _("Arrival Time"),
                    SORTDATE => _("Message Date"),
                    SORTFROM => _("From Address"),
                    SORTSUBJECT => _("Subject Field"),
                    SORTSIZE => _("Message Size"),
                    SORTTHREAD => _("Thread View")),
    'desc' => _("Default sorting criteria:")
);

// user preferred sorting direction
$_prefs['sortdir'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'enum',
    'enum' => array(0 => _("Ascending"),
                    1 => _("Descending")),
    'desc' => _("Default sorting direction:")
);

// mailbox constraints
$_prefs['max_msgs'] = array(
    'value' => 20,
    'locked' => false,
    'shared' => false,
    'type' => 'number',
    'desc' => _("Messages per page in the mailbox view.")
);

// number of spelling corrections per screen
$_prefs['num_words'] = array(
    'value' => 3,
    'locked' => false,
    'shared' => false,
    'type' => 'number',
    'desc' => _("Spelling errors per screen when spell checking.")
);

// expand folder tree by default
$_prefs['nav_expanded'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'enum',
    'enum' => array(0 => _("No"),
                    1 => _("Yes"),
                    2 => _("Remember the last view")),
    'desc' => _("Expand the entire folder tree by default in the folders view?")
);

// list of folders to expand by default
$_prefs['expanded_folders'] = array(
    'value' => 'a:0:{}',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// list of folders to poll for new mail
$_prefs['nav_poll'] = array(
    'value' => '',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// show mailbox legend?
// a value of 0 =no, 1 = yes
$_prefs['show_legend'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Show legend in the mailbox view?")
);

// should we try to mark different conversations with different colors?
$_prefs['highlight_text'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Mark different levels of quoting with different colors?")
);

// should we dim signatures?
$_prefs['dim_signature'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Dim signatures?")
);

// End Display Options preferences


// Message Composition preferences

// wrap text at this many characters
$_prefs['wrap_width'] = array(
    'value' => 80,
    'locked' => false,
    'shared' => false,
    'type' => 'number',
    'desc' => _("Wrap text at this many characters.")
);

// Should the original message be included?
$_prefs['reply_quote'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Include original message in a reply?")
);

// How should we prefix quoted lines in a reply?
$_prefs['quote_prefix'] = array(
    'value' => '> ',
    'locked' => false,
    'shared' => false,
    'type' => 'text',
    'desc' => _("How to prefix quoted lines in a reply:")
);

// compose in a separate window?
$_prefs['compose_popup'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Compose messages in a separate window?")
);

// confirm successful sending of messages?
$_prefs['compose_confirm'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Display confirmation after sending a message? (only when not using a pop-up compose window)")
);

// folder selection widget. includes some javascript, so it's specific
// to IMP.
$_prefs['folderselect'] = array('type' => 'special');

// drafts folder
$_prefs['drafts_folder'] = array(
    'value' => 'drafts',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// closing window after saving a draft?
$_prefs['close_draft'] = array(
    'value' => 1,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Should the compose window be closed after saving a draft?")
);

// End Message Composition preferences


// Login Tasks preferences

// show the last login time of user
// a value of 0 = no, 1 = yes
$_prefs['show_last_login'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Show last login time when logging in?")
);

// select widget for the initial_page preference
$_prefs['initialpageselect'] = array('type' => 'special');

// the page to display. Either a filename like 'folders.php'
// or a mailbox name.
$_prefs['initial_page'] = array(
    'value' => 'INBOX',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// user default mailbox
$_prefs['mailbox'] = array(
    'value' => 'INBOX',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// End Login Tasks preferences


// New Mail preferences

// time before reloading the navigator or mailbox page
$_prefs['refresh_time'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'enum',
    'enum' => array(0 => _("Never"),
                    30 => _("Every 30 seconds"),
                    60 => _("Every minute"),
                    300 => _("Every 5 minutes"),
                    900 => _("Every 15 minutes"),
                    1800 => _("Every half hour")),
    'desc' => _("Refresh Folder Views:")
);

// javascript popup if there's new mail?
$_prefs['nav_popup'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Display pop-up notification of new mail?")
);

// End New Mail preferences


// Addressbook preferences

// addressbook selection widget
$_prefs['sourceselect'] = array('type' => 'special');

// addressbook(s) to use when expanding addresses
// You can provide default values this way (note the \t and the double quotes):
// 'value' => "source_one\tsource_two"
// refer to turba/config/sources.php for possible source values
$_prefs['search_sources'] = array(
    'value' => 'localsql',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// field(s) to use when expanding addresses
// This depends on the search_sources preference if you want to provide default values:
// 'value' => "source_one\tfield_one\tfield_two\nsource_two\tfield_three"
// will search the fields 'field_one' and 'field_two' in source_one and
// 'field_three' in source_two.
// refer to turba/config/sources.php for possible source and field values
$_prefs['search_fields'] = array(
    'value' => '',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// addressbook to use for adding adresseses
// put $cfgSources array element name in the value field.
// Setting value to localsql would allow you to add contacts to MySQL database
// See turba/config/sources.php for more info
$_prefs['add_source'] = array(
    'value' => '',
// 'value' => 'localsql',
    'locked' => false,
    'shared' => false,
    'type' => 'implicit'
);

// End Addressbook preferences
