godotengine / godotengine/godot-vscode-plugin
Lacking support for rich text print in debug console
- Dominant language
- TypeScript
- Stars
- 2.1k
- Forks
- 257
- PR merge metrics
- No merged PRs in 30d
Description
### Godot version
4.6-stable-mono
### VS Code version
1.111.0
### Godot Tools VS Code extension version
2.6.1 (dev, i dont remember the exact commit hash)
### System information
Windows 11
### Issue description
`print_rich()` function doesn't work properly on VSCode debug console:
### Steps to reproduce
Code I used to replicate this:
1. Function (in a `Utilities` autoload):
```gdscript
class_name Utilities extends Node
## Imprime un texto con el color. El color puede ser indicado por valor o por nombre
static func print_color(text: String, color: Color) -> void:
var final_color: String
if color is Color: final_color = color.to_html()
print_rich("[color=#%s]%s[/color]" % [final_color, text])
```
2. Use:
```gdscript
Utilities.print_color(
"[Rock] Roca seleccionada: %s" % Utilities.get_enum_name(element, GameConstants.Elements),
Color.TEAL
)
```
Use this or `print_rich()` directly
Contributor guide
Assessment
This issue has not been assessed yet.