I have a preference, which is by default not enabled as follows.
<androidx.preference.Preference
android:enabled="false"
android:key="Country"/>
After that, preference title is not greyed out. But according to https://developer.android.com/guide/topics/ui/settings/components-and-attributes
A boolean value that indicates whether users can interact with the Preference. When this value is false, the Preference appears grayed out, and users cannot interact with it. The default value is true
I have found a manual solution here
Is there any other way? I think, android:enabled will also greyed out title. Am I misunderstood?