Skip to content
This repository
Fetching contributors…

Cannot retrieve contributors at this time

file 60 lines (50 sloc) 0.941 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
#pragma once

/*
quIRC - simple terminal-based IRC client
Copyright (C) 2010 Edward Cree

See quirc.c for license information
input: handle input routines
*/

#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
#include <ctype.h>

typedef struct
{
char *data;
int l;
int i;
}
ichar;

typedef struct
{
ichar left;
ichar right;
}
iline;

typedef struct
{
int nlines;
int ptr;
int scroll;
bool filled;
char **line;
}
ibuffer;

#include "ttyesc.h"
#include "names.h"
#include "buffer.h"
#include "irc.h"
#include "bits.h"

bool ttab;

int inputchar(iline *inp, int *state);
char * slash_dequote(char *inp);
int cmd_handle(char *inp, char **qmsg, fd_set *master, int *fdmax);
void initibuf(ibuffer *i);
void addtoibuf(ibuffer *i, char *data);
void freeibuf(ibuffer *i);
char back_ichar(ichar *buf); // returns the deleted char
void ifree(iline *buf);

void i_home(iline *inp);
void i_end(iline *inp);
Something went wrong with that request. Please try again.