Closed Bug 442554 Opened 14 years ago Closed 14 years ago

layout.word_select.eat_space_to_next_word should not change word selection method

Categories

(Core :: DOM: Selection, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: hidenosuke, Assigned: masayuki)

References

Details

(4 keywords)

Attachments

(2 files, 1 obsolete file)

If layout.word_select.eat_space_to_next_word is set to true,
word selection method in Japanese text is different from Fx2.

Example text:
カレーは大好きです。甘口より辛口が好きです。

Steps to reproduce:
1. Set layout.word_select.eat_space_to_next_word to true
2. Double click at the top of example text

Actual result:
Selection range is "カレーは大好きです"

Expected result:
Selection range is "カレー"
This is the same behavior as Fx2.
Additional information:
I confirmed with 2008062804-trunk/Windows XP and 2008062902-trunk/Linux.
Component: General → Selection
Product: Firefox → Core
QA Contact: general → selection
Keywords: testcase
Summary: layout.word_select.eat_space_to_next_word shuld not change word selection method → layout.word_select.eat_space_to_next_word should not change word selection method
Attached patch Patch v1.0 (obsolete) — Splinter Review
If aWordSelectEatSpace of nsTextFrame::PeekOffsetWord() is true, aState->mSawBeforeType is not set to true in most CJ text. Because CJ words are not separated by white spaces.

If the previous character and the current character are not white space but the current character is word breakable before it, we should not check aState->mSawBeforeType.
Assignee: nobody → masayuki
Status: NEW → ASSIGNED
Attachment #327970 - Flags: superreview?(roc)
Attachment #327970 - Flags: review?(roc)
Flags: wanted1.9.0.x?
Keywords: intl, regression
Attached patch Patch v1.1Splinter Review
fix some nits and adding a document.
Attachment #327970 - Attachment is obsolete: true
Attachment #328079 - Flags: superreview?(roc)
Attachment #328079 - Flags: review?(roc)
Attachment #327970 - Flags: superreview?(roc)
Attachment #327970 - Flags: review?(roc)
Comment on attachment 328079 [details] [diff] [review]
Patch v1.1

Great!

But please add a mochitest before checking in. You can add it to test_word_movement.html.
Attachment #328079 - Flags: superreview?(roc)
Attachment #328079 - Flags: superreview+
Attachment #328079 - Flags: review?(roc)
Attachment #328079 - Flags: review+
checked-in.
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Comment on attachment 328636 [details] [diff] [review]
Patch v1.1 + mochitest

Let's land this patch to 1.9.0 branch. This bug is very unusable for Japanese Win32 users. And the risk is not high.
Attachment #328636 - Flags: approval1.9.0.2?
Comment on attachment 328636 [details] [diff] [review]
Patch v1.1 + mochitest

Approved for 1.9.0.2. Please land in CVS. a=ss.
Attachment #328636 - Flags: approval1.9.0.2? → approval1.9.0.2+
checked-in to 1.9.0 branch.
Keywords: fixed1.9.0.2
Verified with  Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.0.2) Gecko/2008090212 Firefox/3.0.2.
Flags: wanted1.9.0.x?
You need to log in before you can comment on or make changes to this bug.