Wintermute Engine Forum
Wintermute Engine => Bug reports => Topic started by: Lion on October 02, 2009, 11:32:35 AM
-
I create a window with a static object:
WINDOW
{
X = 0
Y = 0
WIDTH = 1024
HEIGHT = 768
STATIC
{
NAME = "Background"
X = 512
Y = 320
}
}
Then in a script I use the function SetImage() for static object.
How I must know the width & height of the loaded image?
-
You can't, I'm afraid. The static control size is independent on the image size. And there's currently no way of querying sprite frame dimensions from script.
-
Do I can to use the function SizeToFit() of static object?
// Changes the size of the control to fit the contained text or image.
I after to know a width and height of static object? Is it possible so to do?
-
SizeToFit() with images does not work. It is although written in a help:
Changes the size of the control to fit the contained text or image.
Why?
-
Why? I don't know, must have been drunk when writing the docs. Or the code. Or both.
Seriously, it's an omission.
-
Is it possible to do that SizeToFit() function worked and for images?
As it is written in a wme.chm.
It is very necessary...
-
And when will you be able it to add to the WME? Please...
-
The feature request has been noted. As wme is a hobby project the answer to all feature requests is "When -and if- it's done(tm)". Also wme is opensource so people are encouraged to add their own features and submit the code under the same license (lgpl).
EDIT: silly typo