concept text label in category c#

appears as: text label, text labels
Unity in Action: Multiplatform game development in C# with Unity 5

This is an excerpt from Manning's book Unity in Action: Multiplatform game development in C# with Unity 5.

Inside OnGUI() the code defines 2D coordinates for the display (shifted slightly to account for the size of the label) and then calls GUI.Label(). That method displays a text label; because the string passed to the label is an asterisk (*), you end up with that character displayed in the center of the screen. Now it’s much easier to aim in our nascent FPS game!

Objects within the canvas can be parented together for positioning purposes, just like any other objects in the scene. For example, you may want to drag the text object onto the image so that the text will move with the image. Similarly, the default button object has a text object as its child; this button doesn’t need a text label, so delete the text object.