diff --git a/I18N Commander/App/scenes/BtnIcon.tscn b/I18N Commander/App/scenes/BtnIcon.tscn index b69a718..0568aad 100644 --- a/I18N Commander/App/scenes/BtnIcon.tscn +++ b/I18N Commander/App/scenes/BtnIcon.tscn @@ -1,22 +1,16 @@ -[gd_scene load_steps=2 format=3 uid="uid://d0x0yv7nevod7"] +[gd_scene load_steps=3 format=3 uid="uid://d0x0yv7nevod7"] [ext_resource type="Script" path="res://scenes/BtnIcon.cs" id="1_b787p"] +[ext_resource type="Theme" uid="uid://uqhultm05f5a" path="res://theme/ui_theme.tres" id="2_8n123"] -[node name="btn_icon" type="Control"] -layout_mode = 3 -anchors_preset = 15 -anchor_right = 1.0 -anchor_bottom = 1.0 -grow_horizontal = 2 -grow_vertical = 2 +[node name="btn_icon" type="MarginContainer"] +theme_override_constants/margin_left = 6 +theme_override_constants/margin_top = 6 +theme_override_constants/margin_right = 6 +theme_override_constants/margin_bottom = 6 script = ExtResource("1_b787p") -[node name="margin" type="MarginContainer" parent="."] -layout_mode = 0 -offset_right = 40.0 -offset_bottom = 40.0 - -[node name="btn" type="Button" parent="margin"] +[node name="btn" type="Button" parent="."] unique_name_in_owner = true layout_mode = 2 -theme_override_constants/h_separation = 6 +theme = ExtResource("2_8n123") diff --git a/I18N Commander/App/theme/ui_style_box_flat_focus.tres b/I18N Commander/App/theme/ui_style_box_flat_focus.tres new file mode 100644 index 0000000..b56bc6e --- /dev/null +++ b/I18N Commander/App/theme/ui_style_box_flat_focus.tres @@ -0,0 +1,21 @@ +[gd_resource type="StyleBoxFlat" format=3 uid="uid://chaurklijlgu7"] + +[resource] +content_margin_left = 16.0 +content_margin_top = 16.0 +content_margin_right = 16.0 +content_margin_bottom = 16.0 +bg_color = Color(0.309804, 0.309804, 0.309804, 1) +skew = Vector2(2.08165e-12, 2.08165e-12) +border_width_left = 4 +border_width_top = 4 +border_width_right = 4 +border_width_bottom = 4 +border_color = Color(0.0509804, 0.0509804, 0.0509804, 1) +border_blend = true +corner_radius_top_left = 6 +corner_radius_top_right = 6 +corner_radius_bottom_right = 6 +corner_radius_bottom_left = 6 +shadow_size = 2 +shadow_offset = Vector2(1, 1) diff --git a/I18N Commander/App/theme/ui_style_box_flat_hover.tres b/I18N Commander/App/theme/ui_style_box_flat_hover.tres new file mode 100644 index 0000000..0bda853 --- /dev/null +++ b/I18N Commander/App/theme/ui_style_box_flat_hover.tres @@ -0,0 +1,21 @@ +[gd_resource type="StyleBoxFlat" format=3 uid="uid://l1tjpnljc6c1"] + +[resource] +content_margin_left = 16.0 +content_margin_top = 16.0 +content_margin_right = 16.0 +content_margin_bottom = 16.0 +bg_color = Color(0.309804, 0.309804, 0.309804, 1) +skew = Vector2(2.08165e-12, 2.08165e-12) +border_width_left = 3 +border_width_top = 3 +border_width_right = 3 +border_width_bottom = 3 +border_color = Color(0.0509804, 0.0509804, 0.0509804, 1) +border_blend = true +corner_radius_top_left = 6 +corner_radius_top_right = 6 +corner_radius_bottom_right = 6 +corner_radius_bottom_left = 6 +shadow_size = 2 +shadow_offset = Vector2(1, 1) diff --git a/I18N Commander/App/theme/ui_style_box_flat_norm.tres b/I18N Commander/App/theme/ui_style_box_flat_norm.tres new file mode 100644 index 0000000..c05aedb --- /dev/null +++ b/I18N Commander/App/theme/ui_style_box_flat_norm.tres @@ -0,0 +1,19 @@ +[gd_resource type="StyleBoxFlat" format=3 uid="uid://tj810ebe65el"] + +[resource] +content_margin_left = 16.0 +content_margin_top = 16.0 +content_margin_right = 16.0 +content_margin_bottom = 16.0 +bg_color = Color(0.239216, 0.239216, 0.239216, 1) +skew = Vector2(2.08165e-12, 2.08165e-12) +border_width_left = 2 +border_width_top = 2 +border_width_right = 2 +border_width_bottom = 2 +border_color = Color(0, 0, 0, 1) +border_blend = true +corner_radius_top_left = 6 +corner_radius_top_right = 6 +corner_radius_bottom_right = 6 +corner_radius_bottom_left = 6 diff --git a/I18N Commander/App/theme/ui_style_box_flat_press.tres b/I18N Commander/App/theme/ui_style_box_flat_press.tres new file mode 100644 index 0000000..e0f22dd --- /dev/null +++ b/I18N Commander/App/theme/ui_style_box_flat_press.tres @@ -0,0 +1,21 @@ +[gd_resource type="StyleBoxFlat" format=3 uid="uid://he0mxms4j1q7"] + +[resource] +content_margin_left = 16.0 +content_margin_top = 16.0 +content_margin_right = 16.0 +content_margin_bottom = 16.0 +bg_color = Color(0.4, 0.4, 0.4, 1) +skew = Vector2(2.08165e-12, 2.08165e-12) +border_width_left = 3 +border_width_top = 3 +border_width_right = 3 +border_width_bottom = 3 +border_color = Color(0.380392, 0.380392, 0.380392, 1) +border_blend = true +corner_radius_top_left = 6 +corner_radius_top_right = 6 +corner_radius_bottom_right = 6 +corner_radius_bottom_left = 6 +shadow_size = 2 +shadow_offset = Vector2(1, 1) diff --git a/I18N Commander/App/theme/ui_theme.tres b/I18N Commander/App/theme/ui_theme.tres new file mode 100644 index 0000000..3f1da31 --- /dev/null +++ b/I18N Commander/App/theme/ui_theme.tres @@ -0,0 +1,13 @@ +[gd_resource type="Theme" load_steps=5 format=3 uid="uid://uqhultm05f5a"] + +[ext_resource type="StyleBox" uid="uid://chaurklijlgu7" path="res://theme/ui_style_box_flat_focus.tres" id="1_6cjme"] +[ext_resource type="StyleBox" uid="uid://l1tjpnljc6c1" path="res://theme/ui_style_box_flat_hover.tres" id="2_p66gj"] +[ext_resource type="StyleBox" uid="uid://tj810ebe65el" path="res://theme/ui_style_box_flat_norm.tres" id="3_fp785"] +[ext_resource type="StyleBox" uid="uid://he0mxms4j1q7" path="res://theme/ui_style_box_flat_press.tres" id="4_o3616"] + +[resource] +Button/constants/h_separation = 6 +Button/styles/focus = ExtResource("1_6cjme") +Button/styles/hover = ExtResource("2_p66gj") +Button/styles/normal = ExtResource("3_fp785") +Button/styles/pressed = ExtResource("4_o3616")