GUI widget (source code)

= GUI widget
{c}

A <GUI widget> is an interactive or display component of a <graphical user interface>, such as a button, text field or list. It combines presentation, relevant <state> and responses to <software events>. Widgets can contain other widgets; a layout manager arranges them using their size requirements.<Qt Widgets documentation>[Widgets and Layouts]{ref}

For example, a numeric-entry <GUI widget> stores editable text, draws it and reacts to keystrokes. The text `1e` can be a legitimate intermediate editing state even when the completed value must be numeric. Separating editing behavior from the application's data model makes that distinction manageable. A disabled button conveys interface <state>; server-side <authorization> still has to decide whether the underlying action is permitted.