Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android Studio 1.5.1 rendering problems

I'm new to android studio and I have a new version installed (version 1.5.1). For some reason I keep getting an error message (every time I use an app theme) saying that there were rendering problems: styles missing. I looked online for solutions, but most of them are outdated or just do not work.

An image of the error

Thanks for any help.

Manifest file:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.easycodingplus.myapplication">

    <application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">
        <activity
            android:name=".MainActivity"
            android:label="@string/app_name"
            android:theme="@style/AppTheme.NoActionBar">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
    </application>

</manifest>

Build gradle:

apply plugin: 'com.android.application'

android {
    compileSdkVersion 23
    buildToolsVersion "23.0.2"

    defaultConfig {
        applicationId "com.easycodingplus.myapplication"
        minSdkVersion 8
        targetSdkVersion 23
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:appcompat-v7:23.1.1'
    compile 'com.android.support:design:23.1.1'
}
like image 871
Yaron Avatar asked Jan 13 '16 17:01

Yaron


People also ask

What does render problem mean in Android Studio?

rendering problem caused your designer preview used higher API level than your current android API level. Adjust with your current API Level. If the API level isn't in the list, you'll need to install it via the SDK Manager.

What is rendering problem?

Explains things that can go wrong while rendering. We call it “rendering” when a digital object is shown on a screen. Rendering has to do with giving access to a digital file, which after all is the core principle of digital preservation.

What is rendering in Android Studio?

UI Rendering is the act of generating a frame from your app and displaying it on the screen. To ensure that a user's interaction with your app is smooth, your app should render frames in under 16ms to achieve 60 frames per second (why 60fps?).

What to do if Android studio is not opening?

Open Start menu > Computer > System Properties > Advanced System Properties In the Advanced tab > Environment Variables. Add new system variable JAVA_HOME that points to JDK folder, C:\Program Files\Java\jdk1. 7.0_13\


1 Answers

just change your style.xml file like this

<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
    <!-- Customize your theme here. -->
    <item name="colorPrimary">@color/colorPrimary</item>
    <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
    <item name="colorAccent">@color/colorAccent</item>
</style>

and then, go to

File > Project Structure > app >

and set (both should be same with latest version )

source compatibility : 1.7

Target compatibility : 1.7

like image 180
Ajay P. Prajapati Avatar answered Oct 26 '22 02:10

Ajay P. Prajapati