tmux
3.2a
About: tmux is a terminal multiplexer that lets you switch easily between several programs in one terminal.
![]() ![]() |
#include <sys/types.h>
#include <sys/wait.h>
#include <signal.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "tmux.h"
Go to the source code of this file.
Data Structures | |
struct | popup_data |
struct | popup_editor |
Functions | |
static void | popup_redraw_cb (const struct tty_ctx *ttyctx) |
static int | popup_set_client_cb (struct tty_ctx *ttyctx, struct client *c) |
static void | popup_init_ctx_cb (struct screen_write_ctx *ctx, struct tty_ctx *ttyctx) |
static struct screen * | popup_mode_cb (struct client *c, u_int *cx, u_int *cy) |
static int | popup_check_cb (struct client *c, u_int px, u_int py) |
static void | popup_draw_cb (struct client *c, struct screen_redraw_ctx *ctx0) |
static void | popup_free_cb (struct client *c) |
static void | popup_handle_drag (struct client *c, struct popup_data *pd, struct mouse_event *m) |
static int | popup_key_cb (struct client *c, struct key_event *event) |
static void | popup_job_update_cb (struct job *job) |
static void | popup_job_complete_cb (struct job *job) |
int | popup_display (int flags, struct cmdq_item *item, u_int px, u_int py, u_int sx, u_int sy, const char *shellcmd, int argc, char **argv, const char *cwd, struct client *c, struct session *s, popup_close_cb cb, void *arg) |
static void | popup_editor_free (struct popup_editor *pe) |
static void | popup_editor_close_cb (int status, void *arg) |
int | popup_editor (struct client *c, const char *buf, size_t len, popup_finish_edit_cb cb, void *arg) |
|
static |
Definition at line 112 of file popup.c.
References popup_data::c, client::overlay_data, popup_data::px, popup_data::py, popup_data::sx, and popup_data::sy.
Referenced by popup_display(), popup_draw_cb(), and popup_job_update_cb().
int popup_display | ( | int | flags, |
struct cmdq_item * | item, | ||
u_int | px, | ||
u_int | py, | ||
u_int | sx, | ||
u_int | sy, | ||
const char * | shellcmd, | ||
int | argc, | ||
char ** | argv, | ||
const char * | cwd, | ||
struct client * | c, | ||
struct session * | s, | ||
popup_close_cb | cb, | ||
void * | arg | ||
) |
Definition at line 321 of file popup.c.
References popup_data::arg, popup_data::c, popup_data::cb, popup_data::flags, popup_data::ictx, input_init(), popup_data::item, popup_data::job, job_get_event(), JOB_KEEPWRITE, JOB_NOWAIT, JOB_PTY, job_run(), popup_check_cb(), popup_draw_cb(), popup_free_cb(), popup_job_complete_cb(), popup_job_update_cb(), popup_key_cb(), popup_mode_cb(), popup_data::px, popup_data::py, client::references, popup_data::s, screen_init(), server_client_set_overlay(), popup_data::status, popup_data::sx, tty::sx, popup_data::sy, tty::sy, client::tty, and xcalloc().
Referenced by popup_editor().
|
static |
Definition at line 124 of file popup.c.
References popup_data::c, grid_default_cell, client::overlay_check, client::overlay_data, popup_check_cb(), popup_data::px, popup_data::py, popup_data::s, screen_write_ctx::s, screen_init(), screen_write_box(), screen_write_clearscreen(), screen_write_cursormove(), screen_write_fast_copy(), screen_write_start(), screen_write_stop(), popup_data::sx, popup_data::sy, client::tty, and tty_draw_line().
Referenced by popup_display().
int popup_editor | ( | struct client * | c, |
const char * | buf, | ||
size_t | len, | ||
popup_finish_edit_cb | cb, | ||
void * | arg | ||
) |
Definition at line 403 of file popup.c.
References _PATH_TMP, popup_editor::arg, popup_editor::cb, f, global_options, options_get_string(), popup_editor::path, POPUP_CLOSEEXIT, popup_display(), popup_editor_close_cb(), popup_editor_free(), tty::sx, tty::sy, client::tty, xasprintf(), xcalloc(), and xstrdup().
Referenced by window_buffer_start_edit().
|
static |
Definition at line 369 of file popup.c.
References popup_editor::arg, popup_editor::cb, f, popup_editor::path, and popup_editor_free().
Referenced by popup_editor().
|
static |
Definition at line 361 of file popup.c.
References popup_editor::path.
Referenced by popup_editor(), and popup_editor_close_cb().
|
static |
Definition at line 149 of file popup.c.
References popup_data::arg, popup_data::c, popup_data::cb, cmdq_continue(), cmdq_get_client(), popup_data::ictx, input_free(), popup_data::item, popup_data::job, job_free(), client::overlay_data, client::retval, popup_data::s, screen_free(), server_client_unref(), and popup_data::status.
Referenced by popup_display().
|
static |
Definition at line 174 of file popup.c.
References mouse_event::b, popup_data::dragging, popup_data::dx, popup_data::dy, popup_data::job, job_resize(), MOUSE_DRAG, popup_data::px, popup_data::py, popup_data::s, screen_resize(), server_redraw_client(), popup_data::sx, tty::sx, popup_data::sy, tty::sy, client::tty, mouse_event::x, and mouse_event::y.
Referenced by popup_key_cb().
|
static |
Definition at line 92 of file popup.c.
References screen_write_ctx::arg, tty_ctx::arg, popup_redraw_cb(), popup_set_client_cb(), tty_ctx::redraw_cb, and tty_ctx::set_client_cb.
Referenced by popup_job_update_cb().
|
static |
Definition at line 301 of file popup.c.
References popup_data::c, popup_data::flags, popup_data::job, job_get_data(), job_get_status(), POPUP_CLOSEEXIT, POPUP_CLOSEEXITZERO, server_client_clear_overlay(), and popup_data::status.
Referenced by popup_display().
|
static |
Definition at line 277 of file popup.c.
References popup_data::c, tty::flags, popup_data::ictx, input_parse_screen(), job_get_data(), job_get_event(), client::overlay_check, popup_check_cb(), popup_init_ctx_cb(), popup_data::s, client::tty, and TTY_FREEZE.
Referenced by popup_display().
Definition at line 215 of file popup.c.
References mouse_event::b, popup_data::c, popup_data::dragging, popup_data::dx, popup_data::dy, popup_data::flags, input_key(), input_key_get_mouse(), popup_data::job, job_get_event(), key_event::key, KEYC_IS_MOUSE, popup_data::lb, mouse_event::lb, popup_data::lx, mouse_event::lx, popup_data::ly, mouse_event::ly, MOUSE_BUTTONS, MOUSE_DRAG, MOUSE_MASK_META, client::overlay_data, POPUP_CLOSEEXIT, POPUP_CLOSEEXITZERO, popup_handle_drag(), popup_data::px, popup_data::py, popup_data::s, popup_data::sx, popup_data::sy, mouse_event::x, and mouse_event::y.
Referenced by popup_display().
Definition at line 102 of file popup.c.
References popup_data::c, screen::cx, screen::cy, client::overlay_data, popup_data::px, popup_data::py, and popup_data::s.
Referenced by popup_display().
|
static |
Definition at line 62 of file popup.c.
References tty_ctx::arg, popup_data::c, CLIENT_REDRAWOVERLAY, and client::flags.
Referenced by popup_init_ctx_cb().
Definition at line 70 of file popup.c.
References tty_ctx::arg, tty_ctx::bigger, popup_data::c, CLIENT_REDRAWOVERLAY, client::flags, popup_data::px, popup_data::py, tty_ctx::rxoff, tty_ctx::ryoff, tty::sx, tty::sy, client::tty, tty_ctx::wox, tty_ctx::woy, tty_ctx::wsx, tty_ctx::wsy, tty_ctx::xoff, and tty_ctx::yoff.
Referenced by popup_init_ctx_cb().