#include "histedit.h"
Go to the source code of this file.
Classes | |
struct | FKey_t |
struct | ElTerm_t |
Defines | |
#define | TERM_CAN_INSERT 0x001 |
#define | TERM_CAN_DELETE 0x002 |
#define | TERM_CAN_CEOL 0x004 |
#define | TERM_CAN_TAB 0x008 |
#define | TERM_CAN_ME 0x010 |
#define | TERM_CAN_UP 0x020 |
#define | TERM_HAS_META 0x040 |
#define | TERM_HAS_AUTO_MARGINS 0x080 |
#define | TERM_HAS_MAGIC_MARGINS 0x100 |
#define | A_K_DN 0 |
#define | A_K_UP 1 |
#define | A_K_LT 2 |
#define | A_K_RT 3 |
#define | A_K_HO 4 |
#define | A_K_EN 5 |
#define | A_K_DE 6 |
#define | A_K_NKEYS 7 |
#define | EL_FLAGS (el)->fTerm.fFlags |
#define | EL_CAN_UP (EL_FLAGS & TERM_CAN_UP) |
#define | EL_CAN_INSERT (EL_FLAGS & TERM_CAN_INSERT) |
#define | EL_CAN_DELETE (EL_FLAGS & TERM_CAN_DELETE) |
#define | EL_CAN_CEOL (EL_FLAGS & TERM_CAN_CEOL) |
#define | EL_CAN_TAB (EL_FLAGS & TERM_CAN_TAB) |
#define | EL_CAN_ME (EL_FLAGS & TERM_CAN_ME) |
#define | EL_HAS_META (EL_FLAGS & TERM_HAS_META) |
#define | EL_HAS_AUTO_MARGINS (EL_FLAGS & TERM_HAS_AUTO_MARGINS) |
#define | EL_HAS_MAGIC_MARGINS (EL_FLAGS & TERM_HAS_MAGIC_MARGINS) |
Functions | |
el_protected void | term_move_to_line (EditLine_t *, int) |
el_protected void | term_move_to_char (EditLine_t *, int) |
el_protected void | term_clear_EOL (EditLine_t *, int) |
el_protected void | term_overwrite (EditLine_t *, const char *, ElColor_t *, int) |
el_protected void | term_insertwrite (EditLine_t *, const char *, ElColor_t *, int) |
el_protected void | term_deletechars (EditLine_t *, int) |
el_protected void | term_clear_screen (EditLine_t *) |
el_protected void | term_beep (EditLine_t *) |
el_protected int | term_change_size (EditLine_t *, int, int) |
el_protected int | term_get_size (EditLine_t *, int *, int *) |
el_protected int | term_init (EditLine_t *) |
el_protected void | term_bind_arrow (EditLine_t *) |
el_protected void | term_print_arrow (EditLine_t *, const char *) |
el_protected int | term_clear_arrow (EditLine_t *, char *) |
el_protected int | term_set_arrow (EditLine_t *, char *, KeyValue_t *, int) |
el_protected void | term_end (EditLine_t *) |
el_protected int | term_set (EditLine_t *, const char *) |
el_protected int | term_settc (EditLine_t *, int, const char **) |
el_protected int | term_telltc (EditLine_t *, int, const char **) |
el_protected int | term_echotc (EditLine_t *, int, const char **) |
el_protected C int | term__putc (int) |
el_protected int | term__putcolorch (int, ElColor_t *) |
el_protected void | term__setcolor (int fgcol) |
el_protected int | term__atocolor (const char *name) |
el_protected void | term__resetcolor (void) |
el_protected void | term__repaint (EditLine_t *el, int index) |
el_protected void | term__flush (void) |
#define A_K_DE 6 |
#define A_K_DN 0 |
#define A_K_EN 5 |
#define A_K_HO 4 |
#define A_K_LT 2 |
#define A_K_NKEYS 7 |
Definition at line 91 of file term.h.
Referenced by term_bind_arrow(), term_clear_arrow(), term_init(), term_print_arrow(), and term_set_arrow().
#define A_K_RT 3 |
#define A_K_UP 1 |
#define EL_CAN_CEOL (EL_FLAGS & TERM_CAN_CEOL) |
Definition at line 129 of file term.h.
Referenced by re_clear_lines(), term_clear_EOL(), and term_setflags().
#define EL_CAN_DELETE (EL_FLAGS & TERM_CAN_DELETE) |
Definition at line 128 of file term.h.
Referenced by re_update_line(), term_deletechars(), and term_setflags().
#define EL_CAN_INSERT (EL_FLAGS & TERM_CAN_INSERT) |
Definition at line 127 of file term.h.
Referenced by re_update_line(), term_insertwrite(), and term_setflags().
#define EL_CAN_TAB (EL_FLAGS & TERM_CAN_TAB) |
Definition at line 130 of file term.h.
Referenced by term_echotc(), term_move_to_char(), term_telltc(), and tty_rawmode().
#define EL_CAN_UP (EL_FLAGS & TERM_CAN_UP) |
#define EL_FLAGS (el)->fTerm.fFlags |
#define EL_HAS_AUTO_MARGINS (EL_FLAGS & TERM_HAS_AUTO_MARGINS) |
Definition at line 133 of file term.h.
Referenced by re_fastputc(), term_echotc(), term_move_to_line(), term_overwrite(), and term_telltc().
#define EL_HAS_MAGIC_MARGINS (EL_FLAGS & TERM_HAS_MAGIC_MARGINS) |
Definition at line 134 of file term.h.
Referenced by re_fastputc(), term_echotc(), term_overwrite(), and term_telltc().
#define EL_HAS_META (EL_FLAGS & TERM_HAS_META) |
#define TERM_CAN_CEOL 0x004 |
#define TERM_CAN_DELETE 0x002 |
#define TERM_CAN_INSERT 0x001 |
#define TERM_CAN_ME 0x010 |
#define TERM_CAN_TAB 0x008 |
#define TERM_CAN_UP 0x020 |
#define TERM_HAS_AUTO_MARGINS 0x080 |
#define TERM_HAS_MAGIC_MARGINS 0x100 |
#define TERM_HAS_META 0x040 |
el_protected int term__atocolor | ( | const char * | name | ) |
Definition at line 1485 of file term.cxx.
References fprintf(), TTermManip::GetColorIndex(), i, size_t, and term__gettermmanip().
Referenced by prompt_print(), and setColors().
el_protected void term__flush | ( | void | ) |
Definition at line 1647 of file term.cxx.
References fflush(), term_outfile, and void.
Referenced by ed_delete_next_char(), ed_unassigned(), el_getc(), el_gets(), el_gets_newline(), el_push(), el_resize(), em_delete_or_list(), re_fastaddc(), re_goto_bottom(), re_refresh_cursor(), sig_handler(), term__repaint(), and term__resetcolor().
el_protected C int term__putc | ( | int | ) |
Definition at line 1475 of file term.cxx.
References NULL, and term__putcolorch().
Referenced by term_beep(), term_clear_EOL(), term_clear_screen(), term_deletechars(), term_insertwrite(), term_move_to_char(), and term_move_to_line().
el_protected int term__putcolorch | ( | int | , | |
ElColor_t * | ||||
) |
Definition at line 1598 of file term.cxx.
References NULL, term__setcolor(), and term_outfile.
Referenced by re_clear_lines(), re_fastputc(), re_goto_bottom(), term__putc(), term_beep(), term_clear_EOL(), term_clear_screen(), term_insertwrite(), term_move_to_char(), term_move_to_line(), and term_overwrite().
el_protected void term__repaint | ( | EditLine_t * | el, | |
int | index | |||
) |
Definition at line 1613 of file term.cxx.
References ElLine_t::fBufColor, ElLine_t::fBuffer, EditLine_t::fCursor, ElLine_t::fCursor, ElCoord_t::fH, EditLine_t::fLine, ElPrompt_t::fPos, EditLine_t::fPrompt, ElTerm_t::fSize, EditLine_t::fTerm, ElCoord_t::fV, line, term__flush(), term_move_to_char(), term_move_to_line(), and term_overwrite().
Referenced by colorBrackets(), colorWord(), and matchParentheses().
el_protected void term__resetcolor | ( | void | ) |
Definition at line 1464 of file term.cxx.
References TTermManip::ResetTerm(), term__flush(), and term__gettermmanip().
Referenced by rl_complete_internal().
el_protected void term__setcolor | ( | int | fgcol | ) |
Definition at line 1568 of file term.cxx.
References TTermManip::SetColor(), TTermManip::SetDefaultColor(), TTermManip::StartBold(), TTermManip::StartUnderline(), TTermManip::StopBold(), TTermManip::StopUnderline(), and term__gettermmanip().
Referenced by colorBrackets(), colorWord(), rl_complete_internal(), and term__putcolorch().
el_protected void term_beep | ( | EditLine_t * | ) |
Definition at line 1008 of file term.cxx.
References GoodStr, NULL, Str, T_bl, term__putc(), term__putcolorch(), tputs(), and void.
Referenced by c_gets(), ce_inc_search(), ed_unassigned(), el_beep(), el_gets(), el_push(), and em_delete_or_list().
el_protected void term_bind_arrow | ( | EditLine_t * | ) |
Definition at line 1351 of file term.cxx.
References A_K_NKEYS, arrow(), ED_SEQUENCE_LEAD_IN, ED_UNASSIGNED, ElMap_t::fAlt, ElTerm_t::fBuf, ElMap_t::fEmacs, ElTerm_t::fFKey, ElMap_t::fKey, EditLine_t::fMap, ElTerm_t::fStr, EditLine_t::fTerm, ElMap_t::fType, fType, ElMap_t::fVic, i, if(), j, key_add(), key_clear(), MAP_VI, NULL, p, term_reset_arrow(), XK_CMD, and XK_NOD.
Referenced by map_init_emacs(), map_init_vi(), and term_set().
el_protected int term_change_size | ( | EditLine_t * | , | |
int | , | |||
int | ||||
) |
Definition at line 1181 of file term.cxx.
References re_clear_display(), T_co, T_li, term_rebuffer_display(), and Val.
Referenced by el_resize(), and term_set().
el_protected int term_clear_arrow | ( | EditLine_t * | , | |
char * | ||||
) |
Definition at line 1314 of file term.cxx.
References A_K_NKEYS, arrow(), ElTerm_t::fFKey, EditLine_t::fTerm, fType, i, and XK_NOD.
Referenced by map_bind().
el_protected void term_clear_EOL | ( | EditLine_t * | , | |
int | ||||
) |
Definition at line 971 of file term.cxx.
References EL_CAN_CEOL, EditLine_t::fCursor, ElCoord_t::fH, GoodStr, i, NULL, Str, T_ce, term__putc(), term__putcolorch(), tputs(), and void.
Referenced by re_clear_lines(), and re_update_line().
el_protected void term_clear_screen | ( | EditLine_t * | ) |
Definition at line 989 of file term.cxx.
References GoodStr, NULL, Str, T_cd, T_cl, T_ho, T_li, term__putc(), term__putcolorch(), tputs(), Val, and void.
Referenced by ed_clear_screen().
el_protected void term_deletechars | ( | EditLine_t * | , | |
int | ||||
) |
Definition at line 849 of file term.cxx.
References EL_CAN_DELETE, EditLine_t::fErrFile, ElCoord_t::fH, fprintf(), ElTerm_t::fSize, EditLine_t::fTerm, GoodStr, Str, T_dc, T_DC, T_dm, T_ed, term__putc(), tputs(), and void.
Referenced by re_update_line().
el_protected int term_echotc | ( | EditLine_t * | , | |
int | , | |||
const char ** | ||||
) |
Definition at line 1782 of file term.cxx.
References buf, EL_CAN_TAB, EL_HAS_AUTO_MARGINS, EL_HAS_MAGIC_MARGINS, EditLine_t::fOutFile, fprintf(), EditLine_t::fTTY, NULL, silent, t, T_km, ElTTY_t::t_speed, TC_BUFSIZE, Val, verbose, and void.
Referenced by el_builtins_init(), el_get(), and el_set().
el_protected void term_end | ( | EditLine_t * | ) |
Definition at line 387 of file term.cxx.
References el_free, ElTerm_t::fBuf, ElTerm_t::fCap, ElTerm_t::fLoc, ElTerm_t::fStr, EditLine_t::fTerm, ElTerm_t::fVal, NULL, and term_free_display().
Referenced by el_end().
el_protected int term_get_size | ( | EditLine_t * | , | |
int * | , | |||
int * | ||||
) |
Definition at line 1139 of file term.cxx.
References EditLine_t::fInFD, T_co, T_li, and Val.
Referenced by el_resize(), and term_set().
el_protected int term_init | ( | EditLine_t * | ) |
Definition at line 341 of file term.cxx.
References A_K_NKEYS, el_malloc, ElTerm_t::fBuf, ElTerm_t::fCap, ElTerm_t::fFKey, ElTerm_t::fLoc, EditLine_t::fOutFile, ElTerm_t::fStr, EditLine_t::fTerm, ElTerm_t::fVal, NULL, T_str, T_val, TC_BUFSIZE, term_init_arrow(), term_init_color(), term_outfile, term_set(), and void.
Referenced by el_init().
el_protected void term_insertwrite | ( | EditLine_t * | , | |
const char * | , | |||
ElColor_t * | , | |||
int | ||||
) |
Definition at line 897 of file term.cxx.
References EL_CAN_INSERT, EditLine_t::fCursor, EditLine_t::fErrFile, ElCoord_t::fH, fprintf(), ElTerm_t::fSize, EditLine_t::fTerm, GoodStr, Str, T_ei, T_ic, T_IC, T_im, T_ip, term__putc(), term__putcolorch(), term_overwrite(), tputs(), and void.
Referenced by re_update_line().
el_protected void term_move_to_char | ( | EditLine_t * | , | |
int | ||||
) |
Definition at line 704 of file term.cxx.
References EL_CAN_TAB, EditLine_t::fCursor, EditLine_t::fDispColor, EditLine_t::fDisplay, EditLine_t::fErrFile, ElCoord_t::fH, fprintf(), ElTerm_t::fSize, EditLine_t::fTerm, ElCoord_t::fV, GoodStr, i, NULL, Str, T_ch, T_LE, T_RI, term__putc(), term__putcolorch(), term_overwrite(), tputs(), and void.
Referenced by re_clear_lines(), re_refresh_cursor(), re_update_line(), term__repaint(), and term_move_to_line().
el_protected void term_move_to_line | ( | EditLine_t * | , | |
int | ||||
) |
Definition at line 645 of file term.cxx.
References EL_HAS_AUTO_MARGINS, EditLine_t::fCursor, EditLine_t::fDispColor, EditLine_t::fDisplay, EditLine_t::fErrFile, ElCoord_t::fH, fprintf(), ElTerm_t::fSize, EditLine_t::fTerm, ElCoord_t::fV, GoodStr, NULL, Str, T_DO, T_UP, T_up, term__putc(), term__putcolorch(), term_move_to_char(), term_overwrite(), tputs(), and void.
Referenced by re_clear_lines(), re_goto_bottom(), re_refresh_cursor(), re_update_line(), and term__repaint().
el_protected void term_overwrite | ( | EditLine_t * | , | |
const char * | , | |||
ElColor_t * | , | |||
int | ||||
) |
Definition at line 798 of file term.cxx.
References c, EL_HAS_AUTO_MARGINS, EL_HAS_MAGIC_MARGINS, EditLine_t::fCursor, EditLine_t::fDispColor, EditLine_t::fDisplay, EditLine_t::fErrFile, ElCoord_t::fH, fprintf(), ElTerm_t::fSize, EditLine_t::fTerm, ElCoord_t::fV, NULL, term__putcolorch(), term_overwrite(), and void.
Referenced by ed_delete_next_char(), em_delete_or_list(), re_update_line(), term__repaint(), term_insertwrite(), term_move_to_char(), term_move_to_line(), and term_overwrite().
el_protected void term_print_arrow | ( | EditLine_t * | , | |
const char * | ||||
) |
Definition at line 1332 of file term.cxx.
References A_K_NKEYS, arrow(), ElTerm_t::fFKey, EditLine_t::fTerm, fType, i, key_kprint(), and XK_NOD.
Referenced by map_bind().
el_protected int term_set | ( | EditLine_t * | , | |
const char * | ||||
) |
Definition at line 1040 of file term.cxx.
References buf, EDIT_DISABLED, ElTerm_t::fCap, EditLine_t::fErrFile, EditLine_t::fFlags, ElCoord_t::fH, fprintf(), ElTerm_t::fSize, EditLine_t::fTerm, ElCoord_t::fV, getenv(), i, NULL, SIG_BLOCK, SIG_SETMASK, t, T_am, T_co, T_km, T_li, T_MT, T_pt, T_xn, T_xt, TC_BUFSIZE, term_alloc(), term_bind_arrow(), term_change_size(), term_get_size(), term_setflags(), tstr, Val, and void.
Referenced by el_set(), and term_init().
el_protected int term_set_arrow | ( | EditLine_t * | , | |
char * | , | |||
KeyValue_t * | , | |||
int | ||||
) |
Definition at line 1295 of file term.cxx.
References A_K_NKEYS, arrow(), ElTerm_t::fFKey, EditLine_t::fTerm, and i.
Referenced by map_bind().
el_protected int term_settc | ( | EditLine_t * | , | |
int | , | |||
const char ** | ||||
) |
Definition at line 1694 of file term.cxx.
References TNamed::fName, NULL, ts, tstr, and what.
Referenced by el_builtins_init(), el_get(), and el_set().
el_protected int term_telltc | ( | EditLine_t * | , | |
int | , | |||
const char ** | ||||
) |
Definition at line 1657 of file term.cxx.
References EL_BUFSIZ, EL_CAN_TAB, EL_HAS_AUTO_MARGINS, EL_HAS_MAGIC_MARGINS, EL_HAS_META, EditLine_t::fOutFile, fprintf(), ElTerm_t::fStr, EditLine_t::fTerm, key__decode_str(), NULL, t, T_co, T_li, ts, tstr, Val, and void.
Referenced by el_builtins_init(), el_get(), and el_set().