From 96a485cfaa818ece0ef630470fbd0dec3ec4332b Mon Sep 17 00:00:00 2001 From: "karnaze%netscape.com" Date: Fri, 4 Feb 2000 03:17:24 +0000 Subject: [PATCH] new regression tests --- layout/html/tests/table/bugs/bug17826.html | 369 ++------------------- layout/html/tests/table/bugs/bug8411.css | 14 + layout/html/tests/table/bugs/bug8411.xml | 7 + layout/html/tests/table/bugs/file_list.txt | 1 + 4 files changed, 54 insertions(+), 337 deletions(-) create mode 100644 layout/html/tests/table/bugs/bug8411.css create mode 100644 layout/html/tests/table/bugs/bug8411.xml diff --git a/layout/html/tests/table/bugs/bug17826.html b/layout/html/tests/table/bugs/bug17826.html index 633802d597f..60c1a769107 100644 --- a/layout/html/tests/table/bugs/bug17826.html +++ b/layout/html/tests/table/bugs/bug17826.html @@ -1,340 +1,35 @@ - - -BasicTableLayoutStrategy.cpp + + + - - -

BasicTableLayoutStrategy.cpp - Revision 3.152

-There were 4 changes made.
- -
-Legend - - - - -
   Added lines
   Changed lines
   Removed lines
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
BasicTableLayoutStrategy.cpp,3.152
Disk File
Skipping to line 27 
-
#include "nsIStyleContext.h"
-
#include "nsIStyleContext.h"
-
#include "nsStyleConsts.h"
-
#include "nsStyleConsts.h"
-
#include "nsVoidArray.h"
-
#include "nsVoidArray.h"
-
#include "nsHTMLIIDs.h"
-
#include "nsHTMLIIDs.h"
-
 
-
 
-
#if 1
-
#if 0
-
static PRBool gsDebugAssign  = PR_FALSE;
-
static PRBool gsDebugAssign  = PR_FALSE;
-
static PRBool gsDebugBalance = PR_FALSE;
-
static PRBool gsDebugBalance = PR_FALSE;
-
#else
-
#else
-
static PRBool gsDebugAssign  = PR_TRUE;
-
static PRBool gsDebugAssign  = PR_TRUE;
-
static PRBool gsDebugBalance = PR_TRUE;
-
static PRBool gsDebugBalance = PR_TRUE;
Skipping to line 39 
-
 
-
static PRInt32 gsDebugCount = 0;
-
 
-
 
-
PRBool CanAllocate(PRInt32          aTypeToAllocate,
-
PRBool CanAllocate(PRInt32          aTypeToAllocate,
-
                   PRInt32          aTypeAlreadyAllocated,
-
                   PRInt32          aTypeAlreadyAllocated,
-
                   nsTableColFrame* aColFrame,
-
                   nsTableColFrame* aColFrame,
-
                   PRBool&          aConsiderAdj)
-
                   PRBool&          aConsiderAdj)
Skipping to line 164 
-
BasicTableLayoutStrategy::BalanceColumnWidths(nsIPresContext*          aPresContext,
-
BasicTableLayoutStrategy::BalanceColumnWidths(nsIPresContext*          aPresContext,
-
                                              nsIStyleContext*         aTableStyle,
-
                                              nsIStyleContext*         aTableStyle,
-
                                              const nsHTMLReflowState& aReflowState,
-
                                              const nsHTMLReflowState& aReflowState,
-
                                              nscoord                  aMaxWidthIn)
-
                                              nscoord                  aMaxWidthIn)
-
{
-
{
-
  if (gsDebugBalance) {printf("BalanceColumnWidths en max=%d\n", aMaxWidthIn); mTableFrame->Dump(aPresContext, PR_FALSE, PR_TRUE, PR_FALSE);}
-
  if (gsDebugBalance) {printf("BalanceColumnWidths en max=%d count=%d \n", aMaxWidthIn, gsDebugCount++); mTableFrame->Dump(aPresContext, PR_FALSE, PR_TRUE, PR_FALSE);}
-
 
-
 
-
  ContinuingFrameCheck();
-
  ContinuingFrameCheck();
-
  if (!aTableStyle) {
-
  if (!aTableStyle) {
-
    NS_ASSERTION(aTableStyle, "bad style arg");
-
    NS_ASSERTION(aTableStyle, "bad style arg");
-
    return PR_FALSE;
-
    return PR_FALSE;
Skipping to line 696 
-
// Determine min, desired, fixed, and proportional sizes for the cols and 
-
// Determine min, desired, fixed, and proportional sizes for the cols and 
-
// and calculate min/max table width
-
// and calculate min/max table width
-
PRBool BasicTableLayoutStrategy::AssignPreliminaryColumnWidths(nsIPresContext* aPresContext,
-
PRBool BasicTableLayoutStrategy::AssignPreliminaryColumnWidths(nsIPresContext* aPresContext,
-
                                                               nscoord         aMaxWidth)
-
                                                               nscoord         aMaxWidth)
-
{
-
{
-
  if (gsDebugAssign) {printf("AssignPrelimColWidths en max=%d\n", aMaxWidth); mTableFrame->Dump(aPresContext, PR_FALSE, PR_TRUE, PR_FALSE);}
-
  if (gsDebugAssign) {printf("AssignPrelimColWidths en max=%d count=%d \n", aMaxWidth, gsDebugCount++); mTableFrame->Dump(aPresContext, PR_FALSE, PR_TRUE, PR_FALSE);}
-
  PRBool rv = PR_FALSE;
-
  PRBool rv = PR_FALSE;
-
  PRInt32 numRows = mTableFrame->GetRowCount();
-
  PRInt32 numRows = mTableFrame->GetRowCount();
-
  PRInt32 numCols = mTableFrame->GetColCount();
-
  PRInt32 numCols = mTableFrame->GetColCount();
-
  nscoord spacingX = mTableFrame->GetCellSpacingX();
-
  nscoord spacingX = mTableFrame->GetCellSpacingX();
-
  PRInt32 colX, rowX; 
-
  PRInt32 colX, rowX; 
+ + + + + + + + + + + + + + + + +
    
Find a BusinessWhat's NewSearch Tips
 
+ + +

+bug #17826 : Drag the right edge of the window and either widen or +narrow the window; the column widths should oscillate as you resize +the window (tested 1999122008 WinNT) +

+ + diff --git a/layout/html/tests/table/bugs/bug8411.css b/layout/html/tests/table/bugs/bug8411.css new file mode 100644 index 00000000000..9fba2e61d88 --- /dev/null +++ b/layout/html/tests/table/bugs/bug8411.css @@ -0,0 +1,14 @@ +doc { + display: block; + margin: 5px; +} + +p { + display: block; +} + +captionelement { + display: table-caption; + text-align: center; + color: red; +} diff --git a/layout/html/tests/table/bugs/bug8411.xml b/layout/html/tests/table/bugs/bug8411.xml new file mode 100644 index 00000000000..a8cc01c95bf --- /dev/null +++ b/layout/html/tests/table/bugs/bug8411.xml @@ -0,0 +1,7 @@ + + + +

The following text is in a caption element whose style is set to display:table-caption. The element is not inside a table.

+This is a caption element. +

If there's no red text between this text and the previous text the caption is not displayed.

+
diff --git a/layout/html/tests/table/bugs/file_list.txt b/layout/html/tests/table/bugs/file_list.txt index d348964c316..71ad006f576 100644 --- a/layout/html/tests/table/bugs/file_list.txt +++ b/layout/html/tests/table/bugs/file_list.txt @@ -174,6 +174,7 @@ file:///s|/mozilla/layout/html/tests/table/bugs/bug8032-1.html file:///s|/mozilla/layout/html/tests/table/bugs/bug8032-2.html file:///s|/mozilla/layout/html/tests/table/bugs/bug8361.html file:///s|/mozilla/layout/html/tests/table/bugs/bug8381.html +file:///s|/mozilla/layout/html/tests/table/bugs/bug8411.html file:///s|/mozilla/layout/html/tests/table/bugs/bug8499.html file:///s|/mozilla/layout/html/tests/table/bugs/bug8858.html file:///s|/mozilla/layout/html/tests/table/bugs/bug8950.html