Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: TBitmap gets smaller on rotation in delphi xe8 firemonkey multi device proj


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 4 - Last Post: Aug 10, 2015 4:43 AM Last Post By: Remi Arts
Remi Arts

Posts: 40
Registered: 11/15/13
TBitmap gets smaller on rotation in delphi xe8 firemonkey multi device proj  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 31, 2015 7:36 AM
I have an TImage compontent with a bitmap. The image component size properties are singles and TBitmap size properties are integers. The bitmap needs to be the same size as the component and i've made a resize method that gets called everytime the screen rotates.

So i've tried to trunc the component size in order to set the size and tried to round it, but every time the bitmap gets smaller.

I also tried to cast the sizes of the image component to integer so it doesn't have to round the size for the bitmap. But this has no effect.

Is there a solution for this problem?
Chris Dunn

Posts: 160
Registered: 8/22/11
Re: TBitmap gets smaller on rotation in delphi xe8 firemonkey multi device proj  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 31, 2015 12:32 PM   in response to: Remi Arts in response to: Remi Arts
Is the bitmap a child in the component? Just set align=client and use margins.

otherwise use a timer onresize. set it 2 or 3 seconds. in the timer, execute your resize code.

Edited by: Chris Dunn on Jul 31, 2015 12:36 PM
Remi Arts

Posts: 40
Registered: 11/15/13
Re: TBitmap gets smaller on rotation in delphi xe8 firemonkey multi device proj  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Aug 3, 2015 12:25 AM   in response to: Chris Dunn in response to: Chris Dunn
Chris Dunn wrote:
Is the bitmap a child in the component? Just set align=client and use margins.

otherwise use a timer onresize. set it 2 or 3 seconds. in the timer, execute your resize code.

Edited by: Chris Dunn on Jul 31, 2015 12:36 PM

Yes it's a child of an Image component. But the bitmap doesn't have the Align property, only the image component has an align property and it's already set on Client.
Chris Dunn

Posts: 160
Registered: 8/22/11
Re: TBitmap gets smaller on rotation in delphi xe8 firemonkey multi device proj  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Aug 4, 2015 8:28 AM   in response to: Remi Arts in response to: Remi Arts
Need more info.
I can Start new multi device project -> drop timage -> Load bitmap -> onformresize set height and width of Timage in IOS and Android.
The bitmap resizes its-self. Do you have other properties set?
Remi Arts

Posts: 40
Registered: 11/15/13
Re: TBitmap gets smaller on rotation in delphi xe8 firemonkey multi device proj  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Aug 10, 2015 4:43 AM   in response to: Chris Dunn in response to: Chris Dunn
Chris Dunn wrote:
Need more info.
I can Start new multi device project -> drop timage -> Load bitmap -> onformresize set height and width of Timage in IOS and Android.
The bitmap resizes its-self. Do you have other properties set?

Yes I add the bitmap runtime. I use the image compontent to draw on like a signature.
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02