 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Howard Koch Guest
|
Posted: Tue Jul 11, 2006 8:11 am Post subject: screen resolution |
|
|
Hi
I have just tired to install my application on a new xp note book. The app.
was created at 800*600 and the code below has worked for years. Now
regardless of the new pc's screen resolution the app. is way of the screen
and distored. Any help would be much appriciated. If this is wrong group
please advise on correct one.
Thanks
procedure TOpeningScreen.FormCreate(Sender: TObject);
const
ScreenWidth: LongInt = 800;
ScreenHeight: LongInt = 600;
var
OLD_ScreenWidth:longint;
I: Integer;
Temp: TComponent;
begin
scaled := true;
if (screen.width <> ScreenWidth)
then
begin
old_ScreenWidth:= screen.width;
height := longint(height) * longint(screen.height) div ScreenHeight;
width := longint(width) * longint(screen.width) div ScreenWidth;
scaleBy(screen.width, ScreenWidth);
for I := ComponentCount - 1 downto 0 do
begin
with Components[I] do
begin
font.size:=
(screen.width div old_screenwidth) * font.size
end;
end
end;
end;} |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|