Say I want to implement syntax highlighting in an application. The medium is not a Windows Form, therefore I won’t be highlighting text in a normal textbox. Instead I just want to be able to read and understand the same information that Visual Studio uses to highlight text, and apply the logic where I need it. In case it is somehow relevant the target medium is an XNA window.
Is this legal and/or possible? If so, where do I find such an API?
EDIT: If anyone is curious, I am embedding an IronPython interpreter in an XNA window. It would be nice to be able to treat input and output to the same syntax highlighting that IronPython receives in Visual Studio.
I would recommend checking out Markdown with some additional info on Wikipedia.
Update: Given your updated information (in the comments below) I would recommend Pygments which is a Python syntax highlighting engine.