On Tue, 20 Jul 2010 10:55:23 +0200, Moritz Wenk
<[email protected]> wrote:
> Hello,
> 
> my QScintilla Application (using version 2.4.4) crashes when calling 
> QsciScintilla::clearAnnotations(-1) to remove all the annotations.
> From version 2.4 to 2.4.4 the greather than / less than in the if 
> condition in qscintilla.cpp was changed. 
> Looks like it is wrong in 2.4.4?
> 
> Code from 2.4.0:
> 
> // Clear annotations.
> void QsciScintilla::clearAnnotations(int line)
> {
>     if (line > 0)
>         SendScintilla(SCI_ANNOTATIONSETTEXT, line, (const char *)0);
>     else
>         SendScintilla(SCI_ANNOTATIONCLEARALL);
> }
> 
> 
> Code from 2.4.4:
> 
> // Clear annotations.
> void QsciScintilla::clearAnnotations(int line)
> {
>     if (line < 0)
>         SendScintilla(SCI_ANNOTATIONSETTEXT, line, (const char *)0);
>     else
>         SendScintilla(SCI_ANNOTATIONCLEARALL);
> }

Wrong in both versions, I think. It should be...

    if (line >= 0)

Thanks,
Phil
_______________________________________________
QScintilla mailing list
[email protected]
http://www.riverbankcomputing.com/mailman/listinfo/qscintilla

Reply via email to