Files
source/S/src--editor--edit.h.html
github-actions[bot] 08571174ab Deploy to GitHub Pages
2026-02-01 17:32:02 +00:00

133 lines
20 KiB
HTML

<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Transitional//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd'>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head>
<title>src/editor/edit.h</title>
<meta name='robots' content='noindex,nofollow' />
<meta name='generator' content='GLOBAL-6.6.11' />
<meta http-equiv='Content-Style-Type' content='text/css' />
<link rel='stylesheet' type='text/css' href='../style.css' />
</head>
<body>
<!-- beginning of fixed guide -->
<div id='guide'><ul>
<li><a href='#TOP'><img class='icon' src='../icons/first.png' alt='[^]' /></a></li>
<li><a href='#BOTTOM'><img class='icon' src='../icons/last.png' alt='[v]' /></a></li>
<li><a href='#TOP'><img class='icon' src='../icons/top.png' alt='[top]' /></a></li>
<li><a href='#BOTTOM'><img class='icon' src='../icons/bottom.png' alt='[bottom]' /></a></li>
<li><a href='../mains.html'><img class='icon' src='../icons/index.png' alt='[index]' /></a></li>
<li><a href='../help.html'><img class='icon' src='../icons/help.png' alt='[help]' /></a></li>
<li class='standout'><span><a href='../files/src.html'>src</a>/<a href='../files/src--editor.html'>editor</a>/edit.h</span></li>
</ul></div>
<!-- end of fixed guide -->
<div align='right'>Manual pages:
<a href=man/mc.html>mc</a> &bullet; <a href=man/mcdiff.html>mcdiff</a> &bullet; <a href=man/mcedit.html>mcedit</a> &bullet; <a href=man/mcview.html>mcview</a>
</div>
<a id='TOP' name='TOP'></a><h2 class='header'><a href='../mains.html'>root</a>/<a href='../files/src.html'>src</a>/<a href='../files/src--editor.html'>editor</a>/edit.h</h2>
<em class='comment'>/* <img class='icon' src='../icons/n_left.png' alt='[previous]' /><img class='icon' src='../icons/n_right.png' alt='[next]' /><img class='icon' src='../icons/n_first.png' alt='[first]' /><img class='icon' src='../icons/n_last.png' alt='[last]' /><img class='icon' src='../icons/n_top.png' alt='[top]' /><a href='#BOTTOM'><img class='icon' src='../icons/bottom.png' alt='[bottom]' /></a><a href='../mains.html'><img class='icon' src='../icons/index.png' alt='[index]' /></a><a href='../help.html'><img class='icon' src='../icons/help.png' alt='[help]' /></a>&nbsp;<input type='text' readonly onfocus='this.select();' value='+1 src/editor/edit.h' /> */</em>
<hr />
<h2 class='header'><a href='../J/edit.h.html' title='Multiple included from 7 places.'>INCLUDED FROM</a></h2>
<hr />
<pre>
<a id='L1' name='L1'></a> 1 <em class='comment'>/*</em>
<a id='L2' name='L2'></a> 2 <em class='comment'> Editor public API</em>
<a id='L3' name='L3'></a> 3 <em class='comment'> */</em>
<a id='L4' name='L4'></a> 4
<a id='L5' name='L5'></a> 5 <em class='comment'>/** \file edit.h</em>
<a id='L6' name='L6'></a> 6 <em class='comment'> * \brief Header: editor public API</em>
<a id='L7' name='L7'></a> 7 <em class='comment'> * \author Paul Sheer</em>
<a id='L8' name='L8'></a> 8 <em class='comment'> * \date 1996, 1997</em>
<a id='L9' name='L9'></a> 9 <em class='comment'> * \author Andrew Borodin</em>
<a id='L10' name='L10'></a> 10 <em class='comment'> * \date 2009, 2012</em>
<a id='L11' name='L11'></a> 11 <em class='comment'> */</em>
<a id='L12' name='L12'></a> 12
<a id='L13' name='L13'></a> 13 <em class='sharp'>#ifndef</em> <a href='../S/src--editor--edit.h.html#L14' title='Defined at 14 in src/editor/edit.h.'>MC__EDIT_H</a>
<a id='L14' name='L14'></a> 14 <em class='sharp'>#define</em> <a href='../S/src--editor--edit.h.html#L13' title='Referred from 13 in src/editor/edit.h.'>MC__EDIT_H</a>
<a id='L15' name='L15'></a> 15
<a id='L16' name='L16'></a> 16 <em class='sharp'>#include</em> "<a href='lib--global.h.html'>lib/global.h</a>" <em class='comment'>// PATH_SEP_STR</em>
<a id='L17' name='L17'></a> 17 <em class='sharp'>#include</em> "<a href='lib--vfs--vfs.h.html'>lib/vfs/vfs.h</a>" <em class='comment'>// vfs_path_t</em>
<a id='L18' name='L18'></a> 18
<a id='L19' name='L19'></a> 19 <em class='comment'>/*** typedefs(not structures) and defined constants **********************************************/</em>
<a id='L20' name='L20'></a> 20
<a id='L21' name='L21'></a> 21 <em class='sharp'>#define</em> <a href='../R/DEFAULT_WRAP_LINE_LENGTH.html' title='Multiple referred from 3 places.'>DEFAULT_WRAP_LINE_LENGTH</a> 72
<a id='L22' name='L22'></a> 22
<a id='L23' name='L23'></a> 23 <em class='sharp'>#define</em> <a href='../R/EDIT.html' title='Multiple referred from 19 places.'>EDIT</a>(<a href='../Y/x.html' title='Multiple used in 677 places.'>x</a>) ((<a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a> *) (<a href='../Y/x.html' title='Multiple used in 677 places.'>x</a>))
<a id='L24' name='L24'></a> 24 <em class='sharp'>#define</em> <a href='../R/CONST_EDIT.html' title='Multiple referred from 2 places.'>CONST_EDIT</a>(<a href='../Y/x.html' title='Multiple used in 677 places.'>x</a>) ((<strong class='reserved'>const</strong> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a> *) (<a href='../Y/x.html' title='Multiple used in 677 places.'>x</a>))
<a id='L25' name='L25'></a> 25
<a id='L26' name='L26'></a> 26 <em class='comment'>/*** enums ***************************************************************************************/</em>
<a id='L27' name='L27'></a> 27
<a id='L28' name='L28'></a> 28 <em class='comment'>/*** structures declarations (and typedefs of structures)*****************************************/</em>
<a id='L29' name='L29'></a> 29
<a id='L30' name='L30'></a> 30 <em class='comment'>/* Editor widget */</em>
<a id='L31' name='L31'></a> 31 <strong class='reserved'>struct</strong> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a>;
<a id='L32' name='L32'></a> 32 <strong class='reserved'>typedef</strong> <strong class='reserved'>struct</strong> <a href='../R/WEdit.html' title='Multiple referred from 367 places.'>WEdit</a> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a>;
<a id='L33' name='L33'></a> 33
<a id='L34' name='L34'></a> 34 <strong class='reserved'>typedef</strong> <strong class='reserved'>struct</strong>
<a id='L35' name='L35'></a> 35 <em class='brace'>{</em>
<a id='L36' name='L36'></a> 36 <strong class='reserved'>int</strong> <a href='../Y/word_wrap_line_length.html' title='Multiple used in 14 places.'>word_wrap_line_length</a>;
<a id='L37' name='L37'></a> 37 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/typewriter_wrap.html' title='Multiple used in 8 places.'>typewriter_wrap</a>;
<a id='L38' name='L38'></a> 38 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/auto_para_formatting.html' title='Multiple used in 11 places.'>auto_para_formatting</a>;
<a id='L39' name='L39'></a> 39 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/fill_tabs_with_spaces.html' title='Multiple used in 8 places.'>fill_tabs_with_spaces</a>;
<a id='L40' name='L40'></a> 40 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/return_does_auto_indent.html' title='Multiple used in 6 places.'>return_does_auto_indent</a>;
<a id='L41' name='L41'></a> 41 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/backspace_through_tabs.html' title='Multiple used in 5 places.'>backspace_through_tabs</a>;
<a id='L42' name='L42'></a> 42 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/fake_half_tabs.html' title='Multiple used in 16 places.'>fake_half_tabs</a>;
<a id='L43' name='L43'></a> 43 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/persistent_selections.html' title='Multiple used in 14 places.'>persistent_selections</a>;
<a id='L44' name='L44'></a> 44 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/drop_selection_on_copy.html' title='Multiple used in 4 places.'>drop_selection_on_copy</a>; <em class='comment'>// whether we need to drop selection on copy to buffer</em>
<a id='L45' name='L45'></a> 45 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/cursor_beyond_eol.html' title='Multiple used in 20 places.'>cursor_beyond_eol</a>;
<a id='L46' name='L46'></a> 46 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/cursor_after_inserted_block.html' title='Multiple used in 8 places.'>cursor_after_inserted_block</a>;
<a id='L47' name='L47'></a> 47 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/state_full_filename.html' title='Multiple used in 5 places.'>state_full_filename</a>;
<a id='L48' name='L48'></a> 48 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/line_state.html' title='Multiple used in 8 places.'>line_state</a>;
<a id='L49' name='L49'></a> 49 <strong class='reserved'>int</strong> <a href='../Y/line_state_width.html' title='Multiple used in 18 places.'>line_state_width</a>;
<a id='L50' name='L50'></a> 50 <strong class='reserved'>int</strong> <a href='../Y/save_mode.html' title='Multiple used in 5 places.'>save_mode</a>;
<a id='L51' name='L51'></a> 51 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/confirm_save.html' title='Multiple used in 5 places.'>confirm_save</a>; <em class='comment'>// queries on a save</em>
<a id='L52' name='L52'></a> 52 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/save_position.html' title='Multiple used in 6 places.'>save_position</a>;
<a id='L53' name='L53'></a> 53 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/syntax_highlighting.html' title='Multiple used in 10 places.'>syntax_highlighting</a>;
<a id='L54' name='L54'></a> 54 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/group_undo.html' title='Multiple used in 5 places.'>group_undo</a>;
<a id='L55' name='L55'></a> 55 <strong class='reserved'>char</strong> *<a href='../Y/backup_ext.html' title='Multiple used in 9 places.'>backup_ext</a>;
<a id='L56' name='L56'></a> 56 <strong class='reserved'>char</strong> *<a href='../Y/filesize_threshold.html' title='Multiple used in 7 places.'>filesize_threshold</a>;
<a id='L57' name='L57'></a> 57 <strong class='reserved'>char</strong> *<a href='../Y/stop_format_chars.html' title='Multiple used in 14 places.'>stop_format_chars</a>;
<a id='L58' name='L58'></a> 58 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/visible_tabs.html' title='Multiple used in 5 places.'>visible_tabs</a>;
<a id='L59' name='L59'></a> 59 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/visible_tws.html' title='Multiple used in 8 places.'>visible_tws</a>;
<a id='L60' name='L60'></a> 60 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/show_right_margin.html' title='Multiple used in 6 places.'>show_right_margin</a>;
<a id='L61' name='L61'></a> 61 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/simple_statusbar.html' title='Multiple used in 5 places.'>simple_statusbar</a>; <em class='comment'>// statusbar draw style</em>
<a id='L62' name='L62'></a> 62 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../Y/check_nl_at_eof.html' title='Multiple used in 5 places.'>check_nl_at_eof</a>;
<a id='L63' name='L63'></a> 63 <em class='brace'>}</em> <a href='../R/edit_options_t.html' title='Multiple referred from 2 places.'>edit_options_t</a>;
<a id='L64' name='L64'></a> 64
<a id='L65' name='L65'></a> 65 <strong class='reserved'>typedef</strong> <strong class='reserved'>struct</strong>
<a id='L66' name='L66'></a> 66 <em class='brace'>{</em>
<a id='L67' name='L67'></a> 67 <a href='../S/lib--vfs--path.h.html#L31' title='Defined at 31 in lib/vfs/path.h.'>vfs_path_t</a> *<a href='../Y/file_vpath.html' title='Multiple used in 20 places.'>file_vpath</a>;
<a id='L68' name='L68'></a> 68 <strong class='reserved'>long</strong> <a href='../Y/line_number.html' title='Multiple used in 12 places.'>line_number</a>;
<a id='L69' name='L69'></a> 69 <em class='brace'>}</em> <a href='../R/edit_arg_t.html' title='Multiple referred from 35 places.'>edit_arg_t</a>;
<a id='L70' name='L70'></a> 70
<a id='L71' name='L71'></a> 71 <em class='comment'>/*** global variables defined in .c file *********************************************************/</em>
<a id='L72' name='L72'></a> 72
<a id='L73' name='L73'></a> 73 <strong class='reserved'>extern</strong> <a href='../S/src--editor--edit.h.html#L63' title='Defined at 63 in src/editor/edit.h.'>edit_options_t</a> <a href='../Y/edit_options.html' title='Multiple used in 171 places.'>edit_options</a>;
<a id='L74' name='L74'></a> 74
<a id='L75' name='L75'></a> 75 <em class='comment'>/*** declarations of public functions ************************************************************/</em>
<a id='L76' name='L76'></a> 76
<a id='L77' name='L77'></a> 77 <em class='comment'>/* used in main() */</em>
<a id='L78' name='L78'></a> 78 <strong class='reserved'>void</strong> <a href='../S/src--editor--edit.c.html#L4090' title='Defined at 4090 in src/editor/edit.c.'>edit_stack_init</a> (<strong class='reserved'>void</strong>);
<a id='L79' name='L79'></a> 79 <strong class='reserved'>void</strong> <a href='../S/src--editor--edit.c.html#L4101' title='Defined at 4101 in src/editor/edit.c.'>edit_stack_free</a> (<strong class='reserved'>void</strong>);
<a id='L80' name='L80'></a> 80
<a id='L81' name='L81'></a> 81 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../S/src--editor--editwidget.c.html#L1195' title='Defined at 1195 in src/editor/editwidget.c.'>edit_file</a> (<strong class='reserved'>const</strong> <a href='../S/src--editor--edit.h.html#L69' title='Defined at 69 in src/editor/edit.h.'>edit_arg_t</a> *<a href='../Y/arg.html' title='Multiple used in 185 places.'>arg</a>);
<a id='L82' name='L82'></a> 82 <a href='../Y/gboolean.html' title='Multiple used in 1942 places.'>gboolean</a> <a href='../S/src--editor--editwidget.c.html#L1210' title='Defined at 1210 in src/editor/editwidget.c.'>edit_files</a> (<strong class='reserved'>const</strong> <a href='../Y/GList.html' title='Multiple used in 182 places.'>GList</a> *<a href='../Y/files.html' title='Multiple used in 7 places.'>files</a>);
<a id='L83' name='L83'></a> 83
<a id='L84' name='L84'></a> 84 <a href='../S/src--editor--edit.h.html#L69' title='Defined at 69 in src/editor/edit.h.'>edit_arg_t</a> *<a href='../S/src--editor--edit.c.html#L4135' title='Defined at 4135 in src/editor/edit.c.'>edit_arg_vpath_new</a> (<a href='../S/lib--vfs--path.h.html#L31' title='Defined at 31 in lib/vfs/path.h.'>vfs_path_t</a> *<a href='../Y/file_vpath.html' title='Multiple used in 20 places.'>file_vpath</a>, <strong class='reserved'>long</strong> <a href='../Y/line_number.html' title='Multiple used in 12 places.'>line_number</a>);
<a id='L85' name='L85'></a> 85 <a href='../S/src--editor--edit.h.html#L69' title='Defined at 69 in src/editor/edit.h.'>edit_arg_t</a> *<a href='../S/src--editor--edit.c.html#L4156' title='Defined at 4156 in src/editor/edit.c.'>edit_arg_new</a> (<strong class='reserved'>const</strong> <strong class='reserved'>char</strong> *<a href='../Y/file_name.html' title='Multiple used in 83 places.'>file_name</a>, <strong class='reserved'>long</strong> <a href='../Y/line_number.html' title='Multiple used in 12 places.'>line_number</a>);
<a id='L86' name='L86'></a> 86 <strong class='reserved'>void</strong> <a href='../S/src--editor--edit.c.html#L4171' title='Defined at 4171 in src/editor/edit.c.'>edit_arg_init</a> (<a href='../S/src--editor--edit.h.html#L69' title='Defined at 69 in src/editor/edit.h.'>edit_arg_t</a> *<a href='../Y/arg.html' title='Multiple used in 185 places.'>arg</a>, <a href='../S/lib--vfs--path.h.html#L31' title='Defined at 31 in lib/vfs/path.h.'>vfs_path_t</a> *<a href='../Y/vpath.html' title='Multiple used in 942 places.'>vpath</a>, <strong class='reserved'>long</strong> <a href='../Y/line.html' title='Multiple used in 319 places.'>line</a>);
<a id='L87' name='L87'></a> 87 <strong class='reserved'>void</strong> <a href='../S/src--editor--edit.c.html#L4187' title='Defined at 4187 in src/editor/edit.c.'>edit_arg_assign</a> (<a href='../S/src--editor--edit.h.html#L69' title='Defined at 69 in src/editor/edit.h.'>edit_arg_t</a> *<a href='../Y/arg.html' title='Multiple used in 185 places.'>arg</a>, <a href='../S/lib--vfs--path.h.html#L31' title='Defined at 31 in lib/vfs/path.h.'>vfs_path_t</a> *<a href='../Y/vpath.html' title='Multiple used in 942 places.'>vpath</a>, <strong class='reserved'>long</strong> <a href='../Y/line.html' title='Multiple used in 319 places.'>line</a>);
<a id='L88' name='L88'></a> 88 <strong class='reserved'>void</strong> <a href='../S/src--editor--edit.c.html#L4201' title='Defined at 4201 in src/editor/edit.c.'>edit_arg_free</a> (<a href='../S/src--editor--edit.h.html#L69' title='Defined at 69 in src/editor/edit.h.'>edit_arg_t</a> *<a href='../Y/arg.html' title='Multiple used in 185 places.'>arg</a>);
<a id='L89' name='L89'></a> 89
<a id='L90' name='L90'></a> 90 <strong class='reserved'>const</strong> <strong class='reserved'>char</strong> *<a href='../S/src--editor--edit.c.html#L4210' title='Defined at 4210 in src/editor/edit.c.'>edit_get_file_name</a> (<strong class='reserved'>const</strong> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a> *<a href='../Y/edit.html' title='Multiple used in 2245 places.'>edit</a>);
<a id='L91' name='L91'></a> 91 <a href='../Y/off_t.html' title='Multiple used in 615 places.'>off_t</a> <a href='../S/src--editor--edit.c.html#L2838' title='Defined at 2838 in src/editor/edit.c.'>edit_get_cursor_offset</a> (<strong class='reserved'>const</strong> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a> *<a href='../Y/edit.html' title='Multiple used in 2245 places.'>edit</a>);
<a id='L92' name='L92'></a> 92 <strong class='reserved'>long</strong> <a href='../S/src--editor--edit.c.html#L2879' title='Defined at 2879 in src/editor/edit.c.'>edit_get_curs_col</a> (<strong class='reserved'>const</strong> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a> *<a href='../Y/edit.html' title='Multiple used in 2245 places.'>edit</a>);
<a id='L93' name='L93'></a> 93 <strong class='reserved'>const</strong> <strong class='reserved'>char</strong> *<a href='../S/src--editor--syntax.c.html#L1582' title='Defined at 1582 in src/editor/syntax.c.'>edit_get_syntax_type</a> (<strong class='reserved'>const</strong> <a href='../D/WEdit.html' title='Multiple defined in 2 places.'>WEdit</a> *<a href='../Y/edit.html' title='Multiple used in 2245 places.'>edit</a>);
<a id='L94' name='L94'></a> 94
<a id='L95' name='L95'></a> 95 <em class='comment'>/*** inline functions ****************************************************************************/</em>
<a id='L96' name='L96'></a> 96 <em class='sharp'>#endif</em>
</pre>
<hr />
<a id='BOTTOM' name='BOTTOM'></a>
<em class='comment'>/* <img class='icon' src='../icons/n_left.png' alt='[previous]' /><img class='icon' src='../icons/n_right.png' alt='[next]' /><img class='icon' src='../icons/n_first.png' alt='[first]' /><img class='icon' src='../icons/n_last.png' alt='[last]' /><a href='#TOP'><img class='icon' src='../icons/top.png' alt='[top]' /></a><img class='icon' src='../icons/n_bottom.png' alt='[bottom]' /><a href='../mains.html'><img class='icon' src='../icons/index.png' alt='[index]' /></a><a href='../help.html'><img class='icon' src='../icons/help.png' alt='[help]' /></a>&nbsp;<input type='text' readonly onfocus='this.select();' value='+96 src/editor/edit.h' /> */</em>
</body>
</html>