Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Why is the PerlMonks page too wide?

by SiteDocClan
on Nov 18, 2005 at 17:38 UTC ( #509881=sitefaqlet: print w/ replies, xml ) Need Help??

Why is the PerlMonks page too wide?

That is, something is causing the page to be wider than my browser window, forcing me to scroll horizontally.

This node describes some of the most common causes of pages rendering too wide.

Sometimes, the problem is purely an issue of the content of the node. Because these affect everyone, regardless of settings, the solutions necessarily involve "fixing" the node. Examples:

  1. You're viewing a node that has a long line inside of a <pre> tag.

    Solution: /msg the author or solicit one of the janitors to fix the problem. (This usually means replacing the <pre> tags with <code> tags.)

  2. You're viewing a node that has a very long string containing no whitespace. (Note - This could affect different users differently, because line-wrapping behavior is browser dependent. Some browsers wrap on certain non-whitespace characters. And some browsers (notably IE) are crazy enough to not wrap on certain types of whitespace such as a space followed by a slash).

    Solution: /msg the author or solicit one of the janitors to fix the problem. (The usual fix is to put the very long string into <code> tags with a newline.)

In other cases, the problem is an issue of how the node content is interacting with your Display Settings. You should suspect one of these might be the cause if you see a particular node render very wide but no one else does.

  1. You're viewing a node with a long line of code, and you have "Code Wrapping Off" checked (in your Display Settings). This disables all code wrapping; it makes <code> blocks effectively like <pre> blocks.

    Solution: Un-check "Code Wrapping Off" in your Display Settings.

  2. You're viewing a node with a code block containing a long string with no whitespace, and you have "Auto Code Wrap" turned on (see New code wrap options), and you have your "Code Wrap Length" set quite high in your Display Settings.

    Solution: You should either set your "Code Wrap Length" to something low, like between 20 and 40; or turn off "Auto Code Wrap" entirely.

  3. You're viewing a node with a code block containing a long string with no whitespace, and you have "Auto Code Wrap" turned on (see New code wrap options), but you're using a browser that doesn't support soft hyphens.

    Solution: For quite a while, IE was the only browser that supported soft hyphens. But support for soft hyphens is now much more common. If your browser doesn't, it's time to think about upgrading. If that isn't an option, then you can simply turn off "Auto Code Wrap".

Other possible causes:

  1. You're viewing a public or private /msg containing a long line that trickily thwarts the Chatterbox Nodelet's efforts to ensure a sane wrap width. (It does this by inserting whitespace into long strings of non-spaces.) Or possibly the Chatterbox Nodelet is inserting those spaces as intended, but your browser isn't wrapping on them (as noted above).

    Solution: In either case, you basically have two options: switch browsers, or bear with it until the offending message goes away. (If it's in your message inbox, you can delete it.)

  2. You added CSS (in your Display Settings) that makes textareas wide (for example, textarea { width: 100%; }

    Solution: reduce that to a value that works for you, such as 75%. Or remove it altogether.

  3. You've added some text to your Personal Nodelet or Free Nodelet that's forcing your nodelet sidebar to be wider than normal.

    Solution: edit the contents of your Personal Nodelet or Free Nodelet. URLs, for example, should have relatively short link text. Also remember that browsers wrap (break) on whitespace rather liberally — a fact you can exploit to good effect.

Based on the threads Pages often too wide, Occasional PM's page width problem, Monastery Gates page is too wide, New code wrap options, Space or Soft Hyphens, and others.


Back to PerlMonks FAQ
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2014-09-23 08:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (213 votes), past polls