TextPad for Mac

August 5th, 2007

If you read my post about my search for a good email client for Mac, you know that I’m also looking for a good usenet client, as well as a text editor. This post is about the latter.

Sorry for the misleading title – there is no such thing as TextPad for Mac. I wish there was though, as I’m very much used to the program on Windows, and really miss it while typing this on a MacBook.

Back when I started writing HTML, I was happy with Windows’ own native text editor, Notepad. My friend John advised me to use TextPad, as it was so much better, he said. I refused, saying I didn’t need anything better than Notepad.

Then one day he just installed it on my pc without asking (!) and I decided to try it, even if only to stop John from nagging me about it. Soon enough I realised it really was better than Notepad (duh!), and I got hooked. Not a big problem, right? Sure. Until you buy a MacBook and discover there is no TextPad for Mac! Thanks a lot John! 😉

Looking for an alternative, I asked a Mac using friend for advice, and she said ‘TextWrangler‘. That’s the prog I’m typing this in, and initially it looked like it could do the same things as TextPad — I’d just have to remember new keyboard shortcuts. Now that I’m actually using it though, it looks like it doesn’t. Most of it is likely because I haven’t figured out how to use half the stuff that’s listed in the menu yet, but there’s one thing I’m pretty sure can’t be set, which annoys me already.

When I’m coding web pages, I like to minimize the amount of typing. So, if I’m writing a list of navigation links, I start like this:

<li><a href=""></a></li>

I then copy and paste that last line as many times as I need, say 8 times:

<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>

Then I place the cursor inside the <a> element, and type the first linktext:

<li><a href="">Home</a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>
<li><a href=""></a></li>

While my cursor is behind the word ‘Home’, I want to go to the right spot to start typing the second link text. And that, is where TextPad does it right, and all the others do it wrong. How so?

Well, in TextWrangler, BBEdit, TextMate, TextEdit, jEdit, skEdit, Smultron, SubEthaEdit, Tag, and probably any other editor — but I couldn’t be bothered to continue testing — I need to navigate to the right place by moving the cursor one position down and several to the left. In TextPad, one press on the down arrow key brings me where I want to be: in the same spot as where I started typing in the previous line, regardless of how many characters I typed. Call me spoiled, but I want a text editor that behaves exactly like that.

I’m not the only one who swears by TextPad by the way, already back in 2004 Andy Clarke was worried how he could be living without TextPad, even though for different reasons. Several people advised him to use BBEdit, and perhaps it does what Andy wanted it for (haven’t tested all its features), but it doesn’t do the job for me.

I went as far as installing CrossOver Mac, a commercial version of Wine, to run TextPad even on my MacBook, but it’s not optimal, and I find myself using TextWrangler for anything that needs a quick edit or for blog posts like this, while firing up my XP box for serious work.

So, anyone know of a text editor for Mac that does what I described above plus of course preferably also the other TextPad features I use on a daily basis such as search & replace, macros, extension defined tag and text colouring, infinite undo, compare files, search in multiple unopened files, regular expressions, different character encodings and split views?


Update June 2008: the above described behaviour in TextPad is only apparent if you’ve set “constrain cursor to text” in the preferences, as Jason Penney discovered.

26 Responses to “TextPad for Mac”

  1. SteveH says:

    You seem to have covered all the bases with your survey of OS X text editors. I would agree with your views on the benefits of TextPad’s line up/down action – I’ve not seen anything like it even in Windows editors and it is a great time saver once you start to rely on it.

    It would be worth persisting with OS X text editors though as perhaps there are other features that will lead to savings in other areas. As you have already picked up BBEdit is something of an institution and I couldn’t imagine not using as the starting point for any form of text editing. For html skEdit (particularly 4.0 beta) is an excellent application and may offer benefits in other areas.

  2. Els says:

    Thanks for your comment, Steve – your "savings in other areas" urged me to have another look at TextWrangler’s options, and I discovered the very handy pre- and suffix. I need to adjust a bit of course, but over time it’ll be just as quick as the way I did it in TextPad.

    Will have a look at skEdit again as well, later. Thanks for the suggestions! 🙂

  3. sharon says:

    I just lstarted working in text wrangler and the text in the working document is so small & I’ve searched for 30 mins and can’t get it bigger – HELP!!


  4. Els says:

    Hi Sharon – sorry for the late reply, somehow my comment notification wasn’t working right, so I only discovered your comment just now.

    To change the text size in TextWrangler, go to the menu at the top, choose View, then Text Display, then Show Fonts. A new window will come up where you can choose the type of font, and also the size.

    Hope this helps 🙂

  5. Sam says:

    I didn’t yet make the switch to Mac but I’m also looking for a tool to replace TextPad. I’m mostly editing TXT file lists and HTML, XML files so mostly I need block selection, regular expressions and find and replace supported with more than one file like different pages of a given site.

    I am also looking for a solution to do a kind of find and replace having both the "to be replaced" and the "to replace for" texts in a list or file. It is usually like names need to be corrected from Fisher, Sam to Sam Fisher but not only one or two at a time but tens or hundreds of times making it a bit time consuming and urging for an automation.

    Any ideas what program can do it for me?

  6. Els says:

    Apart from the problem I described in the above post, most Mac editors work just fine, and I can recommend TextWrangler.

    If you need TextPad for the same reason I do, then there is no alternative for the Mac, other than to run Windows in Parallels or find a good Wine version to run Windows apps in.

    Search and replace is also a feature of most (if not all) text editors, but if you are looking for a good program that can do that over multiple files that aren’t all open, I’d say use WildEdit, by the same people as TextPad. Again, this is a Windows prog, and I have no idea on a similar program for the Mac yet.

  7. Els says:

    Reading your comment again, I now understand you want to do multiple search and replace routines in one. That’s something even WildEdit can’t do I’m afraid. Googling for it, I find this link: which seems to describe exactly what you want:

    "The search and replace process can be automated with the help of batch files to replace several phrases in one step."

    Again though, it’s a Windows program…

  8. DrFooMod2 says:

    At least I know I’m not alone on the blue marble. I too am a TextPad junky and I need something for Mac. I find I use it quite a bit to edit tabular data from Excel (changing tabs to something else — regex baby!) Also, the syntax highlighting is an absolute must. Maybe this discussion should move to a forum somewhere. Email me a link if it does.

  9. JP says:

    As we discussed offline, this behavior of TextPad is actually a setting. You’ve checked "Constrain Cursor to Text" under Preferences>Editor.

    I’m posting here for the benefit of others who happen upon your blog.

  10. Els says:

    Thanks 🙂
    (updated the post itself too now)

  11. Coelacanth says:

    Hello hello,

    I use a LOT of regexes at work (I’m a metadata monkey) and I haven’t had any luck finding a Mac editor that has good regex functionality. Smultron even had the nerve to ask me if I was sure I wanted to find and replace – yuk! (Almost as annoying, it didn’t find and replace either).

    Do you know an editor that has regex functionality, including bookmarking?

  12. Els says:

    Hi Coelacanth,

    As far as I know, Smultron does find and replace, as well as regex – don’t know how well, but it does regex. Find and replace appears to be in the ‘advanced find’ option. (I don’t have Smultron installed anymore, but just read this in the manual: )

    Whenever I’m on the Mac, I use TextWrangler, which also does have regexp of some sort, but the bookmarking is not quite what I’d like:
    To set markers, you need to fill out the string you want to mark, and a string to mark it. Say, you want to search for ‘foobar’, and mark them with ‘x’. Say, the document has 50 occurrences of ‘foobar’. To see them marked in the document, you need to bring up the marker window, where you see a list: 50 lines that each say ‘x’. By clicking the first one, the first occurrence of ‘foobar’ is highlighted in the document. If you click the 25th one in the list, the 25th ‘foobar’ is highlighted. There is however no way of seeing which one you are looking at, other than counting from the top in the list. Hence, only useful if you are trying to find one or two instances, not when there are many.

    I even checked BBEdit, as many people rave about it, but it uses exactly the same marker system as TextWrangler.

    Moral of the story: for serious editing, I just wait till I’m on my Windows box – it seems there is no good Mac alternative to TextPad 🙁

  13. jcmccutcheon says:

    What about emacs? Its built in.

  14. Els says:

    Built in where?
    Typing ’emacs’ into the finder doesn’t find it. Also, although I’m not exactly familiar with emacs, every time I read about it, it’s in the same sentence as ‘vi’. Not exactly encouraging.

    I’m more the GUI type. Not the command line type 😉

  15. rey says:

    Textpad all the way!

  16. Preston says:

    Yes! Finally, someone who also appreciates the superiority of Windows apps for certain things like text editing. I’ve been on a mac for the last few months and simply cannot get into a rhythm like I could on my xp machine. TextPad is simply the best text editing program I’ve come across and I miss it dearly.

  17. A Mac person who learned on Textpad says:

    I stumbled upon your site while looking for a certain Mac friendly text editor myself. The other day I was in Best Buy and one of the guys told me about what he uses on his mac. I am learning XHTML and am very used to Textpad, (John was right on in telling you about it.) With this said, I just can’t use the ‘Textedit’ version of ‘notepad’ on my new Mac Laptop.
    The guy told me about the new program called ‘Coda’ I think it is fairly new and I just downloaded it to my laptop and have been tinking with it for a while. It is suppose to be a one stop shop for all things editing, but we’ll see. I hope so, because I need it! : D

    I like to have highlighting and this program is amazing. It also has smart shortcuts too. i.e. if you type an opening tag it gives you a short cut list of possible tags. In other words, when I type the paragraph tag, it will type the closing tag. When I type the code to place an image, it gives me the option of auto typing the next step in the code etc.

    Check out the site at
    The free demo lasts for 14 days and you can buy the full version if you wish. Check it out and I hope it does everything you got used to in Textpad.

    Happy typing and I hope your week goes swimmingly!

  18. Emacs Dude says:

    Hello – after seeing the problem you laid out, I went and search for similar function on EMACS and found the solution

    1. When you are at the point you want, which would be at the first point between " ", you place the cursor there and press C-x, C-n to choose this place as the point you want to return to in the next line, then you type whatever adress you want.

    2. Press C-n, or C-p to move down the line, right at the point " " of the next line, or the previous line.

    NEAT HEY ? – and emacs if FREE too 🙂

  19. Emacs Dude says:

    I realise you don’t see EMACS, the built-in one works in the Terminal only, so in the Terminal, type emacs.

    If you want the (that opens as a normal text editor) – go to this place to get the OSX app version of Emacs

    I highly recommend it. It will more likely to be one text editor that you’ll ever need 🙂

  20. Emacs Dude says:

    Oh and I forgot – go here for all the basic editing commands in Emacs

    you will love emacs to death 🙂

  21. Els says:

    Hi EmacsDude,

    Wow, three comments in a row, following an earlier Emacs recommendation by jcmccutcheon on this page… sounds like I really should see what it’s like, right? 😉

    Okay, I’ll give in. I don’t have the time for it now, but I’ll make sure I give Emacs a test run in the coming weeks, either to be delighted, or to be disappointed, but I’ll be sure to post my findings when I do.

  22. HSR says:

    I miss TextPad. The best feature was, you right click on anything, and you can see TextPad as an option.

  23. HSR says:

    @A Mac person who learned on Textpad

    Coda is awesome. I just downloaded it. But its quite expensive, especially for non-commercial use.

  24. Am missing textpad in my new macbook pro i was searching for an alternate solution to textpad and I found your blog but it’s seems there is not alternate solution to textpad.


  25. Oliver says:

    I just wanted to add that I moved to OS X over 2 years ago, and I still miss TextPad a lot, and I have yet to find anything quite as capable and well rounded. I have also installed it on my Virtual Windows, but that is a real hassle if you just want to have a quick edit of a document. Maybe one day they will port it over.

  26. Carrie says:

    no one is mentioning textedit. is it too basic? do I need to download textwranger?