image +   + text does wrap

RESOLVED INACTIVE

Status

()

Core
Layout
P3
normal
RESOLVED INACTIVE
16 years ago
a day ago

People

(Reporter: Boris 'pi' Piwinger, Unassigned)

Tracking

Trunk
Future
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: DUPEME, URL)

Attachments

(3 attachments, 5 obsolete attachments)

(Reporter)

Description

16 years ago
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0rc1) Gecko/20020419

Go to http://www.heise.de/tp/deutsch/special/copy/12393/1.html. Find some links
with the box-with-arrow symbol infront. If you look at the source you find an
image followed by   and text. If you play with your window width you can
make the image and the text next to it wrap. Then the image is on the end of one
line and a space with the link text on the next line. It should be on the same line.

I don't think, this is bug 42495. Dupe me if I'm wrong.

pi
It's definitely a dupe, but not of 42495...
Whiteboard: DUPEME
*** Bug 139803 has been marked as a duplicate of this bug. ***

Updated

16 years ago
Priority: -- → P3
Target Milestone: --- → Future

Comment 4

16 years ago
Changing QA Contact
QA Contact: petersen → moied
(Reporter)

Comment 5

16 years ago
Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.1b) Gecko/2002080104

Also happening with Windows -> OS=ALL

pi
OS: Linux → All
Hardware: PC → All

Comment 6

15 years ago
This bug also is present even without nbsp.

Take the following file, where link_up.gif is a small image at the height of one
line. The example should be self-explanatory. I add this here and not as a new
bug, because I think it's the same.

<html>
  <head>
    <title>Wrap Error</title>
  </head>
  <body>
    <p>This is a text to show that the wrapping in Mozilla has a <img
    src="link_up.gif">slight error. It should not separate image from
    the word <em>slight</em>.</p>

    <p>This is a text to show that the wrapping in Mozilla has a <img
    src="link_up.gif"> slight error. It may separate image from
    the word <em>slight</em> here.</p>

    <p>This is a text to show that the wrapping in Mozilla has a<img
    src="link_up.gif"> slight error. It should not separate image from
    the word <em>a</em>.</p>
  </body>
</html>

Comment 7

15 years ago
Created attachment 132301 [details] [diff] [review]
patch

A patch calculates aMaxElementWidth of consecutive images and text, and breaks
a line including images.

Comment 8

15 years ago
Created attachment 132302 [details]
testcase for a patch

Comment 9

15 years ago
Created attachment 132303 [details]
testcase for a patch
Attachment #132302 - Attachment is obsolete: true

Comment 10

15 years ago
Created attachment 132304 [details]
a result of a patch

Comment 11

15 years ago
Created attachment 132570 [details] [diff] [review]
patch
Attachment #132301 - Attachment is obsolete: true

Comment 12

15 years ago
The other figures same as an image can be also arranged with text by the text
layout code, if the patch is extended.

Comment 13

15 years ago
Created attachment 132974 [details] [diff] [review]
patch

The patch was corrected because the position of a text was being arranged to
the top.
Attachment #132304 - Attachment is obsolete: true
Attachment #132570 - Attachment is obsolete: true

Comment 14

15 years ago
Created attachment 133001 [details]
screen shot

Comment 15

15 years ago
Created attachment 134481 [details] [diff] [review]
patch

The change for nsLineLayout::FindNextText() was modified.

Updated

15 years ago
Attachment #132974 - Attachment is obsolete: true
*** Bug 231609 has been marked as a duplicate of this bug. ***

Comment 17

14 years ago
Isn't this a special case of bug 172819? If nothing except normal space will act
as a line break after image, &nbsp; won't act too, no?
Assignee: attinasi → nobody
QA Contact: moied → layout

Comment 18

a day ago
Per policy at https://wiki.mozilla.org/Bug_Triage/Projects/Bug_Handling/Bug_Husbandry#Inactive_Bugs. If this bug is not an enhancement request or a bug not present in a supported release of Firefox, then it may be reopened.
Status: NEW → RESOLVED
Last Resolved: a day ago
Resolution: --- → INACTIVE
You need to log in before you can comment on or make changes to this bug.