- From: Xiaomei Ji <xji@chromium.org>
- Date: Tue, 28 Jul 2009 17:42:04 -0700
- To: public-webapps@w3.org
- Cc: ap@webkit.org, jshin@chromium.org
Received on Wednesday, 29 July 2009 07:33:53 UTC
We are proposing the following API to expose word breaker through JavaScript. document.extendRange(range, "word") It extends the passed-in range to a range in word boundary. If the passed-in range is an empty range, in which the beginning and ending are the same, the empty range will be extended to a one-word range covers the beginning/ending of passed-in range. In the case where the beginning/ending of passed-in range is at a word boundary, the logically next word will be selected. If the beginning and ending of the passed-in range are not the same, the range is extended to word boundary on both sides. Which means the beginning will be extended to the word boundary on its logically left side if it is not at a word boundary, and ending will be extended to the word boundary on its logically right side if it is not at a word boundary. Please let us know if there is any issues, concerns with the proposal. Thanks, Xiaomei
Received on Wednesday, 29 July 2009 07:33:53 UTC