A 3D kite design program
Describe the problem or limitation you are having in your project:
I forget how some bits of code work, e.g. winding of opengl triangles, an image would help.
Describe the feature / enhancement and how it helps to overcome the problem or limitation:
Picture is worth 1,000 comments.
Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams:
Screenshot, paste into code. Image is a comment.
If this enhancement will not be used often, can it be worked around with a few lines of script?:
Don't know
Is there a reason why this should be core and not an add-on in the asset library?:
Don't know
Not a good odea in general. Adding binary to source files will
a) make the file unusable in many text editors and ides
b) make cod diffs in version control brutal.
Just link to an external image.
There are some relatively benign ways to incorporate an image into text. For example, it might be a base64 encoded .svg. After this, it could be just a matter of loading and displaying such images (and convincing TextEdit that you can take the space up for an image). Might be doable with a addon and some hacky code, in fact.
Could you just put an img tag in?
var x = 1
# <img src="res://image1.png">
var y = 2
And the editor would just show the image (maybe on hover?)
Pasting an image would save it, then add the tag as above?
@monk-e-boy Godot's editor isn't a WebView. HTML tags won't work :slightly_smiling_face:
@monk-e-boy Godot's editor isn't a WebView. HTML tags won't work
What sort of argument is that? It's too tricky to implement?!
Games are visual. Code and comments should incorporate some visual elements.
Animating sprite? Picture of sprite next to code. Looking for code that generates a flower? Look for picture of flower.
https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ImageInsertion
Have used this and it worked fine.
Sorry, I seem to be banging on about the merits of images, I assumed this was a pretty common idea that has been implemented in many editors before. I should have expressed the idea more clearly as an argument rather than " let's catch up to other editors"
Having an IMG tag that dynamically loads the image would be neat to hook into unit test output. You could see test results next to anticipated results. E.g. maze generation with a particular seed.
@monk-e-boy Displaying images directly in text editors is definitely not a common feature. I don't know of any editor that supports it out of the box. (The same goes in terminal emulators; a few of them support it, but it's seldom used in practice.)
What sort of argument is that? It's too tricky to implement?!
We gauge implementation complexity when evaluating proposals. Complex proposals are less likely to be accepted than simpler ones.
Animating sprite? Picture of sprite next to code. Looking for code that generates a flower? Look for picture of flower.
If your sprite is large, you don't want it to waste 10+ lines on your screen :slightly_smiling_face:
Preserving screen real estate is probably more important than displaying images inline at this point.
I can understand displaying images in a tooltip when hovering their path in a preload() statement (for instance). Since we don't have a system for tooltips in the script editor yet, this would have to be implemented from scratch. TextEdit is pending a refactor, so now may not be a good time to implement that just yet.
I think the most feasible workaround to this is actually being able to follow links in the script editor: #1172.
Picture is worth 1,000 comments.
And what about video?:) No joke
Btw it's worth implementing it as a plugin rather core, but there's no such APIs yet
Most helpful comment
I think the most feasible workaround to this is actually being able to follow links in the script editor: #1172.