Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2016-10

TPageControl cannot change parent

3 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Torsten Bonde Christiansen

Hi List.

In the designer it is not posible to use the builtin feature of "Change Parent" (from the context menu) with a TPageControl. Other controls seems to work fine (although i have not tested all of them).

To recreate the problem slap a TPanel and a TPageControl on the mainform and add a single tabsheet. Use "Change Parent" on the Pagecontrol and change it to the panel - and bang.

I use:
Lazarus trunk: r53105
Fpc: 3.0.0 (release) x86_64

Lazarus does a hard crash - even the stack-trace is halted:

torsten at Rainier:~/FreePascal/lazarus$ ./startlazarus is a file
TLazarusManager.Run starting /home/torsten/FreePascal/lazarus/lazarus ... Hint: (lazarus) [TMainIDE.ParseCmdLineOptions]
PrimaryConfigPath="/home/torsten/.lazarus"
Hint: (lazarus) [TMainIDE.ParseCmdLineOptions]
SecondaryConfigPath="/etc/lazarus"
Hint: (lazarus) [TBuildManager.SetBuildTarget] Old=x86_64-linux-gtk2 New=x86_64-linux-gtk2 FPC=True LCL=False
TComponentTreeView.SetSelection: Updating component node values. AddComponent TPanel Parent=Form1:TForm1 23,15,269,625 Parent is 'Form1:TForm1'
Hint: (lazarus) [TPkgManager.AddUnitDependenciesForComponentClasses] Extending Uses unit1.pas ExtCtrls
AddComponent TPageControl Parent=Form1:TForm1 326,26,470,604 Parent is 'Form1:TForm1'
Hint: (lazarus) [TPkgManager.AddUnitDependenciesForComponentClasses] Extending Uses unit1.pas ComCtrls
TComponentTreeView.SetSelection: Selection.ForceUpdate encountered. TComponentTreeView.SetSelection: Selection.ForceUpdate encountered. TApplication.HandleException Access violation
Stack trace:
$00007FE443665D86

This is as far as it goes.

On a side node - it IS posible to select a tabsheet and change the parent to the panel, which IMO should not be posible.

Kind regards
Torsten
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20161014/d3819d81/attachment.html>

Reply by email

Mattias Gaertner
to Torsten Bonde Christiansen

On Fri, 14 Oct 2016 12:16:25 +0200
Torsten Bonde Christiansen via Lazarus

Show quoted text 10 lines
[...] In the designer it is not posible to use the builtin feature of "Change Parent" (from the context menu) with a TPageControl. Other controls seems to work fine (although i have not tested all of them). To recreate the problem slap a TPanel and a TPageControl on the mainform and add a single tabsheet. Use "Change Parent" on the Pagecontrol and change it to the panel - and bang. [...] This is as far as it goes.

Please create a bug report.

On a side node - it IS posible to select a tabsheet and change the parent to the panel, which IMO should not be posible.

And for that too.

Mattias

Reply by email

Torsten Bonde Christiansen
to Mattias Gaertner
Mattias Gaertner wrote 10 lines
On Fri, 14 Oct 2016 12:16:25 +0200 Torsten Bonde Christiansen via Lazarus wrote: > [...] In the designer it is not posible to use the builtin feature of > "Change Parent" (from the context menu) with a TPageControl. Other > controls seems to work fine (although i have not tested all of them). > To recreate the problem slap a TPanel and a TPageControl on the > mainform and add a single tabsheet. Use "Change Parent" on the > Pagecontrol and change it to the panel - and bang. [...] This is as > far as it goes. Please create a bug report.

Done:
http://bugs.freepascal.org/view.php?id=30752

> On a side node - it IS posible to select a tabsheet and change the > parent to the panel, which IMO should not be posible. And for that too.

Done:
http://bugs.freepascal.org/view.php?id=30753

-Torsten.

Reply by email