View Issue Details

IDProjectCategoryView StatusLast Update
0018298LazarusOtherpublic2019-01-24 19:35
ReporterSven Barth Assigned ToMattias Gaertner  
Status resolvedResolutionfixed 
Product Version0.9.29 (SVN) 
Target Version1.4 
Summary0018298: Please update the default layout provided with anchor docking package
DescriptionWhen I enabled anchor docking on two different systems (i386-linux with GTK 2 and i386-win32 with Win32) the first time, I always got a layout that was basically unusable.

First I needed to resize the main window so the main IDE bar was visible again, then I needed to fix the position of the message window which was out of the visible area as well.

I don't know whether this was because I have smaller displays than used for the original display (I have 1280x800 and 1024x600 on those two computers), but as it is the layout scares users away from using anchor docking.
Additional InformationAttached XML file is the layout I have corrected and saved (I didn't dare to dock the object manager though, because I got a error in Win32 when showing it after it had been closed). It replaces the examples/anchordocking/design/ADLayoutDefault.xml file.

The two attached screenshots show how the broken and the corrected layout look like on GTK 2 (they look similar on Win32)
TagsNo tags attached.
Fixed in Revision46451
WidgetsetGTK 2, Win32/Win64
Attached Files


related to 0018538 closedJuha Manninen Lazarus Under certain configurations docked windows, lower window arbitrarily increasing its height 
related to 0019200 resolvedMattias Gaertner Lazarus anchordocking component restore error on windows. 
related to 0001735 closedVincent Snijders Lazarus TColorDialog, TFondDialog (and componentes of Printer4Lazarus) do not test dialog... 
related to 0019810 feedbackMattias Gaertner Lazarus AnchorDockingDsgn - IDE can not save default layout, if monitor has negative coordinates 
related to 0020845 closedMattias Gaertner Lazarus "Tools\Load window layout from file" with AnchorDockDsgn is bugy 
related to 0023596 resolvedMattias Gaertner Lazarus IDE/AnchorDocking: docksite disapears after undocking (patch) 
related to 0018553 resolvedMattias Gaertner Lazarus docked form designer, docking manager does not include the form 
related to 0019132 resolvedMattias Gaertner Lazarus anchordocking: TControl.ChangeBounds loop detected when docking an already docked window to a docksite 
related to 0019735 resolvedMattias Gaertner Lazarus AnchorDocking: opening a layout saved on a smaller monitor renders weird sizing 
related to 0021076 closedJuha Manninen Lazarus Feature like Delphi - Desktop speedsetting 
related to 0022149 resolvedMattias Gaertner Lazarus [Patch] Anchordocking : "HideHeaderCaptionForFloatingCheckBox" not working properly 
related to 0018407 resolvedyang jixian Lazarus Problem editing a form with AnchorDockingDsgn installed 
related to 0026836 closedMattias Gaertner Lazarus AnchorDocking: lost spliters on multiple loading layout 
related to 0034937 resolvedMichl Lazarus AnchorDocking: SimplifyOneControl destroy the layout 
related to 0018977 closedJuha Manninen Lazarus The form position in Delphi2006 style Lazarus IDE is not right. 
related to 0024394 resolvedMattias Gaertner Lazarus Error when saving AnchorDocking layout to file 
related to 0026646 resolvedMattias Gaertner Packages Anchordocking no longer work when using a laptop plus an external monitor. 
related to 0026200 closedZeljan Rikalo Lazarus rev45059 break anchordocking on qt widget type 
related to 0025981 closedJuha Manninen Lazarus Can't use docking layout 
related to 0019714 resolvedMattias Gaertner Lazarus anchordocking: Tab docking: layout will be saved incomplete 
related to 0020868 resolvedMattias Gaertner Packages Anchor Docking: "Save window layout" doesn't save Pages into xml 
related to 0024942 resolvedMattias Gaertner Packages Anchor Docking cannot remember window layout in some case 
related to 0021968 resolvedMattias Gaertner Lazarus AnchorDocking: IDE "Object Inspector" cannot dock. 
related to 0021430 resolvedJuha Manninen Packages Saving AnchorDocking layout to a file... 
related to 0023557 resolvedMattias Gaertner Packages [anchordocking] IDE isn't displayed if a package is into anchordocklayout 
related to 0022709 closedMattias Gaertner Lazarus AnchorDocking. Resizing host window changes children sizes. 
related to 0019272 assignedMattias Gaertner Lazarus AchorDocking ignored FormStyle:=fsStayOnTop 
related to 0016937 resolvedMattias Gaertner Lazarus Docking: Make docking headers optional 
related to 0026893 closedZeljan Rikalo Lazarus AnchorDocking crashes with Object inspector 
related to 0026895 closedJuha Manninen Lazarus AnchorDocking: Messages window either disappears or becomes very small in some situations 
related to 0026906 closedJuha Manninen Lazarus AnchorDocking wrong disable options 
related to 0026999 closedMattias Gaertner Lazarus [AnchorDocking] Wrong loading layout after loaded undocking state 
related to 0027165 closedMattias Gaertner Lazarus [patch] When ObjectInspector is docked to MainBar, the Paste-Command goes to SourceEditor 
related to 0027818 resolvedMattias Gaertner Packages With anchordocking activated, closing project and click on Lz-Mainform makes Proj-Assistant form disappear. 
related to 0028803 closedMattias Gaertner Lazarus Lazarus with Anchordocking always jumps to the wrong monitor in certain setup 
related to 0028843 resolvedMattias Gaertner Lazarus Package Graph close button not close form 
related to 0028858 closedMattias Gaertner Packages [regression] AnchorDocking configuration GUI does not load translations 
related to 0029178 closedMattias Gaertner Lazarus Exception and crash when using "Manage desktops" 
related to 0029190 resolvedMattias Gaertner Lazarus laz raises floating point exception after saving desktop 
related to 0029309 closedOndrej Pokorny Lazarus Wrong AnchorDocking resize behavior 
related to 0028096 resolvedOndrej Pokorny Lazarus AnchorDockingdsgn drive IDE into WM_Size Loop Detected 
related to 0029863 resolvedOndrej Pokorny Packages [regression] Anchordocking doesn't work in Lazarus 1.6 but works in Lazarus 1.4.4 
related to 0031084 closedOndrej Pokorny Lazarus Fix for AnchorDockingDsgn LoadDefaultLayout 
related to 0031883 resolvedMattias Gaertner Packages Anchordocking: When moving the last Editor to another window, the container-window stays open. 
related to 0031895 closedMattias Gaertner Lazarus Close button in docked ToDo list closes IDE 
related to 0032376 closedJuha Manninen Lazarus [AnchorDocking] Parasitic changes sites height with TAnchorDockPanel 
related to 0032390 closedMattias Gaertner Lazarus [AnchorDocking][patch] Wrong varnames inside $ifdefs 
related to 0029200 assignedMattias Gaertner Lazarus Desktop manager restore incorrect docked layouts when layout has docked pages 
related to 0033061 closedMichl Packages Anchordocking, the "Tab position" setting is not saved and restored 
related to 0034508 closedMichl Lazarus AnchorDocking, add an event allowing to draw a custom header 
related to 0034507 new Lazarus AnchorDocking, the "highlight focused" option should have an effect on the pages 


2010-12-22 20:32


mylayout.xml (1,749 bytes)   
<?xml version="1.0"?>
    <Nodes ChildCount="2">
      <Item1 Name="MainIDE" Type="CustomSite" ChildCount="1">
        <Bounds Top="65" Left="137" Width="1107" Height="676">
            <Rect Right="1280" Bottom="800"/>
        <Item1 Name="AnchorDockSite4" Type="Layout" ChildCount="5">
          <Bounds Top="83" Width="1107" Height="566" SplitterPos="79"/>
          <Anchors Align="Bottom"/>
          <Item1 Name="SourceNotebook" Type="Control">
            <Bounds Width="906" Height="472"/>
            <Anchors Right="AnchorDockSplitter3" Bottom="AnchorDockSplitter2"/>
            <Header Position="left"/>
          <Item2 Name="AnchorDockSplitter2" Type="SplitterHorizontal">
            <Bounds Top="472" Width="906" Height="4"/>
            <Anchors Right="AnchorDockSplitter3"/>
          <Item3 Name="AnchorDockSplitter3" Type="SplitterVertical">
            <Bounds Left="906" Width="4" Height="566"/>
          <Item4 Name="CodeExplorerView" Type="Control">
            <Bounds Left="910" Width="197" Height="566"/>
            <Anchors Left="AnchorDockSplitter3"/>
          <Item5 Name="MessagesView" Type="Control">
            <Bounds Top="476" Width="906" Height="90"/>
            <Anchors Top="AnchorDockSplitter2" Right="AnchorDockSplitter3"/>
      <Item2 Name="ObjectInspectorDlg" Type="Control">
        <Bounds Top="200" Width="230" Height="450">
            <Rect Right="1280" Bottom="800"/>
mylayout.xml (1,749 bytes)   

2010-12-22 20:34


screenshot-docking-bad.jpg (113,252 bytes)   
screenshot-docking-bad.jpg (113,252 bytes)   

2010-12-22 20:34


screenshot-docking-fixed.jpg (174,013 bytes)   
screenshot-docking-fixed.jpg (174,013 bytes)   

Sven Barth

2010-12-23 07:02

manager   ~0044512

Would it really hurt that much to put it into 0.9.30?

See it this way: Currently the layout is broken, so some of the potential testers are scared away if they see that on first start after recompilation. But if the first impression they see is at least usable they might even spend the time to write bug reports or even patches.

Also the anchor docking package is not installed by default. So what would break here?

Even if someone who uses trunk has docking enabled, it wouldn't change anything, because the ADLayoutDefault.xml is copied at first start into Lazarus' configuration directory and afterwards replaced by your own default layout (if you set a new one as default). So this updated default layout needs to be opened by manually navigating to the IDE's example directory if a user already uses docking.


Vincent Snijders

2010-12-23 07:54

manager   ~0044513

At this moment, patches get target 0.99 by default now. Only if they fix regressions, they can get target 0.9.30.

Mattias Gaertner

2011-04-23 18:41

manager   ~0047715

Note: the default layout is ok. But it is for big screens and the automatic shrinking on restore is not yet complete.

samuel herzog

2012-02-07 05:26

developer   ~0056606

Tested today on Lazarus 0.9.31 r35081 FPC 2.6.1 i386-win32-win32/win64

Looks ok. maybe fixed in the meantime?

Please re-test and close if ok.

2012-02-07 11:57


lazarus-docking-35197.PNG (115,228 bytes)   
lazarus-docking-35197.PNG (115,228 bytes)   

Sven Barth

2012-02-07 12:00

manager   ~0056616

Attached is a screenshot of a virgin Lazarus 35197, which means:
* downloaded source
* make all (using FPC 2.6.0)
* started using an empty config directory
* added anchordockdsgn package
* recompiled IDE
* restarted IDE

This does definitely not look good. System is a Windows 7 64-bit (but I'm using the 32-Bit version of Lazarus). Loading my layout attached here results in a correct look.


samuel herzog

2012-02-07 20:14

developer   ~0056632

I agree. The screenshot does not look ok.

There seems to be anyway a problem with the height of main-bar.

See Report 0001020. The height of main-bar changes if you press maximize. (even if there is no Anchordocking installed)

So lets fix 0001020 first.

2012-02-21 19:09


Oivind Toien

2014-03-05 10:04

reporter   ~0073470

Tested anchor docking of the IDE with v.1.2.0 final release. The problem is not only that the initial default positions are really messy as noted above (object inspector is not even included in the default layout), but that there is no persistence in the window positions when the IDE is closed down. Thus a nicely edited layout during a session does not appear to be saved/retrieved correctly, so window positions are really messed up again to the messy default. (Win 7 64-bit pro, Lazarus 32 bit rev.44303, AnchorDocking 0.6, AnchorDockingDsgn 0.5).

Udo Schmal

2014-03-06 21:00

reporter   ~0073520

You can use "Tools" and then "Save window layout as default"

Sven Barth

2014-03-07 16:50

manager   ~0073537

Yes, we are aware that the layout can be saved. The problem is that this is the initial default layout that is messed up and thus users might think that anchor docking is broken. It's a bad impression.


Oivind Toien

2014-03-14 17:29

reporter   ~0073702

Thanks for the tip! Yes, I obviously thought it was broken, and had sort of given it up, as I was not aware of the need to actively save a layout, and that there was a menu command for that. I think it would have made more sense if there was an option to save the last used docked layout of the IDE, and that this option was turned on by default, just as when the IDE is undocked. I never looked for the choice to save the layout, as it is not present when the IDE is undocked.

Oivind Toien

2014-03-14 18:23

reporter   ~0073704

Oops, I was celebrating too early. If the IDE is on an external/secondary monitor when layout is saved, next time Lazarus is opened all I am getting is a blank window with the menu on the primary display. (Windows 7 pro 64-bit. Lazarus 1.2 32 bit, ancordocking 0.6, anchordockingdesign 0.5, Primary laptop display 1920x1080, external monitor 1600x1200, both stay on.) The only way to recover is to "restore default layout", which comes up a little better as the big field of the Component toolbar is gone, but is lacking the object inspector window that was saved to the default.

So for now I will have to save the layout on the primary display and move the IDE to the external display when needed. Even if saving on on external display had worked, there is also the question what had happened if the external monitor was not present and a layout had been saved to it. Obviously that cannot be tested at this point.

Zeljan Rikalo

2014-03-15 09:14

developer   ~0073708

Maybe we should ask user to choose layout when docked ide is loaded for the first time ?

Oivind Toien

2014-03-19 03:39


Eudora-docking-grabzone-001.jpg (39,671 bytes)   
Eudora-docking-grabzone-001.jpg (39,671 bytes)   

Oivind Toien

2014-03-19 03:46

reporter   ~0073831

Sounds like a good idea, especially considering that persisting the last used layout would not presently work if Lazarus happened to be on the secondary display when closed and layout automatically saved. Thus having an actively saved default layout is probably best for now.

One little cosmetic thing, not really related to this bug: The grab zones for the docked windows are somewhat unusual and stand out a little too much making the view a little cluttered as they looks like buttons. I notice some programs just use a couple of less intrusive 3D lines for this. (An example is the classic Eudora I am running on my desktop, see uploaded screen shot). Is there an easy way to change this?

Zeljan Rikalo

2014-03-19 07:21

developer   ~0073833

Yes, you have docking settings and there you can set dock header type.

Oivind Toien

2014-03-21 02:33

reporter   ~0073872

Thanks, found it, very nice feature, more advanced than I had expected with so many docking configuration choices appearing under Tools-options.

The docking miniide1 example could perhaps be looked at, everything disappears except the top bar window when the outer frame is re-sized. But then maybe as an example it is not meant to be that robust.

samuel herzog

2014-09-15 19:41

developer   ~0077272

The anchordocking by matthias has been improved very well.

Today I tested the default layout again and want to let you see the result on my laptop.

Please see attached picture. (Lazarus 1.3 r FPC 2.6.5 i386-win32-win32_win64)

samuel herzog

2014-09-15 19:41


samuel herzog

2014-10-07 09:03

developer   ~0078039

Tested today with Lazarus 1.3 r46459 FPC 2.6.5 i386-win32-win32win64.

It looks better now. But it there a reason to not maximize it when starting first time?

I suggest to maximize it.

samuel herzog

2014-10-07 09:04


Mattias Gaertner

2014-10-07 10:46

manager   ~0078042

On big monitors a maximized IDE is too big. For example the source editor margin line is only one third.

Thaddy de Koning

2015-10-15 13:33

reporter   ~0086604

No, it is not. The margin line is already configurable and should stay so because of source code limits, not display limits. Just make sure the ide looks good proportionally.
The margin limit has always been a point of discussion. Not just with the big screens of today. It is still 80/132 related.

Issue History

Date Modified Username Field Change
2010-12-22 20:32 Sven Barth New Issue
2010-12-22 20:32 Sven Barth File Added: mylayout.xml
2010-12-22 20:32 Sven Barth Widgetset => GTK 2, Win32/Win64
2010-12-22 20:34 Sven Barth File Added: screenshot-docking-bad.jpg
2010-12-22 20:34 Sven Barth File Added: screenshot-docking-fixed.jpg
2010-12-22 20:38 Vincent Snijders LazTarget => 0.99.0
2010-12-22 20:38 Vincent Snijders Status new => acknowledged
2010-12-22 20:38 Vincent Snijders Target Version => 0.99.0
2010-12-23 07:02 Sven Barth Note Added: 0044512
2010-12-23 07:54 Vincent Snijders Note Added: 0044513
2011-03-24 11:31 Juha Manninen Relationship added related to 0018977
2011-03-30 09:43 Mattias Gaertner Status acknowledged => assigned
2011-03-30 09:43 Mattias Gaertner Assigned To => Mattias Gaertner
2011-04-23 18:41 Mattias Gaertner Note Added: 0047715
2011-10-03 17:18 Felipe Monteiro de Carvalho LazTarget 0.99.0 => 1.2
2012-02-07 05:26 samuel herzog Note Added: 0056606
2012-02-07 11:57 Sven Barth File Added: lazarus-docking-35197.PNG
2012-02-07 12:00 Sven Barth Note Added: 0056616
2012-02-07 20:14 samuel herzog Note Added: 0056632
2012-02-21 19:09 samuel herzog File Added: 0018298_Lazarus_ 0_9_31_r35517_FPC_2_6_1_i386-win32-win32_win64.gif
2012-03-06 07:14 Paul Ishenin Target Version 0.99.0 => 1.2.0
2013-06-23 16:19 Mattias Gaertner Relationship added related to 0024394
2013-06-23 16:21 Mattias Gaertner Relationship added related to 0018538
2013-06-23 16:21 Mattias Gaertner Relationship added related to 0019200
2013-06-23 16:21 Mattias Gaertner Relationship added related to 0001735
2013-06-23 16:21 Mattias Gaertner Relationship added related to 0019810
2013-06-23 16:22 Mattias Gaertner Relationship added related to 0020845
2013-06-23 16:22 Mattias Gaertner Relationship added related to 0023596
2014-02-15 20:51 Martin Friebe LazTarget 1.2 => 1.4
2014-02-15 20:52 Martin Friebe Target Version 1.2.0 => 1.4
2014-03-05 10:04 Oivind Toien Note Added: 0073470
2014-03-06 21:00 Udo Schmal Note Added: 0073520
2014-03-07 16:50 Sven Barth Note Added: 0073537
2014-03-14 17:29 Oivind Toien Note Added: 0073702
2014-03-14 18:23 Oivind Toien Note Added: 0073704
2014-03-15 09:14 Zeljan Rikalo Note Added: 0073708
2014-03-19 03:39 Oivind Toien File Added: Eudora-docking-grabzone-001.jpg
2014-03-19 03:46 Oivind Toien Note Added: 0073831
2014-03-19 07:21 Zeljan Rikalo Note Added: 0073833
2014-03-21 02:33 Oivind Toien Note Added: 0073872
2014-09-11 18:42 Mattias Gaertner Relationship added related to 0026646
2014-09-11 18:43 Mattias Gaertner Relationship added related to 0026200
2014-09-15 19:41 samuel herzog Note Added: 0077272
2014-09-15 19:41 samuel herzog File Added: default_layout_Lazarus 1.3 r FPC 2.6.5 i386-win32-win32_win64.gif
2014-10-06 21:52 Mattias Gaertner Relationship added related to 0018553
2014-10-06 21:52 Mattias Gaertner Relationship added related to 0019132
2014-10-06 21:52 Mattias Gaertner Relationship added related to 0019735
2014-10-06 21:53 Mattias Gaertner Relationship added related to 0021076
2014-10-06 21:53 Mattias Gaertner Relationship added related to 0022149
2014-10-06 21:58 Mattias Gaertner Relationship added related to 0018407
2014-10-06 23:13 Mattias Gaertner Fixed in Revision => 46451
2014-10-06 23:13 Mattias Gaertner Status assigned => resolved
2014-10-06 23:13 Mattias Gaertner Resolution open => fixed
2014-10-07 09:03 samuel herzog Note Added: 0078039
2014-10-07 09:04 samuel herzog File Added: lazarus_anchordockingLazarus 1.3 r46459 FPC 2.6.5 i386-win32-win32win64.gif
2014-10-07 10:46 Mattias Gaertner Note Added: 0078042
2014-10-09 14:05 Mattias Gaertner Relationship added related to 0026836
2014-10-12 22:24 Mattias Gaertner Relationship added related to 0025981
2014-10-15 08:19 Mattias Gaertner Relationship added related to 0019714
2014-10-15 08:20 Mattias Gaertner Relationship added related to 0020868
2014-10-15 08:20 Mattias Gaertner Relationship added related to 0024942
2014-10-15 08:20 Mattias Gaertner Relationship added related to 0021968
2014-10-15 08:21 Mattias Gaertner Relationship added related to 0021430
2014-10-15 08:22 Mattias Gaertner Relationship added related to 0023557
2014-10-18 12:56 Mattias Gaertner Relationship added related to 0022709
2014-10-18 12:59 Mattias Gaertner Relationship added related to 0019272
2014-10-18 13:00 Mattias Gaertner Relationship added related to 0016937
2014-10-19 12:24 Mattias Gaertner Relationship added related to 0026893
2014-10-19 19:01 Mattias Gaertner Relationship added related to 0026895
2014-10-29 23:37 Mattias Gaertner Relationship added related to 0026906
2014-11-05 23:24 Mattias Gaertner Relationship added related to 0026999
2014-12-14 21:15 Mattias Gaertner Relationship added related to 0027165
2015-04-09 23:52 Mattias Gaertner Relationship added related to 0027818
2015-10-08 14:29 Mattias Gaertner Relationship added related to 0028803
2015-10-13 16:10 Mattias Gaertner Relationship added related to 0028843
2015-10-15 10:03 Mattias Gaertner Relationship added related to 0028858
2015-10-15 13:33 Thaddy de Koning Note Added: 0086604
2015-12-16 00:03 Mattias Gaertner Relationship added related to 0029178
2015-12-16 00:04 Mattias Gaertner Relationship added related to 0029190
2016-01-02 11:33 Mattias Gaertner Relationship added related to 0029309
2016-01-02 11:34 Mattias Gaertner Relationship added related to 0029310
2016-01-02 11:34 Mattias Gaertner Relationship deleted related to 0029310
2016-01-20 12:28 Mattias Gaertner Relationship added related to 0028096
2016-03-20 20:09 Mattias Gaertner Relationship added related to 0029863
2016-12-07 21:05 Michl Relationship added related to 0031084
2017-05-21 22:35 Mattias Gaertner Relationship added related to 0031883
2017-05-23 12:18 Mattias Gaertner Relationship added related to 0031895
2017-09-08 10:42 Mattias Gaertner Relationship added related to 0032376
2017-09-09 12:11 Mattias Gaertner Relationship added related to 0032390
2018-05-22 09:27 Mattias Gaertner Relationship added related to 0029200
2018-05-22 09:27 Mattias Gaertner Relationship added related to 0033061
2018-12-12 22:40 Michl Relationship added related to 0034508
2018-12-12 22:43 Michl Relationship added related to 0034507
2019-01-24 19:35 Michl Relationship added related to 0034937