Is the "Code Sample" feature really needed on english.stackexchange?

I mean that feature that is represented by the "101" icon above the question field? I can't think of any possible situation when that feature would be needed on a site about English.

share
    
possible duplicate of Code sample button –  kiamlaluno Apr 30 '12 at 19:11

3 Answers 3

up vote 3 down vote accepted

I agree; at the very least the "code" symbol should not be used. I sometimes use the format for quoting specific words however. (The monospace font makes it stand out nicely.)

share

As Noldorin says, it can be an effective marker of special words or phrases; I use it too. And the mono-space font can be practical. I can understand why you would call the label "code" misleading; but since it has that name almost universally on internet forums, I think we should keep it. As soon as I saw the tooltip "code" it was immediately clear to me what I could use it for.

share
    
Yes, Cerberus. Ironically, I have also started using it after I asked this question. –  brilliant Jan 16 '11 at 20:29
    
@Brilliant: Ha, funny indeed. –  Cerberus Jan 17 '11 at 0:46

Since real HTML tables are not permitted on Stack Exchange sites—heaven forfend someone wants to write an answer that involves correctly formatting complex tabular data—we have to use the “code” feature for this kind of information. It is absolutely needed for tabular data, as in here, here, and here.

On a side note, please do NOT use the “code” format to make words stand out for any reason. Use italics or “quotation marks” for the use–mention distinction and bold for words that you want to make stand out for other reasons.

share
    
WOW!!! That's really something. I completely forgot about tabular data! "On a side note, please do NOT use the “code” format to make words stand out for any reason" - If its only one word, why not? –  brilliant Jan 17 '11 at 7:30
1  
@brilliant: it’s largely just a matter of consistent/standard style, I think — using code for emphasis is much less standard than the alternatives @nohat suggests. Although I can imagine some arguments for using it for the use/mention distinction: its original use for code, emphasising that the formatted material is being quoted absolutely verbatim, even down to punctuation, is an important distinction which we sometimes want to make here and which none of the alternatives imply quite so strongly. –  PLL Jan 17 '11 at 16:28
    
"... none of the alternatives imply quite so strongly" - Does even the "blockquote" feature not imply that? –  brilliant Jan 17 '11 at 19:23
1  
@brilliant: I would argue not. At the least I frequently make significant choices of where to start and end my blockquotes, eliding the rest with ellipses. To me, "Code" implies "exact quote, including everything relevant" - a very strong version of the use/mention distinction. (But then, I'm a programmer; maybe my judgement is biased here.) –  Tynam Jan 18 '11 at 12:05
    
Tynam, please, explain to me what you mean by "eliding the rest with ellipses". Can you, please, give me some example? –  brilliant Jan 18 '11 at 13:08
    
'... please, explain ... "eliding ... with ellipses".' I have quoted the relevant portion of your comment, and I have elided parts that were not necessary, replacing them with ellipses (the '...' to indicate that something was left out (elided)). –  Hellion Jan 18 '11 at 16:12
    
@Tynam: But what about posting a scrap of code, and editing extra comments (with ; or /* or <! or something) into it? I do that. –  Cerberus Jan 18 '11 at 23:18
    
@Cerberus: Good point; hadn't considered that. (I usually only do that when I've altered the code as well, so it's no longer a quote at all. I'll have to think about this one. On the other hand, that doesn't seem likely to be a problem here on English, so I still lean towards the distinction PLL suggested.) –  Tynam Jan 19 '11 at 1:48
    
@Tynam: It is a difficult matter; I haven't made up my mind yet. It should at least be used consistently within one Question. I have been known to use it with predicate logic and Google search terms. I think I would do that again. I have also used it with hypothetical sentences, for 3 reasons: 1. it stands out better than italic or quotation marks; 2. bold is usually used for emphasis, not for anything between code and quotes; and 3. block quotes do not work if you want to mark phrases in the middle of a sentence. –  Cerberus Jan 19 '11 at 2:53
2  
... I think the reason why I used it with my example sentences was that I needed to distinguish those examples from their interpretations, and that italic v. "quote" made the text too messy and harder to process at a glance. A reason why "quoted text" does not stand out well is that it is only marked at beginning and end, unlike text in code. –  Cerberus Jan 19 '11 at 2:58
1  
...Code is especially easy to follow when a marked phrase goes on to the next line. –  Cerberus Jan 19 '11 at 3:05
    
The only kind of quotations I would be likely to use code for are quotations from monospaced texts (mostly text files and such)... –  SamB May 17 '11 at 16:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .