Feature Suggest: Drop image to fast insert image #97
Description
Activity
Now we have drop and upload to SM, But it's not stable, Because
SMis a free picture cloud.Maybe drop and insert relative path is a good idea.
There are two problem:
- There is no relative path when file is not saved.
- The cursor is hard to control when you drag image to Mart Text directly.
我还是用中文交流吧, 这样清晰一点
免费图片云可能会倒闭,或突然加上限制。
这样的话 原来写的markdown 就废掉了
所以 我建议 在设置里面加一项drop image配置 让用户自行选择传到CM上 还是用 path来插入图片选用path 的话
如果发觉文件没有保存 就直接提供绝对路径
对于明显和markdown文件不属于同一文件夹的图片 也直接提供绝对路径
(如果觉得这种智能化的设置会使用户迷惑, 还有办法就是 直接在drop image配置中 设置upload CM,relative path,abspath3个选项)对于 problem 2
可以退一步来实现:
一旦把图片 drop 到当前窗口, 就直接在光标处插入针对免费的图片问题
以后可能会增加配置,用户可以自行添加私有的图片云服务,使用自己的图片云。应该在 v1.0.0 版本前会增加私有云配置吧。
针对选用 path 问题
现在 Absolute Path 和 Relative Path 都是直接调用了系统的 对话框。可能添加拖拽弹窗,类似现在上传图片的弹窗一样,用户可以选择打开系统对话框还是直接拖入图片。让用户自行选择使用绝对路径还是相对路径。如果没有保存,没有相对路径就直接使用绝对路径。
如果都给一个拖拽的遮罩,就不会存在光标问题了。
Reacted by Lei Yang and Lyn感谢! 拭目以待!
Another suggestion:
To paste images into markdown, I found this implementation is quite convenient:
https://atom.io/packages/markdown-img-pasteWhich allows user take a screenshot, then use "Ctrl+Shift+V" to paste the image into markdown. It actually creates and saves the image file in the same directory of markdown file. So you don't have to save it yourself.
Reacted by Lei Yang, Ran Luo and martinandersen3dMaybe image that paste into markdown will be automatic upload to imgur ?, so we don't need reupload our image into web/internet.
@d4em0n If YOU select
upload to cloud, the image will be automatically upload to a free image cloud service.- added🐼 pluginyou can write a plugin of Mark Text to implement this feature in the futureyou can write a plugin of Mark Text to implement this feature in the future
on Jun 20, 2018 - added a commit that references this issue
on May 13, 2026 - added a commit that references this issue
on Jun 21, 2026
Mark Textis real awesome, and I want to Suggest a feature that could fast insert imageDescription
Drop a image to text editor.
After that,
Mark Textauto insert image to corresponding line with image's relative path.This feature could greatly improve efficiency for write Markdown which include lots images.