Package apple.uikit

Class UIView

    • Constructor Detail

      • UIView

        protected UIView​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • addKeyframeWithRelativeStartTimeRelativeDurationAnimations

        public static void addKeyframeWithRelativeStartTimeRelativeDurationAnimations​(double frameStartTime,
                                                                                      double frameDuration,
                                                                                      UIView.Block_addKeyframeWithRelativeStartTimeRelativeDurationAnimations animations)
        start time and duration are values between 0.0 and 1.0 specifying time and duration relative to the overall time of the keyframe animation
      • alloc

        public static UIView alloc()
      • allocWithZone

        public static java.lang.Object allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • animateWithDurationDelayUsingSpringWithDampingInitialSpringVelocityOptionsAnimationsCompletion

        public static void animateWithDurationDelayUsingSpringWithDampingInitialSpringVelocityOptionsAnimationsCompletion​(double duration,
                                                                                                                          double delay,
                                                                                                                          double dampingRatio,
                                                                                                                          double velocity,
                                                                                                                          long options,
                                                                                                                          UIView.Block_animateWithDurationDelayUsingSpringWithDampingInitialSpringVelocityOptionsAnimationsCompletion_5 animations,
                                                                                                                          UIView.Block_animateWithDurationDelayUsingSpringWithDampingInitialSpringVelocityOptionsAnimationsCompletion_6 completion)
        Performs `animations` using a timing curve described by the motion of a spring. When `dampingRatio` is 1, the animation will smoothly decelerate to its final model values without oscillating. Damping ratios less than 1 will oscillate more and more before coming to a complete stop. You can use the initial spring velocity to specify how fast the object at the end of the simulated spring was moving before it was attached. It's a unit coordinate system, where 1 is defined as travelling the total animation distance in a second. So if you're changing an object's position by 200pt in this animation, and you want the animation to behave as if the object was moving at 100pt/s before the animation started, you'd pass 0.5. You'll typically want to pass 0 for the velocity.
      • appearance

        public static java.lang.Object appearance()
      • appearanceForTraitCollection

        public static java.lang.Object appearanceForTraitCollection​(UITraitCollection trait)
      • appearanceForTraitCollectionWhenContainedIn

        @Deprecated
        public static java.lang.Object appearanceForTraitCollectionWhenContainedIn​(UITraitCollection trait,
                                                                                   UIAppearanceContainer ContainerClass,
                                                                                   java.lang.Object... varargs)
        Deprecated.
      • appearanceForTraitCollectionWhenContainedInInstancesOfClasses

        public static java.lang.Object appearanceForTraitCollectionWhenContainedInInstancesOfClasses​(UITraitCollection trait,
                                                                                                     NSArray<?> containerTypes)
      • appearanceWhenContainedIn

        @Deprecated
        public static java.lang.Object appearanceWhenContainedIn​(UIAppearanceContainer ContainerClass,
                                                                 java.lang.Object... varargs)
        Deprecated.
      • appearanceWhenContainedInInstancesOfClasses

        public static java.lang.Object appearanceWhenContainedInInstancesOfClasses​(NSArray<?> containerTypes)
      • areAnimationsEnabled

        public static boolean areAnimationsEnabled()
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(java.lang.String key)
      • beginAnimationsContext

        public static void beginAnimationsContext​(java.lang.String animationID,
                                                  org.moe.natj.general.ptr.VoidPtr context)
        Deprecated in iOS 13.0. Please use the block-based animation API instead.
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(java.lang.Object aTarget,
                                                                                 org.moe.natj.objc.SEL aSelector,
                                                                                 java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        public static org.moe.natj.objc.Class classForKeyedUnarchiver()
      • clearTextInputContextIdentifier

        public static void clearTextInputContextIdentifier​(java.lang.String identifier)
      • commitAnimations

        public static void commitAnimations()
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • hash_static

        public static long hash_static()
      • inheritedAnimationDuration

        public static double inheritedAnimationDuration()
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • keyPathsForValuesAffectingValueForKey

        public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(java.lang.String key)
      • layerClass

        public static org.moe.natj.objc.Class layerClass()
        default is [CALayer class]. Used when creating the underlying layer for the view.
      • new_objc

        public static java.lang.Object new_objc()
      • performSystemAnimationOnViewsOptionsAnimationsCompletion

        public static void performSystemAnimationOnViewsOptionsAnimationsCompletion​(long animation,
                                                                                    NSArray<? extends UIView> views,
                                                                                    long options,
                                                                                    UIView.Block_performSystemAnimationOnViewsOptionsAnimationsCompletion_3 parallelAnimations,
                                                                                    UIView.Block_performSystemAnimationOnViewsOptionsAnimationsCompletion_4 completion)
        Performs the requested system-provided animation on one or more views. Specify addtional animations in the parallelAnimations block. These additional animations will run alongside the system animation with the same timing and duration that the system animation defines/inherits. Additional animations should not modify properties of the view on which the system animation is being performed. Not all system animations honor all available options.
      • requiresConstraintBasedLayout

        public static boolean requiresConstraintBasedLayout()
        constraint-based layout engages lazily when someone tries to use it (e.g., adds a constraint to a view). If you do all of your constraint set up in -updateConstraints, you might never even receive updateConstraints if no one makes a constraint. To fix this chicken and egg problem, override this method to return YES if your view needs the window to use constraint-based layout.
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setAnimationBeginsFromCurrentState

        public static void setAnimationBeginsFromCurrentState​(boolean fromCurrentState)
      • setAnimationCurve

        public static void setAnimationCurve​(long curve)
      • setAnimationDelay

        public static void setAnimationDelay​(double delay)
      • setAnimationDelegate

        public static void setAnimationDelegate​(java.lang.Object delegate)
      • setAnimationDidStopSelector

        public static void setAnimationDidStopSelector​(org.moe.natj.objc.SEL selector)
      • setAnimationDuration_static

        public static void setAnimationDuration_static​(double duration)
      • setAnimationRepeatAutoreverses

        public static void setAnimationRepeatAutoreverses​(boolean repeatAutoreverses)
      • setAnimationRepeatCount_static

        public static void setAnimationRepeatCount_static​(float repeatCount)
      • setAnimationStartDate

        public static void setAnimationStartDate​(NSDate startDate)
      • setAnimationTransitionForViewCache

        public static void setAnimationTransitionForViewCache​(long transition,
                                                              UIView view,
                                                              boolean cache)
      • setAnimationWillStartSelector

        public static void setAnimationWillStartSelector​(org.moe.natj.objc.SEL selector)
      • setAnimationsEnabled

        public static void setAnimationsEnabled​(boolean enabled)
        ignore any attribute changes while set.
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • userInterfaceLayoutDirectionForSemanticContentAttribute

        public static long userInterfaceLayoutDirectionForSemanticContentAttribute​(long attribute)
        This method returns the layout direction implied by the provided semantic content attribute relative to the application-wide layout direction (as returned by UIApplication.sharedApplication.userInterfaceLayoutDirection).
      • userInterfaceLayoutDirectionForSemanticContentAttributeRelativeToLayoutDirection

        public static long userInterfaceLayoutDirectionForSemanticContentAttributeRelativeToLayoutDirection​(long semanticContentAttribute,
                                                                                                            long layoutDirection)
        This method returns the layout direction implied by the provided semantic content attribute relative to the provided layout direction. For example, when provided a layout direction of RightToLeft and a semantic content attribute of Playback, this method returns LeftToRight. Layout and drawing code can use this method to determine how to arrange elements, but might find it easier to query the container view’s effectiveUserInterfaceLayoutDirection property instead.
      • version_static

        public static long version_static()
      • actionForLayerForKey

        public CAAction actionForLayerForKey​(CALayer layer,
                                             java.lang.String event)
        Description copied from interface: CALayerDelegate
        If defined, called by the default implementation of the -actionForKey: method. Should return an object implementing the CAAction protocol. May return 'nil' if the delegate doesn't specify a behavior for the current event. Returning the null object (i.e. '[NSNull null]') explicitly forces no further search. (I.e. the +defaultActionForKey: method will not be called.)
        Specified by:
        actionForLayerForKey in interface CALayerDelegate
      • addConstraint

        public void addConstraint​(NSLayoutConstraint constraint)
        This method will be deprecated in a future release and should be avoided.  Instead, set NSLayoutConstraint's active property to YES.
      • addConstraints

        public void addConstraints​(NSArray<? extends NSLayoutConstraint> constraints)
        This method will be deprecated in a future release and should be avoided.  Instead use +[NSLayoutConstraint activateConstraints:].
      • addGestureRecognizer

        public void addGestureRecognizer​(UIGestureRecognizer gestureRecognizer)
      • addLayoutGuide

        public void addLayoutGuide​(UILayoutGuide layoutGuide)
        Adds layoutGuide to the receiver, passing the receiver in -setOwningView: to layoutGuide.
      • addMotionEffect

        public void addMotionEffect​(UIMotionEffect effect)
        Begins applying `effect` to the receiver. The effect's emitted keyPath/value pairs will be applied to the view's presentation layer. Animates the transition to the motion effect's values using the present UIView animation context.
      • addSubview

        public void addSubview​(UIView view)
      • alignmentRectForFrame

        public CGRect alignmentRectForFrame​(CGRect frame)
        These two methods should be inverses of each other. UIKit will call both as part of layout computation. They may be overridden to provide arbitrary transforms between frame and alignment rect, though the two methods must be inverses of each other. However, the default implementation uses -alignmentRectInsets, so just override that if it's applicable. It's easier to get right. A view that displayed an image with some ornament would typically override these, because the ornamental part of an image would scale up with the size of the frame. Set the NSUserDefault UIViewShowAlignmentRects to YES to see alignment rects drawn.
      • alignmentRectInsets

        public UIEdgeInsets alignmentRectInsets()
        override this if the alignment rect is obtained from the frame by insetting each edge by a fixed amount. This is only called by alignmentRectForFrame: and frameForAlignmentRect:.
      • alpha

        public double alpha()
        animatable. default is 1.0
      • _appearance

        public java.lang.Object _appearance()
        Description copied from interface: UIAppearance
        To customize the appearance of all instances of a class, send the relevant appearance modification messages to the appearance proxy for the class. For example, to modify the bar tint color for all UINavigationBar instances: [[UINavigationBar appearance] setBarTintColor:myColor]; Note for iOS7: On iOS7 the tintColor property has moved to UIView, and now has special inherited behavior described in UIView.h. This inherited behavior can conflict with the appearance proxy, and therefore tintColor is now disallowed with the appearance proxy.
        Specified by:
        _appearance in interface UIAppearance
      • _appearanceWhenContainedIn

        @Deprecated
        public java.lang.Object _appearanceWhenContainedIn​(UIAppearanceContainer ContainerClass,
                                                           java.lang.Object... varargs)
        Deprecated.
        Description copied from interface: UIAppearance
        To customize the appearances for instances of a class contained within an instance of a container class, or instances in a hierarchy, use +appearanceWhenContainedInInstancesOfClasses: for the appropriate appearance proxy. For example: [[UINavigationBar appearanceWhenContainedInInstancesOfClasses:@[[UISplitViewController class]]] setBarTintColor:myColor]; [[UINavigationBar appearanceWhenContainedInInstancesOfClasses:@[[UITabBarController class], [UISplitViewController class]]] setBarTintColor:myTabbedNavBarColor]; In any given view hierarchy the outermost appearance proxy wins. Specificity (depth of the chain) is the tie-breaker. In other words, the containment statement is treated as a partial ordering. Given a concrete ordering (actual subview hierarchy), we select the partial ordering that is the first unique match when reading the actual hierarchy from the window down.
        Specified by:
        _appearanceWhenContainedIn in interface UIAppearance
      • autoresizesSubviews

        public boolean autoresizesSubviews()
        default is YES. if set, subviews are adjusted according to their autoresizingMask if self.bounds changes
      • autoresizingMask

        public long autoresizingMask()
        simple resize. default is UIViewAutoresizingNone
      • backgroundColor

        public UIColor backgroundColor()
        default is nil. Can be useful with the appearance proxy on custom UIView subclasses.
      • bringSubviewToFront

        public void bringSubviewToFront​(UIView view)
      • canBecomeFocused

        public boolean canBecomeFocused()
        Description copied from interface: UIFocusItem
        Indicates whether or not this item is currently allowed to become focused. Returning NO restricts the item from being focusable, even if it is visible in the user interface. For example, UIControls return NO if they are disabled.
        Specified by:
        canBecomeFocused in interface UIFocusItem
      • clearsContextBeforeDrawing

        public boolean clearsContextBeforeDrawing()
        default is YES. ignored for opaque views. for non-opaque views causes the active CGContext in drawRect: to be pre-filled with transparent pixels
      • clipsToBounds

        public boolean clipsToBounds()
        When YES, content and subviews are clipped to the bounds of the view. Default is NO.
      • collisionBoundingPath

        public UIBezierPath collisionBoundingPath()
        Description copied from interface: UIDynamicItem
        The path must represent a convex polygon with counter clockwise winding and no self intersection. The point (0,0) in the path corresponds to the dynamic item's center.
        Specified by:
        collisionBoundingPath in interface UIDynamicItem
      • collisionBoundsType

        public long collisionBoundsType()
        Description copied from interface: UIDynamicItem
        The collision type represents how the dynamics system will evaluate collisions with respect to the dynamic item. defaults to UIDynamicItemCollisionBoundsTypeRectangle
        Specified by:
        collisionBoundsType in interface UIDynamicItem
      • constraintsAffectingLayoutForAxis

        public NSArray<? extends NSLayoutConstraint> constraintsAffectingLayoutForAxis​(long axis)
        This returns a list of all the constraints that are affecting the current location of the receiver. The constraints do not necessarily involve the receiver, they may affect the frame indirectly. Pass UILayoutConstraintAxisHorizontal for the constraints affecting [self center].x and CGRectGetWidth([self bounds]), and UILayoutConstraintAxisVertical for the constraints affecting[self center].y and CGRectGetHeight([self bounds]).
      • contentCompressionResistancePriorityForAxis

        public float contentCompressionResistancePriorityForAxis​(long axis)
      • contentHuggingPriorityForAxis

        public float contentHuggingPriorityForAxis​(long axis)
      • contentMode

        public long contentMode()
        default is UIViewContentModeScaleToFill
      • contentScaleFactor

        public double contentScaleFactor()
      • contentStretch

        @Deprecated
        public CGRect contentStretch()
        Deprecated.
        animatable. default is unit rectangle {{0,0} {1,1}}. Now deprecated: please use -[UIImage resizableImageWithCapInsets:] to achieve the same effect.
      • decodeRestorableStateWithCoder

        public void decodeRestorableStateWithCoder​(NSCoder coder)
      • didAddSubview

        public void didAddSubview​(UIView subview)
      • didMoveToSuperview

        public void didMoveToSuperview()
      • didMoveToWindow

        public void didMoveToWindow()
      • displayLayer

        public void displayLayer​(CALayer layer)
        Description copied from interface: CALayerDelegate
        If defined, called by the default implementation of the -display method, in which case it should implement the entire display process (typically by setting the `contents' property).
        Specified by:
        displayLayer in interface CALayerDelegate
      • drawRect

        public void drawRect​(CGRect rect)
      • drawRectForViewPrintFormatter

        public void drawRectForViewPrintFormatter​(CGRect rect,
                                                  UIViewPrintFormatter formatter)
        default calls -drawRect:
      • drawViewHierarchyInRectAfterScreenUpdates

        public boolean drawViewHierarchyInRectAfterScreenUpdates​(CGRect rect,
                                                                 boolean afterUpdates)
        Use this method to render a snapshot of the view hierarchy into the current context. Returns NO if the snapshot is missing image data, YES if the snapshot is complete. Calling this method from layoutSubviews while the current transaction is committing will capture what is currently displayed regardless if afterUpdates is YES.
      • effectiveUserInterfaceLayoutDirection

        public long effectiveUserInterfaceLayoutDirection()
        Returns the user interface layout direction appropriate for arranging the immediate content of this view. Always consult the effectiveUserInterfaceLayoutDirection of the view whose immediate content is being arranged or drawn. Do not assume that the value propagates through the view’s subtree.
      • encodeRestorableStateWithCoder

        public void encodeRestorableStateWithCoder​(NSCoder coder)
      • endEditing

        public boolean endEditing​(boolean force)
        use to make the view or any subview that is the first responder resign (optionally force)
      • exchangeSubviewAtIndexWithSubviewAtIndex

        public void exchangeSubviewAtIndexWithSubviewAtIndex​(long index1,
                                                             long index2)
      • exerciseAmbiguityInLayout

        public void exerciseAmbiguityInLayout()
      • frame

        public CGRect frame()
        Description copied from interface: UIFocusItem
        The geometric frame of this item, represented in the `coordinateSpace` of the UIFocusItemContainer in which it is contained.
        Specified by:
        frame in interface UIFocusItem
      • frameForAlignmentRect

        public CGRect frameForAlignmentRect​(CGRect alignmentRect)
      • gestureRecognizerShouldBegin

        public boolean gestureRecognizerShouldBegin​(UIGestureRecognizer gestureRecognizer)
        called when the recognizer attempts to transition out of UIGestureRecognizerStatePossible if a touch hit-tested to this view will be cancelled as a result of gesture recognition returns YES by default. return NO to cause the gesture recognizer to transition to UIGestureRecognizerStateFailed subclasses may override to prevent recognition of particular gestures. for example, UISlider prevents swipes parallel to the slider that start in the thumb
      • hasAmbiguousLayout

        public boolean hasAmbiguousLayout()
        If there aren't enough constraints in the system to uniquely determine layout, we say the layout is ambiguous. For example, if the only constraint in the system was x = y + 100, then there are lots of different possible values for x and y. This situation is not automatically detected by UIKit, due to performance considerations and details of the algorithm used for layout. The symptom of ambiguity is that views sometimes jump from place to place, or possibly are just in the wrong place. -hasAmbiguousLayout runs a check for whether there is another center and bounds the receiver could have that could also satisfy the constraints. -exerciseAmbiguousLayout does more. It randomly changes the view layout to a different valid layout. Making the UI jump back and forth can be helpful for figuring out where you're missing a constraint.
      • hitTestWithEvent

        public UIView hitTestWithEvent​(CGPoint point,
                                       UIEvent event)
        recursively calls -pointInside:withEvent:. point is in the receiver's coordinate system
      • initWithFrame

        public UIView initWithFrame​(CGRect frame)
      • insertSubviewAboveSubview

        public void insertSubviewAboveSubview​(UIView view,
                                              UIView siblingSubview)
      • insertSubviewAtIndex

        public void insertSubviewAtIndex​(UIView view,
                                         long index)
      • insertSubviewBelowSubview

        public void insertSubviewBelowSubview​(UIView view,
                                              UIView siblingSubview)
      • intrinsicContentSize

        public CGSize intrinsicContentSize()
      • invalidateIntrinsicContentSize

        public void invalidateIntrinsicContentSize()
        call this when something changes that affects the intrinsicContentSize. Otherwise UIKit won't notice that it changed.
      • isDescendantOfView

        public boolean isDescendantOfView​(UIView view)
        returns YES for self.
      • isExclusiveTouch

        public boolean isExclusiveTouch()
        default is NO
      • setExclusiveTouch

        public void setExclusiveTouch​(boolean value)
        default is NO
      • isFocused

        public boolean isFocused()
      • isHidden

        public boolean isHidden()
        default is NO. doesn't check superviews
      • setHidden

        public void setHidden​(boolean value)
        default is NO. doesn't check superviews
      • isMultipleTouchEnabled

        public boolean isMultipleTouchEnabled()
        default is NO
      • setMultipleTouchEnabled

        public void setMultipleTouchEnabled​(boolean value)
        default is NO
      • isOpaque

        public boolean isOpaque()
        default is YES. opaque views must fill their entire bounds or the results are undefined. the active CGContext in drawRect: will not have been cleared and may have non-zeroed pixels
      • setOpaque

        public void setOpaque​(boolean value)
        default is YES. opaque views must fill their entire bounds or the results are undefined. the active CGContext in drawRect: will not have been cleared and may have non-zeroed pixels
      • isUserInteractionEnabled

        public boolean isUserInteractionEnabled()
        default is YES. if set to NO, user events (touch, keys) are ignored and removed from the event queue.
      • setUserInteractionEnabled

        public void setUserInteractionEnabled​(boolean value)
        default is YES. if set to NO, user events (touch, keys) are ignored and removed from the event queue.
      • layer

        public CALayer layer()
        returns view's layer. Will always return a non-nil value. view is layer's delegate
      • layerWillDraw

        public void layerWillDraw​(CALayer layer)
        Description copied from interface: CALayerDelegate
        If defined, called by the default implementation of the -display method. Allows the delegate to configure any layer state affecting contents prior to -drawLayer:InContext: such as `contentsFormat' and `opaque'. It will not be called if the delegate implements -displayLayer.
        Specified by:
        layerWillDraw in interface CALayerDelegate
      • layoutGuides

        public NSArray<? extends UILayoutGuide> layoutGuides()
        UILayoutGuide objects owned by the receiver.
      • layoutIfNeeded

        public void layoutIfNeeded()
      • layoutMargins

        public UIEdgeInsets layoutMargins()
        -layoutMargins returns a set of insets from the edge of the view's bounds that denote a default spacing for laying out content. If preservesSuperviewLayoutMargins is YES, margins cascade down the view tree, adjusting for geometry offsets, so that setting the left value of layoutMargins on a superview will affect the left value of layoutMargins for subviews positioned close to the left edge of their superview's bounds If your view subclass uses layoutMargins in its layout or drawing, override -layoutMarginsDidChange in order to refresh your view if the margins change. On iOS 11.0 and later, please support both user interface layout directions by setting the directionalLayoutMargins property instead of the layoutMargins property. After setting the directionalLayoutMargins property, the values in the left and right fields of the layoutMargins property will depend on the user interface layout direction.
      • layoutMarginsDidChange

        public void layoutMarginsDidChange()
      • layoutMarginsGuide

        public UILayoutGuide layoutMarginsGuide()
        The edges of this guide are constrained to equal the edges of the view inset by the layoutMargins
      • layoutSublayersOfLayer

        public void layoutSublayersOfLayer​(CALayer layer)
        Description copied from interface: CALayerDelegate
        Called by the default -layoutSublayers implementation before the layout manager is checked. Note that if the delegate method is invoked, the layout manager will be ignored.
        Specified by:
        layoutSublayersOfLayer in interface CALayerDelegate
      • layoutSubviews

        public void layoutSubviews()
        override point. called by layoutIfNeeded automatically. As of iOS 6.0, when constraints-based layout is used the base implementation applies the constraints-based layout, otherwise it does nothing.
      • leadingAnchor

        public NSLayoutXAxisAnchor leadingAnchor()
        Constraint creation conveniences. See NSLayoutAnchor.h for details.
      • maskView

        public UIView maskView()
      • needsUpdateConstraints

        public boolean needsUpdateConstraints()
      • pointInsideWithEvent

        public boolean pointInsideWithEvent​(CGPoint point,
                                            UIEvent event)
        default returns YES if point is in bounds
      • preferredFocusEnvironments

        public NSArray<?> preferredFocusEnvironments()
        Description copied from interface: UIFocusEnvironment
        The preferred focus environments define where to search for the default focused item in an environment, such as when focus updates programmatically. Starting from the target environment, each preferred focus environment is recursively searched in the order of the array until an eligible, focusable item is found. Preferred focus environments can include focusable and non-focusable items, in addition to non-item environments. Returning an empty array is equivalent to returning an array containing only 'self'.
        Specified by:
        preferredFocusEnvironments in interface UIFocusEnvironment
      • preservesSuperviewLayoutMargins

        public boolean preservesSuperviewLayoutMargins()
        default is NO - set to enable pass-through or cascading behavior of margins from this view’s parent to its children
      • readableContentGuide

        public UILayoutGuide readableContentGuide()
        This content guide provides a layout area that you can use to place text and related content whose width should generally be constrained to a size that is easy for the user to read. This guide provides a centered region that you can place content within to get this behavior for this view.
      • removeConstraint

        public void removeConstraint​(NSLayoutConstraint constraint)
        This method will be deprecated in a future release and should be avoided.  Instead set NSLayoutConstraint's active property to NO.
      • removeConstraints

        public void removeConstraints​(NSArray<? extends NSLayoutConstraint> constraints)
        This method will be deprecated in a future release and should be avoided.  Instead use +[NSLayoutConstraint deactivateConstraints:].
      • removeFromSuperview

        public void removeFromSuperview()
      • removeGestureRecognizer

        public void removeGestureRecognizer​(UIGestureRecognizer gestureRecognizer)
      • removeLayoutGuide

        public void removeLayoutGuide​(UILayoutGuide layoutGuide)
        Removes layoutGuide from the receiver, passing nil in -setOwningView: to layoutGuide.
      • removeMotionEffect

        public void removeMotionEffect​(UIMotionEffect effect)
        Stops applying `effect` to the receiver. Any affected presentation values will animate to their post-removal values using the present UIView animation context.
      • resizableSnapshotViewFromRectAfterScreenUpdatesWithCapInsets

        public UIView resizableSnapshotViewFromRectAfterScreenUpdatesWithCapInsets​(CGRect rect,
                                                                                   boolean afterUpdates,
                                                                                   UIEdgeInsets capInsets)
        Resizable snapshots will default to stretching the center
      • restorationIdentifier

        public java.lang.String restorationIdentifier()
      • semanticContentAttribute

        public long semanticContentAttribute()
      • sendSubviewToBack

        public void sendSubviewToBack​(UIView view)
      • setAlpha

        public void setAlpha​(double value)
        animatable. default is 1.0
      • setAutoresizesSubviews

        public void setAutoresizesSubviews​(boolean value)
        default is YES. if set, subviews are adjusted according to their autoresizingMask if self.bounds changes
      • setAutoresizingMask

        public void setAutoresizingMask​(long value)
        simple resize. default is UIViewAutoresizingNone
      • setBackgroundColor

        public void setBackgroundColor​(UIColor value)
        default is nil. Can be useful with the appearance proxy on custom UIView subclasses.
      • setBounds

        public void setBounds​(CGRect value)
        default bounds is zero origin, frame size. animatable
      • setClearsContextBeforeDrawing

        public void setClearsContextBeforeDrawing​(boolean value)
        default is YES. ignored for opaque views. for non-opaque views causes the active CGContext in drawRect: to be pre-filled with transparent pixels
      • setClipsToBounds

        public void setClipsToBounds​(boolean value)
        When YES, content and subviews are clipped to the bounds of the view. Default is NO.
      • setContentCompressionResistancePriorityForAxis

        public void setContentCompressionResistancePriorityForAxis​(float priority,
                                                                   long axis)
      • setContentHuggingPriorityForAxis

        public void setContentHuggingPriorityForAxis​(float priority,
                                                     long axis)
      • setContentMode

        public void setContentMode​(long value)
        default is UIViewContentModeScaleToFill
      • setContentScaleFactor

        public void setContentScaleFactor​(double value)
      • setContentStretch

        @Deprecated
        public void setContentStretch​(CGRect value)
        Deprecated.
        animatable. default is unit rectangle {{0,0} {1,1}}. Now deprecated: please use -[UIImage resizableImageWithCapInsets:] to achieve the same effect.
      • setFrame

        public void setFrame​(CGRect value)
        animatable. do not use frame if view is transformed since it will not correctly reflect the actual location of the view. use bounds + center instead.
      • setLayoutMargins

        public void setLayoutMargins​(UIEdgeInsets value)
        -layoutMargins returns a set of insets from the edge of the view's bounds that denote a default spacing for laying out content. If preservesSuperviewLayoutMargins is YES, margins cascade down the view tree, adjusting for geometry offsets, so that setting the left value of layoutMargins on a superview will affect the left value of layoutMargins for subviews positioned close to the left edge of their superview's bounds If your view subclass uses layoutMargins in its layout or drawing, override -layoutMarginsDidChange in order to refresh your view if the margins change. On iOS 11.0 and later, please support both user interface layout directions by setting the directionalLayoutMargins property instead of the layoutMargins property. After setting the directionalLayoutMargins property, the values in the left and right fields of the layoutMargins property will depend on the user interface layout direction.
      • setMaskView

        public void setMaskView​(UIView value)
      • setNeedsDisplay

        public void setNeedsDisplay()
      • setNeedsDisplayInRect

        public void setNeedsDisplayInRect​(CGRect rect)
      • setNeedsFocusUpdate

        public void setNeedsFocusUpdate()
        Description copied from interface: UIFocusEnvironment
        Marks this environment as needing a focus update, which if accepted will attempt to reset focus to this environment, or one of its preferred focus environments, on the next update cycle. If this environment does not currently contain the focused item, then calling this method has no effect. If a parent of this environment is also requesting focus, then this environment's request is rejected in favor of the parent's. NOTE: If you provide your own implementation, it must call `[[UIFocusSystem focusSystemForEnvironment:self] requestFocusUpdateToEnvironment:self]`;
        Specified by:
        setNeedsFocusUpdate in interface UIFocusEnvironment
      • setNeedsLayout

        public void setNeedsLayout()
        Allows you to perform layout before the drawing cycle happens. -layoutIfNeeded forces layout early
      • setNeedsUpdateConstraints

        public void setNeedsUpdateConstraints()
      • setPreservesSuperviewLayoutMargins

        public void setPreservesSuperviewLayoutMargins​(boolean value)
        default is NO - set to enable pass-through or cascading behavior of margins from this view’s parent to its children
      • setRestorationIdentifier

        public void setRestorationIdentifier​(java.lang.String value)
      • setSemanticContentAttribute

        public void setSemanticContentAttribute​(long value)
      • setTag

        public void setTag​(long value)
        default is 0
      • setTintAdjustmentMode

        public void setTintAdjustmentMode​(long value)
        -tintAdjustmentMode always returns either UIViewTintAdjustmentModeNormal or UIViewTintAdjustmentModeDimmed. The value returned is the first non-default value in the receiver's superview chain (starting with itself). If no non-default value is found, UIViewTintAdjustmentModeNormal is returned. When tintAdjustmentMode has a value of UIViewTintAdjustmentModeDimmed for a view, the color it returns from tintColor will be modified to give a dimmed appearance. When the tintAdjustmentMode of a view changes (either the view's value changing or by one of its superview's values changing), -tintColorDidChange will be called to allow the view to refresh its rendering.
      • setTintColor

        public void setTintColor​(UIColor value)
        -tintColor always returns a color. The color returned is the first non-default value in the receiver's superview chain (starting with itself). If no non-default value is found, a system-defined color is returned. If this view's -tintAdjustmentMode returns Dimmed, then the color that is returned for -tintColor will automatically be dimmed. If your view subclass uses tintColor in its rendering, override -tintColorDidChange in order to refresh the rendering if the color changes.
      • setTranslatesAutoresizingMaskIntoConstraints

        public void setTranslatesAutoresizingMaskIntoConstraints​(boolean value)
        Default YES
      • sizeThatFits

        public CGSize sizeThatFits​(CGSize size)
        return 'best' size to fit given size. does not actually resize view. Default is return existing view size
      • sizeToFit

        public void sizeToFit()
        calls sizeThatFits: with current view bounds and changes bounds size.
      • snapshotViewAfterScreenUpdates

        public UIView snapshotViewAfterScreenUpdates​(boolean afterUpdates)
        * When requesting a snapshot, 'afterUpdates' defines whether the snapshot is representative of what's currently on screen or if you wish to include any recent changes before taking the snapshot. If called during layout from a committing transaction, snapshots occurring after the screen updates will include all changes made, regardless of when the snapshot is taken and the changes are made. For example: - (void)layoutSubviews { UIView *snapshot = [self snapshotViewAfterScreenUpdates:YES]; self.alpha = 0.0; } The snapshot will appear to be empty since the change in alpha will be captured by the snapshot. If you need to animate the view during layout, animate the snapshot instead. * Creating snapshots from existing snapshots (as a method to duplicate, crop or create a resizable variant) is supported. In cases where many snapshots are needed, creating a snapshot from a common superview and making subsequent snapshots from it can be more performant. Please keep in mind that if 'afterUpdates' is YES, the original snapshot is committed and any changes made to it, not the view originally snapshotted, will be included.
      • superview

        public UIView superview()
      • systemLayoutSizeFittingSize

        public CGSize systemLayoutSizeFittingSize​(CGSize targetSize)
        Equivalent to sending -systemLayoutSizeFittingSize:withHorizontalFittingPriority:verticalFittingPriority: with UILayoutPriorityFittingSizeLevel for both priorities.
      • systemLayoutSizeFittingSizeWithHorizontalFittingPriorityVerticalFittingPriority

        public CGSize systemLayoutSizeFittingSizeWithHorizontalFittingPriorityVerticalFittingPriority​(CGSize targetSize,
                                                                                                      float horizontalFittingPriority,
                                                                                                      float verticalFittingPriority)
      • tag

        public long tag()
        default is 0
      • tintAdjustmentMode

        public long tintAdjustmentMode()
        -tintAdjustmentMode always returns either UIViewTintAdjustmentModeNormal or UIViewTintAdjustmentModeDimmed. The value returned is the first non-default value in the receiver's superview chain (starting with itself). If no non-default value is found, UIViewTintAdjustmentModeNormal is returned. When tintAdjustmentMode has a value of UIViewTintAdjustmentModeDimmed for a view, the color it returns from tintColor will be modified to give a dimmed appearance. When the tintAdjustmentMode of a view changes (either the view's value changing or by one of its superview's values changing), -tintColorDidChange will be called to allow the view to refresh its rendering.
      • tintColor

        public UIColor tintColor()
        -tintColor always returns a color. The color returned is the first non-default value in the receiver's superview chain (starting with itself). If no non-default value is found, a system-defined color is returned. If this view's -tintAdjustmentMode returns Dimmed, then the color that is returned for -tintColor will automatically be dimmed. If your view subclass uses tintColor in its rendering, override -tintColorDidChange in order to refresh the rendering if the color changes.
      • tintColorDidChange

        public void tintColorDidChange()
        The -tintColorDidChange message is sent to appropriate subviews of a view when its tintColor is changed by client code or to subviews in the view hierarchy of a view whose tintColor is implicitly changed when its superview or tintAdjustmentMode changes.
      • translatesAutoresizingMaskIntoConstraints

        public boolean translatesAutoresizingMaskIntoConstraints()
        Default YES
      • updateConstraints

        public void updateConstraints()
        Override this to adjust your special constraints during a constraints update pass
      • updateConstraintsIfNeeded

        public void updateConstraintsIfNeeded()
        Updates the constraints from the bottom up for the view hierarchy rooted at the receiver. UIWindow's implementation creates a layout engine if necessary first.
      • updateFocusIfNeeded

        public void updateFocusIfNeeded()
        Description copied from interface: UIFocusEnvironment
        Forces focus to be updated immediately. If there is an environment that has requested a focus update via -setNeedsFocusUpdate, and the request was accepted, then focus will be updated to that environment or one of its preferred focus environments. NOTE: If you provide your own implementation, it must call `[[UIFocusSystem focusSystemForEnvironment:self] updateFocusIfNeeded];`.
        Specified by:
        updateFocusIfNeeded in interface UIFocusEnvironment
      • viewForBaselineLayout

        @Deprecated
        public UIView viewForBaselineLayout()
        Deprecated.
      • viewForFirstBaselineLayout

        public UIView viewForFirstBaselineLayout()
        -viewForFirstBaselineLayout is called by the constraints system when interpreting the firstBaseline attribute for a view. For complex custom UIView subclasses, override this method to return the text-based (i.e., UILabel or non-scrollable UITextView) descendant of the receiver whose first baseline is appropriate for alignment. UIView's implementation returns [self viewForLastBaselineLayout], so if the same descendant is appropriate for both first- and last-baseline layout you may override just -viewForLastBaselineLayout.
      • viewForLastBaselineLayout

        public UIView viewForLastBaselineLayout()
        -viewForLastBaselineLayout is called by the constraints system when interpreting the lastBaseline attribute for a view. For complex custom UIView subclasses, override this method to return the text-based (i.e., UILabel or non-scrollable UITextView) descendant of the receiver whose last baseline is appropriate for alignment. UIView's implementation returns self.
      • viewPrintFormatter

        public UIViewPrintFormatter viewPrintFormatter()
        returns a new print formatter each time
      • viewWithTag

        public UIView viewWithTag​(long tag)
        recursive search. includes self
      • willMoveToSuperview

        public void willMoveToSuperview​(UIView newSuperview)
      • willMoveToWindow

        public void willMoveToWindow​(UIWindow newWindow)
      • willRemoveSubview

        public void willRemoveSubview​(UIView subview)
      • accessibilityIgnoresInvertColors

        public boolean accessibilityIgnoresInvertColors()
      • addInteraction

        public void addInteraction​(UIInteraction interaction)
      • directionalLayoutMargins

        public NSDirectionalEdgeInsets directionalLayoutMargins()
        directionalLayoutMargins.leading is used on the left when the user interface direction is LTR and on the right for RTL. Vice versa for directionalLayoutMargins.trailing.
      • insetsLayoutMarginsFromSafeArea

        public boolean insetsLayoutMarginsFromSafeArea()
        Default: YES
      • interactions

        public NSArray<?> interactions()
      • removeInteraction

        public void removeInteraction​(UIInteraction interaction)
      • safeAreaInsetsDidChange

        public void safeAreaInsetsDidChange()
      • safeAreaLayoutGuide

        public UILayoutGuide safeAreaLayoutGuide()
        The top of the safeAreaLayoutGuide indicates the unobscured top edge of the view (e.g, not behind the status bar or navigation bar, if present). Similarly for the other edges.
      • setAccessibilityIgnoresInvertColors

        public void setAccessibilityIgnoresInvertColors​(boolean value)
      • setDirectionalLayoutMargins

        public void setDirectionalLayoutMargins​(NSDirectionalEdgeInsets value)
        directionalLayoutMargins.leading is used on the left when the user interface direction is LTR and on the right for RTL. Vice versa for directionalLayoutMargins.trailing.
      • setInsetsLayoutMarginsFromSafeArea

        public void setInsetsLayoutMarginsFromSafeArea​(boolean value)
        Default: YES
      • setInteractions

        public void setInteractions​(NSArray<?> value)
      • coordinateSpace

        public UICoordinateSpace coordinateSpace()
        Description copied from interface: UIFocusItemContainer
        The coordinate space of the focus items contained in this container. The focus items returned by focusItemsInRect: should report their frames in this coordinate space. If you are implementing this protocol, you may find it convenient to return the UIScreen as your coordinate space, and ensure that your contained items report their frames in screen space. Similarly, you might find that your focus items' containing UIView or UIWindow is the most convenient coordinate space to use. You may also choose to implement your own object that conforms to UICoordinateSpace, if that is the most natural solution for your architecture.
        Specified by:
        coordinateSpace in interface UIFocusItemContainer
      • didHintFocusMovement

        public void didHintFocusMovement​(UIFocusMovementHint hint)
        Description copied from interface: UIFocusItem
        Called whenever this focus item is hinting to the user a focus movement might occur. The provided object is mutated by the focus engine whenever the user's finger moves.
        Specified by:
        didHintFocusMovement in interface UIFocusItem
      • modifyAnimationsWithRepeatCountAutoreversesAnimations

        public static void modifyAnimationsWithRepeatCountAutoreversesAnimations​(double count,
                                                                                 boolean autoreverses,
                                                                                 UIView.Block_modifyAnimationsWithRepeatCountAutoreversesAnimations animations)
        Call this method from within an animation block to repeat animations, otherwise has no effect. The total duration of a repeating animation can be computed via (outerAnimationDuration * repeatCount * autoreverses ? 2 : 1).
      • overrideUserInterfaceStyle

        public long overrideUserInterfaceStyle()
        Set `overrideUserInterfaceStyle` to cause this view and its subviews to have a specific `UIUserInterfaceStyle`. Reading this property does not return the current `UIUserInterfaceStyle`. Use `traitCollection.userInterfaceStyle` instead. Whenever possible, use the `overrideUserInterfaceStyle` property on `UIViewController` instead. Use this property only when: - You want a particular style on a single view or small view hierarchy. - You want a particular style on an entire `UIWindow` and its view controllers and presentations, but don't want to force your entire application to have that style. (If you do want your entire application to have a certain style, don't use this, but instead set the `UIUserInterfaceStyle" key in your Info.plist.) When set on an ordinary `UIView`: - This property affects only the traits of this view and its subviews. - It does not affect any view controllers, or any subviews that are owned by different view controllers. When set on a `UIWindow`: - This property affects the `rootViewController` and thus the entire view controller and view hierarchy. - It also affects presentations that happen inside the window.
      • parentFocusEnvironment

        public UIFocusEnvironment parentFocusEnvironment()
        Description copied from interface: UIFocusEnvironment
        The parent focus environment of this environment, or nil if no parent exists. NOTE: If you implement this method, you must return a non-nil value for parent focus environment, otherwise your focus environment will not participate in focus interactions.
        Specified by:
        parentFocusEnvironment in interface UIFocusEnvironment
      • scalesLargeContentImage

        public boolean scalesLargeContentImage()
        Description copied from interface: UILargeContentViewerItem
        Returns whether the image should be scaled to a larger size appropriate for the viewer. If not, the image will be shown at its intrinsic size. For best results when scaling, use a PDF asset with its "Preserve Vector Data" checkbox checked.
        Specified by:
        scalesLargeContentImage in interface UILargeContentViewerItem
      • setLargeContentImage

        public void setLargeContentImage​(UIImage value)
        Defaults to nil, or an appropriate default value for UIKit classes.
      • setLargeContentImageInsets

        public void setLargeContentImageInsets​(UIEdgeInsets value)
        Defaults to UIEdgeInsetsZero.
      • setLargeContentTitle

        public void setLargeContentTitle​(java.lang.String value)
        Defaults to nil, or an appropriate default value for UIKit classes.
      • setOverrideUserInterfaceStyle

        public void setOverrideUserInterfaceStyle​(long value)
        Set `overrideUserInterfaceStyle` to cause this view and its subviews to have a specific `UIUserInterfaceStyle`. Reading this property does not return the current `UIUserInterfaceStyle`. Use `traitCollection.userInterfaceStyle` instead. Whenever possible, use the `overrideUserInterfaceStyle` property on `UIViewController` instead. Use this property only when: - You want a particular style on a single view or small view hierarchy. - You want a particular style on an entire `UIWindow` and its view controllers and presentations, but don't want to force your entire application to have that style. (If you do want your entire application to have a certain style, don't use this, but instead set the `UIUserInterfaceStyle" key in your Info.plist.) When set on an ordinary `UIView`: - This property affects only the traits of this view and its subviews. - It does not affect any view controllers, or any subviews that are owned by different view controllers. When set on a `UIWindow`: - This property affects the `rootViewController` and thus the entire view controller and view hierarchy. - It also affects presentations that happen inside the window.
      • setScalesLargeContentImage

        public void setScalesLargeContentImage​(boolean value)
        Defaults to NO, or an appropriate default value for UIKit classes.
      • setShowsLargeContentViewer

        public void setShowsLargeContentViewer​(boolean value)
        Defaults to NO.
      • setTransform3D

        public void setTransform3D​(CATransform3D value)
        default is CATransform3DIdentity. animatable. Please use this property instead of the transform property on the layer
      • showsLargeContentViewer

        public boolean showsLargeContentViewer()
        Description copied from interface: UILargeContentViewerItem
        Returns whether the item shows the large content viewer. In general, only views that cannot scale for the full range of Dynamic Type sizes should return YES. For this property to take effect, the item or an ancestor view must have a UILargeContentViewerInteraction.
        Specified by:
        showsLargeContentViewer in interface UILargeContentViewerItem
      • transform3D

        public CATransform3D transform3D()
        default is CATransform3DIdentity. animatable. Please use this property instead of the transform property on the layer
      • focusGroupIdentifier

        public java.lang.String focusGroupIdentifier()
        Description copied from interface: UIFocusEnvironment
        The identifier of the focus group that this view belongs to. If this is nil, subviews inherit their superview's focus group.
        Specified by:
        focusGroupIdentifier in interface UIFocusEnvironment
      • setFocusGroupIdentifier

        public void setFocusGroupIdentifier​(java.lang.String value)
        The identifier of the focus group that this view belongs to. If this is nil, subviews inherit their superview's focus group.