[TxMt] <img> & <css> drag commands

Michael michael at stoichiometry.net
Wed Mar 30 10:34:40 UTC 2005


On 29 Mar 2005, at 16:46, Allan Odgaard wrote:

> On Mar 29, 2005, at 16:49, Michael wrote:
>
>> I was wondering if anyone had got the built-in HTML drag commands for 
>> <img> and <css> to work in Textmate 1b5?
>
> It works for me. What's not apparent from the bundle editor is that 
> currently the extension of the file in which you drop the image is 
> used to figure out which drag command to execute.
>
> In the future this will be changed to instead rely on the scope, but 
> for now the HTML file should have one of these extensions: html, htm, 
> rhtml, shtml, phtml, php, php3, php4, php5, inc, cfm, cfml, dbm, dbml.
>
> You can edit the drag command outside TextMate if you're using another 
> extension for your files.
>
>> Currently if I drag a html  or PDF file from the project window into 
>> a HTML file I'm working on it will create a <a href=""> link, but if 
>> I drag an image file or css file onto the HTML file, Textmate will 
>> insert the raw source of the dragged file.
>
> Hmm... judging from this, your document does have the proper 
> extension. Which extension does the dragged CSS or image file have?

.css and .jpg

Interestingly this morning after re-launching Textmate when I drag and 
drop an image I get:

Error 4: no file was specified
	Try 'sips --help' for help using this tool
	<img src="" width="0" height="0" alt="" />

but still get the source of a css file when dragged and dropped.

>
> ______________________________________________________________________
> For new threads USE THIS: textmate at lists.macromates.com
> (threading gets destroyed and the universe will collapse if you don't)
> http://lists.macromates.com/mailman/listinfo/textmate




More information about the textmate mailing list