1 /*
2  * Copyright (C) 2011 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License
15  */
16 
17 /**
18  * This is a part of the inputmethod-common static Java library.
19  * The original source code can be found at frameworks/opt/inputmethodcommon of Android Open Source
20  * Project.
21  */
22 
23 package com.android.inputmethodcommon;
24 
25 import android.graphics.drawable.Drawable;
26 
27 /**
28  * InputMethodSettingsInterface is the interface for adding IME related preferences to
29  * PreferenceActivity or PreferenceFragment.
30  */
31 public interface InputMethodSettingsInterface {
32     /**
33      * Sets the title for the input method settings category with a resource ID.
34      * @param resId The resource ID of the title.
35      */
setInputMethodSettingsCategoryTitle(int resId)36     public void setInputMethodSettingsCategoryTitle(int resId);
37 
38     /**
39      * Sets the title for the input method settings category with a CharSequence.
40      * @param title The title for this preference.
41      */
setInputMethodSettingsCategoryTitle(CharSequence title)42     public void setInputMethodSettingsCategoryTitle(CharSequence title);
43 
44     /**
45      * Sets the title for the input method enabler preference for launching subtype enabler with a
46      * resource ID.
47      * @param resId The resource ID of the title.
48      */
setSubtypeEnablerTitle(int resId)49     public void setSubtypeEnablerTitle(int resId);
50 
51     /**
52      * Sets the title for the input method enabler preference for launching subtype enabler with a
53      * CharSequence.
54      * @param title The title for this preference.
55      */
setSubtypeEnablerTitle(CharSequence title)56     public void setSubtypeEnablerTitle(CharSequence title);
57 
58     /**
59      * Sets the icon for the preference for launching subtype enabler with a resource ID.
60      * @param resId The resource id of an optional icon for the preference.
61      */
setSubtypeEnablerIcon(int resId)62     public void setSubtypeEnablerIcon(int resId);
63 
64     /**
65      * Sets the icon for the Preference for launching subtype enabler with a Drawable.
66      * @param drawable The drawable of an optional icon for the preference.
67      */
setSubtypeEnablerIcon(Drawable drawable)68     public void setSubtypeEnablerIcon(Drawable drawable);
69 }
70