30 lines
1.1 KiB
C#
30 lines
1.1 KiB
C#
using Godot;
|
|
using System;
|
|
|
|
public partial class TestConsole : CanvasLayer
|
|
{
|
|
public override void _Ready()
|
|
{
|
|
var output = GetNode<RichTextLabel>("/root/Playground/Console/Panel/MarginContainer/VBoxContainer/ConsoleOutput");
|
|
var panel = GetNode<Panel>("/root/Playground/Console/Panel");
|
|
panel.Visible = true;
|
|
if (output != null)
|
|
{
|
|
GD.Print($"Visible: {output.Visible}");
|
|
GD.Print($"Modulate: {output.Modulate}");
|
|
GD.Print($"SelfModulate: {output.SelfModulate}");
|
|
GD.Print($"Size: {output.Size}");
|
|
GD.Print($"Position: {output.Position}");
|
|
|
|
// Force a minimum size
|
|
output.SizeFlagsVertical = Control.SizeFlags.ExpandFill;
|
|
|
|
output.Text = "TEST WORKING!";
|
|
|
|
// Also try changing background to bright red to see if it exists
|
|
var styleBox = new StyleBoxFlat();
|
|
styleBox.BgColor = Colors.Red;
|
|
output.AddThemeStyleboxOverride("normal", styleBox);
|
|
}
|
|
}
|
|
} |