controls, like views, interact with the user and what is a control? The sliders, switches, and so on that we use are all controls. The base class for the control is Uicontrol. The contents of the control are as follows:
It is mainly selected, can be used and highlighted. We use a button to show:
Unchecked state:
Blue Word on the white background, now we tick selected:
When selected, it turns into a blue-bottomed white, flipped, which is also in line with our daily habits.
If highlighting is selected, the color will be lighter gray:
Space supports a variety of interactive events, such as gestures, touch, drag, and so on. are in the class uicontrolevents. A control's target-action mechanism, in which a control sends a message to another object after an event related to it occurs.
Is the manipulation of the appearance of the control, primarily horizontal and vertical alignment.
The constraints and views of the control are almost as well as the constraints of the distance.
The control also has important accessibility features:
Traits: Concise description of State/behavior/usage combinations.
Hint: A brief indication of the result of an action.
Frame: The screen coordinate frame of an element.
Value: The current value of an element
Swift UI Special training 26 Controls Overview