Skip to content

Commit 039eaf2

Browse files
authored
Update IMGUIHyperLabel.cs
1 parent a506d37 commit 039eaf2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

com.stansassets.plugins-dev-kit/Editor/IMGUI/Controls/IMGUIHyperLabel.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,11 @@ public void HighLight(string pattern)
5656
var lastCopyIndex = 0;
5757
foreach (var index in indexes)
5858
{
59+
if (index < lastCopyIndex)
60+
{
61+
lastCopyIndex = index;
62+
}
63+
5964
m_HighlightedContext.text += m_Content.text.Substring(lastCopyIndex, index - lastCopyIndex);
6065
m_HighlightedContext.text += "<color=yellow>";
6166
m_HighlightedContext.text += m_Content.text.Substring(index, pattern.Length);

0 commit comments

Comments
 (0)