Mattias Gaertner schrieb:
> > ClientRect Left,Top is 0,0, so Right=ClientWidth and
Bottom=ClientHeight.
>
> Is this really consistent with a scrolled client area, inner borders,
> swapped scrollbars in BiDi mode etc.?
I'm not sure what you mean with "inner borders".
See e.g. TControl
Hans-Peter Diettrich hat am 7. Oktober 2011 um 13:33
geschrieben:
> Mattias Gaertner schrieb:
>
> > ClientRect Left,Top is 0,0, so Right=ClientWidth and Bottom=ClientHeight.
>
> What about the determination of the ScrollOffset:
>
> function TScrollingWinControl.GetClientScrollOffset: TPoint;
Hans-Peter Diettrich hat am 7. Oktober 2011 um 13:18
geschrieben:
> Mattias Gaertner schrieb:
>
> > > > Where exactly is TRect used to hold the Width and Height? File and
> > Line.
> > >
> > > TControl.GetClientRect
> > > (controls.inc 1525..)
> > >
> > > BoundsRect and ClientRect cont
Mattias Gaertner schrieb:
ClientRect Left,Top is 0,0, so Right=ClientWidth and Bottom=ClientHeight.
What about the determination of the ScrollOffset:
function TScrollingWinControl.GetClientScrollOffset: TPoint;
begin
if (HorzScrollBar <> nil) and (VertScrollBar <> nil) then
begin
Resu
Mattias Gaertner schrieb:
> > Where exactly is TRect used to hold the Width and Height? File and
Line.
>
> TControl.GetClientRect
> (controls.inc 1525..)
>
> BoundsRect and ClientRect contain different information, despite the
> similar name and type.
They both return a Left,Top,Rig
Hans-Peter Diettrich hat am 7. Oktober 2011 um 11:52
geschrieben:
> Felipe Monteiro de Carvalho schrieb:
> > On Fri, Oct 7, 2011 at 6:34 AM, Hans-Peter Diettrich
> > wrote:
> >> The ambiguous use of TRect, with either BottomRight or WidthHeight in the
> >> second TPoint, often leads to misu
On Fri, Oct 7, 2011 at 11:52 AM, Hans-Peter Diettrich
wrote:
> TControl.GetClientRect
> (controls.inc 1525..)
wow, what a nasty thing =D I was using it wrongly myself.
Unfortunately it is Delphi-compatible:
http://docwiki.embarcadero.com/VCL/en/Controls.TControl.ClientRect
--
Felipe Monteiro
Felipe Monteiro de Carvalho schrieb:
On Fri, Oct 7, 2011 at 6:34 AM, Hans-Peter Diettrich
wrote:
The ambiguous use of TRect, with either BottomRight or WidthHeight in the
second TPoint, often leads to misunderstandings and flawed code (as above).
It were helpful when type alias would be introdu
On Fri, Oct 7, 2011 at 6:34 AM, Hans-Peter Diettrich
wrote:
> The ambiguous use of TRect, with either BottomRight or WidthHeight in the
> second TPoint, often leads to misunderstandings and flawed code (as above).
> It were helpful when type alias would be introduced and used, or when the
> argume
TControl.ScrolledClientRect offsets *all* fields in the TRect by the
scroll offsets. This is *incorrect*, when the TRect is initialized to
ClientRect, where the second set of coordinates is the Width and Heigth,
not the BottomRight corner of the area. Obviously Width and Height are
insensitive
10 matches
Mail list logo