RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TCustomOutline.LoadFromStream Method (TStream)

Loads the outline from a text image read from a stream.

Pascal
procedure LoadFromStream(Stream: TStream); overload;
procedure LoadFromStream(Stream: TStream; Encoding: TEncoding); overload;
C++
__fastcall LoadFromStream(TStream Stream);
__fastcall LoadFromStream(TStream Stream, TEncoding Encoding);

Call LoadFromStream to fill an outline from the stream specified by the Stream parameter. For example, use LoadFromStream to load an outline from an image stored in a database table, using a TBlobStream object. Each node in the outline is separated by a newline character. The stream does not provide the root node. 

Leading tabs and spaces are converted into levels of the outline. Text without any leading tabs or spaces becomes level 1 items. For example, the following set of strings represents an outline with three first level children descended from the root, and an additional, second level child on the first and third nodes:

ChildA
 ChildA1
ChildB
ChildC
 ChildC1

To fill the outline from a text image read from a file, use the LoadFromFile method. To fill the outline from a text image represented as a TStrings object, use the Lines property. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!