mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-09 15:28:14 +02:00
LCL: Take the width of TPageControl's TTabSheets into account in an autosized form. Issue #36493, patch by Joeny Ang.
git-svn-id: trunk@65218 -
This commit is contained in:
parent
1159b4327b
commit
a04f03d6df
@ -527,6 +527,7 @@ type
|
||||
property PageControl: TPageControl read GetPageControl write SetPageControl;
|
||||
property TabIndex: Integer read GetTabIndex;
|
||||
published
|
||||
property AutoSize;
|
||||
property BorderWidth;
|
||||
property BiDiMode;
|
||||
property Caption;
|
||||
@ -606,6 +607,7 @@ type
|
||||
|
||||
property Align;
|
||||
property Anchors;
|
||||
property AutoSize;
|
||||
property BorderSpacing;
|
||||
property BiDiMode;
|
||||
property Constraints;
|
||||
|
@ -221,6 +221,10 @@ end;
|
||||
|
||||
function TCustomPage.IsControlVisible: Boolean;
|
||||
begin
|
||||
// when autosizing, need this to return True so that the sizes of non-active
|
||||
// pages will be considered in parent's GetPreferredSize()
|
||||
if AutoSizingAll then
|
||||
Exit(True);
|
||||
Result := inherited IsControlVisible;
|
||||
if Result and (Parent is TCustomTabControl) then
|
||||
Result := PageIndex = TCustomTabControl(Parent).PageIndex;
|
||||
|
Loading…
Reference in New Issue
Block a user