mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 00:56:10 +00:00 
			
		
		
		
	Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw and init_ctx callbacks - use the palette if the option value is default. Allows application-set fg and bg to work in panes again.
This commit is contained in:
		@@ -184,8 +184,10 @@ screen_write_initctx(struct screen_write_ctx *ctx, struct tty_ctx *ttyctx,
 | 
			
		||||
	if (ctx->init_ctx_cb != NULL) {
 | 
			
		||||
		ctx->init_ctx_cb(ctx, ttyctx);
 | 
			
		||||
		if (ttyctx->palette != NULL) {
 | 
			
		||||
			ttyctx->defaults.fg = ttyctx->palette->fg;
 | 
			
		||||
			ttyctx->defaults.bg = ttyctx->palette->bg;
 | 
			
		||||
			if (COLOUR_DEFAULT(ttyctx->defaults.fg))
 | 
			
		||||
				ttyctx->defaults.fg = ttyctx->palette->fg;
 | 
			
		||||
			if (COLOUR_DEFAULT(ttyctx->defaults.bg))
 | 
			
		||||
				ttyctx->defaults.bg = ttyctx->palette->bg;
 | 
			
		||||
		}
 | 
			
		||||
	} else {
 | 
			
		||||
		ttyctx->redraw_cb = screen_write_redraw_cb;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user