fix(icon): use custom icons for Terminal and PTY

This commit is contained in:
Leroy Hopson 2024-05-19 11:42:27 +12:00
parent 98394bfbf5
commit 608f27ba0c
No known key found for this signature in database
GPG key ID: D2747312A6DB51AA
4 changed files with 8 additions and 8 deletions

View file

@ -2,7 +2,7 @@
importer="texture" importer="texture"
type="CompressedTexture2D" type="CompressedTexture2D"
uid="uid://q1dpdt7xx8jf" uid="uid://ixravk0w4lkt"
path="res://.godot/imported/pty_icon.svg-7c3f500292e2f95935d23c435d6de47f.ctex" path="res://.godot/imported/pty_icon.svg-7c3f500292e2f95935d23c435d6de47f.ctex"
metadata={ metadata={
"vram_texture": false "vram_texture": false
@ -31,7 +31,7 @@ process/normal_map_invert_y=false
process/hdr_as_srgb=false process/hdr_as_srgb=false
process/hdr_clamp_exposure=false process/hdr_clamp_exposure=false
process/size_limit=0 process/size_limit=0
detect_3d/compress_to=1 detect_3d/compress_to=0
svg/scale=1.0 svg/scale=1.0
editor/scale_with_editor_scale=false editor/scale_with_editor_scale=false
editor/convert_colors_with_editor_theme=false editor/convert_colors_with_editor_theme=false

View file

@ -31,7 +31,7 @@ process/normal_map_invert_y=false
process/hdr_as_srgb=false process/hdr_as_srgb=false
process/hdr_clamp_exposure=false process/hdr_clamp_exposure=false
process/size_limit=0 process/size_limit=0
detect_3d/compress_to=1 detect_3d/compress_to=0
svg/scale=1.0 svg/scale=1.0
editor/scale_with_editor_scale=false editor/scale_with_editor_scale=false
editor/convert_colors_with_editor_theme=false editor/convert_colors_with_editor_theme=false

View file

@ -3,6 +3,11 @@
entry_symbol = "godot_xterm_library_init" entry_symbol = "godot_xterm_library_init"
compatibility_minimum = "4.2.0" compatibility_minimum = "4.2.0"
[icons]
Terminal = "res://addons/godot_xterm/icons/terminal_icon.svg"
PTY = "res://addons/godot_xterm/icons/pty_icon.svg"
[libraries] [libraries]
linux.debug.x86_64 = "res://addons/godot_xterm/native/bin/libgodot-xterm.linux.template_debug.x86_64.so" linux.debug.x86_64 = "res://addons/godot_xterm/native/bin/libgodot-xterm.linux.template_debug.x86_64.so"

View file

@ -17,13 +17,8 @@ func _enter_tree():
var asciicast_script = preload("./resources/asciicast.gd") var asciicast_script = preload("./resources/asciicast.gd")
add_custom_type("Asciicast", "Animation", asciicast_script, null) add_custom_type("Asciicast", "Animation", asciicast_script, null)
var terminal_icon = load(
"%s/nodes/terminal/terminal_icon.svg" % get_script().resource_path.get_base_dir()
)
if pty_supported: if pty_supported:
var base_dir = get_script().resource_path.get_base_dir() var base_dir = get_script().resource_path.get_base_dir()
var pty_icon = load("%s/nodes/pty/pty_icon.svg" % base_dir)
var pty_script var pty_script
match OS.get_name(): match OS.get_name():
"Linux", "FreeBSD", "NetBSD", "OpenBSD", "BSD", "macOS": "Linux", "FreeBSD", "NetBSD", "OpenBSD", "BSD", "macOS":