Files
SharpIDE/src/SharpIDE.Godot/Features/CodeEditor/SymbolTooltips/LabelTooltip.cs
Matt Parker 826fc851c3 rename class
2026-01-31 14:24:48 +10:00

27 lines
715 B
C#

using Godot;
using Microsoft.CodeAnalysis;
namespace SharpIDE.Godot.Features.CodeEditor;
public static partial class SymbolInfoComponents
{
public static RichTextLabel GetLabelSymbolInfo(ILabelSymbol symbol)
{
var label = new RichTextLabel();
label.PushColor(TextEditorDotnetColoursDark.White);
label.PushFont(MonospaceFont);
label.AddText("label ");
label.AddLabelName(symbol);
label.Pop();
label.Pop();
return label;
}
private static void AddLabelName(this RichTextLabel label, ILabelSymbol symbol)
{
label.PushColor(TextEditorDotnetColoursDark.White);
label.AddText(symbol.Name);
label.Pop();
}
}