Loading...
 
Skip to main content

Code plugin messes up page width (right hand column is now offscreen)

Status
Closed
Subject
Code plugin messes up page width (right hand column is now offscreen)
Version
3.x
Category
  • Error
  • Usability
  • Consistency
  • Less than 30-minutes fix
Feature
Wiki (page view, edit, history, rename, etc)
Wiki Plugin (extends basic syntax)
Submitted by
ChadDa3mon
Volunteered to solve
Gary Cunningham-Lee
Lastmod by
Gary Cunningham-Lee
Rating
(0)
Description

When you use the code plugin, the page width formatting is thrown off. Instead of seeing both left/right colums, the right column gets shoved off the screen and I have to scroll. This is with scroll bars already setup on the code plugin itself.

--
Chealer :
This happens when nowrap was not set.

Gary (chibaguy):
In my checking (trunk version, but same relevant CSS as in Tiki 3 and $), almost all browsers respect the overflow:auto rule for the code plugin and don't cause the page to widen. I put a long unbroken line of text in the code plugin, and in Opera, IE, Safari (Windows), and SRWare Iron (Chromium - webkit), even this unbroken line was broken to impose a scrollbar on the code area and avoid a scrollbar on the window. Firefox was the only browser that failed at this.

If the current rules - overflow:auto, and 90% width in some themes - then all browsers will allow the long line to display unbroken and create the page-bottom scrollbar, pushing the right column out of view. As I understand it, this is the behavior reported as a bug here.

Solution

All themes define the code class codelisting with overflow: auto; but this doesn't work. Some themes set width: 90% but that only gives a horizontal bar ~10% wider than the longest code line. Gary, could you look at that? If there's no way to set the width to avoid enlarging the page, we should probably get rid of the horizontal bar.

Gary: The overflow:auto does work, if the plugin parameter wrap=1 is set, with the exception that Firefox won't break an unbroken line of text, so IMO the current behavior is appropriate. If I'm misunderstanding the problem, please file another bug request with more information.

Workaround
Firefox will also break an unbroken line to fit into the code area if the area is given a width, so to ensure that wide code content will not widen the center column and push the right column out of view, the theme stylesheet can be edited to give .codelisting a specific width in units (not a percentage).
Importance
7
Easy to solve?
8
Priority
56
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
2513
Created
Monday 18 May, 2009 13:19:24 UTC
by Unknown
LastModif
Monday 18 January, 2010 05:54:31 UTC


Show PHP error messages