<html><head><style>body{font-family:Helvetica,Arial;font-size:13px}</style></head><body style="word-wrap:break-word"><div id="bloop_customfont" style="margin:0px">This is huge!</div><div id="bloop_customfont" style="margin:0px"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px;color:rgba(0,0,0,1.0);margin:0px;line-height:auto">Thanks so much for this! I’ll be hopefully carving out a big chunk for this work this weekend!</div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px;color:rgba(0,0,0,1.0);margin:0px;line-height:auto"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px;color:rgba(0,0,0,1.0);margin:0px;line-height:auto">I’ll be sure to keep you updated.</div> <br> <div id="bloop_sign_1475170267425325824" class="bloop_sign"><div style="font-family:helvetica,arial;font-size:13px">Thanks again,</div><div style="font-family:helvetica,arial;font-size:13px"><br>Graham Heath<br><br></div></div> <br><p class="airmail_on">On September 28, 2016 at 11:42:25 AM, Allan Odgaard (<a href="mailto:mailinglist@textmate.org">mailinglist@textmate.org</a>) wrote:</p> <blockquote type="cite" class="clean_bq"><span><div><div></div><div>



<title></title>


<div style="font-family:sans-serif">
<div style="white-space:normal">
<p dir="auto">A few “typos” made it into my email.</p>
<p dir="auto">The values should have been <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">onDocumentChange</code> and <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">onDocumentSave</code> rather than <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">documentDidChange</code> and <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">documentDidSave</code>. The latter though is what
they’ll likely be changed to.</p>
<p dir="auto">And the environment variable present for successive
runs is <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">TM_REFRESH</code>.</p>
<p dir="auto">Here’s an example which works with the current
nightly build: <a href="https://github.com/textmate/markdown.tmbundle/blob/live-preview/Commands/Markdown%20preview.plist" style="color:#3983c4">https://github.com/textmate/markdown.tmbundle/blob/live-preview/Commands/Markdown%20preview.plist</a></p>
<p dir="auto">On 28 Sep 2016, at 16:59, Allan Odgaard wrote:</p>
<p dir="auto"></p>
</div>
<div style="white-space:pre-wrap"></div>
<blockquote style="border-left:2px solid #777;color:#777;margin:0 0 5px;padding-left:5px">
<div id="03612419-B798-43D2-B685-328E1894BBCC">
<div style="font-family:sans-serif">
<div style="white-space:normal">
<p dir="auto">On 24 Aug 2016, at 18:26, Graham Heath wrote:</p>
<p dir="auto">Current test build has a preliminary implementation
of this feature.</p>
<p dir="auto"></p>
</div>
<div style="white-space:pre-wrap">
<blockquote style="border-left:2px solid #777;color:#777;margin:0 0 5px;padding-left:5px">
<div dir="auto">Thats great news. You mention that the commands
could update the HTML view,</div>
<div dir="auto">would they also have access to the gutter (and/or
tooltips)?</div>
</blockquote>
</div>
<div style="white-space:normal">
<p dir="auto">You can access gutter via <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">$TM_MATE</code> and tool tips can be shown by
using <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">$DIALOG</code>.</p>
<p dir="auto"></p>
</div>
<div style="white-space:pre-wrap">
<blockquote style="border-left:2px solid #777;color:#777;margin:0 0 5px;padding-left:5px">
<div dir="auto">You’ve got a good point that the process should be
killed when a user no</div>
<div dir="auto">longer wants it, for my use though I can’t imagine
wanting to turn the</div>
<div dir="auto">linter service off while TextMate was still open.
If there was a</div>
<div dir="auto">"application-will-close" event, bundles could be
responsible for cleaning</div>
<div dir="auto">up after themselves.</div>
</blockquote>
</div>
<div style="white-space:normal">
<p dir="auto">Here is the preliminary documentation (I will likely
change the keys to match the semantic classes and also make it a
mask rather than either/or):</p>
<hr style="background:#333;background-image:linear-gradient(to right,#ccc,#333,#ccc);border:0;height:1px" height="1">
<p dir="auto">New <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">autoRefresh</code> key that can be set in
<code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">tmCommand</code>, value can be either:</p>
<ul>
<li><code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">documentDidChange</code>: Re-run the command
after document has changed.</li>
<li><code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">documentDidSave</code>: Re-run the command after
a file in the project has been saved (after delay to coalesce
multiple documents being saved).</li>
</ul>
<p dir="auto">If a document has <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">autoRefresh</code> set to <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">onDocumentChange</code> it will stop running if
the document is closed. If there is a HTML output window, this
window will then also close.</p>
<p dir="auto">If a command has HTML output, closing the HTML output
will stop running the command.</p>
<p dir="auto">If the user runs a command with <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">autoRefresh</code> enabled for a second time, and
there is an open HTML output window associated with the command,
then it brings the window to front, otherwise it will stop the
first instance.</p>
<p dir="auto">For successive command executions the <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">TM_REFREH</code> environment variable is present
and set to <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">YES</code>.</p>
<p dir="auto">Planned: If the command’s title matches: <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">(\w+) / (\w+) (.+)</code> then it will show as
<code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">$1 $3</code> by default and <code style="background-color:#f7f7f7;border-radius:3px;margin:0;padding:0 0.4em" bgcolor="#F7F7F7">$2 $3</code> when running. This means the command
can be named “Show / Hide Preview” and will appear as “Show
Preview” unless the preview is already showing, in which case it
becomes “Hide Preview”.</p>
<p dir="auto"></p>
</div>
<div style="white-space:pre-wrap">
<blockquote style="border-left:2px solid #777;color:#777;margin:0 0 5px;padding-left:5px">
<div dir="auto">Debouncing an event like this over 300ms would mean
that the event doesn’t</div>
<div dir="auto">fire until 300ms have elapsed where the trigger
wasn’t re-triggered.</div>
</blockquote>
</div>
<div style="white-space:normal">
<p dir="auto">Such complicated terms for “when the user is idle”
:)</p>
</div>
</div>
</div>
</blockquote>
<div style="white-space:normal">
<div dir="auto"></div>
<blockquote style="border-left:2px solid #777;color:#777;margin:0 0 5px;padding-left:5px">
<div dir="auto"></div>
<div dir="auto">
_______________________________________________</div>
<div dir="auto">textmate mailing list</div>
<div dir="auto"><a href="mailto:textmate@lists.macromates.com">textmate@lists.macromates.com</a></div>
</blockquote>
</div>
<div style="white-space:normal">
<blockquote style="border-left:2px solid #777;color:#777;margin:0 0 5px;padding-left:5px">
<p dir="auto"><a href="http://lists.macromates.com/listinfo/textmate" style="color:#777">http://lists.macromates.com/listinfo/textmate</a></p>
</blockquote>
</div>
</div>



<br>_______________________________________________
<br>textmate mailing list
<br><a href="mailto:textmate@lists.macromates.com">textmate@lists.macromates.com</a>
<br><a href="http://lists.macromates.com/listinfo/textmate">http://lists.macromates.com/listinfo/textmate</a></div></div></span></blockquote></body></html>