Instance Method インスタンスメソッド

accessibilityHitTest(_:)

Returns the deepest descendant of the accessibility hierarchy that contains the specified point.

Declaration 宣言

func accessibilityHitTest(_ point: NSPoint) -> Any?

Parameters パラメータ

point

The point being hit-tested, in lower-left relative screen coordinates.

Return Value 戻り値

The deepest accessibility element in the accessibility hierarchy that contains the specified point.

Discussion 解説

You can assume that the specified point has already been determined to lie within the accessibility element's frame. Override this method to do deeper hit-testing by identifying which child element, if any, contains the point. NSMatrix, for example, identifies which of its cells contains the point and propagates the hit-test to it.

If the specified point is not contained within one of the accessibility element's children, either return self or, if available, invoke the superclass's implementation. The default NSView and NSCell implementations test whether the accessibility element is an ignored element and, if it is, return the receiver's first unignored parent; otherwise they return self.

See Also 参照

Available Methods and Properties