SaveToStream(Stream: IIOStream);
The SaveToStream method saves the font to stream.
Sub UserProc;
Var
Font, FontFromStream: IGxFont;
Stream: IIOStream;
Begin
Stream := New MemoryStream.Create;
Font := New GxFont.Create("Arial", 13);
Font.SaveToStream(Stream);
Stream.Position := 0;
FontFromStream := New GxFont.CreateFromStream(Stream);
End Sub UserProc;
After executing the example the font is created and saved to the stream. Then the font is created from this stream and saved to the FontFromStream variable.
See also: