Method AddStickyBtnCore
AddStickyBtnCore(string?, ImageSet?, ImageSet?, string?, EventHandler?)
Adds a sticky button to the user interface with the specified text, images, tooltip, and action.
public virtual SpeedButton AddStickyBtnCore(string? text, ImageSet? imageSet, ImageSet? imageSetDisabled, string? toolTip = null, EventHandler? action = null)
Parameters
textstringThe text to display on the button. Can be null if no text is required.
imageSetImageSetThe set of images to use for the button's normal state. Can be null if no image is required.
imageSetDisabledImageSetThe set of images to use for the button's disabled state. Can be null if no image is required.
toolTipstringThe tooltip text to display when the user hovers over the button. Can be null if no tooltip is required.
actionEventHandlerThe event handler to invoke when the button is clicked. Can be null if no action is required.
Returns
- SpeedButton
A SpeedButton instance representing the sticky button. The button's margin is set to the default sticky button margin, and its click behavior adjusts the border widths based on the sticky state.
Remarks
A sticky button remains in a pressed state until explicitly toggled. The border widths of the button are adjusted dynamically based on its sticky state when clicked.