[Lazarus] IDE docking flaw?
Hans-Peter Diettrich
DrDiettrich1 at aol.com
Wed Jun 8 03:15:58 CEST 2011
Mattias Gaertner schrieb:
>> Sorry, I still cannot find a Layout list in the MainBar :-(
>
> Your MiniIDE has default layouts, because you added them to the menu.
> Same can be done by an IDE package that registers a dock master.
A menu entry is different from a ComboBox. Such a visual component can
already be used by the the IDE's SimpleLayout...
> For anchordocking the simplelayout is only important, when the user
> uninstalls/deactivates anchordocking. That's why simplelayout should
> store screen bounds of docked forms.
Not a good idea with notebook-docking :-(
> If I understand you correct, you want to use simplelayout in parallel
> with your dockmaster, right?
Not really, but GetForm may introduce such a dependency. Why should a
DockMaster guess where to place new forms, when the IDE already
established such defaults?
>> [...]
>>>> I've improved TScreen
>>>> and ShowForm already, so that my ShowForm will force all forms into the
>>>> monitor bounds. [Patch available on demand]
>>> Have you tested this under Linux/gtk2?
>> No, but it should work when Screen.Monitors returns the true monitor
>> bounds. More complicated is exclusion of the TaskBar...
>
> AFAIK Screen.Monitors changes when switching to another workspace.
May be, but how does the IDE handle such switching?
[AFAIR at least Ubuntu uses system-wide screen and monitor settings]
IMO such a problem occurs only when an already running application is
assigned to an different or all workspaces. What should an application
do then, provided that it is notified at all?
> And it seems the monitor bounds are not always correct from the
> beginning, for example when the IDE creates its first window and calls
> restore layout. This seems to be a general problem on all widgetsets.
That's why I made the ScreenBounds dynamic: GetScreenBounds determines
the bounds on its first call, at least. This can be done whenever the
screen manager sends a notification of changed screen resolution,
taskbar position, or the like.
DoDi
More information about the Lazarus
mailing list