Ovis_Decoration_2D_Text_Create()

Abstract

Creates 2D text.

Syntax

Ovis_Decoration_2D_Text_Create (text, position, color, layer_ptr, destroy_proc, user_state_ptr)
Argument Type Description
text const char * Text
position OvisT_2D_Position Position of the text
color PrgT_Color Color
layer_ptr OvisT_Layer * Ovis layer
destroy_proc OvisT_Decoration_State_Destroy_Proc Destroys the data associated with the object and deallocates its memory
user_state_ptr void * Optional user-provided state of the decoration

Return Type

OvisT_2D_Text *

The 2D text

ovis_decoration.h

Details

This function creates Ovis 2D text. It specifies the attributes of the text. Initially text has 0% transparency (fully visible) and is not flashing.

Example

OvisT_2D_Position					pos;
OvisT_2D_Text					* text;
PrgT_Color					color = prg_rgb_from_string ("blue");

pos.x = 20;
pos.y = 0; /* middle of the window */
text = Ovis_Decoration_2D_Text_Create ("This is my text", pos, color,
	OPC_NIL, OPC_NIL, OPC_NIL);

Errors

  • Invalid 2D position <x,y>. 2D position values must be between -128 and 127.

Reference

本站文档由 北京智网畅联科技有限公司 整理、翻译并提供 · Documentation compiled and provided by Beijing ZNetLink Technology Co., Ltd.

交流群 · QQ Group:OPNET/智网妙算网络仿真交流群(群号 486383494)

原文档 © 2017 Riverbed Technology · 本站为公益翻译,由 AI 辅助完成,请仔细甄别

Original documentation © 2017 Riverbed Technology. Community translation, AI-assisted. Contact: jiazequn@znetlink.com