UCommonButtonBase - Custom Hitboxes

Error while parsing Rich Text Content

Hi,

This seems like a good solution, though I’d be a bit worried about making the change on our end. The current implementation means that buttons derived off of UCommonButtonBase will work out of the box without having to change any defaults, even though UserWidgets are non-hittestable by default. This doesn’t make a lot of sense since the visible bit of the hierarchy is obfuscated, but changing the default behavior to match the UCommonButtonBase visibility would mean a lot of buttons would just stop working until the visibility was adjusted. That said, I think it’s a good solution to your problem, as long as designers are aware that you’ll need to either change the default visibility of the button or add something hit-testable as a child.

Best,

Cody

Hey,

Appreciate the response.

Funny you should note that risk of the change, as have had to make the suggested change above less globally reaching as you say. Given that most buttons are set by default to not be hit testable it did break the usability of buttons - however you could argue we’ve ‘got away with it’ given the visibility value set on the overall widget is thrown away really in favor of the visible internal button.

In the end the non ideal, but less destructive solution I went for was a separate serialised setting so you could change the visibility of the hidden button & had it default to visible.

Figured worth reaching out about this point either way though, given the restriction ofUCommonButtonBase not working with custom shapes & others may benefit from knowing it can be fixed/epic being made aware to make their own fix.

Thanks,

Cameron