<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - A composition underline is placed to wrong position in RTL"
href="https://bugs.webkit.org/show_bug.cgi?id=158602#c10">Comment # 10</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - A composition underline is placed to wrong position in RTL"
href="https://bugs.webkit.org/show_bug.cgi?id=158602">bug 158602</a>
from <span class="vcard"><a class="email" href="mailto:Hironori.Fujii@sony.com" title="Fujii Hironori <Hironori.Fujii@sony.com>"> <span class="fn">Fujii Hironori</span></a>
</span></b>
<pre>zalan,
Thanks for your review.
(In reply to <a href="show_bug.cgi?id=158602#c9">comment #9</a>)
<span class="quote">> > Source/WebCore/rendering/InlineTextBox.cpp:938
> > + if (!isLeftToRightDirection())
> > + start = m_logicalWidth - width - start;
>
> Do you mind making a helper function for this as now this logic is both at
> InlineTextBox::paintDecoration and here? (and maybe it's even missing from
> some of the other painting methods)</span >
It has a similar logic.
But, it seems difficult to simplify these codes.
Could you tell me a code you think of.
<span class="quote">> There is this 'start += 1;' a few lines below, does it work fine with RTL?</span >
No problem.
Because this code shortens the underline by 1px each from both sides.
<span class="quote">> // We need to have some space between underlines of subsequent clauses, because some input methods do not use different underline styles for those.
> // We make each line shorter, which has a harmless side effect of shortening the first and last clauses, too.
> start += 1;
> width -= 2;</span ></pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>