Open Bug 87013 Opened 25 years ago Updated 4 years ago

Margin on XUL boxes inside <box equalsize="always"> causes weird layout effects

Categories

(Core :: XUL, defect)

x86
Windows NT
defect

Tracking

()

Future

People

(Reporter: rogerd, Unassigned)

Details

(Keywords: testcase)

Attachments

(1 file)

970 bytes, application/vnd.mozilla.xul+xml
Details
From Bugzilla Helper: User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:0.9.1) Gecko/20010607 BuildID: 2001060703 I'm trying to build a simple table using: <box orient="vertical"> <box flex="1" equalsize="always" > <box style="margin: 2px;" flex="1" > ... </box> <box style="margin: 2px;" flex="1" > ... </box> </box> <box style="margin: 2px;" flex="1" > ... </box> <box style="margin: 2px;" flex="1" > ... </box> </box> </box> When I resize the outer box, the last row is willing to compress the margins (which I don't want), while the preceeding row(s) don't compress but end up sticking off the right-hand edge of the screen. Reproducible: Always Steps to Reproduce: 1. Load the following XUL: <?xml version="1.0" encoding="US-ASCII"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <window id="main" align="center" debug="false" valign="middle" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" > <box flex="1" > </box> <splitter> <grippy/> </splitter> <box style="border: 1px black solid;" orient="vertical" > <box flex="1" equalsize="always" > <box style="background: white; margin: 20px;" flex="1" > <text value="1111111111111" /> </box> <box style="background: white; margin: 20px;" flex="1" > <text value="2222222222222" /> </box> </box> <box flex="1" equalsize="always" > <box style="background: white; margin: 20px;" flex="1" > <text value="3" /> </box> <box style="background: white; margin: 20px;" flex="1" > <text value="4" /> </box> </box> </box> </window> 2. Using the grippy (the presence of a grippy isn't essential to reproducing the problem, but does make it easier to try out), make the table narrower. Actual Results: The last row compresses (which it shouldn't), while the preceeding row goes off the right-hand edge of the screen. Expected Results: The table refuses to compress.
Attached file XUL file for test case —
Keywords: testcase
box --> evaughan
Assignee: trudelle → evaughan
Target Milestone: --- → mozilla1.0
I'll take a look. But you should try doing a grid for this. Try: <grid> <columns> <column flex="1"/> <column/> <column/> </columns> <rows> <row> <button value="1"/> <button value="2"/> <button value="3"/> </row> <row> <button value="4"/> <button value="5"/> <button value="6"/> </row> </rows> </grid>
Status: NEW → ASSIGNED
Target Milestone: mozilla1.0 → Future
Component: XP Toolkit/Widgets: XUL → XUL
QA Contact: jrgmorrison → xptoolkit.widgets

The bug assignee is inactive on Bugzilla, so the assignee is being reset.

Assignee: eric → nobody
Status: ASSIGNED → NEW
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: