{"id":3263,"date":"2013-09-11T07:00:00","date_gmt":"2013-09-11T07:00:00","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/oldnewthing\/2013\/09\/11\/why-does-internet-explorer-put-tab-stops-at-8-character-intervals-instead-of-4-like-all-right-thinking-people\/"},"modified":"2013-09-11T07:00:00","modified_gmt":"2013-09-11T07:00:00","slug":"why-does-internet-explorer-put-tab-stops-at-8-character-intervals-instead-of-4-like-all-right-thinking-people","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/oldnewthing\/20130911-00\/?p=3263","title":{"rendered":"Why does Internet Explorer put tab stops at 8-character intervals instead of 4, like all right-thinking people?"},"content":{"rendered":"<p>When you embed a TAB character (U+0009) in a &lt;PRE&gt; block (or more precisely, an element whose <code>white-space<\/code> CSS property is computed to be <code>pre<\/code> or <code>pre-wrap<\/code>), Internet Explorer will move the current position to the next multiple of eight characters. Many people prefer four. (Some <i>insist<\/i> that only four is the correct value and anybody who disagrees with them is simply wrong.)\n Why eight?\n Because that&#8217;s <a href=\"http:\/\/www.w3.org\/TR\/CSS21\/text.html#white-space-model\"> what the standard says<\/a>.<\/p>\n<blockquote class=\"q\"><p> All tabs (U+0009) are rendered as a horizontal shift that lines up the start edge of the next glyph with the next tab stop. Tab stops occur at points that are multiples of 8 times the width of a space (U+0020) rendered in the block&#8217;s font from the block&#8217;s starting content edge.  <\/p><\/blockquote>\n<p> Note that the standard does not provide an extensibility point to customize the position of tab stops. The number eight is hard-coded into the standard. If you don&#8217;t like that, then don&#8217;t use tabs. (There appears to be a draft proposal to add a <code>tab-size<\/code> property to control this, but nothing standard yet, at least not at the time I originally wrote this article.)<\/p>\n<p> Okay, but why did the standard pick eight as the tab stop interval? I don&#8217;t know (never having attended any CSS standardization meetings), but I suspect they were observing existing practice. For reasons unknown even to Wikipedia, teletypewriter tab stops were historically placed at eight-column intervals. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>When you embed a TAB character (U+0009) in a &lt;PRE&gt; block (or more precisely, an element whose white-space CSS property is computed to be pre or pre-wrap), Internet Explorer will move the current position to the next multiple of eight characters. Many people prefer four. (Some insist that only four is the correct value and [&hellip;]<\/p>\n","protected":false},"author":1069,"featured_media":111744,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[26],"class_list":["post-3263","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-oldnewthing","tag-other"],"acf":[],"blog_post_summary":"<p>When you embed a TAB character (U+0009) in a &lt;PRE&gt; block (or more precisely, an element whose white-space CSS property is computed to be pre or pre-wrap), Internet Explorer will move the current position to the next multiple of eight characters. Many people prefer four. (Some insist that only four is the correct value and [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/3263","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/users\/1069"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/comments?post=3263"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/3263\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media\/111744"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media?parent=3263"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/categories?post=3263"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/tags?post=3263"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}