Make LineEdit not ugly as hell.
This commit is contained in:
@@ -73,6 +73,13 @@ namespace Content.Client.UserInterface
|
|||||||
buttonDisabled.SetPatchMargin(StyleBox.Margin.All, 2);
|
buttonDisabled.SetPatchMargin(StyleBox.Margin.All, 2);
|
||||||
buttonDisabled.SetContentMarginOverride(StyleBox.Margin.Left | StyleBox.Margin.Right, 4);
|
buttonDisabled.SetContentMarginOverride(StyleBox.Margin.Left | StyleBox.Margin.Right, 4);
|
||||||
|
|
||||||
|
var lineEditTex = resCache.GetResource<TextureResource>("/Nano/lineedit.png").Texture;
|
||||||
|
var lineEdit = new StyleBoxTexture
|
||||||
|
{
|
||||||
|
Texture = lineEditTex,
|
||||||
|
};
|
||||||
|
lineEdit.SetPatchMargin(StyleBox.Margin.All, 3);
|
||||||
|
lineEdit.SetContentMarginOverride(StyleBox.Margin.Horizontal, 5);
|
||||||
|
|
||||||
Stylesheet = new Stylesheet(new[]
|
Stylesheet = new Stylesheet(new[]
|
||||||
{
|
{
|
||||||
@@ -175,6 +182,13 @@ namespace Content.Client.UserInterface
|
|||||||
{
|
{
|
||||||
new StyleProperty(BoxContainer.StylePropertySeparation, 2),
|
new StyleProperty(BoxContainer.StylePropertySeparation, 2),
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
// Fancy LineEdit
|
||||||
|
new StyleRule(new SelectorElement(typeof(LineEdit), null, null, null),
|
||||||
|
new[]
|
||||||
|
{
|
||||||
|
new StyleProperty(LineEdit.StylePropertyStyleBox, lineEdit),
|
||||||
|
}),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
Resources/Nano/lineedit.png
Normal file
BIN
Resources/Nano/lineedit.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 161 B |
2
engine
2
engine
Submodule engine updated: b3e3066c53...2462caf25a
Reference in New Issue
Block a user