diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..085e8ba --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +Thumbs.db diff --git a/README.md b/README.md index 6bfe15e..6d16923 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,10 @@ Sometimes, you just want to open a markdown file to edit it quickly, you don't c This plugin is not finished, there's still some things to fix (custom css, focus, etc). So, don't run away if you have any trouble, just submit an issue [here](http://github.com/math2001/MarkdownLivePreview/issues). +### Demo + + + ### How to open the [README](http://github.com/math2001/MarkdownLivePreview/README.md) Some of the package add a command in the menus, others in the command palette, or other nowhere. None of those options are really good, especially the last one on ST3 because the packages are compressed. But, fortunately, there is plugin that exists and **will solve this problem** for us (and he has a really cute name, don't you think?): [ReadmePlease](https://packagecontrol.io/packages/ReadmePlease). diff --git a/demo.gif b/demo.gif new file mode 100644 index 0000000..d4ddb92 Binary files /dev/null and b/demo.gif differ diff --git a/md_in_popup.py b/md_in_popup.py index 4e2e37a..9533337 100644 --- a/md_in_popup.py +++ b/md_in_popup.py @@ -1,9 +1,19 @@ import sublime import sublime_plugin -from sublimetools import * import html from . import markdown2 +# Main sublime tools function + +def md(*t, **kwargs): + sublime.message_dialog(kwargs.get('sep', '\n').join([str(el) for el in t])) + +def sm(*t, **kwargs): + sublime.status_message(kwargs.get('sep', ' ').join([str(el) for el in t])) + +def em(*t, **kwargs): + sublime.error_message(kwargs.get('sep', ' ').join([str(el) for el in t])) + class MarkdownInPopupCommand(sublime_plugin.EventListener): def run(self, view): view.show_popup('