I have a (desktop) container control containing a label, a couple of canvases, and a textfield. It gets instantiated and embedded into two other containercontrols at runtime to make a scrolling list. It’s been 36 pixels high for a long time. Now I want to make it taller, so I made it taller in the IDE - it’s 178 pixels high. When I run the app, however, it’s alway 36 pixels high. I even exported it and dragged it back into the project - still 36 pixels high.
In the layout editor for the cc:
Breakpointed where the cc is being embedded: Height = 36
That’s caused by unchecking the visibility box of the property in the Inspector Behavior dialog. Unfortunately it makes the property invisible in the editor too so you’ll need to fix it in your source file.
Thanks, that led me to the source of the problem, which is poorly-written code: buried in the class is a method that sets the height to hard-coded values
@Greg_O how do you make the property visible again in the inspector behavior, if by mistake you unchecked it ? it happened in one of my class and I’m unable to make it visible again… the property is in the class, but the inspector doesn’t show it. it is shown in the superclass, and it’s not shadowed by a subclass property I checked. thanks.
and if the project is in binary ? I must save as text or xml, modify it and reopen it ?
my class is in an external item, do I need to search in the class file, or in the project ?
thanks.
You can’t fix it in a binary project as is. I agree that it’s not optimal but it’s also something that Xojo would have to fix for us.
I remember having a discussion with NP shortly after the change was made and the problem is that there needed to be two states for visibility. One for “Internal” that Xojo could use for making things not visible to users and one for “visible” which allowed users to determine which ones were visible in their own classes. Unfortunately this is an implementation issue that goes all the way back to when the dialog was introduced in Real Studio. Do I think that it’s impossible to fix? No. Do I think that it’s going to get refactored anytime soon? Also no.