Skip to main content Link Menu Expand (external link) Document Search Copy Copied

InfoBoxAttribute Public class

Description

This attribute class is used in Unity C# scripts to display an information box above a field in the inspector window. The information box can contain a message and a message type, such as info, warning, or error. This can be useful for providing additional context or warnings about a field.

Diagram

  flowchart LR
  classDef interfaceStyle stroke-dasharray: 5 5;
  classDef abstractStyle stroke-width:4px
  subgraph Rhinox.XR.Grapple
  Rhinox.XR.Grapple.InfoBoxAttribute[[InfoBoxAttribute]]
  end
  subgraph UnityEngine
UnityEngine.PropertyAttribute[[PropertyAttribute]]
  end
UnityEngine.PropertyAttribute --> Rhinox.XR.Grapple.InfoBoxAttribute

Members

Properties

Public properties

Type Name Methods
string Message
A string containing the message to display in the information box.
get, set
MessageType MessageType
A MessageType enum value specifying the type of message to display in the information box.
get, set

Details

Summary

This attribute class is used in Unity C# scripts to display an information box above a field in the inspector window. The information box can contain a message and a message type, such as info, warning, or error. This can be useful for providing additional context or warnings about a field.

Inheritance

  • PropertyAttribute

Constructors

InfoBoxAttribute [1/2]

public InfoBoxAttribute(string message)
Arguments
Type Name Description
string message The message to display.
Summary

This constructor creates an instance of the InfoBoxAttribute class with the given message and sets the message type to MessageType.Info.

InfoBoxAttribute [2/2]

public InfoBoxAttribute(string message, MessageType messageType)
Arguments
Type Name Description
string message The message to display.
MessageType messageType The desired message type.
Summary

This constructor creates an instance of the InfoBoxAttribute class with the given message and message type.

Properties

Message

public string Message { get; set; }
Summary

A string containing the message to display in the information box.

MessageType

public MessageType MessageType { get; set; }
Summary

A MessageType enum value specifying the type of message to display in the information box.

Generated with ModularDoc