From ad6de871c37bc1468aaf6956df9f9de025b5e47f Mon Sep 17 00:00:00 2001 From: Scutlet <103026559+Scutlet@users.noreply.github.com> Date: Sun, 16 Aug 2026 15:47:13 +0200 Subject: [PATCH 1/5] Search asset aliases --- .../AssetWindow/AssetViewWindow.cs | 28 +++++++++++++++---- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/src/DockedWindows/AssetWindow/AssetViewWindow.cs b/src/DockedWindows/AssetWindow/AssetViewWindow.cs index c4daed7..d8a589f 100644 --- a/src/DockedWindows/AssetWindow/AssetViewWindow.cs +++ b/src/DockedWindows/AssetWindow/AssetViewWindow.cs @@ -515,19 +515,32 @@ private string TextEplislon(string text, float textWidth, float itemWidth) #region Asset Loading + /// + /// Filters assets based on its visibility and some search term. + /// + /// Full list of assets + /// Filtered list of assets private List UpdateSearch(List assets) { List filtered = new List(); for (int i = 0; i < assets.Count; i++) { - bool HasText = assets[i].Name != null && - assets[i].Name.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0; - if (!assets[i].Visible) + // Not visible continue; - if (isSearch && HasText || !isSearch) - filtered.Add(assets[i]); + if (isSearch) + { + // Search for matches if filtering is applied + bool hasText = assets[i].Name != null && + assets[i].Name.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0; + + hasText |= assets[i].Aliases.Any(s => s.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0); + + if (!hasText) + continue; + } + filtered.Add(assets[i]); } return filtered; } @@ -667,6 +680,11 @@ public class AssetItem public string DisplayName { get; internal set; } + /// + /// Aliases of the asset, which are also valid search terms + /// + public string[] Aliases { get; set; } = Array.Empty(); + /// /// The image ID of the icon. /// From 8a81c849cd7ead9d2cf50f51df3c016d2ba090d2 Mon Sep 17 00:00:00 2001 From: Scutlet <103026559+Scutlet@users.noreply.github.com> Date: Sun, 16 Aug 2026 16:59:28 +0200 Subject: [PATCH 2/5] Search outliner aliases Related commit in Toolbox.core --- src/DockedWindows/Outliner/Outliner.cs | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/src/DockedWindows/Outliner/Outliner.cs b/src/DockedWindows/Outliner/Outliner.cs index a6f7d6e..9122753 100644 --- a/src/DockedWindows/Outliner/Outliner.cs +++ b/src/DockedWindows/Outliner/Outliner.cs @@ -144,8 +144,7 @@ public void ScrollToSelected(NodeBase target) private bool GetNodePosition(NodeBase target, NodeBase parent, ref float pos, float itemHeight) { - bool HasText = parent.Header != null && - parent.Header.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0; + bool HasText = parent.IsNameMatch(_searchText); //Search is active and node is found but is not in results so skip scrolling if (isSearch && parent == target && !HasText) @@ -303,8 +302,7 @@ private void SetupNodes(NodeBase node) private void CalculateCount(NodeBase node, ref int counter) { - bool HasText = node.Header != null && - node.Header.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0; + bool HasText = node.IsNameMatch(_searchText); if (isSearch && HasText || !isSearch) { @@ -328,8 +326,7 @@ public void DeselectAll() public void DrawNode(NodeBase node, float itemHeight, int level = 0) { - bool HasText = node.Header != null && - node.Header.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0; + bool HasText = node.IsNameMatch(_searchText); char icon = IconManager.FOLDER_ICON; if (node.Tag is STGenericMesh) @@ -818,14 +815,7 @@ private bool SelectNodeRange(NodeBase node, NodeBase selectedNode1, NodeBase sel private List GetSearchableNodes(List nodes) { - List nodeList = new List(); - foreach (var node in nodes) - { - bool hasText = node.Header != null && node.Header.IndexOf(_searchText, StringComparison.OrdinalIgnoreCase) >= 0; - if (hasText) - nodeList.Add(node); - } - return nodeList; + return nodes.Where(n => n.IsNameMatch(_searchText)).ToList(); } private void LoadTextureIcon(NodeBase node) From 7e894ccc09e2d442d47bf8e190979b3f657e399f Mon Sep 17 00:00:00 2001 From: Scutlet <103026559+Scutlet@users.noreply.github.com> Date: Sun, 16 Aug 2026 23:16:19 +0200 Subject: [PATCH 3/5] Additional icons --- src/Icons/IconManager.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Icons/IconManager.cs b/src/Icons/IconManager.cs index bb45660..024923f 100644 --- a/src/Icons/IconManager.cs +++ b/src/Icons/IconManager.cs @@ -88,6 +88,7 @@ public class IconManager public const char DESELECT_ICON = '\uf850'; public const char SELECT_ICON = '\uf84c'; + public const char INFO_ICON = '\uf05a'; public const char WARNING_ICON = '\uf071'; public const char VIDEO_ICON = '\uf03d'; @@ -103,6 +104,10 @@ public class IconManager public const char PATH_CONNECT = '\uf337'; public const char PATH_CONNECT_AUTO = '\uf126'; + public const char ICON_WII_U = '\uf0a0'; // HDD + public const char ICON_SWITCH = '\uf11b'; // gamepad + public const char ICON_MOD = '\uf0ad'; // wrench + public const int ICON_SIZE = 18; static bool init = false; From 5756d6cf654980c8624c501a811d1d4cee5d4d9f Mon Sep 17 00:00:00 2001 From: Scutlet <103026559+Scutlet@users.noreply.github.com> Date: Tue, 18 Aug 2026 23:12:59 +0200 Subject: [PATCH 4/5] Download icon --- src/Icons/IconManager.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Icons/IconManager.cs b/src/Icons/IconManager.cs index 024923f..72722d4 100644 --- a/src/Icons/IconManager.cs +++ b/src/Icons/IconManager.cs @@ -107,6 +107,7 @@ public class IconManager public const char ICON_WII_U = '\uf0a0'; // HDD public const char ICON_SWITCH = '\uf11b'; // gamepad public const char ICON_MOD = '\uf0ad'; // wrench + public const char ICON_DOWNLOAD = '\uf019'; public const int ICON_SIZE = 18; From e42b17bb9551e7dd738e56d76be80e3ed22d06f0 Mon Sep 17 00:00:00 2001 From: Scutlet <103026559+Scutlet@users.noreply.github.com> Date: Thu, 20 Aug 2026 21:33:40 +0200 Subject: [PATCH 5/5] Fix INVALID MESSAGE WITH QUOTES Both ' and " cause the infamous INVALID MESSAGE WITH QUOTES message. Sanitize them both. --- src/Dialogs/DialogHandler.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Dialogs/DialogHandler.cs b/src/Dialogs/DialogHandler.cs index 99a78e7..4d939a0 100644 --- a/src/Dialogs/DialogHandler.cs +++ b/src/Dialogs/DialogHandler.cs @@ -50,7 +50,8 @@ public static void RenderActiveWindows() public static void ShowException(Exception ex) { - string message = ex.Message.Replace("'", ""); + // Replace both ' and " with nothing. Messages with these values cause INVALID MESSAGE WITH QUOTES + string message = ex.Message.Replace("'", "").Replace("\"", ""); Clipboard.SetText($"{ex.Message} \n{ex.StackTrace}"); TinyFileDialog.MessageBoxErrorOk($"{message} Details copied to clipboard!");