diff --git a/app/src/main/java/gm/tieba/tabswitch/hooker/TSPreferenceHelper.java b/app/src/main/java/gm/tieba/tabswitch/hooker/TSPreferenceHelper.java index 1c971016..29c04192 100644 --- a/app/src/main/java/gm/tieba/tabswitch/hooker/TSPreferenceHelper.java +++ b/app/src/main/java/gm/tieba/tabswitch/hooker/TSPreferenceHelper.java @@ -221,6 +221,8 @@ private void showRegexDialog(final Activity activity, final String title) { editText.setHintTextColor(Color.GRAY); } editText.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_FLAG_MULTI_LINE); + editText.setFallbackLineSpacing(false); + editText.setLineSpacing(0, 1.2F); final LinearLayout linearLayout = new LinearLayout(currentActivity); linearLayout.setGravity(Gravity.CENTER_HORIZONTAL); diff --git a/app/src/main/java/gm/tieba/tabswitch/hooker/add/HistoryCache.java b/app/src/main/java/gm/tieba/tabswitch/hooker/add/HistoryCache.java index e8e2d946..c316a4a1 100644 --- a/app/src/main/java/gm/tieba/tabswitch/hooker/add/HistoryCache.java +++ b/app/src/main/java/gm/tieba/tabswitch/hooker/add/HistoryCache.java @@ -2,7 +2,6 @@ import android.app.Activity; import android.app.AlertDialog; -import android.content.DialogInterface; import android.graphics.Color; import android.os.Bundle; import android.text.Editable; @@ -95,6 +94,8 @@ private void showRegexDialog(final Activity activity) { editText.setHintTextColor(Color.GRAY); } editText.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_FLAG_MULTI_LINE); + editText.setFallbackLineSpacing(false); + editText.setLineSpacing(0, 1.2F); editText.addTextChangedListener(new TextWatcher() { @Override