Hi pri_sama,

> I want to create an Edit box which when enlarged or shrinked the
> text 
> inside should be changed(size) accordingly maintaining the same
> ratio. 
> Has somebody have any idea about this ? please help.
> (Delphi 5)

First you have to resize your edit box. Either in OnResize event of your form 
or by setting property Anchor of TEdit.

Secondly i would calculate FontSize:

myFontSize := Round(Min(
   Self.ClientWidth / const100PercentFormWidth * constOrgFontSize),
   Self.ClientHeight / const100PercentFormHeight * constOrgFontSize));


-- 
Cheers,
J�rn



-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/delphi-en/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to