- Sliced sprites are scaled instead of tiling (so they work properly even if the UI element is smaller than the sprite)
- Option to use separate sprites for different states of a GUIComponent (e.g. hovered/pressed button) - Option to configure "child styles" for the individual elements of a GUIComponent (e.g. the background frame and the handle of a scroll bar)
This commit is contained in:
@@ -150,6 +150,7 @@ namespace Barotrauma
|
||||
|
||||
public override void ApplyStyle(GUIComponentStyle style)
|
||||
{
|
||||
if (style == null) return;
|
||||
base.ApplyStyle(style);
|
||||
|
||||
textColor = style.textColor;
|
||||
@@ -174,6 +175,8 @@ namespace Barotrauma
|
||||
|
||||
this.alignment = alignment;
|
||||
|
||||
this.padding = new Vector4(5.0f, 5.0f, 5.0f, 5.0f);
|
||||
|
||||
this.textAlignment = textAlignment;
|
||||
|
||||
if (parent != null)
|
||||
|
||||
Reference in New Issue
Block a user