From ron_elicit@yahoo.com Tue Sep 4 02:09:24 2007 From: Jon Ippolito To: textmate@lists.macromates.com Subject: [TxMt] HTML autoconversion of urls to hyperlinks Date: Tue, 04 Sep 2007 02:09:00 +0000 Message-ID: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============8407885330086921306==" --===============8407885330086921306== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hi all, The Hyperlink Helper bundle is fun, but it would be more useful for me to hav= e a macro that would auto-convert all urls in a text document to active hyperlinks--eg, replacing: Please visit my home page at http://mysite.net/home.html today! with Please visit my home page at mysite.net/home.html today! or some variation on this. I could write this macro as a RegExp global replace, but I was thinking someo= ne else may have already scripted it. If you know of a pre-existing macro, please let me know. BTW this forum has been very helpful and quick to respond in the past--thanks for the support! jon --===============8407885330086921306==-- From ron_elicit@yahoo.com Tue Sep 4 10:02:29 2007 From: Jon Ippolito To: textmate@lists.macromates.com Subject: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Tue, 04 Sep 2007 10:01:59 +0000 Message-ID: In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3333473670346722435==" --===============3333473670346722435== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Jon Ippolito writes: >=20 > Hi all, >=20 > The Hyperlink Helper bundle is fun, but it would be more useful for me=20 to have a > macro that would auto-convert all urls in a text document to active > hyperlinks--eg, replacing: >=20 > Please visit my home page at http://mysite.net/home.html today! >=20 > with >=20 > Please visit my home page at href=3D"http://mysite.net/home.html">mysite.net/home.html today! >=20 > or some variation on this. >=20 > I could write this macro as a RegExp global replace, but I was thinking som= eone > else may have already scripted it. If you know of a pre-existing macro,=20 please > let me know. >=20 > BTW this forum has been very helpful and quick to respond in the past--than= ks > for the support! >=20 Also, it would be helpful to know if there is a way to turn off the automated title attribute lookup feature when choosing Wrap Selection as Link (Ctrl-Shift-L).=20 It's a nifty feature but slows me down when I'm coding on a slow Internet connection. Thanks! jon --===============3333473670346722435==-- From nilcolor@gmail.com Tue Sep 4 10:23:33 2007 From: Alexey Blinov To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Tue, 04 Sep 2007 14:23:31 +0400 Message-ID: <61450f630709040323y70215fb4oe8caedc7a1670e84@mail.gmail.com> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2054353610217740499==" --===============2054353610217740499== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable On 9/4/07, Jon Ippolito wrote: > > Also, it would be helpful to know if there is a way to turn off the automat= ed > title attribute lookup feature when choosing Wrap Selection as Link > (Ctrl-Shift-L). > > It's a nifty feature but slows me down when I'm coding on a slow > Internet connection. > I doubles this request. --===============2054353610217740499==-- From james.hicks@lightmaker.com Tue Sep 4 10:33:47 2007 From: James Hicks To: textmate@lists.macromates.com Subject: RE: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Tue, 04 Sep 2007 11:34:30 +0100 Message-ID: <004101c7eedf$2dbcbcd0$940e290a@gbrman.lightmaker.local> In-Reply-To: <61450f630709040323y70215fb4oe8caedc7a1670e84@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============7583336509815004509==" --===============7583336509815004509== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit When making image tags into links you get the entire image tag duplicated into the title attribute. Would be nice if the tags were stripped from this and just the filename minus extension was used. James Hicks t. +44 (0)161 834 9889 ____________________________________________________________________________ _________ The information transmitted in this email is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer. ____________________________________________________________________________ _________ -----Original Message----- From: textmate-bounces(a)lists.macromates.com [mailto:textmate-bounces(a)lists.macromates.com] On Behalf Of Alexey Blinov Sent: 04 September 2007 11:24 AM To: TextMate users Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks On 9/4/07, Jon Ippolito wrote: > > Also, it would be helpful to know if there is a way to turn off the automated > title attribute lookup feature when choosing Wrap Selection as Link > (Ctrl-Shift-L). > > It's a nifty feature but slows me down when I'm coding on a slow > Internet connection. > I doubles this request. ______________________________________________________________________ For new threads USE THIS: textmate(a)lists.macromates.com (threading gets destroyed and the universe will collapse if you don't) http://lists.macromates.com/mailman/listinfo/textmate --===============7583336509815004509==-- From brett@circlesixdesign.com Tue Sep 4 17:07:41 2007 From: Brett Terpstra To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Tue, 04 Sep 2007 12:07:38 -0500 Message-ID: <2D056032-6FAA-45E2-9C98-589A0425CB6E@circlesixdesign.com> In-Reply-To: <61450f630709040323y70215fb4oe8caedc7a1670e84@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============7373651239719175900==" --===============7373651239719175900== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit This was already in my HTML bundle, but I can't remember if it was default or not. I have both pop up on Ctrl-Shift-L so that I can choose. Brett On Sep 4, 2007, at 5:23 AM, Alexey Blinov wrote: > On 9/4/07, Jon Ippolito wrote: >> >> Also, it would be helpful to know if there is a way to turn off >> the automated >> title attribute lookup feature when choosing Wrap Selection as Link >> (Ctrl-Shift-L). >> >> It's a nifty feature but slows me down when I'm coding on a slow >> Internet connection. >> > I doubles this request. > > ______________________________________________________________________ > For new threads USE THIS: textmate(a)lists.macromates.com > (threading gets destroyed and the universe will collapse if you don't) > http://lists.macromates.com/mailman/listinfo/textmate --===============7373651239719175900== Content-Type: application/octet-stream Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="WrapSelectionasLinkNoTitle.tmSnippet" MIME-Version: 1.0 PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHBsaXN0IFBV QkxJQyAiLS8vQXBwbGUgQ29tcHV0ZXIvL0R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Zz4KPC9kaWN0Pgo8L3BsaXN0Pgo= --===============7373651239719175900==-- From throw-away-1@macromates.com Wed Sep 5 00:27:11 2007 From: Allan Odgaard To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Wed, 05 Sep 2007 02:27:09 +0200 Message-ID: In-Reply-To: <004101c7eedf$2dbcbcd0$940e290a@gbrman.lightmaker.local> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0585195977388565164==" --===============0585195977388565164== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Sep 4, 2007, at 12:34 PM, James Hicks wrote: > When making image tags into links you get the entire image tag > duplicated > into the title attribute. Would be nice if the tags were stripped > from this > and just the filename minus extension was used. Can you give an example of this? --===============0585195977388565164==-- From throw-away-1@macromates.com Wed Sep 5 00:30:22 2007 From: Allan Odgaard To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Wed, 05 Sep 2007 02:30:21 +0200 Message-ID: <75E245FB-6FCC-43EA-A51B-1A764BAC5FC5@macromates.com> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3728454492169865107==" --===============3728454492169865107== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Sep 4, 2007, at 12:01 PM, Jon Ippolito wrote: > [...] it would be helpful to know if there is a way to turn off the > automated > title attribute lookup feature when choosing Wrap Selection as Link > (Ctrl-Shift-L). Presently only be editing the command. I see Brent sent an additional command w/o the feature, which would let you pick which each time. Probably that is better than a setting. --===============3728454492169865107==-- From throw-away-1@macromates.com Wed Sep 5 00:32:38 2007 From: Allan Odgaard To: textmate@lists.macromates.com Subject: Re: [TxMt] HTML autoconversion of urls to hyperlinks Date: Wed, 05 Sep 2007 02:32:36 +0200 Message-ID: <73F98075-98C6-4B4C-89AA-31062780DC17@macromates.com> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5833166881881705608==" --===============5833166881881705608== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit On Sep 4, 2007, at 4:09 AM, Jon Ippolito wrote: > [...] it would be more useful for me to have a macro that would > auto-convert all urls in a text document to active hyperlinks [...] > > I could write this macro as a RegExp global replace, but I was > thinking someone > else may have already scripted it. If you know of a pre-existing > macro, please > let me know. Are you familiar with Markdown? Perhaps it would be more effective for you to write the first draft of your text in Markdown and press ⌃⇧H to generate the HTML -- Markdown will convert into http://macromates.com/ --===============5833166881881705608==-- From brett@circlesixdesign.com Wed Sep 5 13:10:08 2007 From: Brett Terpstra To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Wed, 05 Sep 2007 08:10:06 -0500 Message-ID: <60E40B64-8979-420B-A62F-9CC0D20B1E79@circlesixdesign.com> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============7647270995427640693==" --===============7647270995427640693== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit He's right. If you just highlight a full image tag and choose Wrap as Link, it will insert the full image tag into the title attribute. I have a regex to strip that, I'll upload tonight. Brett On Sep 4, 2007, at 7:27 PM, Allan Odgaard wrote: > On Sep 4, 2007, at 12:34 PM, James Hicks wrote: > >> When making image tags into links you get the entire image tag >> duplicated >> into the title attribute. Would be nice if the tags were stripped >> from this >> and just the filename minus extension was used. > > Can you give an example of this? > > > > > ______________________________________________________________________ > For new threads USE THIS: textmate(a)lists.macromates.com > (threading gets destroyed and the universe will collapse if you don't) > http://lists.macromates.com/mailman/listinfo/textmate --===============7647270995427640693==-- From brett@circlesixdesign.com Thu Sep 6 01:06:58 2007 From: Brett Terpstra To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Wed, 05 Sep 2007 20:06:56 -0500 Message-ID: <57AC9801-8A5D-408C-B8EC-7212FA6E7595@circlesixdesign.com> In-Reply-To: <60E40B64-8979-420B-A62F-9CC0D20B1E79@circlesixdesign.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2852699095538191232==" --===============2852699095538191232== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit This is a modification of the command in the Hyperlink bundle as a new command. It just adds code that checks to see if there is a title, and if not, checks to see if it's linking an image (HTML) and grabs, in order, it's alt or src attribute for the title. It's rough, but it does need to be done. The linking bundle frequently sticks entire html tags into the title attribute. I'm a huge fan/ proponent of proper title attributes, so I'd like to make them as convenient as possible. Also, I'm pretty sure that I made this version too HTML specific to be worth much to the Hyperlink Helper bundle. But I only had about 5 minutes to spend on it, so I'm offering what I can. Brett On Sep 5, 2007, at 8:10 AM, Brett Terpstra wrote: > He's right. If you just highlight a full image tag and choose Wrap > as Link, it will insert the full image tag into the title > attribute. I have a regex to strip that, I'll upload tonight. > > Brett > > On Sep 4, 2007, at 7:27 PM, Allan Odgaard wrote: > >> On Sep 4, 2007, at 12:34 PM, James Hicks wrote: >> >>> When making image tags into links you get the entire image tag >>> duplicated >>> into the title attribute. Would be nice if the tags were stripped >>> from this >>> and just the filename minus extension was used. >> >> Can you give an example of this? >> >> >> >> >> _____________________________________________________________________ >> _ >> For new threads USE THIS: textmate(a)lists.macromates.com >> (threading gets destroyed and the universe will collapse if you >> don't) >> http://lists.macromates.com/mailman/listinfo/textmate > > > ______________________________________________________________________ > For new threads USE THIS: textmate(a)lists.macromates.com > (threading gets destroyed and the universe will collapse if you don't) > http://lists.macromates.com/mailman/listinfo/textmate --===============2852699095538191232== Content-Type: application/zip Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="wrapaslink.zip" MIME-Version: 1.0 UEsDBBQAAAAIAFqgJTejBUmQtwQAAEIJAAAtAAAAV3JhcCBXb3JkIDogU2VsZWN0aW9uIGFzIExp bmsgcmVkdXgudG1Db21tYW5knVZrd9o4EP28/IqJaWo7xBawIU8I5bmb0zThBNh2FwjH2IJ4sWVX lgNpyP72HZlHCU3PnrMfbEbSzNw7VyOLYnnue/BIeeQGrKTkzKwClN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R2fUn BNLJmlAjrBhc35pQmFGVU5B7hEodwoRbIxAPdIUw5oG/CvAEoIwRt5N2eIWR+JaU3r0yyCgkWQdY C5W4rWXCLCVFSxx1BZUAVGHZfes++0kg4v4kEDVJ3rBswuTrA427qsnoTFt/uK+vbj4Om7d3nyod daDjzkWxJ3Zvh7HleSPLnl5J4N07YhZwZzfAfcsxoh61hRuwXW98Gl9jF7sIG3Y36v56151ZPt31 +sytED4jEyDQXuOAFcG1PGOcOvF8N00QizdIuiyiXFSiNnPDkP6gRGRj/+3GJFfRg/C9Q9iYuD18 6gQztj0nLdejq6nRyA6c9cAPXCaf1RD3QfDYFjFSlxO7POLY/eGyPio0qqfH+abRLODrKHtWMKrV wq9G/iR/cnZ8Wmnkjrfu/SJZ/gkpkuQvymXqX1BLAQIUAxQAAAAIAFqgJTejBUmQtwQAAEIJAAAt AAAAAAAAAAAAAACkgQAAAABXcmFwIFdvcmQgOiBTZWxlY3Rpb24gYXMgTGluayByZWR1eC50bUNv bW1hbmRQSwUGAAAAAAEAAQBbAAAAAgUAAAAA --===============2852699095538191232==-- From throw-away-1@macromates.com Thu Sep 6 04:39:30 2007 From: Allan Odgaard To: textmate@lists.macromates.com Subject: Re: [TxMt] Re: HTML autoconversion of urls to hyperlinks Date: Thu, 06 Sep 2007 06:39:28 +0200 Message-ID: <49D02B64-1488-48DD-A7A4-6A19FCFBB7F8@macromates.com> In-Reply-To: <60E40B64-8979-420B-A62F-9CC0D20B1E79@circlesixdesign.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3830392829314281751==" --===============3830392829314281751== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Sep 5, 2007, at 3:10 PM, Brett Terpstra wrote: > He's right. If you just highlight a full image tag and choose Wrap > as Link, it will insert the full image tag into the title > attribute. [...] Not for me. If I have a URL on the clipboard, it inserts the page title in the title attribute, otherwise it does not insert any title attribute at all (for the a tag). --===============3830392829314281751==--