I had set an image for a button but realized it was much too big.
I resized it and copied it to a new name, set the path to that new file, and the button stayed the same size, but with a blurry icon.
Here is the resized image :
I had set an image for a button but realized it was much too big.
I resized it and copied it to a new name, set the path to that new file, and the button stayed the same size, but with a blurry icon.
Here is the resized image :
Hello - toolbar buttons use three bitmap sizes - you need to edit all three for them all to look correct.
-Pascal
Oh damned, why do I end up here : this was intended for Grasshopper / Human UI
My question has nothing to do with Rhinoās buttons
Any idea whatās causing this bloated button phenomenon ?
If I reconnect the path of the image to the button component, the size goes back to normal ; ānormalā being the size that was set through the āadjust element positioningā component.
Please, anyone : am I alone with this ?
Iād like to use icons in my Human UI definitions, but Iām stuck with texts until I solve this ussue.
Hi Keyu,
thanks for your test.
Today, I have a new flavor of bizarre : the button stays small when I refresh, but if itās not connected to an āAdjustPosā component, it will inflate againā¦
Just to make it clear : what library does Human UI use ? ETO or Windows Forms ?
Neither. Windows Presentation Framework.
Bests,
Keyu Gan
Maybe you can upload that part of your definition and the images you were using
Bests,
Keyu Gan
OK here it is :
BIG icons.gh (27.7 KB)
I serialized / internalized the images.
The bug still manifests.
Could this interfere with ETO elements in Rhino ?
Weāve been plagued with empty ETO pop-ups and tabs for three years now, and recently, with Human UI windows active, activating a Rhino ETO window crashes Rhino.
No. Eto & WPF & WinForm are basically three things, which I guess is also part of the reason why Andrew doesnāt actively work on HumanUI ā¦
Ughā¦ just crashed again.
The only thing I get is this crash log file :
RhinoDotNetCrash.txt (6.9 KB)
It says something about it being " impossible to find ressource āiconbutton/themes/aero2.normalcolor.xamlā "
That file is present on my hard drive :
But looking at the crash file, I see two mentions of a path that doesnāt exist on my computer since I have no "D:" drive :
Maybe thereās something special about the French localization of Windows ā¦
Anyways, do you see the big icons bug with my file, on your side ?
yes. let me see waht happened
Eto is WPF on Windows Rhino.
Hi Steve, did you have a look at the crash log ?
Ok, so you get the swollen icons too, right ?
Thatās fine as long as you are only developing for Windows. You can mix WPF with Eto. Look at the crash that was posted here; you can see that it is just WPF.
@curtisw can you take a look at this? Iām having trouble deciphering what is happening. It may be the reason Olivier has had problems with WPF for so longā¦ or maybe not.
@osuire the crash is happening because human-ui includes an old version of Xceed.Wpf.Toolkit.dll
(3.0), which is incompatible with the version that is shipped with Rhino (3.6). Due to the way we handle assemblies in Rhino, this causes a conflict if the human-ui version loads before the one shipped with Rhino.
If you remove (or rename) that assembly from the human-ui plugin it shouldnāt crash. Iāve created RH-62909 to look into a way to get around that if possible without causing other issues.
As for your issue with image sizes, your source image appears to be saved with 16 Pixels Per Inch. WPF looks at this to determine what size to show it at. Windows is by default 96 PPI, so 32 pixels * 96 / 16 = 192 logical pixels. If you edit the image and re-save it at 96 PPI, then it should show at the expected size.
Hope this helps!