GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   why do so many designers use 2 spaces instead of tab in HTML? (https://gfy.com/showthread.php?t=849374)

brandonstills 08-20-2008 11:46 PM

why do so many designers use 2 spaces instead of tab in HTML?
 
Is that a Dreamweaver thing?

When trying to edit it everything gets misaligned. Plus spaces don't play well with most text editor indentation tools.

I have to reformat all the HTML I get delivered just so I can modify it and add code to it.

borked 08-20-2008 11:57 PM

just use your editor (if it supports it) to replace two spaces with a tab (\t)

spacedog 08-21-2008 12:01 AM

probably because there is no tab in html.
You'd have to use span or pre

borked 08-21-2008 12:15 AM

I thought he was talking about misaligned code... double spaces won't do anything in html either, you'd have to type   

mattz 08-21-2008 12:18 AM

umm no two spaces exsist in html

JamesK 08-21-2008 12:19 AM

there's no such thing as tab

brandonstills 08-21-2008 12:19 AM

I'm talking about indentation not spaces actually showing up on the rendered page.

Substituting 2 spaces with \t will work for most cases though. I'll give that a try.

brandonstills 08-21-2008 12:22 AM

Quote:

Originally Posted by borked (Post 14639871)
I thought he was talking about misaligned code... double spaces won't do anything in html either, you'd have to type   

I am. Thought it was obvious from the context of talking about indentation and text editors.

GrouchyAdmin 08-21-2008 01:47 AM

You're the first self-proclaimed programmer I've ever seen to bitch about spaces vs tabs in favor of tabs. The first. I've been doing this for over 15 years, and HTML beautifying for about 12. Congratulations!

GrouchyAdmin 08-21-2008 01:54 AM

Quote:

Originally Posted by borked (Post 14639871)
I thought he was talking about misaligned code... double spaces won't do anything in html either, you'd have to type   

You don't want to see how KHTML handles that. It's.. really awful. They don't even use a real lexer; they just search for two space chars, and inline strcpy, and place   in place of one, then strcpy the rest.

I found this tidbit when I got bitched at by the 18th warez-trillian-0.4 owner who said my sentences kept having &jibberish. I double space my sentences; it's more legible that way.

AlienQ - BANNED FOR LIFE 08-21-2008 02:31 AM

I have found that sometimes white space can break layouts from time to time, but the reason I am posting is, why are you paying for a web coder that does that kind of thing?

brandonstills 08-21-2008 04:13 AM

Quote:

Originally Posted by GrouchyAdmin (Post 14640006)
You're the first self-proclaimed programmer I've ever seen to bitch about spaces vs tabs in favor of tabs. The first. I've been doing this for over 15 years, and HTML beautifying for about 12. Congratulations!

Congratulations for what? I've been programming for almost twice that by the way... Not that I see the relevance.

Why do you think they invented the tab key in the first place? For indentation. What's the space key for? For separating words and sentences (tokens in code parlance).

Try changing the indentation on a block of code when it has spaces instead of tabs. Both vi and Textmate don't like it very much. I hate 2 spaces. What are you still using DOS with an 80x25 character display? Change your screen resolution and font size. 2 spaces is like a few millimeters. Barely even noticeable that it's indented. If you use tabs you can let the user control tab sizes, thus letting the user choose their preference. Congratulations for making it really difficult for me to notice the indentation.

Gee, let me hit space 4 times to indent instead of tab once. Want to go back, now I have to hit delete multiple times. Congratulations for wasting my time.

If I'm editing HTML code and I hit enter to create a new line and then hit tab to indent... well it indents different distance from the code below that should be at the same indentation level. Congratulations for fucking up my indentation.

If I want to change the indentation and highlight a block and tell it to unindent, guess what, it only goes to the left 1 space instead of 1 indentation level. Congratulations for wasting my time yet again.

BTW, I used to use spaces about 15 years ago when I programmed in DOS. It made sense back then because 8 spaces for tab was huge. But that's not the case anymore. Almost nobody uses 8 spaces for tab and screen resolutions are much higher now. A wise UNIX teacher taught me to use tabs and that was some of the best advice I have ever been given.

Lycanthrope 08-21-2008 06:27 AM

Fucks spaces AND tabs.

Spunky 08-21-2008 06:29 AM

Format C

misterhhs 08-21-2008 06:31 AM

I never use html tricks for designing a page. It's perfect possible with css alone.

TheDoc 08-21-2008 06:40 AM

Two spaces is the proper space between a sentence for a paragraph.

raven1083 08-21-2008 06:44 AM

no tab at all

undersoul 08-21-2008 08:06 AM

Quote:

Originally Posted by brandonstills (Post 14639879)
Substituting 2 spaces with \t will work for most cases though. I'll give that a try.

that should do the trick :thumbsup

ScottXXX 08-21-2008 08:09 AM

most everyone that I've seen that does that is using dreamweaver with its out of the box settings

SCORE Ralph 08-21-2008 08:29 AM

Quote:

Originally Posted by GrouchyAdmin (Post 14640006)
You're the first self-proclaimed programmer I've ever seen to bitch about spaces vs tabs in favor of tabs. The first. I've been doing this for over 15 years, and HTML beautifying for about 12. Congratulations!

Then it must be a new-school thing to use Tabs over spaces. Every young programmer here uses tabs, older guys use dual-spacing. Must be something theyre are teaching now... Im self-taught and prefer tabs.

Iron Fist 08-21-2008 08:35 AM

Just html code formatting? Who cares :)

brandonstills 08-21-2008 01:11 PM

Quote:

Originally Posted by aspwm (Post 14641000)
Then it must be a new-school thing to use Tabs over spaces. Every young programmer here uses tabs, older guys use dual-spacing. Must be something theyre are teaching now... Im self-taught and prefer tabs.

Actually about 15 years ago it WAS better to use spaces than tabs. I hinted on a few reasons for that earlier but now they don't apply anymore IMO. Also, text editors work well with tabs, they don't work well with spaces.

brandonstills 08-21-2008 01:12 PM

Quote:

Originally Posted by sharphead (Post 14641036)
Just html code formatting? Who cares :)

tryre adingadocume ntthatisnotf ormattedcorrec tlyanddo esnotfol lowanygo odrulestom akeite as ytoreadan dtheny outellme formatt ingdoe snot ma tter.

ScottXXX 08-21-2008 01:21 PM

Sadly, I read that just fine.

bbm 08-21-2008 01:22 PM

Its easier

2012 08-21-2008 02:24 PM

Quote:

Originally Posted by brandonstills (Post 14639786)
Is that a Dreamweaver thing?

When trying to edit it everything gets misaligned. Plus spaces don't play well with most text editor indentation tools.

I have to reformat all the HTML I get delivered just so I can modify it and add code to it.

... gosh, that's gotta suck. I hate the "search/replace" feature myself.

So...
*PHP syntax doesn't meet your standards
*Dreamweaver doesn't cut the mustard
*30+ years as a fulltime programmer

With all that experience have you ever considered creating your own tools or contributing to any open source projects?:thumbsup

borked 08-21-2008 04:12 PM

haha, only amongst programmers can this frikking argument occur!!!

personally, I'm a tab man, and as soon as I see code with spaces for indentation, be it 2 or 4 or whatever, I find what is the tab equivalent and search all/replace.

Each to their own.

Now should opening braces go on a new line or follow on the same line of the code they open?

That is worth an argument......

I personally open braces on the same line that they open as I treat them as a colon or semi colon - they are following on from what was just said, but is in a new context. Those poooofters that just open braces on a new line can't follow the code and so need to visualise where they've opened a brace to be able to close it.

:P

brandonstills 08-21-2008 06:59 PM

Quote:

Originally Posted by fartfly (Post 14642910)
With all that experience have you ever considered creating your own tools or contributing to any open source projects?:thumbsup

I have but finances don't allow me to right now. I used to write tutorials on operating system development back when I was in high school. Loved it. I also have some ideas for new development methodologies that I want to prototype and experiment with but needing to work and pay the bills keeps me away from them. Probably for the better right now. I find myself ignoring everything else and spending a whole week reading arcane computer science papers if I don't watch myself. Eventually I want to write my own language / environment focused on web application development. I haven't decided if I will open source it though. I've thought of doing some open source work with factor, parrot or rubinius to get me some experience in the field when I have more time.


All times are GMT -7. The time now is 04:59 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123