Open qwitwa opened 9 months ago
This appears to be a highly desired feature within our community.
At present, Panku directly accesses the output file produced by the Godot engine to retrieve all text passed to native Godot log functions like print
, print_rich
, push_error
, etc. (really primitive, since godot does not provide proper logging utilities for external tools). This text is then displayed using a BBCode text component.
When print_rich
outputs to standard output, it converts a supported subset of BBCode to ANSI escape codes, which the terminal emulator then displays.
To accurately capture the original BBCode string passed to print_rich
, we need to create a wrapper function, such as panku_print_rich
, to intercept the BBCode.
In summary, we should introduce a new log API to the Panku singleton to properly manage rich output.
This represents an excellent opportunity for contribution. I strongly encourage you to develop this feature and submit a pull request!
Yeah, I'm also experiencing this issue. I use BBcode to color my own logger's output, then it's ingested by Panku and it prints the ANSI codes (it applies the colors too):
Is your feature request related to a problem? Please describe. I want to see rich text output, but instead I see terminal escape codes
Describe the solution you'd like Rich text output displays in panku as in the terminal output
Example of terminal output using print_rich:![image](https://github.com/Ark2000/PankuConsole/assets/2302478/8373e1bf-c95d-45f1-8f6b-f47641ba62af)
How it appears inside of panku:![image](https://github.com/Ark2000/PankuConsole/assets/2302478/593c10e9-24d4-4c47-9a87-5fd11de9790f)