YSTest  PreAlpha_b400_20130424
The YSLib Test Project
 全部 类 命名空间 文件 函数 变量 类型定义 枚举 枚举值 友元 宏定义 组 页
YSLib::Drawing::TextRenderer类 参考

文本渲染器。 更多...

#include <TextRenderer.h>

类 YSLib::Drawing::TextRenderer 继承关系图:
YSLib::Drawing::TextRenderer 的协作图:

Public 成员函数

 TextRenderer (TextState &ts, const Graphics &g)
 
 TextRenderer (TextState &ts, const Graphics &g, const Rect &mask)
 
void operator() (ucs4_t)
 渲染单个字符。
 
const TextState & GetTextState () const ynothrow
 
TextState & GetTextState () ynothrow
 
const Graphics & GetContext () const ynothrow
 
void ClearLine (u16 l, SDst n)
 清除缓冲区第 l 行起始的 n 行像素。
 
SDst GetHeight () const ynothrow
 
SDst GetWidth () const ynothrow
 
const Size & GetSize () const ynothrow
 
- Public 成员函数 继承自 YSLib::Drawing::GTextRendererBase< TextRenderer >
u16 GetTextLineN () const
 取按当前行高和行距所能显示的最大行数。
 
u16 GetTextLineNEx () const
 取按当前行高和行距(行间距数小于行数 1 )所能显示的最大行数。
 

Public 属性

TextState & State
 
const Graphics & Buffer
 
Rect ClipArea
 

详细描述

文本渲染器。

警告
非虚析构。
自从
build 190

文本渲染器:简单实现。

在文件 TextRenderer.h 第 335 行定义.

构造及析构函数说明

YSLib::Drawing::TextRenderer::TextRenderer ( TextState &  ts,
const Graphics &  g 
)
inline

在文件 TextRenderer.h 第 342 行定义.

YSLib::Drawing::TextRenderer::TextRenderer ( TextState &  ts,
const Graphics &  g,
const Rect &  mask 
)
inline

在文件 TextRenderer.h 第 350 行定义.

成员函数说明

void TextRenderer::ClearLine ( u16  l,
SDst  n 
)

清除缓冲区第 l 行起始的 n 行像素。

注解
图形接口上下文不可用或 l 越界时忽略。
n 被限制为不越界。
n 为 0 时清除之后的所有行。

在文件 TextRenderer.cpp 第 94 行定义.

参考 YSLib::Drawing::ClearPixel(),h , 以及 YB_LIKELY.

函数调用图:

const Graphics& YSLib::Drawing::TextRenderer::GetContext ( ) const
inline

在文件 TextRenderer.h 第 365 行定义.

SDst YSLib::Drawing::TextRenderer::GetHeight ( ) const
inline
自从
build 308

在文件 TextRenderer.h 第 368 行定义.

const Size& YSLib::Drawing::TextRenderer::GetSize ( ) const
inline

在文件 TextRenderer.h 第 370 行定义.

const TextState& YSLib::Drawing::TextRenderer::GetTextState ( ) const
inline

在文件 TextRenderer.h 第 362 行定义.

TextState& YSLib::Drawing::TextRenderer::GetTextState ( )
inline

在文件 TextRenderer.h 第 363 行定义.

SDst YSLib::Drawing::TextRenderer::GetWidth ( ) const
inline

在文件 TextRenderer.h 第 369 行定义.

void TextRenderer::operator() ( ucs4_t  c)

渲染单个字符。

在文件 TextRenderer.cpp 第 87 行定义.

类成员变量说明

const Graphics& YSLib::Drawing::TextRenderer::Buffer

在文件 TextRenderer.h 第 339 行定义.

Rect YSLib::Drawing::TextRenderer::ClipArea

在文件 TextRenderer.h 第 340 行定义.

TextState& YSLib::Drawing::TextRenderer::State

在文件 TextRenderer.h 第 338 行定义.


该类的文档由以下文件生成: