Show / Hide Table of Contents

Class SeStringBuilder

Helper class to build SeStrings using a builder pattern.

Inheritance
System.Object
SeStringBuilder
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Dalamud.Game.Text.SeStringHandling
Assembly: Dalamud.dll
Syntax
public class SeStringBuilder

Properties

| Improve this Doc View Source

BuiltString

Gets the built SeString.

Declaration
public SeString BuiltString { get; set; }
Property Value
Type Description
SeString

Methods

| Improve this Doc View Source

Add(Payload)

Add a payload to the builder.

Declaration
public SeStringBuilder Add(Payload payload)
Parameters
Type Name Description
Payload payload

The payload to add.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddIcon(BitmapFontIcon)

Add an icon to the builder.

Declaration
public SeStringBuilder AddIcon(BitmapFontIcon icon)
Parameters
Type Name Description
BitmapFontIcon icon

The icon to add.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddItalics(String)

Add italicized raw text to the builder.

Declaration
public SeStringBuilder AddItalics(string text)
Parameters
Type Name Description
System.String text

The raw text.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddItalicsOff()

Turn italics off.

Declaration
public SeStringBuilder AddItalicsOff()
Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddItalicsOn()

Turn italics on.

Declaration
public SeStringBuilder AddItalicsOn()
Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddItemLink(UInt32, ItemPayload.ItemKind, String)

Add an item link to the builder.

Declaration
public SeStringBuilder AddItemLink(uint itemId, ItemPayload.ItemKind kind, string itemNameOverride = null)
Parameters
Type Name Description
System.UInt32 itemId

The item ID.

ItemPayload.ItemKind kind

Kind of item to encode.

System.String itemNameOverride

Override for the item's name.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddItemLink(UInt32, Boolean, String)

Add an item link to the builder.

Declaration
public SeStringBuilder AddItemLink(uint itemId, bool isHq, string itemNameOverride = null)
Parameters
Type Name Description
System.UInt32 itemId

The item ID.

System.Boolean isHq

Whether or not the item is high quality.

System.String itemNameOverride

Override for the item's name.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddItemLinkRaw(UInt32)

Add an item link to the builder.

Declaration
public SeStringBuilder AddItemLinkRaw(uint rawItemId)
Parameters
Type Name Description
System.UInt32 rawItemId

The raw item ID.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddMapLink(UInt32, UInt32, Int32, Int32)

Add a map link payload to the builder.

Declaration
public SeStringBuilder AddMapLink(uint territoryTypeId, uint mapId, int rawX, int rawY)
Parameters
Type Name Description
System.UInt32 territoryTypeId

The id of the TerritoryType entry for this link.

System.UInt32 mapId

The id of the Map entry for this link.

System.Int32 rawX

The internal raw x-coordinate for this link.

System.Int32 rawY

The internal raw y-coordinate for this link.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddMapLink(UInt32, UInt32, Single, Single, Single)

Add a map link payload to the builder.

Declaration
public SeStringBuilder AddMapLink(uint territoryTypeId, uint mapId, float niceXCoord, float niceYCoord, float fudgeFactor = 0.05F)
Parameters
Type Name Description
System.UInt32 territoryTypeId

The id of the TerritoryType entry for this link.

System.UInt32 mapId

The id of the Map entry for this link.

System.Single niceXCoord

The human-readable x-coordinate for this link.

System.Single niceYCoord

The human-readable y-coordinate for this link.

System.Single fudgeFactor

An optional offset to account for rounding and truncation errors; it is best to leave this untouched in most cases.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddQuestLink(UInt32)

Add a quest link to the builder.

Declaration
public SeStringBuilder AddQuestLink(uint questId)
Parameters
Type Name Description
System.UInt32 questId

The quest ID.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddStatusLink(UInt32)

Add a status effect link to the builder.

Declaration
public SeStringBuilder AddStatusLink(uint statusId)
Parameters
Type Name Description
System.UInt32 statusId

The status effect ID.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddText(String)

Append raw text to the builder.

Declaration
public SeStringBuilder AddText(string text)
Parameters
Type Name Description
System.String text

The raw text.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddUiForeground(String, UInt16)

Add colored text to the current builder.

Declaration
public SeStringBuilder AddUiForeground(string text, ushort colorKey)
Parameters
Type Name Description
System.String text

The raw text.

System.UInt16 colorKey

The text color.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddUiForeground(UInt16)

Start colored text in the current builder.

Declaration
public SeStringBuilder AddUiForeground(ushort colorKey)
Parameters
Type Name Description
System.UInt16 colorKey

The text color.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddUiForegroundOff()

Turn off a previous colored text.

Declaration
public SeStringBuilder AddUiForegroundOff()
Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddUiGlow(String, UInt16)

Add glowing text to the current builder.

Declaration
public SeStringBuilder AddUiGlow(string text, ushort colorKey)
Parameters
Type Name Description
System.String text

The raw text.

System.UInt16 colorKey

The glow color.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddUiGlow(UInt16)

Start an UiGlow in the current builder.

Declaration
public SeStringBuilder AddUiGlow(ushort colorKey)
Parameters
Type Name Description
System.UInt16 colorKey

The glow color.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

AddUiGlowOff()

Turn off a previous UiGlow.

Declaration
public SeStringBuilder AddUiGlowOff()
Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

Append(SeString)

Append another SeString to the builder.

Declaration
public SeStringBuilder Append(SeString toAppend)
Parameters
Type Name Description
SeString toAppend

The SeString to append.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

Append(String)

Append raw text to the builder.

Declaration
public SeStringBuilder Append(string text)
Parameters
Type Name Description
System.String text

The raw text.

Returns
Type Description
SeStringBuilder

The current builder.

| Improve this Doc View Source

Build()

Return the built string.

Declaration
public SeString Build()
Returns
Type Description
SeString

The built string.

| Improve this Doc View Source

Encode()

Encode the built string to bytes.

Declaration
public byte[] Encode()
Returns
Type Description
System.Byte[]

The built string, encoded to UTF-8 bytes.

| Improve this Doc View Source

ToString()

Return the text representation of this string.

Declaration
public override string ToString()
Returns
Type Description
System.String

The text representation of this string.

Overrides
System.Object.ToString()
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX