How can I know the visible size of my activity?
I'm trying to get the Activity real size,
not the height and width from getHeight()
and getWidth()
,
which gives me the screen full size.
I've found a way to know the exact height of my activity: if you have a view filling all the available screen behind the title bar and the task bar, just use View. getBottom() to get the real height of that activity.
Light visible from the star Deneb covers a minuscule fraction of your visual field (its 'angular diameter' is 0.0024 arcseconds). A light-emitting object seen as the same size when 15cm from your face, would be 1.75 nanometres wide. That's only about 10 times the width of an atom of gold!
I think you'll want to look at Activity.getWindow()
and Window.getDecorView()
, and get the width/height of that.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With