Results 1 to 13 of 13
  1. #1
    Join Date
    Dec 2000
    Location
    Milwaukee, WI
    Posts
    139

    Dreamweaver - Insert Spaces When Tab is Pressed?

    I've always used Homesite as my webpage editor. In Homesite there is an option in the settings menu that allows for spaces to be inserted when the tab key is pressed. I just recently had to use Dreamweaver and noticed there is really no specific setting that does the same. There is a menu that allows you to set line indenting to use spaces, but what about when the tab key is pressed? Does anyone know how to make the tab key insert spaces instead of the actual tab character in Dreamweaver? I googled this topic but didn't find much at all.

  2. #2
    Join Date
    Jan 2002
    Location
    Toronto, Canada
    Posts
    11,059
    If by spaces you mean adding non-breaking spaces, you can do that in DW with

    Ctrl-Shift-spacebar

    Vito
    DemoDemo.com - Flash tutorials since 2002
    DemoWolf.com - 5,300+ Flash tutorials for hosting companies, incl. Voice tutorials

  3. #3
    Join Date
    Dec 2000
    Location
    Milwaukee, WI
    Posts
    139
    No I'm referring to spaces within the editor. Instead of using tabs to indent lines, I prefer to use spaces i.e. hit the spacebar 4 times then begin coding a line. Homesite allowed you to make the "Tab" key display spaces instead of a tab. I always set the tab key to display 4 spaces so instead of having to hit the spacebar 4 times I can just hit tab once for each indentation. I can't figure out how to do the same in Dreamweaver. In Dreamweaver the tab key simply inserts a tab and not spaces, like Homesite used to do.

  4. #4
    Join Date
    Jan 2002
    Location
    Toronto, Canada
    Posts
    11,059
    I see. Sorry, I don't know how to do that, sorry.

    Vito
    DemoDemo.com - Flash tutorials since 2002
    DemoWolf.com - 5,300+ Flash tutorials for hosting companies, incl. Voice tutorials

  5. #5
    Join Date
    Dec 2003
    Location
    Vancouver BC, eh?
    Posts
    570
    Are you talking about Edit-->Preferences->Code Format

  6. #6
    Join Date
    Dec 2000
    Location
    Milwaukee, WI
    Posts
    139
    Well, I guess, but I'm not sure I get what to enter in the settings there. Right now I have "Indent" checked, "Use" set to spaces, "Indent size" set to 4 and "Tab Size" set to 4. Whenever I hit tab in an open document, it inserts the tab character though, not 4 spaces. My issue is I would like the "tab" key to insert 4 spaces instead of the actual tab character. (like Homesite allows you to do)

  7. #7
    Are you editing in the design view panel? If so, dw will usually encode special characters. You can try editing in the code view panel, or select "do not encode special characters" in the preference panel: Preferences->Code Rewriting
    Gleem Studios
    www.gleem.com

  8. #8
    Even better....download JEdit. Its the best editor out there and has code formatting for almost every language ever created.

    You have to mess with it a bit to get it the way you want, but when you do, its the best editor you can use next to notepad.exe

    http://www.jedit.org
    ~Marque

  9. #9
    Join Date
    Dec 2000
    Location
    Milwaukee, WI
    Posts
    139
    Originally posted by Gleem
    Are you editing in the design view panel? If so, dw will usually encode special characters. You can try editing in the code view panel, or select "do not encode special characters" in the preference panel: Preferences->Code Rewriting
    I don't think people are understanding what my problem is. I'm not editing HTML code. I'm coding PHP/MySQL. Instead of using tabs to indent lines of code, I prefer to use spaces. In Homesite (what Dreamweaver is basically based off of) you can set the "Tab" key (the key above CAPS LOCK) to insert spaces instead of the tab character. I'm wondering how to do the same in Dreamweaver.

  10. #10
    Join Date
    Dec 2003
    Location
    Vancouver BC, eh?
    Posts
    570
    I thin I know what you are saying. But I am not sure how to do it DW. If you tab it goes 4 spaces, if you go back it goes back 4 spaces. What you want is it to treat the tab like 4 spaces?

  11. #11
    Ok, I'll give it another try. If I'm understanding you correctly, you should be able to accomplish this by setting the "Tab Size" in preferences, as stated before. For example, when I set my tab size to "2" spaces, my tab button will then move the cursor over two spaces, rather than the default of 4. This would be same amount of space as hitting my space bar twice.

    I'm assuming that when you say "tab character" you are refering to the default space that is created when pressing tab, correct?
    Gleem Studios
    www.gleem.com

  12. #12
    ahhh! I think you are right Marble. Unfortunately, I don't know of way to do this either.
    Gleem Studios
    www.gleem.com

  13. #13
    Join Date
    Dec 2000
    Location
    Milwaukee, WI
    Posts
    139
    That sucks that they would remove that feature that was available in Homesite. Yet another reason why I dislike Dreamweaver.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •