mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 00:56:10 +00:00 
			
		
		
		
	Do not need to work out status line offset, we already have it.
This commit is contained in:
		
							
								
								
									
										13
									
								
								tty.c
									
									
									
									
									
								
							
							
						
						
									
										13
									
								
								tty.c
									
									
									
									
									
								
							@@ -963,21 +963,16 @@ tty_redraw_region(struct tty *tty, const struct tty_ctx *ctx)
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
/* Is this position visible in the pane? */
 | 
					/* Is this position visible in the pane? */
 | 
				
			||||||
static int
 | 
					static int
 | 
				
			||||||
tty_is_visible(struct tty *tty, const struct tty_ctx *ctx, u_int px, u_int py,
 | 
					tty_is_visible(__unused struct tty *tty, const struct tty_ctx *ctx, u_int px,
 | 
				
			||||||
    u_int nx, u_int ny)
 | 
					    u_int py, u_int nx, u_int ny)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	u_int	xoff = ctx->xoff + px, yoff = ctx->yoff + py, lines;
 | 
						u_int	xoff = ctx->rxoff + px, yoff = ctx->ryoff + py;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (!ctx->bigger)
 | 
						if (!ctx->bigger)
 | 
				
			||||||
		return (1);
 | 
							return (1);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (status_at_line(tty->client) == 0)
 | 
					 | 
				
			||||||
		lines = status_line_size(tty->client);
 | 
					 | 
				
			||||||
	else
 | 
					 | 
				
			||||||
		lines = 0;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	if (xoff + nx <= ctx->wox || xoff >= ctx->wox + ctx->wsx ||
 | 
						if (xoff + nx <= ctx->wox || xoff >= ctx->wox + ctx->wsx ||
 | 
				
			||||||
	    yoff + ny <= ctx->woy || yoff >= lines + ctx->woy + ctx->wsy)
 | 
						    yoff + ny <= ctx->woy || yoff >= ctx->woy + ctx->wsy)
 | 
				
			||||||
		return (0);
 | 
							return (0);
 | 
				
			||||||
	return (1);
 | 
						return (1);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user