Added noto sans to be the default mono font
This commit is contained in:
parent
69089c9910
commit
1597733d43
@ -22,6 +22,17 @@ val openSansFontFamily = FontFamily(
|
||||
Font("fonts/OpenSans/OpenSans-BoldItalic.ttf", FontWeight.Bold, FontStyle.Italic),
|
||||
)
|
||||
|
||||
val notoSansMonoFontFamily = FontFamily(
|
||||
Font("fonts/NotoSansMono/NotoSansMono-Regular.ttf", FontWeight.Normal, FontStyle.Normal),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-Italic.ttf", FontWeight.Normal, FontStyle.Italic),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-Medium.ttf", FontWeight.Medium, FontStyle.Normal),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-MediumItalic.ttf", FontWeight.Medium, FontStyle.Italic),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-SemiBold.ttf", FontWeight.SemiBold, FontStyle.Normal),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-SemiBoldItalic.ttf", FontWeight.SemiBold, FontStyle.Italic),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-Bold.ttf", FontWeight.Bold, FontStyle.Normal),
|
||||
Font("fonts/NotoSansMono/NotoSansMono-BoldItalic.ttf", FontWeight.Bold, FontStyle.Italic),
|
||||
)
|
||||
|
||||
const val LETTER_SPACING = 0.5
|
||||
|
||||
@Composable
|
||||
|
@ -27,6 +27,7 @@ import androidx.compose.ui.unit.dp
|
||||
import com.jetpackduba.gitnuro.extensions.*
|
||||
import com.jetpackduba.gitnuro.keybindings.KeybindingOption
|
||||
import com.jetpackduba.gitnuro.keybindings.matchesBinding
|
||||
import com.jetpackduba.gitnuro.theme.notoSansMonoFontFamily
|
||||
import com.jetpackduba.gitnuro.theme.tertiarySurface
|
||||
import com.jetpackduba.gitnuro.theme.secondarySurface
|
||||
import com.jetpackduba.gitnuro.ui.components.PrimaryButton
|
||||
@ -115,7 +116,7 @@ fun Blame(
|
||||
text = line + blameResult.resultContents.lineDelimiter,
|
||||
color = MaterialTheme.colors.onBackground,
|
||||
modifier = Modifier.padding(vertical = 8.dp, horizontal = 16.dp),
|
||||
fontFamily = FontFamily.Monospace,
|
||||
fontFamily = notoSansMonoFontFamily,
|
||||
maxLines = 1,
|
||||
)
|
||||
}
|
||||
@ -137,7 +138,7 @@ private fun LineNumber(line: Int, highestLineLength: Int) {
|
||||
Text(
|
||||
text = line.toStringWithSpaces(highestLineLength),
|
||||
color = MaterialTheme.colors.onBackground,
|
||||
fontFamily = FontFamily.Monospace,
|
||||
fontFamily = notoSansMonoFontFamily,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@ -940,7 +940,7 @@ fun DiffLineText(line: Line, diffEntryType: DiffEntryType, onActionTriggered: ()
|
||||
modifier = Modifier
|
||||
.padding(start = 16.dp)
|
||||
.fillMaxSize(),
|
||||
fontFamily = FontFamily.Monospace,
|
||||
fontFamily = notoSansMonoFontFamily,
|
||||
style = MaterialTheme.typography.body2,
|
||||
color = MaterialTheme.colors.onBackground,
|
||||
overflow = TextOverflow.Visible,
|
||||
@ -968,7 +968,7 @@ fun LineNumber(text: String, remarked: Boolean) {
|
||||
text = text,
|
||||
modifier = Modifier
|
||||
.padding(start = 8.dp, end = 4.dp),
|
||||
fontFamily = FontFamily.Monospace,
|
||||
fontFamily = notoSansMonoFontFamily,
|
||||
style = MaterialTheme.typography.body2,
|
||||
color = if (remarked) MaterialTheme.colors.onBackground else MaterialTheme.colors.onBackgroundSecondary,
|
||||
)
|
||||
|
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Black.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Black.ttf
Normal file
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Bold.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Bold.ttf
Normal file
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-ExtraBold.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-ExtraBold.ttf
Normal file
Binary file not shown.
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Light.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Light.ttf
Normal file
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Medium.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Medium.ttf
Normal file
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Regular.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Regular.ttf
Normal file
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-SemiBold.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-SemiBold.ttf
Normal file
Binary file not shown.
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Thin.ttf
Normal file
BIN
src/main/resources/fonts/NotoSansMono/NotoSansMono-Thin.ttf
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user