This repository was archived by the owner on Oct 15, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
java/app/passwordstore/ui/adapters
ui/compose/src/main/res/font Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 55
66package app.passwordstore.ui.adapters
77
8- import android.graphics.Typeface
98import android.text.method.PasswordTransformationMethod
109import android.view.LayoutInflater
1110import android.view.View
1211import android.view.ViewGroup
1312import androidx.core.content.ContextCompat
13+ import androidx.core.content.res.ResourcesCompat
1414import androidx.recyclerview.widget.RecyclerView
1515import app.passwordstore.R
1616import app.passwordstore.data.passfile.Totp
1717import app.passwordstore.data.password.FieldItem
1818import app.passwordstore.databinding.ItemFieldBinding
19+ import app.passwordstore.ui.compose.R as composeR
1920import com.google.android.material.textfield.TextInputLayout
2021
2122class FieldItemAdapter (
@@ -84,7 +85,11 @@ class FieldItemAdapter(
8485 null
8586 }
8687 if (fieldItem.key == FieldItem .ItemType .PASSWORD .type) {
87- typeface = Typeface .create(" monospace" , Typeface .NORMAL )
88+ typeface =
89+ ResourcesCompat .getFont(
90+ binding.root.context,
91+ composeR.font.jetbrainsmono_nl_regular,
92+ )
8893 }
8994 setOnClickListener { copyTextToClipboard(itemText.text.toString()) }
9095 }
Original file line number Diff line number Diff line change 158158 android : layout_marginStart =" @dimen/activity_horizontal_margin"
159159 android : layout_marginTop =" 16dp"
160160 android : layout_marginEnd =" @dimen/activity_horizontal_margin"
161- android : fontFamily =" monospace "
161+ android : fontFamily =" @font/jetbrainsmono_nl_regular "
162162 android : gravity =" center_horizontal"
163163 android : textIsSelectable =" true"
164164 android : textSize =" 10sp"
You can’t perform that action at this time.
0 commit comments