Translations:Text Formatting/7/en

From Neos Wiki
Jump to navigation Jump to search
Tag Example Description
align <align=left>Text</align> Sets text alignment. Valid argunments are left, right, center and justify.
allcaps <allcaps>Text</allcaps> Renders lowercase characters as small uppercase characters. Same as the smallcaps tag.
alpha <alpha=#80>Text</alpha> Renders text with a specific transparency level (#FF is fully opaque, and #00 is fully transparent). Because of a bug alpha can accept color names like this <alpha=red>Text</alpha>.
b <b>Text</b> Shows text in boldface.
br <br> Inserts a line break into the text.
closeall </closeall> Closes all format specifiers that came before this tag.
closeallblock <closeallblock> creates a block for the above closeall tag to operate in, e.g. <b><closeallblock><i>Blabla</closeall></closeallblock></b> prevents the <b> tag from being closed
color <color=#FF0000>Text</color> Sets the color of the text according to the parameter value. The color can be specified in the traditional HTML format: #rrggbbaa where the letters correspond to pairs of hexadecimal digits denoting the red, green, blue and alpha (optional) values for the color. For example, cyan at full opacity would be specified by color=#00ffffff. You can specify hexadecimal values in short form; #FF0000 is equivalent to #F00. You may also use the names of colors, such as red, green, blue and so on. A list of all valid colors can be found in the Color Names section.
font <font="Font Name">Font (by name)</font> OR <font=1>Font (by index)</font> Renders the text with a specific font, specified either by index or by name. This requires the usage of a FontCollection component.
glyph <glyph name="test"> Renders a Sprite. Same as the sprite tag. Sprites insert an image into text, they ignore colors. This requires both FontChain & DynamicSpriteFont Components. Sprites in Neos use a SpriteURL which is a direct link to the image and the Sprite Name. To prevent content from breaking in case your link breaks. It's recommended to use images you Know will not expire, like saving the image to your inventory where you can keep it safe. Example of using a sprite would be <sprite name=baguette> -- You can customize their position & separation using DynamicSpriteFont. This can be changed per sprite.
gradient <gradient=#F00,#00F>Text</gradient> The gradient tag does not do anything, but it exists in the code and parses correctly when written in game. Presumably it would have created a horizontal gradient over the text, using the specified color values.
i <i>Text</i> Shows text in italics.
line-height <line-height=200%>Line Height</line-height> Changes the line height of the text by the specified percentage (200% means the line height will be twice as large).
lowercase <lowercase>Text</lowercase> Forces all characters to be lowercase
mark <mark=#ffff00aa></mark> Used to highlight text in an RGBA hex color. Hex codes can be written in short form, if the alpha values are omitted the default value will be 25% alpha.
nobr <nobr>Text</nobr> Prevents automatic line breaks from being inserted. This can be useful if you want words to stay together and not be separated by word wrapping.
noparse <noparse>Text</noparse> OR <noparse=4>Text Prevents the contents of the tag from being parsed as rich text. Alternatively instead of a closing tag a number can be specified inside of the opening tag which will prevent the N next characters from being parsed.
s <s>Text</s> Shows text with a line through it
size <size=16>Text</size> OR <size=80%>Text</size> Sets the size of the text. It's recommended to use the relative version of this tag, as the absolute units can be vastly different when applied in physical ui (TextRenderer component) and UIX canvases (Text component).
smallcaps <smallcaps>Text</smallcaps> Same as the allcaps tag.
nobr <nobr>Text</nobr> Prevents the contents of the tag from being broken across lines. Useful for bounded text.
sprite <sprite name="test"> Same as the glyph tag.
sub <sub>Text</sub> Displays the text in subscript
sup <sup>Text</sup> Displays the text in superscript
u <u>Text</u> Shows text with a line beneath it
uppercase <uppercase>Text</uppercase> Forces all characters to be uppercase.