1
0
mirror of https://github.com/rfivet/uemacs.git synced 2024-12-24 01:56:26 -05:00

Increase maximum virtual terminal size.

This commit is contained in:
Renaud 2017-06-01 08:05:59 +08:00
parent 35f2184253
commit 57363dcb19
3 changed files with 8 additions and 11 deletions

View File

@ -20,11 +20,6 @@
#define CTLX 0x04000000 /* ^X flag, or'ed in */ #define CTLX 0x04000000 /* ^X flag, or'ed in */
#define SPEC 0x08000000 /* special key (function keys) */ #define SPEC 0x08000000 /* special key (function keys) */
/* Actual 380x134 on a 1920x1080 screen in landscape,
if smaller font or portrait orientation limit to 400x150 */
#define MAXCOL 400
#define MAXROW 150
#endif #endif
/* end of defines.h */ /* end of defines.h */

7
tcap.c
View File

@ -156,17 +156,12 @@ static void tcapopen(void)
fputs( "Termcap entry incomplete (columns)\n", stderr) ; fputs( "Termcap entry incomplete (columns)\n", stderr) ;
exit( EXIT_FAILURE) ; exit( EXIT_FAILURE) ;
} }
#ifdef SIGWINCH
/* At initialization we use maximum size even if current OS window is smaller */
term.t_mrow = int_row < MAXROW ? int_row : MAXROW ; term.t_mrow = int_row < MAXROW ? int_row : MAXROW ;
term.t_nrow = term.t_mrow - 1 ; term.t_nrow = term.t_mrow - 1 ;
term.t_mcol = int_col < MAXCOL ? int_col : MAXCOL ; term.t_mcol = int_col < MAXCOL ? int_col : MAXCOL ;
term.t_ncol = term.t_mcol ; term.t_ncol = term.t_mcol ;
#else
term.t_mrow = term.t_nrow > MAXROW ? MAXROW : term.t_nrow;
term.t_mcol = term.t_ncol > MAXCOL ? MAXCOL : term.t_ncol;
#endif
p = tcapbuf; p = tcapbuf;
t = tgetstr("pc", &p); t = tgetstr("pc", &p);
if (t) if (t)

View File

@ -6,6 +6,13 @@
#include "retcode.h" #include "retcode.h"
#include "utf8.h" #include "utf8.h"
/* Actual 471x175 on a 1920x1080 screen in landscape,
if smaller font or portrait orientation limit to 500x200 */
#define MAXCOL 500
#define MAXROW 200
/* /*
* The editor communicates with the display using a high level interface. A * The editor communicates with the display using a high level interface. A
* "TERM" structure holds useful variables, and indirect pointers to routines * "TERM" structure holds useful variables, and indirect pointers to routines