Some iOS APIs are just retarded.

Apple's retarded double negative:
myUIButton.isHidden = fasle

How about just:
myUIButton.isShown = true

  • 6
    How about `UIObject.visible`?
    No indirection that way.
    Nice and clear.
  • 2
    This. Visible in most rendering models is a compositor setting, whereas hidden is an instance exemption from display.

    Personally I don't find a lot of value to the distinction and would be fine with visible being the only setting, even if there's slight variation in the mechanics.
  • 1
    @SortOfTested Fair point.
  • 0
    JavaFX does that, too with having disabledProperty(). So no surprise to me.

    Depending on your logic, explicitly hiding something is more clear than the other way around.

    Edit: 0x @cafebabe 's explanation seems better than mine.
Add Comment