jimmycushnie / fancytextrendering Goto Github PK
View Code? Open in Web Editor NEWRender markdown & clickable links with TextMeshPro in Unity.
License: Do What The F*ck You Want To Public License
Render markdown & clickable links with TextMeshPro in Unity.
License: Do What The F*ck You Want To Public License
HTTP and HTTPS links can be automatically detected. The same should apply to email addresses, with a mailto
link generated.
Hi,
Love this tool - has great utility, thanks for making it.
I'm trying to make a text editor for journaling, where users view/edit a single block of fancy text and never see the markdown syntax. I haven't had any success, and I'm not sure if it's supported just yet. I've created a basic setup with the DemoRenderUpdater (similar to the demo scene), and then tried a few things without success:
I wonder if you have a solution to this, have considered it, or have suggestions for how to go about it.
Thanks again for making this
I am trying to import this package in my existing project. I did Window -> Package Manager -> Add Package from git URL
. Unity console says,
[Package Manager Window] Cannot perform upm operation: Unable to add package [https://github.com/JimmyCushnie/FancyTextRendering.git]:
[https://github.com/JimmyCushnie/FancyTextRendering.git] does not point to a valid package. No package manifest was found. [NotFound].
UnityEditor.EditorApplication:Internal_CallUpdateFunctions ()
and
[Package Manager Window] Error adding package: https://github.com/JimmyCushnie/FancyTextRendering.git.
UnityEditor.EditorApplication:Internal_CallUpdateFunctions ()
What am I doing wrong?
Due to the way escaping currently works, if you have a single isolated \
it will be invisible. You have to type two for a backslash to show up. This is lame and it's also in violation of markdown spec/standard, so it should be fixed.
You should be able to use >
to format a quote, like so:
hi every1 im new!!!!!!! holds up spork my name is katy but u can call me t3h PeNgU1N oF d00m!!!!!!!! lol…as u can see im very random!!!! thats why i came here, 2 meet random ppl like me ^^… im 13 years old (im mature 4 my age tho!!) i like 2 watch invader zim w/ my girlfreind (im bi if u dont like it deal w/it) its our favorite tv show!!! bcuz its SOOOO random!!!! shes random 2 of course but i want 2 meet more random ppl =) like they say the more the merrier!!!! lol…neways i hope 2 make alot of freinds here so give me lots of commentses!!!!
DOOOOOMMMM!!!!!!!!!!!!!!!! <--- me bein random again ^^ hehe…toodles!!!!!love and waffles,
t3h PeNgU1N oF d00m
This is going to be tricky unless TMP makes some big changes. We'll probably have to add the vertical line in manually as a separate game object.
You should be able to create full width line breaks with ---
or ===
, like so:
TMP doesn't really support this, and the line break will probably have to be a separate game object, similar to quotes (#5)
TL;DR: using LogicUI.FancyTextRendering to include the MarkdownReader component
I'm still having trouble getting your tool up and running. You mentioned that I may need to reference the FancyTextRendering assembly in my code, but according to the documentation this is done automatically for all assemblies inside the Assets folder, right?
With this I'm assuming the other dependencies you mentioned are installed correctly, but I don't understand why this assembly file isn't being recognized.
Currently only one level of list is supported. You should be able to nest lists, like so:
1. List level one!
1. Another item on list level one!
1. Oh damn an indented list!
1. How cool is that!
* And you can even mix and match the type of list!
* There's no limit to how deep you can go!
1. Wowzers!!!
Related: #9
We already have inline monospace by using a single backtick. We should also have block monospace by using three backticks on a line.
It would be extra amazing if block monospace supported syntax highlighting for various languages, but that shit's really hard and probably out of scope for this project.
In most markdown renderers, if you want to use the shrug emoticon ¯\_(ツ)_/¯
, you have to type it like ¯\\\_(ツ)_/¯
to fix the escape stuff. This is presently the case with FTR as well, though you can't see it in the demo because the demo doesn't have a japanese font installed. I hate this, and I want FTR to manually search for ¯\_(ツ)_/¯
and render it properly, no extra escapes needed. However the extra escaped version should also work for compatibility with users who are used to that.
If I write
`*example*`
It should say *example*
, in monospace. Currently it makes "example" monospaced and italic, incorrectly interpreting the asterisks.
Perhaps stuff in monospace should also use the TMP noparse tag.
Any idea on whether image embedding would be supported in this?
Use a ^
to make some text raise in the air.
Markdown | Looks like |
---|---|
super^script | superscript |
It would also be great to support group superscript for stuff inside brackets:
Markdown | Looks like |
---|---|
here's a ^(bunch of stuff in superscript) | here's a bunch of stuff in superscript |
This is an esoteric markdown feature not found in most renderers, but I like it so I want to add it to FTR.
It shouldn't be too difficult, TMP has a native superscript tag.
You should be able to create markdown tables, like this one!
| Heading one! | Heading two! | Heading three! |
| ------------------------------------------------------------ | ------------------------------------------------------------ | --------------------------------------- |
| Look at this crazy stuff! | You can even include **markdown *formatting*** within tables! | fdsafdsafdsa |
| I am trained in gorilla warfare and I’m the top sniper in the entire US armed forces. You are nothing to me but just another target. I will wipe you the fuck out with precision the likes of which has never been seen before on this Earth, mark my fucking words. | graaaaaaaafdsafdsafdsafdsafdsa | nh ufeawnf ewan fhewaui fhewauif hdsaui |
Heading one! | Heading two! | Heading three! |
---|---|---|
Look at this crazy stuff! | You can even include markdown formatting within tables! | fdsafdsafdsa |
I am trained in gorilla warfare and I’m the top sniper in the entire US armed forces. You are nothing to me but just another target. I will wipe you the fuck out with precision the likes of which has never been seen before on this Earth, mark my fucking words. | graaaaaaaafdsafdsafdsafdsafdsa | nh ufeawnf ewan fhewaui fhewauif hdsaui |
This is going to be insanely complicated to implement. Glhf
Currently, each node of a list can only have one line. A line break will be interpreted as the end of the list. In accordance with markdown spec, a single line break should be treated as a line break within the current list node.
1. List
1. More list
Second line
1. Last list
Ok now the list is over
Second line
Ok now the list is over
Ok now the list is over
Related: #2
We do a little of this before and after lists, but it should be done everywhere.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.