Layout inspector | Saviour for those who recently moved into new companies

Photo by Danial RiCaRoS on Unsplash

Whenever we switch companies or project we face a common issue which is activity and fragment related to a feature.

If your project architecture is good you can understand easily and work on functionality but suppose if you don’t have much time for reading the complete flow, you need to do a small change like hiding or showing a view, or making dimen changes or maybe 🤓 drawable changes.

So here comes ann easy and short solution.


Android studio has provided a tool to debug your layout at the dynamic time when it is running on the device instead of opening an XML file.

Open the layout inspector :

Step 1: Click on tools and select layout inspector

Step 2: You will see a window like this select your application

Step 3 : Then you will see a view like this.

Here you can see the ids and file name where all those components are available.

On the left, we have a layout tree that shows the hierarchy of view. In the middle is a screenshot of the current visible window. and in the right, there are properties of the selected view.

It helps you in debugging of the layout.

Thanks for the read. If you like it please don’t forget to clap and share it.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store