| 3 |
* screen |
* screen |
| 4 |
* - advanced telnet-based user interactive input / output features |
* - advanced telnet-based user interactive input / output features |
| 5 |
* |
* |
| 6 |
* Copyright (C) 2004-2025 by Leaflet <leaflet@leafok.com> |
* Copyright (C) 2004-2025 Leaflet <leaflet@leafok.com> |
| 7 |
*/ |
*/ |
| 8 |
|
|
| 9 |
#ifndef _SCREEN_H_ |
#ifndef _SCREEN_H_ |
| 10 |
#define _SCREEN_H_ |
#define _SCREEN_H_ |
| 11 |
|
|
| 12 |
|
#include "io.h" |
| 13 |
#include <stddef.h> |
#include <stddef.h> |
| 14 |
|
|
| 15 |
#define CTRL_SEQ_CLR_LINE "\033[K" |
extern const char CTRL_SEQ_CLR_LINE[]; |
| 16 |
#define MSG_EXT_MAX_LEN 400 |
|
| 17 |
|
enum display_constant_t |
| 18 |
|
{ |
| 19 |
|
MSG_EXT_MAX_LEN = 400, |
| 20 |
|
}; |
| 21 |
|
|
| 22 |
struct display_ctx_t |
struct display_ctx_t |
| 23 |
{ |
{ |
| 42 |
|
|
| 43 |
extern void set_input_echo(int echo); |
extern void set_input_echo(int echo); |
| 44 |
|
|
| 45 |
extern int str_input(char *buffer, int buffer_length, int echo_mode); |
extern int str_input(char *buffer, int buffer_length, enum io_echo_t echo_mode); |
| 46 |
extern int get_data(int row, int col, char *prompt, char *buffer, int buffer_length, int max_display_len); |
extern int get_data(int row, int col, char *prompt, char *buffer, int buffer_length, int max_display_len); |
| 47 |
|
|
| 48 |
// eof_exit = 0 : Do not exit at EOF |
// eof_exit = 0 : Do not exit at EOF |