Add ControlChildSize option to disable autosizing child controls in UI panel
#2511
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
// Copyright (c) 2012-2024 Wojciech Figat. All rights reserved.
|
||||
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace FlaxEngine.GUI
|
||||
{
|
||||
/// <summary>
|
||||
@@ -133,7 +135,7 @@ namespace FlaxEngine.GUI
|
||||
/// <summary>
|
||||
/// Gets or sets the value indicating whenever the panel size will be based on a children dimensions.
|
||||
/// </summary>
|
||||
[EditorOrder(30), Tooltip("If checked, the panel size will be based on a children dimensions.")]
|
||||
[EditorOrder(30), DefaultValue(true), Tooltip("If checked, the panel size will be based on a children dimensions.")]
|
||||
public bool AutoSize
|
||||
{
|
||||
get => _autoSize;
|
||||
@@ -147,6 +149,12 @@ namespace FlaxEngine.GUI
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the value indicating whenever the panel can resize children controls (eg. auto-fit width/height).
|
||||
/// </summary>
|
||||
[EditorOrder(35), DefaultValue(true), Tooltip("If checked, the panel can resize children controls (eg. auto-fit width/height).")]
|
||||
public bool ControlChildSize { get; set; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the panel area margin.
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user