1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2002 Gilles Roux
12 * 2010 Yoshihisa Uchida
14 * This program is free software; you can redistribute it and/or
15 * modify it under the terms of the GNU General Public License
16 * as published by the Free Software Foundation; either version 2
17 * of the License, or (at your option) any later version.
19 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
20 * KIND, either express or implied.
22 ****************************************************************************/
23 #ifndef PLUGIN_TEXT_VIEWER_PREFERENCES_H
24 #define PLUGIN_TEXT_VIEWER_PREFERENCES_H
71 /* horizontal_scroll_mode */
77 /* vertical_scroll_mode */
89 struct tv_preferences
{
96 unsigned horizontal_scrollbar
;
97 unsigned vertical_scrollbar
;
100 unsigned header_mode
;
101 unsigned footer_mode
;
102 unsigned horizontal_scroll_mode
;
103 unsigned vertical_scroll_mode
;
105 int autoscroll_speed
;
109 unsigned narrow_mode
;
111 unsigned indent_spaces
;
115 #ifdef HAVE_LCD_BITMAP
116 unsigned char font_name
[MAX_PATH
];
119 unsigned char file_name
[MAX_PATH
];
123 * global pointer to the preferences (read-only)
125 extern const struct tv_preferences
* const preferences
;
128 * change the preferences
133 void tv_set_preferences(const struct tv_preferences
*new_prefs
);
136 * copy the preferences
139 * the preferences in copy destination
141 void tv_copy_preferences(struct tv_preferences
*copy_prefs
);
144 * set the default settings
147 * the preferences which store the default settings
149 void tv_set_default_preferences(struct tv_preferences
*p
);
152 * register the function to be executed when the current preferences is changed
155 * the function to be executed when the current preferences is changed
157 void tv_add_preferences_change_listner(void (*listner
)(const struct tv_preferences
*oldp
));