#include "ecurses.h"
#include <sys/types.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <termios.h>
#include <unistd.h>
#include "compat/strlcpy.h"
#include <ekg/bindings.h>
#include <ekg/debug.h>
#include <ekg/windows.h>
#include <ekg/xmalloc.h>
#include <ekg/commands.h>
#include <ekg/sessions.h>
#include <ekg/plugins.h>
#include <ekg/recode.h>
#include <ekg/stuff.h>
#include <ekg/themes.h>
#include <ekg/userlist.h>
#include <ekg/vars.h>
#include <ekg/queries.h>
#include "old.h"
#include "completion.h"
#include "bindings.h"
#include "contacts.h"
#include "mouse.h"
#include "notify.h"
Definicje | |
#define | __fgcolor(x, y, z) |
#define | __bgcolor(x, y) case x: bgcolor = y; break; |
#define | __add_format(x, z) |
#define | __add_format_emp(x, y) __add_format(x, y ? (char *) empty_format : NULL) |
#define | __add_format_dup(x, y, z) __add_format(x, y ? xstrdup(z) : NULL) |
#define | __add_format_emp_st(x, y) case y: __add_format(x, (char *) empty_format) break |
#define | __add_format_emp_st(x, y) case y: __add_format("query_" x, (char *) empty_format); break |
#define | __init_bg(x, y) |
#define | GET_TIME(tv) (gettimeofday(&tv, (struct timezone *)NULL)) |
#define | DIF_TIME(t1, t2) |
#define | lastlog_edge WF_BOTTOM |
#define | lastlog_margin 1 |
#define | lastlog_frame WF_TOP |
#define | lastlog_wrap 0 |
Funkcje | |
int | ncurses_password_input (void *data, va_list ap) |
int | ncurses_session_disconnect_handler (void *data, va_list ap) |
void | ncurses_update_real_prompt (ncurses_window_t *n) |
static int | color_pair (int fg, int bg) |
static int | color_pair_bold (int fg, int bold, int bg) |
void | ncurses_commit (void) |
static int | ncurses_backlog_add_real (window_t *w, fstring_t *str) |
int | ncurses_backlog_add (window_t *w, fstring_t *str) |
int | ncurses_backlog_split (window_t *w, int full, int removed) |
void | ncurses_resize (void) |
static int | fstring_attr2ncurses_attr (short chattr) |
static CHAR_T | ncurses_fixchar (CHAR_T ch, int *attr) |
int | cmd_mark (const char *name, const char **params, session_t *session, const char *target, int quiet) |
static void | draw_thin_red_line (window_t *w, int y) |
void | ncurses_redraw (window_t *w) |
void | ncurses_clear (window_t *w, int full) |
void | ncurses_refresh (void) |
static void | update_header (void) |
static int | window_printat (WINDOW *w, int x, int y, const char *format, struct format_data *data, int fgcolor, int bold, int bgcolor) |
static char * | ncurses_window_activity (void) |
static void | reprint_statusbar (WINDOW *w, int y, const char *format, struct format_data *data) |
void | update_statusbar (int commit) |
int | ncurses_window_kill (window_t *w) |
void | ncurses_init (void) |
void | ncurses_deinit (void) |
void | ncurses_line_adjust (void) |
void | ncurses_lines_adjust (void) |
void | ncurses_input_update (int new_line_index) |
static void | print_char (WINDOW *w, int y, int x, CHAR_T ch, int attr) |
static int | ekg_getch (int meta, unsigned int *ch) |
int | ncurses_watch_winch (int type, int fd, watch_type_t watch, void *data) |
void | ncurses_redraw_input (unsigned int ch) |
static void | bind_exec (struct binding *b) |
int | ncurses_watch_stdin (int type, int fd, watch_type_t watch, void *data) |
void | header_statusbar_resize (const char *dummy) |
void | changed_backlog_size (const char *var) |
static int | ncurses_ui_window_lastlog (window_t *lastlog_w, window_t *w) |
int | ncurses_lastlog_update (window_t *w) |
void | ncurses_lastlog_new (window_t *w) |
int | ncurses_window_new (window_t *w) |
Zmienne | |
static WINDOW * | ncurses_status = NULL |
static WINDOW * | ncurses_header = NULL |
WINDOW * | ncurses_input = NULL |
WINDOW * | ncurses_contacts = NULL |
CHAR_T * | ncurses_history [HISTORY_MAX] |
int | ncurses_history_index = 0 |
CHAR_T * | ncurses_line = NULL |
CHAR_T * | ncurses_yanked = NULL |
CHAR_T ** | ncurses_lines = NULL |
int | ncurses_line_start = 0 |
int | ncurses_line_index = 0 |
int | ncurses_lines_start = 0 |
int | ncurses_lines_index = 0 |
int | ncurses_input_size = 1 |
int | ncurses_debug = 0 |
int | ncurses_noecho = 0 |
static int | ncurses_screen_height |
static int | ncurses_screen_width |
static struct termios | old_tio |
int | winch_pipe [2] |
int | have_winch_pipe = 0 |
static char | ncurses_funnything [5] = "|/-\\" |
CHAR_T * | ncurses_passbuf |
volatile int | sigint_count |
static int | ncurses_redraw_input_already_exec = 0 |
#define __add_format | ( | x, | ||
z | ||||
) |
#define __add_format_dup | ( | x, | ||
y, | ||||
z | ||||
) | __add_format(x, y ? xstrdup(z) : NULL) |
#define __add_format_emp | ( | x, | ||
y | ||||
) | __add_format(x, y ? (char *) empty_format : NULL) |
#define __add_format_emp_st | ( | x, | ||
y | ||||
) | case y: __add_format(x, (char *) empty_format) break |
#define __add_format_emp_st | ( | x, | ||
y | ||||
) | case y: __add_format("query_" x, (char *) empty_format); break |
#define __bgcolor | ( | x, | ||
y | ||||
) | case x: bgcolor = y; break; |
#define __fgcolor | ( | x, | ||
y, | ||||
z | ||||
) |
case x: fgcolor = z; bold = 0; break; \ case y: fgcolor = z; bold = 1; break;
#define __init_bg | ( | x, | ||
y | ||||
) |
init_pair(x, COLOR_BLACK, y); \ init_pair(x + 1, COLOR_RED, y); \ init_pair(x + 2, COLOR_GREEN, y); \ init_pair(x + 3, COLOR_YELLOW, y); \ init_pair(x + 4, COLOR_BLUE, y); \ init_pair(x + 5, COLOR_MAGENTA, y); \ init_pair(x + 6, COLOR_CYAN, y); \ init_pair(x + 7, COLOR_WHITE, y);
#define DIF_TIME | ( | t1, | ||
t2 | ||||
) |
((t2.tv_sec -t1.tv_sec) *1000+ \ (t2.tv_usec-t1.tv_usec)/1000)
#define GET_TIME | ( | tv | ) | (gettimeofday(&tv, (struct timezone *)NULL)) |
#define lastlog_edge WF_BOTTOM |
#define lastlog_frame WF_TOP |
#define lastlog_margin 1 |
#define lastlog_wrap 0 |
static void bind_exec | ( | struct binding * | b | ) | [static] |
void changed_backlog_size | ( | const char * | var | ) |
int cmd_mark | ( | const char * | name, | |
const char ** | params, | |||
session_t * | session, | |||
const char * | target, | |||
int | quiet | |||
) |
static int color_pair | ( | int | fg, | |
int | bg | |||
) | [static] |
static int color_pair_bold | ( | int | fg, | |
int | bold, | |||
int | bg | |||
) | [inline, static] |
static void draw_thin_red_line | ( | window_t * | w, | |
int | y | |||
) | [static] |
static int ekg_getch | ( | int | meta, | |
unsigned int * | ch | |||
) | [static] |
static int fstring_attr2ncurses_attr | ( | short | chattr | ) | [inline, static] |
void header_statusbar_resize | ( | const char * | dummy | ) |
int ncurses_backlog_split | ( | window_t * | w, | |
int | full, | |||
int | removed | |||
) |
void ncurses_clear | ( | window_t * | w, | |
int | full | |||
) |
void ncurses_commit | ( | void | ) |
void ncurses_deinit | ( | void | ) |
static CHAR_T ncurses_fixchar | ( | CHAR_T | ch, | |
int * | attr | |||
) | [inline, static] |
void ncurses_init | ( | void | ) |
void ncurses_input_update | ( | int | new_line_index | ) |
void ncurses_lastlog_new | ( | window_t * | w | ) |
int ncurses_lastlog_update | ( | window_t * | w | ) |
void ncurses_line_adjust | ( | void | ) |
void ncurses_lines_adjust | ( | void | ) |
int ncurses_password_input | ( | void * | data, | |
va_list | ap | |||
) |
void ncurses_redraw | ( | window_t * | w | ) |
void ncurses_redraw_input | ( | unsigned int | ch | ) |
void ncurses_refresh | ( | void | ) |
void ncurses_resize | ( | void | ) |
int ncurses_session_disconnect_handler | ( | void * | data, | |
va_list | ap | |||
) |
void ncurses_update_real_prompt | ( | ncurses_window_t * | n | ) |
int ncurses_watch_stdin | ( | int | type, | |
int | fd, | |||
watch_type_t | watch, | |||
void * | data | |||
) |
int ncurses_watch_winch | ( | int | type, | |
int | fd, | |||
watch_type_t | watch, | |||
void * | data | |||
) |
static char* ncurses_window_activity | ( | void | ) | [static] |
int ncurses_window_kill | ( | window_t * | w | ) |
int ncurses_window_new | ( | window_t * | w | ) |
static void print_char | ( | WINDOW * | w, | |
int | y, | |||
int | x, | |||
CHAR_T | ch, | |||
int | attr | |||
) | [static] |
static void reprint_statusbar | ( | WINDOW * | w, | |
int | y, | |||
const char * | format, | |||
struct format_data * | data | |||
) | [static] |
static void update_header | ( | void | ) | [static] |
void update_statusbar | ( | int | commit | ) |
static int window_printat | ( | WINDOW * | w, | |
int | x, | |||
int | y, | |||
const char * | format, | |||
struct format_data * | data, | |||
int | fgcolor, | |||
int | bold, | |||
int | bgcolor | |||
) | [static] |
int have_winch_pipe = 0 |
WINDOW* ncurses_contacts = NULL |
int ncurses_debug = 0 |
char ncurses_funnything[5] = "|/-\\" [static] |
WINDOW* ncurses_header = NULL [static] |
CHAR_T* ncurses_history[HISTORY_MAX] |
int ncurses_history_index = 0 |
WINDOW* ncurses_input = NULL |
int ncurses_input_size = 1 |
CHAR_T* ncurses_line = NULL |
int ncurses_line_index = 0 |
int ncurses_line_start = 0 |
CHAR_T** ncurses_lines = NULL |
int ncurses_lines_index = 0 |
int ncurses_lines_start = 0 |
int ncurses_noecho = 0 |
CHAR_T* ncurses_passbuf |
int ncurses_redraw_input_already_exec = 0 [static] |
int ncurses_screen_height [static] |
int ncurses_screen_width [static] |
WINDOW* ncurses_status = NULL [static] |
CHAR_T* ncurses_yanked = NULL |
struct termios old_tio [static] |
volatile int sigint_count |
int winch_pipe[2] |