WindowMetrics
public
final
class
WindowMetrics
extends Object
java.lang.Object
|
↳ |
androidx.window.WindowMetrics
|
Metrics about a Window
, consisting of its bounds.
This is usually obtained from WindowManager.getCurrentWindowMetrics()
or
WindowManager.getMaximumWindowMetrics()
.
Summary
Inherited methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
Public constructors
WindowMetrics
public WindowMetrics (Rect bounds)
Constructs a new WindowMetrics
instance.
Parameters |
bounds |
Rect : rect describing the bounds of the window, see getBounds() .
|
Public methods
equals
public boolean equals (Object o)
getBounds
public Rect getBounds ()
Returns a new Rect
describing the bounds of the area the window occupies.
Note that the size of the reported bounds can have different size than
Display.getSize(Point)
. This method reports the window size including all system
decorations, while Display.getSize(Point)
reports the area excluding navigation bars
and display cutout areas.
Returns |
Rect |
window bounds in pixels.
|
hashCode
public int hashCode ()