"ASSERTION: Overlapping or discontiguous frames => BAD" with floating first-letter, overflow, arabic

RESOLVED WORKSFORME

Status

()

Core
Graphics
RESOLVED WORKSFORME
11 years ago
9 years ago

People

(Reporter: Jesse Ruderman, Assigned: smontagu)

Tracking

(Blocks: 2 bugs, {assertion, testcase})

Trunk
assertion, testcase
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

11 years ago
Created attachment 281957 [details]
testcase

Loading the testcase triggers this assertion, which was added recently in 
bug 393796.

###!!! ASSERTION: Overlapping or discontiguous frames => BAD: 'mappedFlow->mStartFrame == aFrame || mappedFlow->GetContentEnd() == aFrame->GetContentOffset()', file /Users/jruderman/trunk/mozilla/layout/generic/nsTextFrameThebes.cpp, line 1312
Simon, I'll bet my socks this is the bidi resolver.
(Assignee)

Comment 2

11 years ago
Many thanks to Uri for helping me understand what is going on here. It's certainly partly the bidi resolver, but the floating first-letter is also a major character in the drama ;-) 

Is it correct that the continuation frame created for the first letter is a *fluid* continuation? http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/layout/base/nsCSSFrameConstructor.cpp&rev=1.1402&mark=11706-11707#11688
(Note that CreateContinuingFrame has an argument aIsFluid that defaults to true)

In the testcase there is a break between RTL and LTR runs after the first letter, and since the first-letter's continuation is fluid the bidi resolver creates a non-fluid continuation at the same point in the content.
> Is it correct that the continuation frame created for the first letter is a
> *fluid* continuation?

Yes.

So we end up with an empty fluid continuation? I suppose we can probably fix textframe to tolerate that.
(Assignee)

Updated

11 years ago
Assignee: nobody → smontagu
OS: Mac OS X → All
Hardware: PC → All
(Assignee)

Comment 4

10 years ago
I no longer get the assertion with the testcase, but I do get: WARNING: offset before this frame's content: file .../nsTextFrameThebes.cpp, line 4360
(Reporter)

Comment 5

10 years ago
WFM.  I don't even see the warning.  (smontagu, please file a new bug if you think it's worth investigating the warning.)
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → WORKSFORME
(Assignee)

Comment 6

10 years ago
Frametree at the warning:

line 0x8abfe84: count=4 state=inline,dirty,prevmarginclean,not impacted,not wrapped,before:nobr,after:nobr[0x10001] {0,0,0,0} ca={55920,0,780,660} <
  Placeholder(body)(1)@0x8abfefc {0,0,0,0} outOfFlowFrame=Letter(body)(1)@0x8abfc98
  Text(0)@0x8abff34[1,1,T]  next=0x8abfda8 prev-continuation=0x84d8b6c {0,0,0,0} [state=10220000] [content=0x89b5030] sc=0x8a621dc pst=:-moz-non-element<
    "\n"
  >
  Text(0)@0x8abfda8[1,1,T]  next=0x8abfd70 {0,0,0,0} [state=00220204] SELECTED [content=0x89b5030] sc=0x8a621dc pst=:-moz-non-element<
    "\n"
  >
  Inline(span)(1)@0x8abfd70 {0,0,0,0} [state=00e00000] [content=0x88a3ae0] [sc=0x8a5e578]<>
> floats <
  placeholder@0x8abfefc Letter(body)(1) region={55920,0,780,660}
>
Float-list<
  Letter(body)(1)@0x8abfc98 {55920,0,780,660} [state=00000100] [content=0x8a57e98] [sc=0x8a5e194] pst=:first-letter<
    Text(0)@0x84d8b6c[0,1,F]  next-continuation=0x8abff34 {0,0,780,660} [state=00320000] [content=0x89b5030] sc=0x8abfeac pst=:-moz-non-element<
      "\0177267"
    >
  >
>

Notice the two textframes with the same content. I believe this is the same issue as bug 401621.

Updated

10 years ago
Flags: in-testsuite?
(Reporter)

Comment 7

10 years ago
Crashtest checked in.
Flags: in-testsuite? → in-testsuite+
(Reporter)

Comment 8

9 years ago
Simon, did the fix for bug 401621 make the warning in comment 6 go away?
(Assignee)

Comment 9

9 years ago
With current trunk I don't get that warning either with or without the fix.
You need to log in before you can comment on or make changes to this bug.