2 * \brief Header: internal file viewer
8 #include "lib/global.h"
10 /*** typedefs(not structures) and defined constants **********************************************/
14 /*** enums ***************************************************************************************/
16 /*** structures declarations (and typedefs of structures)*****************************************/
18 /*** global variables defined in .c file *********************************************************/
20 extern int mcview_default_hex_mode
;
21 extern int mcview_default_nroff_flag
;
22 extern int mcview_global_wrap_mode
;
23 extern int mcview_default_magic_flag
;
25 extern int mcview_altered_hex_mode
;
26 extern int mcview_altered_magic_flag
;
27 extern int mcview_altered_nroff_flag
;
29 extern int mcview_remember_file_position
;
30 extern int mcview_max_dirt_limit
;
32 extern int mcview_mouse_move_pages
;
33 extern char *mcview_show_eof
;
35 /*** declarations of public functions ************************************************************/
37 /* Creates a new mcview_t object with the given properties. Caveat: the
38 * origin is in y-x order, while the extent is in x-y order. */
39 extern struct mcview_struct
*mcview_new (int y
, int x
, int lines
, int cols
, gboolean is_panel
);
42 /* Shows {file} or the output of {command} in the internal viewer,
43 * starting in line {start_line}.
45 extern gboolean
mcview_viewer (const char *command
, const vfs_path_t
* file_vpath
, int start_line
);
47 extern gboolean
mcview_load (struct mcview_struct
*, const char *, const char *, int);
49 /*** inline functions ****************************************************************************/
50 #endif /* MC__VIEWER_H */