Show / Hide Table of Contents

Class MultiFormatTextLabel

A multi-format text label supporting variable pixel fonts and layouts. Designed for Daggerfall's formatted text records such as books and status popups. This class will be improved over time as needed.

Inheritance
Object
BaseScreenComponent
MultiFormatTextLabel
Inherited Members
BaseScreenComponent.rectRestrictedRenderArea
BaseScreenComponent.restrictedRenderAreaCustomParent
BaseScreenComponent.restrictedRenderAreaCoordinateType
BaseScreenComponent.backgroundTexture
BaseScreenComponent.animatedBackgroundTextures
BaseScreenComponent.backgroundTextureLayout
BaseScreenComponent.OnKeyboardEvent
BaseScreenComponent.OnMouseEnter
BaseScreenComponent.OnMouseLeave
BaseScreenComponent.OnMouseMove
BaseScreenComponent.OnMouseDown
BaseScreenComponent.OnMouseUp
BaseScreenComponent.OnMouseClick
BaseScreenComponent.OnMouseDoubleClick
BaseScreenComponent.OnRightMouseDown
BaseScreenComponent.OnRightMouseUp
BaseScreenComponent.OnRightMouseClick
BaseScreenComponent.OnRightMouseDoubleClick
BaseScreenComponent.OnMiddleMouseDown
BaseScreenComponent.OnMiddleMouseUp
BaseScreenComponent.OnMiddleMouseClick
BaseScreenComponent.OnMiddleMouseDoubleClick
BaseScreenComponent.OnMouseScrollUp
BaseScreenComponent.OnMouseScrollDown
BaseScreenComponent.Enabled
BaseScreenComponent.UseFocus
BaseScreenComponent.OverridesHotkeySequences
BaseScreenComponent.Name
BaseScreenComponent.Tag
BaseScreenComponent.Position
BaseScreenComponent.Size
BaseScreenComponent.RootSize
BaseScreenComponent.Parent
BaseScreenComponent.Rectangle
BaseScreenComponent.HorizontalAlignment
BaseScreenComponent.VerticalAlignment
BaseScreenComponent.RestrictedRenderAreaCoordinateType
BaseScreenComponent.RectRestrictedRenderArea
BaseScreenComponent.RestrictedRenderAreaCustomParent
BaseScreenComponent.UseRestrictedRenderArea
BaseScreenComponent.CustomMousePosition
BaseScreenComponent.MousePosition
BaseScreenComponent.LastMousePosition
BaseScreenComponent.ScaledMousePosition
BaseScreenComponent.BackgroundColor
BaseScreenComponent.MouseOverBackgroundColor
BaseScreenComponent.BackgroundColorTexture
BaseScreenComponent.BackgroundTexture
BaseScreenComponent.BackgroundCroppedRect
BaseScreenComponent.AnimatedBackgroundTextures
BaseScreenComponent.AnimationDelayInSeconds
BaseScreenComponent.BackgroundTextureLayout
BaseScreenComponent.InteriorWidth
BaseScreenComponent.InteriorHeight
BaseScreenComponent.Scale
BaseScreenComponent.AutoSize
BaseScreenComponent.LocalScale
BaseScreenComponent.ToolTip
BaseScreenComponent.ToolTipText
BaseScreenComponent.SuppressToolTip
BaseScreenComponent.MinAutoScale
BaseScreenComponent.MaxAutoScale
BaseScreenComponent.MouseOverComponent
BaseScreenComponent.TopMargin
BaseScreenComponent.BottomMargin
BaseScreenComponent.LeftMargin
BaseScreenComponent.RightMargin
BaseScreenComponent.Update()
BaseScreenComponent.ScreenToLocal(Vector2)
BaseScreenComponent.ScreenToLocal(Rect)
BaseScreenComponent.GotFocus()
BaseScreenComponent.LostFocus()
BaseScreenComponent.TriggerMouseClick()
BaseScreenComponent.KeyboardEvent(Event)
BaseScreenComponent.MouseClick(Vector2)
BaseScreenComponent.RightMouseClick(Vector2)
BaseScreenComponent.MiddleMouseClick(Vector2)
BaseScreenComponent.MouseDoubleClick(Vector2)
BaseScreenComponent.RightMouseDoubleClick(Vector2)
BaseScreenComponent.MiddleMouseDoubleClick(Vector2)
BaseScreenComponent.MouseEnter()
BaseScreenComponent.MouseLeave(BaseScreenComponent)
BaseScreenComponent.MouseMove(Int32, Int32)
BaseScreenComponent.MouseScrollUp()
BaseScreenComponent.MouseScrollDown()
BaseScreenComponent.Dispose()
BaseScreenComponent.SetMargins(Margins, Int32)
BaseScreenComponent.OffsetFrom(BaseScreenComponent, Sides, Int32)
BaseScreenComponent.SetFocus()
BaseScreenComponent.HasFocus()
Namespace: DaggerfallWorkshop.Game.UserInterface
Assembly: Assembly-CSharp.dll
Syntax
public class MultiFormatTextLabel : BaseScreenComponent, IDisposable

Properties

| Improve this Doc View Source

ActualTextHeight

Declaration
public int ActualTextHeight { get; }
Property Value
Type Description
Int32
| Improve this Doc View Source

ExtraLeading

Gets or sets extra leading between rows.

Declaration
public int ExtraLeading { get; set; }
Property Value
Type Description
Int32
| Improve this Doc View Source

Font

Declaration
public DaggerfallFont Font { get; set; }
Property Value
Type Description
DaggerfallFont
| Improve this Doc View Source

HighlightColor

Declaration
public Color HighlightColor { get; set; }
Property Value
Type Description
Color
| Improve this Doc View Source

LineCount

Declaration
public int LineCount { get; }
Property Value
Type Description
Int32
| Improve this Doc View Source

LineHeight

Declaration
public int LineHeight { get; }
Property Value
Type Description
Int32
| Improve this Doc View Source

MaxTextHeight

Declaration
public int MaxTextHeight { get; set; }
Property Value
Type Description
Int32
| Improve this Doc View Source

MaxTextWidth

Declaration
public int MaxTextWidth { get; set; }
Property Value
Type Description
Int32
| Improve this Doc View Source

MinTextureDimTextLabel

used to set min texture dims of textlabel to higher values if there would be aspect or scaling issues with small texts otherwise (e.g. some single-lined textlabels in inventory infopanel)

Declaration
public int MinTextureDimTextLabel { get; set; }
Property Value
Type Description
Int32
| Improve this Doc View Source

ShadowColor

Declaration
public Color ShadowColor { get; set; }
Property Value
Type Description
Color
| Improve this Doc View Source

ShadowPosition

Declaration
public Vector2 ShadowPosition { get; set; }
Property Value
Type Description
Vector2
| Improve this Doc View Source

TextAlignment

Declaration
public HorizontalAlignment TextAlignment { get; set; }
Property Value
Type Description
HorizontalAlignment
| Improve this Doc View Source

TextColor

Declaration
public Color TextColor { get; set; }
Property Value
Type Description
Color
| Improve this Doc View Source

TextLabels

Declaration
public List<TextLabel> TextLabels { get; }
Property Value
Type Description
List<TextLabel>
| Improve this Doc View Source

TextScale

set text scale factor - 1.0f is default value, 0.5f is half sized text, 2.0f double sized text and so on

Declaration
public float TextScale { get; set; }
Property Value
Type Description
Single
| Improve this Doc View Source

WrapText

Declaration
public bool WrapText { get; set; }
Property Value
Type Description
Boolean
| Improve this Doc View Source

WrapWords

Declaration
public bool WrapWords { get; set; }
Property Value
Type Description
Boolean

Methods

| Improve this Doc View Source

AddTextLabel(String, DaggerfallFont, Color)

Adds a single text item. Each subsequent text item will be appended to the previous text item position. Call NewLine() to start a new line.

Declaration
public TextLabel AddTextLabel(string text, DaggerfallFont font, Color color)
Parameters
Type Name Description
String text

Text for this label.

DaggerfallFont font

Font for this label.

Color color

Text color for this label.

Returns
Type Description
TextLabel

TextLabel.

| Improve this Doc View Source

ChangeScrollPosition(Int32)

Declaration
public void ChangeScrollPosition(int amount)
Parameters
Type Name Description
Int32 amount
| Improve this Doc View Source

Clear()

Clears current labels.

Declaration
public void Clear()
| Improve this Doc View Source

Draw()

Declaration
public override void Draw()
Overrides
BaseScreenComponent.Draw()
| Improve this Doc View Source

NewLine()

Start a new line.

Declaration
public void NewLine()
| Improve this Doc View Source

ResizeY(Single)

Declaration
public void ResizeY(float newSize)
Parameters
Type Name Description
Single newSize
| Improve this Doc View Source

SetRowLeading(Int32)

Declaration
protected virtual void SetRowLeading(int amount)
Parameters
Type Name Description
Int32 amount
| Improve this Doc View Source

SetText(TextFile.Token[])

Adds formatted text labels from a RSC token array.

Declaration
public virtual void SetText(TextFile.Token[] tokens)
Parameters
Type Name Description
TextFile.Token[] tokens

Daggerfall RSC token array.

| Improve this Doc View Source

SetText(TextAsset)

Adds formatted text labels from a TextAsset. Currently only supports newlines, not tabs or other formatting characters.

Declaration
public virtual void SetText(TextAsset textAsset)
Parameters
Type Name Description
TextAsset textAsset

Source TextAsset.

| Improve this Doc View Source

UpdateRestrictedRenderArea()

Declaration
public void UpdateRestrictedRenderArea()
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX