src/pspg.c
static int
adjust_first_row(int _first_row, DataDesc *desc, ScrDesc *scrdesc)
{
	int		max_first_row;

	if (_first_row < 0)
		_first_row = 0;

	/*
	 * When header line is invisible, then visible area is one row
	 * bigger, and then first row should be lower.
	 */
	max_first_row = desc->last_row - desc->title_rows - scrdesc->main_maxy + 1 - fix_hide_header_line;
	max_first_row = max_first_row < 0 ? 0 : max_first_row;

	return _first_row > max_first_row ? max_first_row : _first_row;
}
/*
 * Ensure so first_row is in correct range
 */
Ensure so first_row is in correct range
Ensure so first_row is in correct range
static int
adjust_first_row(int _first_row, DataDesc *desc, ScrDesc *scrdesc)
{
	int		max_first_row;
	if (_first_row < 0)
		_first_row = 0;
	max_first_row = desc->last_row - desc->title_rows - scrdesc->main_maxy + 1 - fix_hide_header_line;
	max_first_row = max_first_row < 0 ? 0 : max_first_row;
	return _first_row > max_first_row ? max_first_row : _first_row;
}
static int adjust_first_row ( int _first_row , DataDesc * desc , ScrDesc * scrdesc ) { int max_first_row ; if ( _first_row < 0 ) _first_row = 0 ; max_first_row = desc -> last_row - desc -> title_rows - scrdesc -> main_maxy + 1 - fix_hide_header_line ; max_first_row = max_first_row < 0 ? 0 : max_first_row ; return _first_row > max_first_row ? max_first_row : _first_row ; }
Ensure so first_row is in correct range
Ensure so first_row is in correct range
/*
	 * When header line is invisible, then visible area is one row
	 * bigger, and then first row should be lower.
	 */