Hi all,

I am using Scintilla 1.67 in a project of mine and am getting the following assertion in LineLayoutCache::AllocateForLevel:
  PLATFORM_ASSERT(useCount == 0);

What is this ensuring? What is useCount used for?

A little more information on my project...

I have a statically-built scintilla library (no lexer component) linked into a DLL. That DLL provides a COM object that uses Scintilla to provide a text editor interface to my program using WTL and the AtlScintilla.h utility written by Gilad Novik. This program is a text-to-speech application to read documents that does the following in a loop:
1.  Gets the next line of text in a document:
  a. Use GetCurrentPos() to determine where we are in the document;
  b. Use GetCharAt() to see where the end of the current sentence is;
c. Use GetTextRange() to get the sentence text (I am currently returning this as a BSTR, but need to use UCS2FromUTF8 to convert it properly).
2.  Hilight each word as they are being read using SetSel().

After a while, the assertion is triggered.

NOTE: I am using SetCaretLineVisible(true). This will sometimes keep the previous line drawn with the caret visible look.

NOTE: I get redraw problems if I select text (now in readonly mode) while the document is being read. That will keep the selected text drawn as selected.

NOTE: I will be raising these as bugs, for now I just want to get Scintilla working :).

Any help would be greatfully appreciated.
- Reece


_______________________________________________
Scintilla-interest mailing list
[email protected]
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Reply via email to