Hi Joan,
>> > 5. OpenOffice should be able to replace the wrong sentences.
>>
>> The checker should preserve formating, footnotes, etc. Ideally these
>> things should not be passed to the checker (the footnotes and the like
>> could be passed when the paragraph or the sentence that includes them
>> has been checked, for example), but if the user chooses to accept a
>> suggestion, the format (i.e. italics), the footnotes, etc. should remain
>> in the original places. Perhaps we could pass "markers" embedded in the
>> paragraph text and then return them in the corrected text to "align"
>> the
>> original and the checked sentences.
>>
>>
>> hum... I think API can deal with it, my idea is not letting grammar
>> checkers deal with these details, only analyse and suggests corrections.
>> It could be difficult letting a grammar checker deal with indexes, text
>> positions, underlining etc.
>
> The checker can have a function to check a sentence (clean). If the user
> wants to replace the original text with a corrected one the API can ask
> the checker to divide the corrected sentence in fragments corresponding
> to fragments in the original sentence. The checker is allowed to ignore
> the request, and even the OpenOffice could not use this function but it
> should exist. No one knows better than the checker the correspondence
> between the original and the corrected sentences. It's not difficult to
> think abot cases very difficult to solve for the API, that doesn't has
> enough information.
>
> For example, my Catalan checker can correct the sentence "El tamany del
> fitxer" ("The size of the file"; "tamany" is a barbarism) to "La mida
> del fitxer". The corrected words can be very different from the original
> ones, there can be more or less words or a change of order. Here is an
> example of my proposal:
> - The user has written "El *tamany* del fitxer", with "tamany" italized.
> - OpenOffice submits "El tamany del fitxer" (a clean text).
> - The checker tells that there is a mistake and that "El tamany" should
> be replaced by "La mida".
> - The user accepts the change.
> - OpenOffice then asks the checker to divide "La mida del fitxer"
> proportionally to 3/6/11, the lengths of the three portions ("El ",
> "tamany" and " del fitxer").
> - The checker responds with 3/4/11, the lengths of "La ", "mida" and
> "del fitxer".
> - OpenOffice can then write down the change without breaking the format.
> - If the checker has not the capability of "aligning" the sentences,
> OpenOffice can proceed by "trial and error".
Even so it possible to do such things (the spellcheck dialog tries sth.
like this on it's own) I will only be of use if there are grammar
checkers that are willing to do this task or even already have an API
of their own for it.
If yet not seen such an API in any grammar checker. Especially not in
commercial ones. Is there already a non-commercial one that does it?
Currently it thinks we should rate this a "nice-to-have". Later if there
are implementation that can do it and are willing to do so. We could
introduce a new optional interface e.g. XSentenceFragmenter that does
the task and could be checked if is supported by the actual implementation.
Thus I think we should not yet think too much about it since to me
it looks this can be done later without breaking a (by then) already
existing implementation or the curently to be defined API for analyzing
the text and iterating over it.
Thomas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]