#include <ipc/fb.h>
#include <async.h>
#include <stdio.h>
#include <sys/mman.h>
#include <str.h>
#include <align.h>
#include <bool.h>
#include "console.h"
#include "gcons.h"
Go to the source code of this file.
Defines | |
#define | COLOR_BACKGROUND 0xffffff |
#define | COLOR_FOREGROUND 0x202020 |
#define | COLOR_MAIN 0xffffff |
#define | CONSOLE_MARGIN 6 |
#define | CONSOLE_TOP 66 |
#define | STATUS_HEIGHT 48 |
#define | STATUS_SPACE 4 |
#define | STATUS_START 110 |
#define | STATUS_TOP 8 |
#define | STATUS_WIDTH 48 |
Enumerations | |
enum | butstate |
Functions | |
static void | clear (void) |
static void | draw_pixmap (char *logo, size_t size, sysarg_t x, sysarg_t y) |
Draw a PPM pixmap to framebuffer. | |
void | gcons_change_console (size_t index) |
Notification run on changing console (except kernel console). | |
static int | gcons_find_conbut (sysarg_t x, sysarg_t y) |
void | gcons_in_kernel (void) |
Change to kernel console. | |
void | gcons_init (int phone) |
Initialize nice graphical console environment. | |
int | gcons_mouse_btn (bool state) |
Handle mouse click. | |
void | gcons_mouse_move (ssize_t dx, ssize_t dy) |
Handle mouse move. | |
void | gcons_notify_char (size_t index) |
Notification function that gets called on new output to virtual console. | |
void | gcons_notify_connect (size_t index) |
Notification function called on console connect. | |
void | gcons_notify_disconnect (size_t index) |
Notification function called on service disconnect from console. | |
void | gcons_redraw_console (void) |
Redraws console graphics. | |
static ssize_t | limit (ssize_t a, ssize_t left, ssize_t right) |
Return x, where left <= x <= right && |a-x| == min(|a-x|) is smallest. | |
static void | make_anim (void) |
static int | make_pixmap (char *data, size_t size) |
Creates a pixmap on framebuffer. | |
static void | redraw_state (size_t index) |
Redraw the button showing state of a given console. | |
static void | set_rgb_color (uint32_t fgcolor, uint32_t bgcolor) |
static void | tran_putch (wchar_t ch, sysarg_t col, sysarg_t row) |
Transparent putchar. | |
static int | vp_create (sysarg_t x, sysarg_t y, sysarg_t width, sysarg_t height) |
Create view port. | |
static void | vp_switch (int vp) |
Variables | |
static size_t | active_console = 0 |
static int | animation = -1 |
static bool | btn_pressed = false |
static sysarg_t | btn_x = 0 |
static sysarg_t | btn_y = 0 |
static enum butstate | console_state [CONSOLE_COUNT] |
static int | console_vp |
static int | cstatus_vp [CONSOLE_COUNT] |
static int | fbphone |
static int | ic_pixmaps [CONS_LAST] = {-1, -1, -1, -1, -1, -1} |
List of pixmaps identifying these icons. | |
static sysarg_t | mouse_x = 0 |
static sysarg_t | mouse_y = 0 |
static bool | use_gcons = false |
static sysarg_t | xres |
static sysarg_t | yres |
Definition in file gcons.c.