mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 09:26:05 +00:00 
			
		
		
		
	Draw command prompt correctly with status line off.
This commit is contained in:
		
							
								
								
									
										10
									
								
								status.c
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								status.c
									
									
									
									
									
								
							@@ -659,9 +659,10 @@ status_message_redraw(struct client *c)
 | 
			
		||||
	memcpy(&old_status, &c->status, sizeof old_status);
 | 
			
		||||
 | 
			
		||||
	lines = status_line_size(c->session);
 | 
			
		||||
	if (lines <= 1)
 | 
			
		||||
	if (lines <= 1) {
 | 
			
		||||
		lines = 1;
 | 
			
		||||
		screen_init(&c->status, c->tty.sx, 1, 0);
 | 
			
		||||
	else
 | 
			
		||||
	} else
 | 
			
		||||
		screen_init(&c->status, c->tty.sx, lines, 0);
 | 
			
		||||
 | 
			
		||||
	len = screen_write_strlen("%s", c->message_string);
 | 
			
		||||
@@ -811,9 +812,10 @@ status_prompt_redraw(struct client *c)
 | 
			
		||||
	memcpy(&old_status, &c->status, sizeof old_status);
 | 
			
		||||
 | 
			
		||||
	lines = status_line_size(c->session);
 | 
			
		||||
	if (lines <= 1)
 | 
			
		||||
	if (lines <= 1) {
 | 
			
		||||
		lines = 1;
 | 
			
		||||
		screen_init(&c->status, c->tty.sx, 1, 0);
 | 
			
		||||
	else
 | 
			
		||||
	} else
 | 
			
		||||
		screen_init(&c->status, c->tty.sx, lines, 0);
 | 
			
		||||
 | 
			
		||||
	len = screen_write_strlen("%s", c->prompt_string);
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user