<style name="AppTheme" parent="Theme.AppCompat">
No you can't, because the accent color is defined in the theme and themes are read-only in Android.
The only thing you can do is switch themes or set the color of each component manually.
Note: you can apply a theme to a portion of UI instead of the whole Activity in order to change the accent color (or other things) locally. To do so, you can use the
android:theme attribute in your XML layout with the AppCompat library, or you can inflate a layout by providing a
ContextThemeWrapper as context to your