This is no longer a stub. Updated descriptions, added links.
(2 intermediate revisions by 2 users not shown)
Line 2:
Line 2:
<translate>
<translate>
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=ButtonStringAppendComponent.png
|Image=ButtonStringAppendComponent.png
Line 8:
Line 7:
}}
}}
The ButtonStringAppend component can be used to add a string to the beginning or end of a string whenever a button is pressed.
The '''ButtonStringAppend''' component can be used to add a [[Type:string|string]] to the beginning or end of a string whenever an [[Type:IButton|IButton]] is pressed.
<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|TargetString|IField`1|TypeString0=IField<string>| The string to which <code>AppendString</code> will be added.
|TargetString|'''[[Type:IField`1|IField`1]]<[[Type:String|String]]>'''|TypeAdv0=true| The string to which <code>AppendString</code> will be added.
|AppendString|String| The string to add to <code>TargetString</code>.
|AppendString|String| The string to add to <code>TargetString</code>.
|AppendInFront|Bool| Whether or not to add <code>AppendString</code> to the beginning of the string. (This does not reverse <code>AppendString</code>.)
|AppendInFront|Bool| Whether or not to add <code>AppendString</code> to the beginning of the string. (This does not reverse <code>AppendString</code>.)
Line 20:
Line 19:
<!--T:3-->
<!--T:3-->
== Usage ==
== Usage ==
To function, the component simply needs to be attached to a slot that also has a button component attached to it. From then on, pressing that button will activate the ButtonStringAppend, making it append its <code>AppendString</code> to its <code>TargetString</code>.
To function, the component simply needs to be attached to a [[Slot|slot]] that also has a button component attached to it. From then on, pressing that button will activate the '''ButtonStringAppend''', making it append its <code>AppendString</code> to its <code>TargetString</code>.
Whether or not to add AppendString to the beginning of the string. (This does not reverse AppendString.)
Usage
To function, the component simply needs to be attached to a slot that also has a button component attached to it. From then on, pressing that button will activate the ButtonStringAppend, making it append its AppendString to its TargetString.