nw::font::TextWriterBase::SetBuffer Member Function

Syntax

static void * SetBuffer(
     std::size_t size
);
static void * SetBuffer(
     CharType*   buffer,
     std::size_t size
);

List of Overloaded Member Functions

SetBuffer ( std::size_t ) Allocates a buffer for extracting formatted text.
SetBuffer ( CharType *, std::size_t ) Allocates a buffer for extracting formatted text.

Description of SetBuffer ( std::size_t )

This buffer is used to extract a formatted character string using a member function of TextWriter for handling formatted character strings. If the character string after extraction exceeds the size of this buffer, the excessive part of the string is truncated for the process.
The five functions listed below are nw::font::TextWriter member functions that handle formatted character strings.

nw::font::TextWriter::CalcFormatStringWidth
nw::font::TextWriter::CalcFormatStringHeight
nw::font::TextWriter::CalcFormatStringRect
nw::font::TextWriter::Printf
nw::font::TextWriter::VPrintf .

For the format that specifies only the buffer size, the buffer is specified such that it is allocated on the stack. Note: The stack may overflow if an attempt is made to allocate too large a buffer on the stack.

A buffer holding 256 characters is allocated on the stack by default.

Description of SetBuffer ( CharType *, std::size_t )

This buffer is used to extract a formatted character string using a member function of TextWriter for handling formatted character strings. If the character string after extraction exceeds the size of this buffer, the excessive part of the string is truncated for the process.
The five functions listed below are nw::font::TextWriter member functions that handle formatted character strings.

nw::font::TextWriter::CalcFormatStringWidth
nw::font::TextWriter::CalcFormatStringHeight
nw::font::TextWriter::CalcFormatStringRect
nw::font::TextWriter::Printf
nw::font::TextWriter::VPrintf .

For the format that specifies only the buffer size, the buffer is specified such that it is allocated on the stack. Note: The stack may overflow if an attempt is made to allocate too large a buffer on the stack.

A buffer holding 256 characters is allocated on the stack by default.


CONFIDENTIAL