Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Pages often too wide

by spiritway (Vicar)
on Feb 08, 2006 at 05:52 UTC ( [id://528731]=monkdiscuss: print w/replies, xml ) Need Help??

Every so often, some of PerlMonk's pages are too wide to fit my browser without scrolling horizontally. I hate that. I believe the problem is that some code examples have long lines. I changed my display options to wrap code at 50 characters, which I would think is sufficient, but it doesn't eliminate the problem.

Is there some other way to ensure that pages aren't too wide?

Replies are listed 'Best First'.
Re: Pages often too wide (link)
by tye (Sage) on Feb 08, 2006 at 06:28 UTC

      I agree with your original sentiments that this should be a faqlet. When I see the tell tale horizontal scrollbar, I usually make the effort to determine which writeup has the offending long line, and put it up for editing consideration.

      A special case of 2 which deserves mentioning is long URLs, which can be shortened by replacing them with pipe links.

      --

      Oh Lord, won’t you burn me a Knoppix CD ?
      My friends all rate Windows, I must disagree.
      Your powers of persuasion will set them all free,
      So oh Lord, won’t you burn me a Knoppix CD ?
      (Missquoting Janis Joplin)

      ...It wasn't a rhetorical question, but it looks like no answer is coming.

      Sorry, [id://tye], I thought it was a rhetorical question. My apologies.

      Actually, your reference does explain the problem, which apparently is one that would likely affect everyone. The page on which this problem occurred was one in which there were long strings of code without whitespace. I've got Auto Code Wrap going, have the wrap width set to 50 (I even tried 20, with no effect), and still got the effect. My screen is wide enough (1280 px.). Thanks for referring me to the article - it was indeed helpful in explaining what was going on.

        So then the source of the problem is that you are using a browser that doesn't support soft hyphen (which, amazingly, FireFox still doesn't support) and the work-around is to disable "auto" code wrapping (or switch browsers).

        If you didn't "get" that from the linked note, then suggestions on how to make it clearer would be appreciated (I already see plenty of room for improving clarity there, but was hoping one of tbe wordsmiths would greatly improve it when making a sitefaqlet out of it).

        - tye        

Re: Pages often too wide
by shiza (Hermit) on Feb 08, 2006 at 18:04 UTC
    Get a widescreen monitor! j/k, I experience the same thing from time to time.
Re: Pages often too wide
by jalex (Novice) on Feb 12, 2006 at 03:50 UTC
    Options I would try:

    (reasonable approach)I would fiddle with a stylesheet and
    come up with your own stylesheet/css thing that worked
    with your setup.

    (shotgun to kill a bee approach)Buy a 20" widescreen LCD
    from Dell when they are on special for ~400$ or less.
    This could solve the problem you are having plus give
    you a great screen. I would recommend other brands, but
    there just hasn't been a better deal. If you have a
    laptop, consider upgrading to a laptop with a screen
    using 1680x1050 resolution or better.

    Send screenshots or examples and that may inspire a whole
    new set of replies.

Re: Pages often too wide
by turo (Friar) on Feb 11, 2006 at 09:46 UTC

    The perlmonks' cgi only break long lines if it is found a space or tab on some part of line.

    Sometimes, people, writes some one-line code without any spaces, so the result is a wide page. So, trying to wrap the code to 50 chars is useless.
    I wrote once, a script whithout almost any space ... i'm guilty.

    I think, the solution, is not on your browser ...
    Re-educate monks (including me here) for putting some spaces on a long string (every 80 char, p.e.), could be the real solution

    regards
    turo

    Umm, i've noticed that those long unbreakable strings are breaken (with another criteria) when you see the nodes whithout login, as an Anonymous Monk :).

    perl -Te 'print map { chr((ord)-((10,20,2,7)[$i++])) } split //,"turo"'
Re: Pages often too wide
by nasa (Beadle) on Feb 11, 2006 at 00:42 UTC
    What screen resolution are you on.
    You could try
    Right mouse desktop
    Properties
    Settings.
    Then increase your screen area by raising the resolution
    with the slider bar.
    Have a shot
    Works for me.
Re: Pages often too wide
by Anonymous Monk on Feb 08, 2006 at 12:38 UTC

      Which browser and O/S?

      ctl-F11 does nothing for me, with Firefox & Windows XP

      emc

      " When in doubt, use brute force." — Ken Thompson

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: monkdiscuss [id://528731]
Approved by Old_Gray_Bear
Front-paged by hsmyers
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (7)
As of 2024-03-28 14:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found