ContainerControl is not a RectControl?

Hi Folks,

I’m trying to manipulate controls on a layout aimed at smart control positioning and sizing. I have things working very well with MOST items until I get to a ContainerControl. In my control settings loop, I check for IsA RectControl and the Containers are not being caught.

Is this expected or a bug?

Mac OS
Xojo 2017r3.

Expected. Containers are their own thing.

The container is not the control. That is a different one with another name. You find it when you loop through controls on the window…

I’m not sure how to tell from the new documentation, but in the older documentation ContainerControl doesn’t have the "inherits from RectControl" part at the top, which means exactly what Bob said.

Edit: Oh, I misplaced it, it’s on the right and says it inherits from Object. But this lets us know how IsA will respond. I noticed this after Dave shouted at us in the next post.

CONTAINERCONTROL inherits from OBJECT, just like WINDOW does

RECTCONTROL inherits from]CONTROL which in turn inherits from OBJECT

shhhhh… sorry to have offended anyone that can imply “volume” from typed text

To confuse things further, IIRC a containControl IsA Window…

  • karen

[quote=378307:@Karen Atkocius]To confuse things further, IIRC a containControl IsA Window…

  • karen[/quote]
    Tested this just now in 2017r3, and holy cow it’s true. Thanks for the tip!

Introspection reports Container Control as Embedded Window…

Yes, isa can be used with EmbeddedWindowControl to detect the container.

Capitals can also provide emphasis. Stay cool, and think outside the box … :wink:

We have lots of great formatting tools (https://forum.xojo.com/38560-post-formatting-tips) for emphasis.

… the emoji selection is weird …

I actually went there to find a smiley face with sunglasses to show you how cool I was, but we don’t have one :frowning:

You forgot thinking outside the box:

You can use a smaller one:

My coolness required a larger one … :wink:

<(^.^)>

Sorry had to try this one :stuck_out_tongue:

Of course. :slight_smile:

Can you please change the URL on the quoted text to https? I just found out that I broke the ‘lock’ on Firefox (Parts of this page are not secure).

Done