I came up with these the other day, and thought someone else might
find these useful. They're very small bundles that simply let you type
(while working in HTML) and have properly coded typographic
characters.
I come from a print design background, and am used to being rather
particular with my typography. One of my biggest pet peeves is seeing
a double tick mark (") where a proper quote mark (") should be.
I've been learning to hand-code my websites, but something that always
frustrated me with HTML was having to code out – when I was used
to just hitting opt - (hyphen).
So I came up with the attached snippets that let me do what I wanted
to do - I can type the character as I'm used to typing it, and
Textmate inserts the proper HTML code.
I'll be honest, I got the idea for this when I tried out SkEdit - it
was the one feature that I missed in Textmate. But it was easy enough
to add myself.
Enjoy! I hope there are some typophiles that will like this!
Sorry if it's old news for some of you guys, but I just found out
that using MacFUSE and sshfs makes it super easy to use TextMate
projects/tabs with files on remotes servers (as long as you have SSH
access). I know the question comes back once in a while on here, and
I for one was never really satisfied with the workarounds people
suggested...
This solution makes it really dead simple to get access to all
TextMate Project features... I wrote up a little blog post with the
details if someone's interested:
http://minimaldesign.net/blog/workflow/remote-textmate-projects
Hope it helps :)
Hi All,
I'm new to Textmate, and I have to say I am most impressed! What a
beautiful piece of software. I downloaded the 30 day trial, and I am
having problems with one thing: reformatting php code.
Let's say I had a piece of code like this:
// make sure it doesn't crash in an ugly way
if (!function_exists('foo'))
{
die("this function required");
}
and I run the reformat on it, or ^Q, then I get this:
// make sure it doesn't crash in an ugly way if
(!function_exists('foo')) { die("this function required"); }
Not very helpful, and you notice that the 'if' is now on a comment line!
Note that this performs the same whether I have the file showing as
HTML or PHP. Given the amount of work that's gone into PHP capability
overall (great completion for example) I'm shocked that this is
standard behavior out of the box.
Would love to get some tips from the textmate masters on here. Thank you!
Brian Armstrong
Hi!
Is there a way for do a "replace all" only in a selection? I can only
find "Use selection for find" but that puts only the selected text
into the find-part of the find-dialog.
I searched for something like this in TextMate already quite often
and therefore I think other ppl would use it as well but I can't
remember that I've ever read a feature request for this, therefore it
must be somewhere…
Niels
Hello Allan & other TM friends,
I'm one of the disturbed folks who tries to make life difficult for myself
and those around me by using the Dvorak-Qwerty layout. Apple was kind enough
to create this monster, but not kind enough to provide the adequate means
for developers to fully support it in their apps[1].
Is there anything in the works to handle the DQ layout properly in TM2? I'm
debating a switch to a pure Dvorak[2] layout and since TM is the app I type
into for hours daily it has the largest influence on my decision. I know
it's foolish to think that maybe Leopard will include some new key handling
abilities just for us DQ guys, but I'm clinging to a shred of hope.
The only reason I'm bringing this up is that every now and then a new bundle
shortcut will catch me by surprise, ie. Cmd-Opt-/ (which is Cmd-Opt-[ in
DQ) for commenting blocks overwrote the shortcut for re-indenting a block or
line. Cmd-/ works as it should, but for some reason Cmd-Opt-/ uses the
Dvorak / instead of the Qwerty /. Some default shortcuts don't work at all
(show scope). It's not that big of a deal and I accept that this is the
price I pay for choosing an obscure layout. However, my dislike of surprises
while coding[3] outweighs the benefits of using DQ in the first place; hence
this message.
[1] http://comox.textdrive.com/pipermail/textmate/2005-August/005238.html
[2] Oh how I would/will miss the cut, copy & paste shortcuts. They suck on a
Dvorak layout.
[3] I know, I know. Why the hell do I use the cutting edge build of TM if I
don't want surprises? ;-)
--
Sami Samhuri
http://sami.samhuri.net
Context:
I needed to insert tex files which filenames contained spaces into my
document. LaTex can handle this efficiently if quotes are provided in
the \include (like in \include{"bla bla/bla bla"}).
For easy moving along my document, I intended to use the "Open
Included File" command. But that command doesn't handle the quoted
filenames, as the quotes are taken into account as normal characters.
So here I am with a line to be added to that command in order to
correct that misbehaviour:
10: ...
11: if options.empty?
12: print "Did not find any appropriate item to open in #{ENV
['TM_SELECTED_TEXT'] ? "selection" : "current line" }"
13: else
14: options[0].each{|el| el.gsub!(/(^\")?(\"$)?/, '')} #<--
Here it is!
15: filepath = `kpsewhich #{e_sh options[0]}`.chomp
16: if filepath.empty?
17: ...
I don't know how to commit changes in a bundle (according I am
allowed to!). So now it's up to you, folks, to add it to the repository.
Note that I quickly and unformally tested it, and everything seems ok.
Xavier Cambar
Every so often, TextMate stops handling key bindings for bundle items. Built-in commands still work as expected. When I check ⌃⇧P in Select Bundle Item, it shows ⌃⇧<some roundrect symbol>. The behaviour persists even when I restart TextMate. Logging out seems to fix it. Sometimes it fixes itself. I haven't found anything in console.log.
It just happened to me again. This time I used Key Codes[1] to check what TextMate was getting.
Key Down
Characters:
Unicode: 16 / 0x10
Keys: ⇧^P
Key Code: 35 / 0x23
Modifiers: 2490371 / 0x260003
Terminal saw the modifier as 0x260103. Later, TextMate started showing 0x260103, too, but the command still didn't work.
Finally -- and I have no idea what changed -- things started working again, and I now have a modifier of 0x60103 in all apps.
[1] http://www.petermaurer.de/nasi.php?thema=keycodes&sprache=english