Repository: godotengine/godot
File: editor/themes/theme_modern.cpp (C++)

Code before:
		const Color readonly_warning_color = p_config.error_color.lerp(p_config.dark_icon_and_font ? Color(0, 0, 0) : Color(1, 1, 1), 0.25);

		p_theme->set_color("property_color", "EditorProperty", p_config.font_color);
		p_theme->set_color("readonly_color", "EditorProperty", readonly_color);
		p_theme->set_color("warning_color", "EditorProperty", p_config.warning_color);
		p_theme->set_color("readonly_warning_color", "EditorProperty", readonly_warning_color);

		Ref<StyleBoxFlat> style_property_group_note = p_config.base_style->duplicate();
		Color property_group_note_color = p_config.accent_color;
		property_group_note_color.a = 0.1;
		style_property_group_note->set_bg_color(property_group_note_color);
		p_theme->set_stylebox("bg_group_note", "EditorProperty", style_property_group_note);

		// EditorInspectorSection.

		Color inspector_section_color = p_config.font_color.lerp(Color(0.5, 0.5, 0.5), 0.35);
		p_theme->set_color(SceneStringName(font_color), "EditorInspectorSection", inspector_section_color);

		Color inspector_indent_color = p_config.accent_color;
		inspector_indent_color.a = 0.2;
		Ref<StyleBoxFlat> inspector_indent_style = EditorThemeManager::make_flat_stylebox(inspector_indent_color, 2.0 * EDSCALE, 0, 2.0 * EDSCALE, 0);
		p_theme->set_stylebox("indent_box", "EditorInspectorSection", inspector_indent_style);
		p_theme->set_constant("indent_size", "EditorInspectorSection", 6.0 * EDSCALE);
		p_theme->set_constant("h_separation", "EditorInspectorSection", p_config.base_margin * EDSCALE);

		Color prop_subsection_round_color = p_config.dark_color_1.lerp(p_config.mono_color_icon_and_font, p_config.dark_icon_and_font ? 0.09 : 0.16);
		p_theme->set_color("prop_subsection_round", EditorStringName(Editor), prop_subsection_round_color);

		Ref<StyleBoxFlat> style_highlight_subsection = p_config.base_style->duplicate();
		style_highlight_subsection->set_bg_color(prop_subsection_round_color);
		style_highlight_subsection->set_corner_radius_all(p_config.corner_radius * EDSCALE);
		p_theme->set_stylebox("style_highlight_subsection", EditorStringName(Editor), style_highlight_subsection);

		p_theme->set_color("prop_subsection", EditorStringName(Editor), Color(1, 1, 1, 0));
#ifndef DISABLE_DEPRECATED // Used before 4.3.
		p_theme->set_color("property_color", EditorStringName(Editor), p_config.dark_color_1.lerp(p_config.mono_color_icon_and_font, 0.12));
#endif

		// EditorInspectorCategory.

		Ref<StyleBoxFlat> category_bg = p_config.base_style->duplicate();
		category_bg->set_bg_color(p_config.surface_high_color);
		category_bg->set_content_margin_individual(0, p_config.base_margin * EDSCALE, 0, p_config.base_margin * EDSCALE);
		if (p_config.draw_extra_borders) {
			category_bg->set_border_width_all(1);
			category_bg->set_border_color(p_config.extra_border_color_2);
		}
		p_theme->set_stylebox("bg", "EditorInspectorCategory", category_bg);

		p_theme->set_constant("inspector_margin", EditorStringName(Editor), 12 * EDSCALE);


Review comment (suggestion):
as a heads up, `mono_color_icon_and_font` is getting renamed to `mono_color_font` in https://github.com/godotengine/godot/pull/112277 so this will be a merge conflict and one of the PRs will need a rebase

Code after:

		const Color property_color = p_config.font_color.lerp(Color(0.5, 0.5, 0.5), 0.5);
		const Color readonly_color = property_color.lerp(p_config.dark_icon_and_font ? Color(0, 0, 0) : Color(1, 1, 1), 0.25);
		const Color readonly_warning_color = p_config.error_color.lerp(p_config.dark_icon_and_font ? Color(0, 0, 0) : Color(1, 1, 1), 0.25);

		p_theme->set_color("property_color", "EditorProperty", p_config.font_color);
		p_theme->set_color("readonly_color", "EditorProperty", readonly_color);
		p_theme->set_color("warning_color", "EditorProperty", p_config.warning_color);
		p_theme->set_color("readonly_warning_color", "EditorProperty", readonly_warning_color);

		Ref<StyleBoxFlat> style_property_group_note = p_config.base_style->duplicate();
		Color property_group_note_color = p_config.accent_color;
		property_group_note_color.a = 0.1;
		style_property_group_note->set_bg_color(property_group_note_color);
		p_theme->set_stylebox("bg_group_note", "EditorProperty", style_property_group_note);

		// EditorInspectorSection.

		Color inspector_section_color = p_config.font_color.lerp(Color(0.5, 0.5, 0.5), 0.35);
		p_theme->set_color(SceneStringName(font_color), "EditorInspectorSection", inspector_section_color);

		Color inspector_indent_color = p_config.accent_color;
		inspector_indent_color.a = 0.2;
		Ref<StyleBoxFlat> inspector_indent_style = EditorThemeManager::make_flat_stylebox(inspector_indent_color, 2.0 * EDSCALE, 0, 2.0 * EDSCALE, 0);
		p_theme->set_stylebox("indent_box", "EditorInspectorSection", inspector_indent_style);
		p_theme->set_constant("indent_size", "EditorInspectorSection", 6.0 * EDSCALE);
		p_theme->set_constant("h_separation", "EditorInspectorSection", p_config.base_margin * EDSCALE);

		Color prop_subsection_stylebox_color = p_config.dark_color_1.lerp(p_config.mono_color_font, p_config.dark_icon_and_font ? 0.09 : 0.16);
		p_theme->set_color("prop_subsection_stylebox", EditorStringName(Editor), prop_subsection_stylebox_color);

		Ref<StyleBoxFlat> style_highlight_subsection = p_config.base_style->duplicate();
		style_highlight_subsection->set_bg_color(prop_subsection_stylebox_color);
		style_highlight_subsection->set_corner_radius_all(p_config.corner_radius * EDSCALE);
		p_theme->set_stylebox("style_highlight_subsection", EditorStringName(Editor), style_highlight_subsection);

		p_theme->set_color("prop_subsection", EditorStringName(Editor), Color(1, 1, 1, 0));
#ifndef DISABLE_DEPRECATED // Used before 4.3.
		p_theme->set_color("property_color", EditorStringName(Editor), p_config.dark_color_1.lerp(p_config.mono_color_font, 0.12));
#endif

		// EditorInspectorCategory.

		Ref<StyleBoxFlat> category_bg = p_config.base_style->duplicate();
		category_bg->set_bg_color(p_config.surface_high_color);
		category_bg->set_content_margin_individual(0, p_config.base_margin * EDSCALE, 0, p_config.base_margin * EDSCALE);
		if (p_config.draw_extra_borders) {
			category_bg->set_border_width_all(1);
			category_bg->set_border_color(p_config.extra_border_color_2);
		}
		p_theme->set_stylebox("bg", "EditorInspectorCategory", category_bg);