Bug 12115 - RTL text is jumbled on display
Summary: RTL text is jumbled on display
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tables (show other bugs)
Version: 420+
Hardware: Mac OS X 10.5
: P2 Major
Assignee: Nobody
URL: http://www.walla.co.il
Keywords: HasReduction
: 12183 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-01-04 13:59 PST by Pat
Modified: 2007-01-12 01:33 PST (History)
3 users (show)

See Also:


Attachments
The walla.co.il html page in question (15.28 KB, text/html)
2007-01-04 14:16 PST, Pat
no flags Details
How to sign into walla.co.il (207.40 KB, image/png)
2007-01-04 14:30 PST, Pat
no flags Details
Area that is jumbled (61.24 KB, image/png)
2007-01-04 14:35 PST, Pat
no flags Details
reduced test page (4.95 KB, text/html)
2007-01-04 15:08 PST, Pat
no flags Details
Reduction (736 bytes, text/html)
2007-01-06 09:13 PST, mitz
no flags Details
Fix fixed table layout (178.01 KB, patch)
2007-01-06 15:52 PST, mitz
hyatt: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pat 2007-01-04 13:59:19 PST
The rtl text on http://www.walla.co.il is jumbled inside a table, that is nested inside of a <div dir=rtl>.

To reproduce:
Go to http://www.walla.co.il and sign into the email account to read email.
Username:hebrew9 (display name "Just Checking", email "hebrew9@walla.co.il")
Password:12345

You will see that the subject, size, date, and name are jumbled at the end.
You will also see that, if you scroll over the "sent from name" on the right, that the rest of the page content is jumbled.
Comment 1 Pat 2007-01-04 14:16:45 PST
Created attachment 12225 [details]
The walla.co.il html page in question

The html page in question.  The comments below are from this html page.

Here is the start of the <div align=... that the <table> is nested in. The ending </div> is at the bottom of page.
<div name="GHIDDEN" id="GHIDDEN" style="display:none;"></div>
<script id="JSHIDDEN" src=""></script>
<div align="center" dir="rtl">

Here is the <table> that starts to show the text jumbled.
<style>
.w-txt-clip {text-overflow : ellipsis; overflow : hidden}
</style>
<table height=23 width=100% [snip]

Here is the <table> inside a <form> that has the subject, name, size, and date that are completely jumbled.
<table id=gMainList cellpadding=0 cellspacing=0 width=100%>
<col width=20><col width=20 class=w1><col width=30% class="w-txt-clip w3"><col width=70% class="w-txt-clip w3"><col width=0 class="w-txt-clip w2b" nowrap><col width=60 class=w2><col width=30 class=w2>

<tr class="w1 wGroupSep"><td></td><td></td><td colspan=5>היום - יום חמישי</td></tr>
<tr><td colspan=7><div class=sep> </div></td></tr>

<tr height=23 class=wList1 id=mi0><td><input type=checkbox name="m[0]" value="196263413" onclick="wm_s(0,this.checked)"></td><td><img src=http://ico.walla.co.il/wu/d/rtl/v/mail/s1.gif></td><td><nobr><a href="" onclick="return wm_sm(196263413,-1,-1);" title="hebrew9@walla.com">Just Checking</a></nobr></td><td><nobr><a href="" onclick="return wm_sm(196263413,-1,-1);">test</a></nobr></td><td></td><td>22:30:45</td><td>2K</td></tr>
<tr><td colspan=7><div class=sep> </div></td></tr>

</table>
Comment 2 Pat 2007-01-04 14:30:29 PST
Created attachment 12227 [details]
How to sign into walla.co.il
Comment 3 Pat 2007-01-04 14:35:11 PST
Created attachment 12228 [details]
Area that is jumbled 

This screen shot is from Firefox to show what the area in question looks like.
Comment 4 Pat 2007-01-04 15:08:42 PST
Created attachment 12230 [details]
reduced test page
Comment 5 mitz 2007-01-06 09:13:04 PST
Created attachment 12259 [details]
Reduction

The test page reduces to this issue with fixed table layout. Apparently it has nothing to do with RTL.
Comment 6 mitz 2007-01-06 10:30:58 PST
WebKit's fixed table layout tries to satisfy percent widths first, then adds the fixed widths no matter what. I don't know what this algorithm is based on, but Firefox does things differently: it seems to satisfy the fixed widths first, then percentages (if any available width remains; percentages taken out of the original available width), then distribute the remainder among auto columns. If there are no auto columns and the resulting width is less than the available width, everything is scaled up to fit. This is different from WebKit's frameset layout algorithm (in that it blows up fixed lengths even if there are percentages).
Comment 7 mitz 2007-01-06 11:01:47 PST
I don't understand this change: <http://trac.webkit.org/projects/webkit/changeset/3952>.
Comment 8 mitz 2007-01-06 15:52:30 PST
Created attachment 12265 [details]
Fix fixed table layout
Comment 9 Dave Hyatt 2007-01-11 20:32:34 PST
Comment on attachment 12265 [details]
Fix fixed table layout

r=me
Comment 10 Mark Rowe (bdash) 2007-01-11 20:44:56 PST
Landed in r18790.
Comment 11 mitz 2007-01-12 01:33:35 PST
*** Bug 12183 has been marked as a duplicate of this bug. ***