Is there a way to control the height for <pre> blocks? (Edit: I have in mind further limiting beyond the default limit.) For superuser, I think this would be a useful feature (and possibly for other stackexchange sites as well). This is related to a similar discussion titled "Asking a question with lots of source code" (plain text link at bottom).

It seems that good posting practice is to include the minimum amount of quoted text. However, when items such as configuration files, listings of installed packages, etc. are provided in posts, the asker may not know which item an answerer will look for, but a complete list may provide valuable information.

An example is this post, which includes a number of included listings. I came across that reading what meta.su thought were related posts (the top-rated question used this as an example of where <code> tags were causing undesirable formatting).

I used my one link for the example, which I think is more important than the related discussion on meta.so, but here is the link:


The <pre> block already has a max height set, specifically

max-height: 600px;

There are some bugs in IE7 and IE8 that might prevent that from working, but it works in all other browsers.

  • I edited the question - I was unclear. I am aware of the current limit, but it takes up a large part of the screen for what is sometimes a limited-utility backup to the question, rather than an integral part of it.
    – sage
    Jan 8 '11 at 0:56

You must log in to answer this question.

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