From 5d6f509d634bc46f0d522f34474f2f7bc36e16e5 Mon Sep 17 00:00:00 2001 From: lazarus Date: Tue, 15 Oct 2002 17:09:54 +0000 Subject: [PATCH] AJ: fixed GTK DrawText to use WordWrap, and add DT_EditControl git-svn-id: trunk@3515 - --- lcl/interfaces/gnome/gnomewinapi.inc | 10 ++++++++-- lcl/lcltype.pp | 4 ++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lcl/interfaces/gnome/gnomewinapi.inc b/lcl/interfaces/gnome/gnomewinapi.inc index d97bbc90d2..ac7581e2ee 100644 --- a/lcl/interfaces/gnome/gnomewinapi.inc +++ b/lcl/interfaces/gnome/gnomewinapi.inc @@ -203,14 +203,17 @@ begin If Lines <> nil then begin Line := Lines^.Rows; While Line <> nil do begin + If (((Flags and DT_EditControl) = DT_EditControl) and + (tm.tmHeight > (theRect.Bottom - theRect.Top))) or + (theRect.Top > theRect.Bottom) + then + break; If Line^.Data <> nil then begin LineInfo := PGnomeIconTextInfoRow(Line^.Data)^; DrawLine(LineInfo.theText, LineInfo.Text_Length, theRect.Top); Inc(theRect.Top, TM.tmHeight); end; Line := Line^.Next; - If theRect.Top > theRect.Bottom then - Break; end; Result := 1; end; @@ -501,6 +504,9 @@ end; { $Log$ + Revision 1.8 2002/10/15 17:09:54 lazarus + AJ: fixed GTK DrawText to use WordWrap, and add DT_EditControl + Revision 1.7 2002/10/14 18:36:57 lazarus AJ: Improvements/Fixes to new PromptUser API diff --git a/lcl/lcltype.pp b/lcl/lcltype.pp index 2336a30cc0..82f1416190 100644 --- a/lcl/lcltype.pp +++ b/lcl/lcltype.pp @@ -148,6 +148,7 @@ const DT_CALCRECT = $400; DT_NOPREFIX = $800; DT_INTERNAL = $1000; + DT_EDITCONTROL = $2000; //============================================== // Draw frame constants @@ -1621,6 +1622,9 @@ end. { $Log$ + Revision 1.22 2002/10/15 17:09:53 lazarus + AJ: fixed GTK DrawText to use WordWrap, and add DT_EditControl + Revision 1.21 2002/10/12 16:36:39 lazarus AJ: added new QueryUser/NotifyUser