14
11

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Androidでプロジェクト生成時に自動でimportされるsupport-v7-appcompatを解除する

Posted at

Androidでプロジェクト生成時に自動でimportされてしまう、support-v7-appcompatを解除します。

普通に設定からimportを外すだけだとエラーが発生してしまうので、stylesを変更します。

◆values/styles.xml
style name="AppBaseTheme" parent="Theme.AppCompat.Light"
  ↓
style name="AppBaseTheme" parent="android:Theme.Light"

◆values-v11/styles.xml
style name="AppBaseTheme" parent="Theme.AppCompat.Light"
  ↓変更
style name="AppBaseTheme" parent="android:Theme.Holo.Light"

◆values-v14/styles.xml
style name="AppBaseTheme"parent="Theme.AppCompat.Light.DarkActionBar"
  ↓変更
style name="AppBaseTheme"parent="android:Theme.Holo.Light.DarkActionBar"

14
11
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
14
11

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?