1
0
mirror of https://github.com/rfivet/uemacs.git synced 2024-11-15 17:16:48 -05:00

Adjust MAXROW/MAXCOL to values aligned with 1920x1080 landscape resolution. If smaller font or portrait, limit to 400x150 (colxrow).

This commit is contained in:
Renaud 2015-01-05 16:54:21 +08:00
parent 48ea9279a6
commit e096092d5b
2 changed files with 9 additions and 2 deletions

View File

@ -14,5 +14,7 @@
#define CTLX 0x40000000 /* ^X flag, or'ed in */ #define CTLX 0x40000000 /* ^X flag, or'ed in */
#define SPEC 0x80000000 /* special key (function keys) */ #define SPEC 0x80000000 /* special key (function keys) */
#define MAXCOL 500 /* Actual 380x134 on a 1920x1080 screen in landscape,
#define MAXROW 500 if smaller font or portrait orientation limit to 400x150 */
#define MAXCOL 400
#define MAXROW 150

5
tcap.c
View File

@ -164,6 +164,11 @@ static void tcapopen(void)
/* At initialization we use maximum size even if current OS window is smaller */ /* At initialization we use maximum size even if current OS window is smaller */
term.t_mrow = MAXROW ; term.t_mrow = MAXROW ;
term.t_mcol = MAXCOL ; term.t_mcol = MAXCOL ;
if( term.t_nrow >= term.t_mrow)
term.t_nrow = term.t_mrow - 1 ;
if( term.t_ncol > term.t_mcol)
term.t_ncol = term.t_mcol ;
#else #else
term.t_mrow = term.t_nrow > MAXROW ? MAXROW : term.t_nrow; term.t_mrow = term.t_nrow > MAXROW ? MAXROW : term.t_nrow;
term.t_mcol = term.t_ncol > MAXCOL ? MAXCOL : term.t_ncol; term.t_mcol = term.t_ncol > MAXCOL ? MAXCOL : term.t_ncol;