From e7b5464dedb45da611051cd81b40866cfaba5e48 Mon Sep 17 00:00:00 2001 From: "attinasi%netscape.com" Date: Thu, 10 Aug 2000 23:03:11 +0000 Subject: [PATCH] Text with 'whitespace:nowrap' no longer uses special Win32-only text measurement code becasue it didn't work. b=42832 r=waterson git-svn-id: svn://10.0.0.236/trunk@76036 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/layout/generic/nsTextFrame.cpp | 4 +++- mozilla/layout/html/base/src/nsTextFrame.cpp | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/mozilla/layout/generic/nsTextFrame.cpp b/mozilla/layout/generic/nsTextFrame.cpp index 3ac3ad324e2..c06b5e0afcc 100644 --- a/mozilla/layout/generic/nsTextFrame.cpp +++ b/mozilla/layout/generic/nsTextFrame.cpp @@ -3618,8 +3618,10 @@ nsTextFrame::MeasureText(nsIPresContext* aPresContext, PRBool justDidFirstLetter = PR_FALSE; #ifdef _WIN32 PRBool measureTextRuns = !aTextData.mComputeMaxWordWidth && !aTs.mPreformatted && - !aTs.mSmallCaps && !aTs.mWordSpacing && !aTs.mLetterSpacing; + !aTs.mSmallCaps && !aTs.mWordSpacing && !aTs.mLetterSpacing && + aTextData.mWrapping; // Don't measure text runs with letter spacing active, it doesn't work + // it also doesn't work if we are not word-wrapping (bug 42832) #else PRBool measureTextRuns = PR_FALSE; #endif diff --git a/mozilla/layout/html/base/src/nsTextFrame.cpp b/mozilla/layout/html/base/src/nsTextFrame.cpp index 3ac3ad324e2..c06b5e0afcc 100644 --- a/mozilla/layout/html/base/src/nsTextFrame.cpp +++ b/mozilla/layout/html/base/src/nsTextFrame.cpp @@ -3618,8 +3618,10 @@ nsTextFrame::MeasureText(nsIPresContext* aPresContext, PRBool justDidFirstLetter = PR_FALSE; #ifdef _WIN32 PRBool measureTextRuns = !aTextData.mComputeMaxWordWidth && !aTs.mPreformatted && - !aTs.mSmallCaps && !aTs.mWordSpacing && !aTs.mLetterSpacing; + !aTs.mSmallCaps && !aTs.mWordSpacing && !aTs.mLetterSpacing && + aTextData.mWrapping; // Don't measure text runs with letter spacing active, it doesn't work + // it also doesn't work if we are not word-wrapping (bug 42832) #else PRBool measureTextRuns = PR_FALSE; #endif