Skip to content

Commit 0a60d1b

Browse files
authored
Updated icons to use SVG when possible (contributed by williamchange)
2 parents 70ba7b6 + 469e799 commit 0a60d1b

40 files changed

Lines changed: 319 additions & 631 deletions
Lines changed: 9 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,18 @@
11
[remap]
22

3-
importer="texture"
4-
type="CompressedTexture2D"
5-
uid="uid://c2ljin3axj2sd"
6-
path="res://.godot/imported/arrow.svg-e1254f39413b91d100a308431d762230.ctex"
7-
metadata={
8-
"vram_texture": false
9-
}
3+
importer="svg"
4+
type="DPITexture"
5+
uid="uid://7ydi1c1ic17e"
6+
path="res://.godot/imported/arrow.svg-e1254f39413b91d100a308431d762230.dpitex"
107

118
[deps]
129

1310
source_file="res://addons/flexible_layout/arrow.svg"
14-
dest_files=["res://.godot/imported/arrow.svg-e1254f39413b91d100a308431d762230.ctex"]
11+
dest_files=["res://.godot/imported/arrow.svg-e1254f39413b91d100a308431d762230.dpitex"]
1512

1613
[params]
1714

18-
compress/mode=0
19-
compress/high_quality=false
20-
compress/lossy_quality=0.7
21-
compress/uastc_level=0
22-
compress/rdo_quality_loss=0.0
23-
compress/hdr_compression=1
24-
compress/normal_map=0
25-
compress/channel_pack=0
26-
mipmaps/generate=false
27-
mipmaps/limit=-1
28-
roughness/mode=0
29-
roughness/src_normal=""
30-
process/channel_remap/red=0
31-
process/channel_remap/green=1
32-
process/channel_remap/blue=2
33-
process/channel_remap/alpha=3
34-
process/fix_alpha_border=true
35-
process/premult_alpha=false
36-
process/normal_map_invert_y=false
37-
process/hdr_as_srgb=false
38-
process/hdr_clamp_exposure=false
39-
process/size_limit=0
40-
detect_3d/compress_to=1
41-
svg/scale=1.0
42-
editor/scale_with_editor_scale=false
43-
editor/convert_colors_with_editor_theme=false
15+
base_scale=1.0
16+
saturation=1.0
17+
color_map={}
18+
compress=true
Lines changed: 9 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,18 @@
11
[remap]
22

3-
importer="texture"
4-
type="CompressedTexture2D"
5-
uid="uid://bja65j8x1jrvj"
6-
path="res://.godot/imported/tab.svg-ccf47035ab2d2b2098f3b421c7a32000.ctex"
7-
metadata={
8-
"vram_texture": false
9-
}
3+
importer="svg"
4+
type="DPITexture"
5+
uid="uid://dqdyudofmmv61"
6+
path="res://.godot/imported/tab.svg-ccf47035ab2d2b2098f3b421c7a32000.dpitex"
107

118
[deps]
129

1310
source_file="res://addons/flexible_layout/tab.svg"
14-
dest_files=["res://.godot/imported/tab.svg-ccf47035ab2d2b2098f3b421c7a32000.ctex"]
11+
dest_files=["res://.godot/imported/tab.svg-ccf47035ab2d2b2098f3b421c7a32000.dpitex"]
1512

1613
[params]
1714

18-
compress/mode=0
19-
compress/high_quality=false
20-
compress/lossy_quality=0.7
21-
compress/uastc_level=0
22-
compress/rdo_quality_loss=0.0
23-
compress/hdr_compression=1
24-
compress/normal_map=0
25-
compress/channel_pack=0
26-
mipmaps/generate=false
27-
mipmaps/limit=-1
28-
roughness/mode=0
29-
roughness/src_normal=""
30-
process/channel_remap/red=0
31-
process/channel_remap/green=1
32-
process/channel_remap/blue=2
33-
process/channel_remap/alpha=3
34-
process/fix_alpha_border=true
35-
process/premult_alpha=false
36-
process/normal_map_invert_y=false
37-
process/hdr_as_srgb=false
38-
process/hdr_clamp_exposure=false
39-
process/size_limit=0
40-
detect_3d/compress_to=1
41-
svg/scale=1.0
42-
editor/scale_with_editor_scale=false
43-
editor/convert_colors_with_editor_theme=false
15+
base_scale=1.0
16+
saturation=1.0
17+
color_map={}
18+
compress=true
Lines changed: 9 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,18 @@
11
[remap]
22

3-
importer="texture"
4-
type="CompressedTexture2D"
5-
uid="uid://cfugy4gny4tfh"
6-
path="res://.godot/imported/godot_logo.svg-4b89d8bf8533de4522d0f7d92c0a0af4.ctex"
7-
metadata={
8-
"vram_texture": false
9-
}
3+
importer="svg"
4+
type="DPITexture"
5+
uid="uid://bc6or0m45wo0f"
6+
path="res://.godot/imported/godot_logo.svg-4b89d8bf8533de4522d0f7d92c0a0af4.dpitex"
107

118
[deps]
129

1310
source_file="res://material_maker/icons/godot_logo.svg"
14-
dest_files=["res://.godot/imported/godot_logo.svg-4b89d8bf8533de4522d0f7d92c0a0af4.ctex"]
11+
dest_files=["res://.godot/imported/godot_logo.svg-4b89d8bf8533de4522d0f7d92c0a0af4.dpitex"]
1512

1613
[params]
1714

18-
compress/mode=0
19-
compress/high_quality=false
20-
compress/lossy_quality=0.7
21-
compress/uastc_level=0
22-
compress/rdo_quality_loss=0.0
23-
compress/hdr_compression=1
24-
compress/normal_map=0
25-
compress/channel_pack=0
26-
mipmaps/generate=false
27-
mipmaps/limit=-1
28-
roughness/mode=0
29-
roughness/src_normal=""
30-
process/channel_remap/red=0
31-
process/channel_remap/green=1
32-
process/channel_remap/blue=2
33-
process/channel_remap/alpha=3
34-
process/fix_alpha_border=true
35-
process/premult_alpha=false
36-
process/normal_map_invert_y=false
37-
process/hdr_as_srgb=false
38-
process/hdr_clamp_exposure=false
39-
process/size_limit=0
40-
detect_3d/compress_to=1
41-
svg/scale=1.0
42-
editor/scale_with_editor_scale=false
43-
editor/convert_colors_with_editor_theme=false
15+
base_scale=1.0
16+
saturation=1.0
17+
color_map={}
18+
compress=true

material_maker/windows/about/about.gd

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,5 +115,9 @@ func open_url(url) -> void:
115115
func _notification(what: int) -> void:
116116
match what:
117117
NOTIFICATION_THEME_CHANGED:
118-
%EpicLogo.material.set_shader_parameter("invert",
119-
"light" in mm_globals.main_window.theme.resource_path)
118+
var is_light_theme : bool = "light" in mm_globals.main_window.theme.resource_path
119+
%EpicLogo.material.set_shader_parameter("invert", is_light_theme)
120+
$BG.color.a = float(is_light_theme)
121+
for logo in $HBoxContainer/MarginContainer/SocialNetworks.get_children():
122+
if logo.material:
123+
logo.material.set_shader_parameter("invert", is_light_theme)

material_maker/windows/about/about.tscn

Lines changed: 66 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,66 @@
1-
[gd_scene load_steps=16 format=3 uid="uid://btww87u0o4x7t"]
1+
[gd_scene load_steps=22 format=3 uid="uid://btww87u0o4x7t"]
22

33
[ext_resource type="Script" uid="uid://c80e0om4076tc" path="res://material_maker/windows/about/about.gd" id="1"]
4-
[ext_resource type="Texture2D" uid="uid://uwqukrk00ios" path="res://material_maker/windows/about/github.png" id="2"]
5-
[ext_resource type="Texture2D" uid="uid://d0417sp8jvp7a" path="res://material_maker/windows/about/itchio.png" id="5"]
4+
[ext_resource type="Shader" path="res://material_maker/windows/about/about_light_dark.gdshader" id="3_a5pf6"]
5+
[ext_resource type="Texture2D" uid="uid://e6bml33fn07p" path="res://material_maker/windows/about/itchio.svg" id="5_a5pf6"]
6+
[ext_resource type="Texture2D" uid="uid://deyqa1lpneeew" path="res://material_maker/windows/about/patreon.svg" id="5_wcmb3"]
67
[ext_resource type="Texture2D" uid="uid://dntvnke4pcqqf" path="res://icon.png" id="6"]
7-
[ext_resource type="Texture2D" uid="uid://bxfuae46y2fdc" path="res://material_maker/windows/about/youtube.png" id="7"]
8-
[ext_resource type="Texture2D" uid="uid://c1due54dyeob1" path="res://material_maker/windows/about/x.svg" id="8_a5pf6"]
9-
[ext_resource type="Texture2D" uid="uid://d3measjdowk0x" path="res://material_maker/windows/about/facebook.png" id="9"]
10-
[ext_resource type="Texture2D" uid="uid://cnso3ncxhcnek" path="res://material_maker/windows/about/bluesky.svg" id="9_a5pf6"]
11-
[ext_resource type="Texture2D" uid="uid://dvniks5a8tybt" path="res://material_maker/windows/about/discord.png" id="10"]
12-
[ext_resource type="Texture2D" uid="uid://clxj8dqkqggfi" path="res://material_maker/windows/about/mastodon.svg" id="10_wcmb3"]
13-
[ext_resource type="Texture2D" uid="uid://btvwy8odw2nmx" path="res://material_maker/windows/about/patreon.png" id="11"]
14-
[ext_resource type="Texture2D" uid="uid://t53vu231awns" path="res://material_maker/windows/about/epic_megagrant.svg" id="12"]
15-
16-
[sub_resource type="Shader" id="Shader_0an10"]
17-
code = "shader_type canvas_item;
18-
19-
uniform sampler2D tex;
20-
uniform bool invert = false;
21-
22-
void fragment() {
23-
vec4 col = texture(tex, UV);
24-
COLOR = invert ? col : vec4(1.0-col.rgb, col.a);
25-
}
26-
"
8+
[ext_resource type="Texture2D" uid="uid://n8jt6rureb5f" path="res://material_maker/windows/about/discord.svg" id="6_0an10"]
9+
[ext_resource type="Texture2D" uid="uid://bjhogo6c5ev1x" path="res://material_maker/windows/about/github.svg" id="6_a5pf6"]
10+
[ext_resource type="Texture2D" uid="uid://dxn6pembncyas" path="res://material_maker/windows/about/x.svg" id="8_a5pf6"]
11+
[ext_resource type="Texture2D" uid="uid://dranxt7hxluot" path="res://material_maker/windows/about/bluesky.svg" id="9_a5pf6"]
12+
[ext_resource type="Texture2D" uid="uid://bhcv8xiydl2fx" path="res://material_maker/windows/about/mastodon.svg" id="10_wcmb3"]
13+
[ext_resource type="Texture2D" uid="uid://c06d6ulgucg4q" path="res://material_maker/windows/about/epic_megagrant.svg" id="12"]
14+
[ext_resource type="Texture2D" uid="uid://ck3om64nu1ghj" path="res://material_maker/windows/about/youtube.svg" id="12_wcmb3"]
15+
[ext_resource type="Texture2D" uid="uid://d3measjdowk0x" path="res://material_maker/windows/about/facebook.svg" id="13_wcmb3"]
2716

2817
[sub_resource type="ShaderMaterial" id="ShaderMaterial_a5pf6"]
29-
shader = SubResource("Shader_0an10")
18+
shader = ExtResource("3_a5pf6")
3019
shader_parameter/tex = ExtResource("12")
20+
shader_parameter/scale = 1.0
3121
shader_parameter/invert = false
3222

3323
[sub_resource type="PlaceholderTexture2D" id="PlaceholderTexture2D_0an10"]
3424

25+
[sub_resource type="ShaderMaterial" id="ShaderMaterial_y717h"]
26+
shader = ExtResource("3_a5pf6")
27+
shader_parameter/tex = ExtResource("5_wcmb3")
28+
shader_parameter/scale = 4.0
29+
shader_parameter/invert = false
30+
31+
[sub_resource type="PlaceholderTexture2D" id="PlaceholderTexture2D_71vq8"]
32+
33+
[sub_resource type="ShaderMaterial" id="ShaderMaterial_wcmb3"]
34+
shader = ExtResource("3_a5pf6")
35+
shader_parameter/tex = ExtResource("6_a5pf6")
36+
shader_parameter/scale = 4.0
37+
shader_parameter/invert = false
38+
39+
[sub_resource type="PlaceholderTexture2D" id="PlaceholderTexture2D_a5pf6"]
40+
41+
[sub_resource type="ShaderMaterial" id="ShaderMaterial_71vq8"]
42+
shader = ExtResource("3_a5pf6")
43+
shader_parameter/tex = ExtResource("8_a5pf6")
44+
shader_parameter/scale = 4.0
45+
shader_parameter/invert = false
46+
47+
[sub_resource type="PlaceholderTexture2D" id="PlaceholderTexture2D_wcmb3"]
48+
3549
[node name="About" type="Window"]
50+
oversampling_override = 1.0
3651
title = "About Material Maker"
3752
position = Vector2i(0, 36)
3853
size = Vector2i(600, 500)
3954
script = ExtResource("1")
4055

56+
[node name="BG" type="ColorRect" parent="."]
57+
anchors_preset = 15
58+
anchor_right = 1.0
59+
anchor_bottom = 1.0
60+
grow_horizontal = 2
61+
grow_vertical = 2
62+
color = Color(0.91764706, 0.91764706, 0.91764706, 0)
63+
4164
[node name="HBoxContainer" type="HBoxContainer" parent="."]
4265
anchors_preset = 15
4366
anchor_right = 1.0
@@ -184,18 +207,17 @@ theme_override_constants/margin_bottom = 8
184207

185208
[node name="SocialNetworks" type="VBoxContainer" parent="HBoxContainer/MarginContainer"]
186209
layout_mode = 2
187-
size_flags_vertical = 3
188210

189211
[node name="Patreon" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
212+
material = SubResource("ShaderMaterial_y717h")
190213
custom_minimum_size = Vector2(32, 32)
191214
layout_mode = 2
192215
size_flags_horizontal = 4
193216
size_flags_vertical = 6
194217
tooltip_text = "Patreon"
195218
mouse_default_cursor_shape = 2
196-
texture_normal = ExtResource("11")
197-
ignore_texture_size = true
198-
stretch_mode = 4
219+
texture_normal = SubResource("PlaceholderTexture2D_71vq8")
220+
stretch_mode = 5
199221

200222
[node name="ItchIo" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
201223
custom_minimum_size = Vector2(32, 32)
@@ -204,20 +226,20 @@ size_flags_horizontal = 4
204226
size_flags_vertical = 6
205227
tooltip_text = "itch.io"
206228
mouse_default_cursor_shape = 2
207-
texture_normal = ExtResource("5")
229+
texture_normal = ExtResource("5_a5pf6")
208230
ignore_texture_size = true
209-
stretch_mode = 4
231+
stretch_mode = 5
210232

211233
[node name="Github" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
234+
material = SubResource("ShaderMaterial_wcmb3")
212235
custom_minimum_size = Vector2(32, 32)
213236
layout_mode = 2
214237
size_flags_horizontal = 4
215238
size_flags_vertical = 6
216239
tooltip_text = "GitHub"
217240
mouse_default_cursor_shape = 2
218-
texture_normal = ExtResource("2")
219-
ignore_texture_size = true
220-
stretch_mode = 4
241+
texture_normal = SubResource("PlaceholderTexture2D_a5pf6")
242+
stretch_mode = 0
221243

222244
[node name="Discord" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
223245
custom_minimum_size = Vector2(32, 32)
@@ -226,20 +248,20 @@ size_flags_horizontal = 4
226248
size_flags_vertical = 6
227249
tooltip_text = "Discord"
228250
mouse_default_cursor_shape = 2
229-
texture_normal = ExtResource("10")
251+
texture_normal = ExtResource("6_0an10")
230252
ignore_texture_size = true
231-
stretch_mode = 4
253+
stretch_mode = 5
232254

233255
[node name="X" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
256+
material = SubResource("ShaderMaterial_71vq8")
234257
custom_minimum_size = Vector2(32, 32)
235258
layout_mode = 2
236259
size_flags_horizontal = 4
237260
size_flags_vertical = 6
238261
tooltip_text = "X"
239262
mouse_default_cursor_shape = 2
240-
texture_normal = ExtResource("8_a5pf6")
241-
ignore_texture_size = true
242-
stretch_mode = 4
263+
texture_normal = SubResource("PlaceholderTexture2D_wcmb3")
264+
stretch_mode = 5
243265

244266
[node name="BlueSky" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
245267
custom_minimum_size = Vector2(32, 32)
@@ -250,7 +272,7 @@ tooltip_text = "Bluesky"
250272
mouse_default_cursor_shape = 2
251273
texture_normal = ExtResource("9_a5pf6")
252274
ignore_texture_size = true
253-
stretch_mode = 4
275+
stretch_mode = 5
254276

255277
[node name="Mastodon" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
256278
custom_minimum_size = Vector2(32, 32)
@@ -261,7 +283,7 @@ tooltip_text = "Mastodon"
261283
mouse_default_cursor_shape = 2
262284
texture_normal = ExtResource("10_wcmb3")
263285
ignore_texture_size = true
264-
stretch_mode = 4
286+
stretch_mode = 5
265287

266288
[node name="Youtube" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
267289
custom_minimum_size = Vector2(32, 32)
@@ -270,9 +292,9 @@ size_flags_horizontal = 4
270292
size_flags_vertical = 6
271293
tooltip_text = "YouTube"
272294
mouse_default_cursor_shape = 2
273-
texture_normal = ExtResource("7")
295+
texture_normal = ExtResource("12_wcmb3")
274296
ignore_texture_size = true
275-
stretch_mode = 4
297+
stretch_mode = 5
276298

277299
[node name="Facebook" type="TextureButton" parent="HBoxContainer/MarginContainer/SocialNetworks"]
278300
visible = false
@@ -282,7 +304,8 @@ size_flags_horizontal = 4
282304
size_flags_vertical = 6
283305
tooltip_text = "Facebook"
284306
mouse_default_cursor_shape = 2
285-
texture_normal = ExtResource("9")
307+
texture_normal = ExtResource("13_wcmb3")
308+
ignore_texture_size = true
286309
stretch_mode = 4
287310

288311
[connection signal="close_requested" from="." to="." method="queue_free"]
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
shader_type canvas_item;
2+
3+
uniform sampler2D tex;
4+
uniform float scale = 1.0;
5+
uniform bool invert = false;
6+
7+
void fragment() {
8+
vec4 col = texture(tex, UV*scale);
9+
COLOR = invert ? col : vec4(1.0-col.rgb, col.a);
10+
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
uid://clbm7f7vq3mgp

0 commit comments

Comments
 (0)