Neeraj Sewani
Neeraj Sewani

Reputation: 4297

Action bar not visible in Android Studio

I used a custom toolbar in one of my activities by setting the theme of that activity to No Action Bar in the Android Manifest file.

<activity android:name=".ChatLogActivity"
              android:theme="@style/Theme.AppCompat.Light.NoActionBar"
              android:windowSoftInputMode="adjustResize"
    >

But now rest all the activities are showing no action bar in the Android Studio at the time of designing which is making the whole designing process cumbersome. However, the action bar is showing up in the phone in all those activities. I tried doing "Invalidate cache and restart" but the problem still persists. I can't understand why is it happening.

Screenshots
enter image description here

enter image description here

EDIT 1: Theme is already set to Dark action bar in the design tab
enter image description here

P.S: I know the UI is an eyesore

Upvotes: 1

Views: 3459

Answers (2)

Malith Kuruwita
Malith Kuruwita

Reputation: 652

This has changed with the latest versions of Android Studio IDE

Android Studio V4.1.1

enter image description here

enter image description here

enter image description here

Upvotes: 3

Miguel P.
Miguel P.

Reputation: 1007

Is this only in the preview? If so, just turn on 'Show Layout Decorations' in the preview tab of your layout file.

Android Studio v3.4.1 enter image description here

Upvotes: 8

Related Questions