"Fossies" - the Fresh Open Source Software Archive

Member "feh-3.4.1/src/options.h" (29 May 2020, 5411 Bytes) of package /linux/privat/feh-3.4.1.tar.bz2:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "options.h" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 3.4_vs_3.4.1.

    1 /* options.h
    2 
    3 Copyright (C) 1999-2003 Tom Gilbert.
    4 Copyright (C) 2010-2020 Daniel Friesel.
    5 
    6 Permission is hereby granted, free of charge, to any person obtaining a copy
    7 of this software and associated documentation files (the "Software"), to
    8 deal in the Software without restriction, including without limitation the
    9 rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
   10 sell copies of the Software, and to permit persons to whom the Software is
   11 furnished to do so, subject to the following conditions:
   12 
   13 The above copyright notice and this permission notice shall be included in
   14 all copies of the Software and its documentation and acknowledgment shall be
   15 given in the documentation and software packages that this Software was
   16 used.
   17 
   18 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
   19 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
   20 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
   21 THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
   22 IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
   23 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
   24 
   25 */
   26 
   27 #ifndef OPTIONS_H
   28 #define OPTIONS_H
   29 
   30 enum on_last_slide_action {
   31     ON_LAST_SLIDE_RESUME = 0,
   32     ON_LAST_SLIDE_QUIT,
   33     ON_LAST_SLIDE_HOLD
   34 };
   35 
   36 struct __fehoptions {
   37     unsigned char multiwindow;
   38     unsigned char montage;
   39     unsigned char index;
   40     unsigned char thumbs;
   41     unsigned char slideshow;
   42     unsigned char recursive;
   43     unsigned char output;
   44     unsigned char verbose;
   45     unsigned char display;
   46     unsigned char bg;
   47     unsigned char alpha;
   48     unsigned char alpha_level;
   49     unsigned char aspect;
   50     unsigned char stretch;
   51     unsigned char keep_http;
   52     unsigned char use_conversion_cache;
   53     unsigned char borderless;
   54     unsigned char randomize;
   55     unsigned char jump_on_resort;
   56     unsigned char full_screen;
   57     unsigned char draw_filename;
   58 #ifdef HAVE_LIBEXIF
   59     unsigned char draw_exif;
   60     unsigned char auto_rotate;
   61 #endif
   62 #ifdef HAVE_INOTIFY
   63     unsigned char auto_reload;
   64     int inotify_fd;
   65 #endif
   66     unsigned char list;
   67     unsigned char quiet;
   68     unsigned char preload;
   69     unsigned char loadables;
   70     unsigned char unloadables;
   71     unsigned char reverse;
   72     unsigned char no_menus;
   73     unsigned char scale_down;
   74     unsigned char bgmode;
   75     unsigned char xinerama;
   76     unsigned char screen_clip;
   77     unsigned char hide_pointer;
   78     unsigned char draw_actions;
   79     unsigned char draw_info;
   80     unsigned char cache_thumbnails;
   81     unsigned char on_last_slide;
   82     unsigned char hold_actions[10];
   83     unsigned char text_bg;
   84     unsigned char no_fehbg;
   85     unsigned char keep_zoom_vp;
   86     unsigned char insecure_ssl;
   87     unsigned char filter_by_dimensions;
   88     unsigned char edit;
   89 
   90     char *output_file;
   91     char *output_dir;
   92     char *bg_file;
   93     char *image_bg;
   94     char *font;
   95     char *title_font;
   96     char *title;
   97     char *thumb_title;
   98     char *actions[10];
   99     char *action_titles[10];
  100     char *fontpath;
  101     char *filelistfile;
  102     char *menu_font;
  103     char *customlist;
  104     char *caption_path;
  105     char *start_list_at;
  106     char *info_cmd;
  107     char *index_info;
  108 
  109     int force_aliasing;
  110     int thumb_w;
  111     int thumb_h;
  112     int limit_w;
  113     int limit_h;
  114     unsigned int thumb_redraw;
  115     double reload;
  116     int sort;
  117     int version_sort;
  118     int debug;
  119     int geom_enabled;
  120     int geom_flags;
  121     int geom_x;
  122     int geom_y;
  123     unsigned int geom_w;
  124     unsigned int geom_h;
  125     int offset_flags;
  126     int offset_x;
  127     int offset_y;
  128     int default_zoom;
  129     int zoom_mode;
  130     unsigned char adjust_reload;
  131     int xinerama_index;
  132     char *x11_class;
  133 
  134     /* signed in case someone wants to invert scrolling real quick */
  135     int scroll_step;
  136 
  137     // imlib cache size in mebibytes
  138     int cache_size;
  139 
  140     unsigned int min_width, min_height, max_width, max_height;
  141 
  142     unsigned char mode;
  143     unsigned char paused;
  144 
  145     double slideshow_delay;
  146 
  147     signed int conversion_timeout;
  148 
  149     Imlib_Font menu_fn;
  150 };
  151 
  152 struct __fehkey {
  153     unsigned int keysyms[3];
  154     unsigned int keystates[3];
  155     unsigned int state;
  156     unsigned int button;
  157     char *name;
  158 };
  159 
  160 enum key_action {
  161     EVENT_menu_close = 0,
  162     EVENT_menu_parent,
  163     EVENT_menu_down,
  164     EVENT_menu_up,
  165     EVENT_menu_child,
  166     EVENT_menu_select,
  167     EVENT_scroll_left,
  168     EVENT_scroll_right,
  169     EVENT_scroll_down,
  170     EVENT_scroll_up,
  171     EVENT_scroll_left_page,
  172     EVENT_scroll_right_page,
  173     EVENT_scroll_down_page,
  174     EVENT_scroll_up_page,
  175     EVENT_prev_img,
  176     EVENT_next_img,
  177     EVENT_jump_back,
  178     EVENT_jump_fwd,
  179     EVENT_prev_dir,
  180     EVENT_next_dir,
  181     EVENT_jump_random,
  182     EVENT_quit,
  183     EVENT_close,
  184     EVENT_remove,
  185     EVENT_delete,
  186     EVENT_jump_first,
  187     EVENT_jump_last,
  188     EVENT_action_0,
  189     EVENT_action_1,
  190     EVENT_action_2,
  191     EVENT_action_3,
  192     EVENT_action_4,
  193     EVENT_action_5,
  194     EVENT_action_6,
  195     EVENT_action_7,
  196     EVENT_action_8,
  197     EVENT_action_9,
  198     EVENT_zoom_in,
  199     EVENT_zoom_out,
  200     EVENT_zoom_default,
  201     EVENT_zoom_fit,
  202     EVENT_zoom_fill,
  203     EVENT_size_to_image,
  204     EVENT_render,
  205     EVENT_toggle_actions,
  206     EVENT_toggle_aliasing,
  207     EVENT_toggle_auto_zoom,
  208 #ifdef HAVE_LIBEXIF
  209     EVENT_toggle_exif,
  210 #endif
  211     EVENT_toggle_filenames,
  212     EVENT_toggle_info,
  213     EVENT_toggle_pointer,
  214     EVENT_toggle_caption,
  215     EVENT_toggle_pause,
  216     EVENT_toggle_menu,
  217     EVENT_toggle_fullscreen,
  218     EVENT_reload_image,
  219     EVENT_save_image,
  220     EVENT_save_filelist,
  221     EVENT_orient_1,
  222     EVENT_orient_3,
  223     EVENT_flip,
  224     EVENT_mirror,
  225     EVENT_reload_minus,
  226     EVENT_reload_plus,
  227     EVENT_toggle_keep_vp,
  228     EVENT_toggle_fixed_geometry,
  229     EVENT_pan,
  230     EVENT_zoom,
  231     EVENT_blur,
  232     EVENT_rotate,
  233     EVENT_LIST_END
  234 };
  235 
  236 void init_parse_options(int argc, char **argv);
  237 char *feh_string_normalize(char *str);
  238 
  239 extern fehoptions opt;
  240 
  241 #endif