Multiformat Output (RichText/Log Function)

As a Roblox Developer, it is currently hard to customize your Output Messages (unless you make your own output interface, which is something I don’t really want to). :neutral_face:

My idea is to use RichText in the Output Window. That way, you can allow HTML Tags inside your output to highlight important parts in a print statement, bring more life to your messages etc.


Aditionally, a function along the lines of log() or customlog() would also be nice.
How it works is each time log is called, the window uses rich text. You can give it custom HTML tags (like < b >Text < /b > to make it bold, ` Text `` to make it preformatted, < i > Text < /i> for italic and so on. This would also allow developers to use custom text colors for their print/log statements, like in the following example:

log("<font color='rgb(200, 50, 255)'><b>This is a pink message!</b></font>")
log("<i>Italic text!</i>")

This would allow for important parts of a print statement to be highlighted, while keeping the output clean and organized.
Aditionally, we could have the option to give our logs a custom icon, as seen for info, warn and error.
How this would work is you could make a new TextLabel Instance using log() as seen in the following example:

local newLog: Log = log("<i>Hello world!</i>")
newLog.Icon = "rbxassetid://123"

Aditionally, being able to schedule messages would also be cool, but not as important. What you could do is newLog.Hidden = true. Then, after a certain amount of time (like 3 seconds, using the task library, you could show it), using the Hidden property- or Visible.

Thanks for reading! Let me know if you have any suggestions and feedback about this. :slightly_smiling_face:

5 Likes

It’s been a while so I feel like this is worth bumping