One nice feature would be if the source code was automatically hidden when the question is too big, and clicking on something be able to make the code visible.

In this question people are asking a lot of data, so the question is currently huge and hard to get an overview. This feature would allow people to see the question from a high-level point-of-view, and see the code as they feel they should.

  • 6
    This would only encourage people to dump large segments of code. We want to encourage them to minimize it to just the code that needs to be shown. – Servy Aug 14 '13 at 20:31
  • @Servy I agree that encourage big lots of code is bad, but sometimes seems necessary. In the given question, I gave a minimized example, and only add what people were asking. – fotanus Aug 14 '13 at 20:32
  • 1
    If it's truly necessary to have a large code snippet, then people shouldn't be hiding it. That people want to hide it is a pretty strong indication that there's too much code there. – Servy Aug 14 '13 at 20:34
  • 1
    @Servy what about allow people with some rep turn a block of code in a mode where others can minimize/maximize? This way, we are not encouraging new users to dump a lot of code, and yet for people that are used with the site create a better view for the question. – fotanus Aug 14 '13 at 20:38
  • People who have been using the site for a while should know better than the rest that you shouldn't be including large code snippets, or in the rare cases where they're needed they wouldn't want them hidden. – Servy Aug 14 '13 at 20:41

They could rig up something like this, they already use these interface elements elsewhere in the site:

Code Block Dropdown

So of course, hitting the arrow would bring up the full code block. I'd actually do it somewhat differently in order to not lose width on the code block, but something along these lines would be helpful.

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