Closed Bug 364071 Opened 18 years ago Closed 18 years ago

Fix nsTextTransformer API so that aWordLenResult will become an output-only parameter again (in Get[Next|Prev]Word)

Categories

(Core :: Layout, defect)

defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: uriber, Unassigned)

Details

Spun off from bug 363732.

Background:
In bug 36163 the aWordLenResult parameter to nsTextTransformer::GetPrevWord and nsTextTransformer::GetNextWord, which was originally an output parameter, was overloaded and became an I/O parameter.
Its value on input (if it's not -1) now indicates an offset in the content where scanning for the next/prev word should stop.

This is confusing, as this parameter now holds a different type of value on input and output.

Plan for fixing this:
Add aBeginOffset and aEndOffset parameters to nsTextTransformer::Init(), that would mark the range inside the content for the transformer to work with. Store these values in data members (mBeginOffset, mEndOffset), and use them where currently the input values of aWordLenResult is used. -1 will be allowed for aEndOffset, signifying "end of content".

Sounds reasonable?
The new textframe code makes nsTextTransformer obsolete, so let's not do this.
WONTFIX, then.
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.