How to make a button checkable

In the UIElements Samples included with 2019.2, I notice that buttons can have a Checked state. How do I make a button Checkable?

You must use the Toggle class:

setting it’s value to true will make it checked.

Turns out, you can’t set a Button in the checked state without internal access. The UIElementsSample window is cheating it seems :frowning: