Status & Roadmap
Authors & License
Funding Ultimate++
Search on this site
Search in forums

SourceForge.net Logo
Home » U++ TheIDE » U++ TheIDE: Layout (Forms) Designer » Why Size difference on top window and button?
icon5.gif  Why Size difference on top window and button? [message #32932] Tue, 21 June 2011 22:23 Go to next message
silverx is currently offline  silverx
Messages: 62
Registered: March 2011
I have created a simple layout with a top window and button on it. The window size is 335, 250 yet when I run the getsize it comes up with 358, 288, and then I have a button on the window the size is 200, 175, yet when I run the get size on it it shows 214, 173.

Why is their a difference? How do I get the actual size of the item? Is this a bug, or am I missing something here?

I have attached the file with the everything in it so you can see.


  • Attachment: Sizeinfo.zip
    (Size: 1.44KB, Downloaded 341 times)
Re: Why Size difference on top window and button? [message #33077 is a reply to message #32932] Wed, 06 July 2011 00:28 Go to previous message
dolik.rce is currently offline  dolik.rce
Messages: 1789
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

Hi silverx,

The cause lies in the concept of "zooming". It is intended to make things look the same on systems with various settings. The layout designer internally uses the "Z" functions (e.g. LeftPosZ() etc.). If you invoked the same code yourself, using e.g. LeftPos(), you would achieve the values you expected. Read the detailed explanation in this article: http://www.ultimatepp.org/srcdoc$CtrlCore$LogPos$en-us.html

Best regards,
Previous Topic: More info on IDE designer
Next Topic: How to Change Button background image, and mouse over image
Goto Forum:

Current Time: Sun Jun 23 16:13:13 CEST 2024

Total time taken to generate the page: 0.00959 seconds