trichview.com

trichview.support




Re: A few puzzling question


Return to index


Author

Message

Sergey Tkachenko

Posted: 11/10/2003 13:59:48


> 1. At times, when opening rvf files in a sequence, Delphi gives an error

> Canvas does not allow drawing. What can be the possible causes of this

error.

> It does not always happen,but only once in a while. Could the error be

attributed

> to RvE.Format, since I did call format at certain lines of the codes.


As far as I know, there can be numerous reasons for this error. Sorry, I

cannot help without additional information.


>

> 2. Do I need to REFRESH (not in helpfile) after FORMAT/CLEAR.


No


> Do I need to FORMAT after clearing(CLEAR)?


Yes


> What does REFRESH do?


Repaints the control's window. See the Delphi help file, TContol.Refresh.


>

> 3. If I insert text with AddNL, and a certain textstyle does not exists,

> I will get Listindex out of bound. Rve.FORMAT is issued after this. Will

> this error be reflected in the FORMAT_ procedure as LastItemFormatted(this

> integer value will be negative then)? I am doing a lengthy debugging for

> my company's application and need your kind comments.


Exception must not happen if you use too large text and paragraph indices in

AddNL (if you are not using too old version of TRichView).

Such text will be drawn with the special style (see TextStyles.InvalidItem,

ParaStyles.InvalidItem).

By default, invalid text style is white-on-red, invalid paragraph style has

red border.


Value of LastItemFormatted is unspecified, if an exception occurs in

Format_.

(LastItemFormatted is important only for FormatTail method)





Powered by ABC Amber Outlook Express Converter