Merge branch 'more_verbose_error_messages' of https://github.com/Luflosi/kitty

This commit is contained in:
Kovid Goyal 2019-02-26 08:04:13 +05:30
commit 1c9d6bf9e6
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -406,10 +406,10 @@ calc_cell_metrics(FontGroup *fg) {
if (ch >= MIN_HEIGHT && ch <= MAX_DIM) cell_height = ch; if (ch >= MIN_HEIGHT && ch <= MAX_DIM) cell_height = ch;
else log_error("Cell height invalid after adjustment, ignoring adjust_line_height"); else log_error("Cell height invalid after adjustment, ignoring adjust_line_height");
int line_height_adjustment = cell_height - before_cell_height; int line_height_adjustment = cell_height - before_cell_height;
if (cell_height < MIN_HEIGHT) fatal("Line height too small"); if (cell_height < MIN_HEIGHT) fatal("Line height too small: %u", cell_height);
if (cell_height > MAX_DIM) fatal("Line height too large"); if (cell_height > MAX_DIM) fatal("Line height too large: %u", cell_height);
if (cell_width < MIN_WIDTH) fatal("Cell width too small"); if (cell_width < MIN_WIDTH) fatal("Cell width too small: %u", cell_width);
if (cell_width > MAX_DIM) fatal("Cell width too large"); if (cell_width > MAX_DIM) fatal("Cell width too large: %u", cell_width);
#undef MIN_WIDTH #undef MIN_WIDTH
#undef MIN_HEIGHT #undef MIN_HEIGHT
#undef MAX_DIM #undef MAX_DIM