The toggle script exposes colors for
Normal
Highlighted
Pressed
Disabled
but where is: Selected?
The toggle script exposes colors for
Normal
Highlighted
Pressed
Disabled
but where is: Selected?
And - how can we change these colors by script?
Same problem here!
I’m trying to change text color when Toggle is on using Animation but I can’t.
public virtual void OnDeselect(BaseEventData eventData);
public virtual void OnMove(AxisEventData eventData);
public virtual void OnPointerDown(PointerEventData eventData);
public virtual void OnPointerEnter(PointerEventData eventData);
public virtual void OnPointerExit(PointerEventData eventData);
public virtual void OnPointerUp(PointerEventData eventData);
public virtual void OnSelect(BaseEventData eventData);
This works:
GetComponent(UI.Text).color = myColor;
GetComponent(UI.Toggle).colors.highlightedColor = myColor;