(717837ca0) Fixed: Editor spacing & element sizes in 4k

This commit is contained in:
Joonas Rikkonen
2019-05-16 06:24:55 +03:00
parent dc2f96443a
commit 52d3737416
14 changed files with 249 additions and 265 deletions
@@ -110,11 +110,12 @@ namespace Barotrauma
public GUIComponent CreateEditingHUD(bool inGame = false)
{
int heightScaled = (int)(20 * GUI.Scale);
editingHUD = new GUIFrame(new RectTransform(new Vector2(0.3f, 0.25f), GUI.Canvas, Anchor.CenterRight) { MinSize = new Point(400, 0) }) { UserData = this };
GUIListBox listBox = new GUIListBox(new RectTransform(new Vector2(0.95f, 0.8f), editingHUD.RectTransform, Anchor.Center), style: null);
var editor = new SerializableEntityEditor(listBox.Content.RectTransform, this, inGame, showName: true, elementHeight: 20);
var editor = new SerializableEntityEditor(listBox.Content.RectTransform, this, inGame, showName: true);
var buttonContainer = new GUILayoutGroup(new RectTransform(new Point(listBox.Content.Rect.Width, 20)), isHorizontal: true)
var buttonContainer = new GUILayoutGroup(new RectTransform(new Point(listBox.Content.Rect.Width, heightScaled)), isHorizontal: true)
{
Stretch = true,
RelativeSpacing = 0.02f