mirror of
				https://github.com/godotengine/godot.git
				synced 2025-10-31 13:41:03 +00:00 
			
		
		
		
	Improve appearance of the editor Debugger bottom panel menu
- Make the Debugger bottom panel menu more prominent when there are errors or warnings by adjusting the text color. - Add some spacing to the right of the error/warning icon for better visual appearance.
This commit is contained in:
		
							parent
							
								
									435d50bf0f
								
							
						
					
					
						commit
						bb681ef9f2
					
				
					 2 changed files with 8 additions and 0 deletions
				
			
		|  | @ -265,15 +265,20 @@ void EditorDebuggerNode::_notification(int p_what) { | |||
| 
 | ||||
| 		if (error_count == 0 && warning_count == 0) { | ||||
| 			debugger_button->set_text(TTR("Debugger")); | ||||
| 			debugger_button->remove_theme_color_override("font_color"); | ||||
| 			debugger_button->set_icon(Ref<Texture2D>()); | ||||
| 		} else { | ||||
| 			debugger_button->set_text(TTR("Debugger") + " (" + itos(error_count + warning_count) + ")"); | ||||
| 			if (error_count >= 1 && warning_count >= 1) { | ||||
| 				debugger_button->set_icon(get_theme_icon(SNAME("ErrorWarning"), SNAME("EditorIcons"))); | ||||
| 				// Use error color to represent the highest level of severity reported.
 | ||||
| 				debugger_button->add_theme_color_override("font_color", get_theme_color(SNAME("error_color"), SNAME("Editor"))); | ||||
| 			} else if (error_count >= 1) { | ||||
| 				debugger_button->set_icon(get_theme_icon(SNAME("Error"), SNAME("EditorIcons"))); | ||||
| 				debugger_button->add_theme_color_override("font_color", get_theme_color(SNAME("error_color"), SNAME("Editor"))); | ||||
| 			} else { | ||||
| 				debugger_button->set_icon(get_theme_icon(SNAME("Warning"), SNAME("EditorIcons"))); | ||||
| 				debugger_button->add_theme_color_override("font_color", get_theme_color(SNAME("warning_color"), SNAME("Editor"))); | ||||
| 			} | ||||
| 		} | ||||
| 		last_error_count = error_count; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Hugo Locurcio
						Hugo Locurcio