FreeBASIC  0.91.0
hinit.c File Reference
#include "../fb.h"
#include "fb_private_console.h"
#include "../fb_private_thread.h"
#include <signal.h>
#include <termcap.h>
#include <sys/ioctl.h>
#include <fcntl.h>
Include dependency graph for hinit.c:

Go to the source code of this file.

Macros

#define _GNU_SOURCE   1
 

Typedefs

typedef void(* SIGHANDLER )(int)
 

Functions

FBCALL void fb_BgLock (void)
 
FBCALL void fb_BgUnlock (void)
 
static void * bg_thread (void *arg)
 
void fb_hStartBgThread (void)
 
static int default_getch (void)
 
static void signal_handler (int sig)
 
void fb_hRecheckConsoleSize (void)
 
static void sigwinch_handler (int sig)
 
int fb_hTermOut (int code, int param1, int param2)
 
int fb_hInitConsole ()
 
void fb_hExitConsole (void)
 
static void hInit (void)
 
void fb_hInit (void)
 
void fb_hEnd (int unused)
 

Variables

FBCONSOLE __fb_con
 
static SIGHANDLER old_sighandler [NSIG]
 
static volatile sig_atomic_t __fb_console_resized
 
static const char * seq []
 
static pthread_t __fb_bg_thread
 
static int bgthread_inited = FALSE
 
static pthread_mutex_t __fb_bg_mutex
 

Macro Definition Documentation

#define _GNU_SOURCE   1

Definition at line 4 of file hinit.c.

Typedef Documentation

typedef void(* SIGHANDLER)(int)

Definition at line 19 of file hinit.c.

Function Documentation

static void* bg_thread ( void *  arg)
static

Definition at line 42 of file hinit.c.

Here is the caller graph for this function:

static int default_getch ( void  )
static

Definition at line 66 of file hinit.c.

Here is the caller graph for this function:

FBCALL void fb_BgLock ( void  )

Definition at line 28 of file hinit.c.

FBCALL void fb_BgUnlock ( void  )

Definition at line 29 of file hinit.c.

void fb_hEnd ( int  unused)

Definition at line 437 of file hinit.c.

Here is the call graph for this function:

void fb_hExitConsole ( void  )

Definition at line 289 of file hinit.c.

Here is the call graph for this function:

Here is the caller graph for this function:

void fb_hInit ( void  )

Definition at line 427 of file hinit.c.

Here is the call graph for this function:

int fb_hInitConsole ( void  )

Definition at line 225 of file hinit.c.

Here is the call graph for this function:

Here is the caller graph for this function:

void fb_hRecheckConsoleSize ( void  )

Definition at line 127 of file hinit.c.

Here is the caller graph for this function:

void fb_hStartBgThread ( void  )

Definition at line 58 of file hinit.c.

Here is the call graph for this function:

Here is the caller graph for this function:

int fb_hTermOut ( int  code,
int  param1,
int  param2 
)

Definition at line 191 of file hinit.c.

Here is the caller graph for this function:

static void hInit ( void  )
static

Definition at line 334 of file hinit.c.

Here is the call graph for this function:

Here is the caller graph for this function:

static void signal_handler ( int  sig)
static

Definition at line 71 of file hinit.c.

Here is the call graph for this function:

Here is the caller graph for this function:

static void sigwinch_handler ( int  sig)
static

Definition at line 185 of file hinit.c.

Here is the caller graph for this function:

Variable Documentation

pthread_mutex_t __fb_bg_mutex
static

Definition at line 27 of file hinit.c.

pthread_t __fb_bg_thread
static

Definition at line 25 of file hinit.c.

FBCONSOLE __fb_con

Definition at line 17 of file hinit.c.

volatile sig_atomic_t __fb_console_resized
static

Definition at line 21 of file hinit.c.

int bgthread_inited = FALSE
static

Definition at line 26 of file hinit.c.

SIGHANDLER old_sighandler[NSIG]
static

Definition at line 20 of file hinit.c.

const char* seq[]
static
Initial value:
= { "cm", "ho", "cs", "cl", "ce", "WS", "bl", "AF", "AB",
"me", "md", "SF", "ve", "vi", "dc", "ks", "ke" }

Definition at line 22 of file hinit.c.