How can I always show Android Studios Preview?-ThrowExceptions

Exception or error:

I have probably hit some setting in Android Studio. So my problem is, my Preview window hides every time I click somewhere in the xml code.

Obviously I want the preview available the entire time I’m in the xml editor so that I can view my changes, and also without having to click the Preview button all the time.

Any ideas?

How to solve:

Found the answer. The tabs in Android Studio seem to have different amount of actions attached to them, but you can access some more if you go to Window -> Active Tool Window (with the preview tab selected/focused) and then click “Docked Mode”, an option previously unavailable in the tabs options. When Docked mode is activated for the tab it is now available in the tab options!

###

I need preview layouts when writing code.

  • click [android studio] > [preferences] > [layout editor]
  • uncheck [Hide preview window when editing non-layout files.]

It works for me.

###

Click on View -> Tools Window – > Preview, on the left of preview have small setting icon, click on it and select Pinned Mode.

It works for me.

###

A shortcut is also available for seeing preview in android studio

press ctrl + tab and a switcher window will open

you can select preview from there using arrows key

Leave a Reply

Your email address will not be published. Required fields are marked *