[Lazarus] IDE Main Window: height is too small and cannot resize (Linux/GTK2)
Mark Morgan Lloyd
markMLl.lazarus at telemetry.co.uk
Mon Feb 13 09:29:25 CET 2012
Bart wrote:
> On 2/11/12, Luiz Americo Pereira Camara <luizmed at oi.com.br> wrote:
>> I dont see why all this fuzz.
>> In my copy of Lazarus (win32) the IDE remember the position of the window.
>> So, if the user does not like the default height just resize to his
>> desire and next time open will show the "correct" height
>
> It's not fuzz.
> As stated before: the height of the IDE main windows is limited to 85 pixels.
> This is too small for my OS/WM/Theme on Linux.
> If I would use a larger fontsize on Windows the 85 pixels would
> probably also bee too small.
> Currently, it is impossible to get a proper window layout for this window.
>
> You cannot rely on the value of (client)height being correct on GTK2
> until after the form is shown (after OnShow).
> I have wrestled with that may times when sizing forms by code and
> trying to make their size just big enough.
>
> I have some code lying aroud that tries to compensate for the
> clientheight/height issue, which on my system gives a rough
> approximation.
> That code however relies on Application.QueueAsyncCall(), which isn't
> implemented for all widgetsets IIRC.
As we all have.
If I understand the issue correctly, GUI programming was originally
defined in terms of a predefined form size containing vector-drawn
components: there might be issues with jaggies or imprecise positioning
due to numeric rounding but in general content could be scaled to fit
its container.
The problem is that an increasing amount of the UI is now defined by
bitmaps- icons, photos or dynamic content- and the programming model is
not good at positioning this and then shrink-fitting a frame around it,
taking into account any widgetset-defined "furniture".
--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk
[Opinions above are the author's, not those of his employers or colleagues]
More information about the Lazarus
mailing list