mirror of
https://github.com/curioustorvald/Terrarum-sans-bitmap.git
synced 2026-06-08 23:14:05 +09:00
removing old hacks
This commit is contained in:
@@ -132,15 +132,14 @@ open class GameFontBase : Font {
|
|||||||
val chr = s[i]
|
val chr = s[i]
|
||||||
val ctype = getSheetType(s[i])
|
val ctype = getSheetType(s[i])
|
||||||
|
|
||||||
if (chr.toInt() == 0x21B) // Romanian t; HAX!
|
if (variableWidthSheets.contains(ctype)) {
|
||||||
len += 6
|
len += try {
|
||||||
else if (variableWidthSheets.contains(ctype)) {
|
asciiWidths[chr.toInt()]!!
|
||||||
try {
|
|
||||||
len += asciiWidths[chr.toInt()]!!
|
|
||||||
}
|
}
|
||||||
catch (e: kotlin.KotlinNullPointerException) {
|
catch (e: kotlin.KotlinNullPointerException) {
|
||||||
println("KotlinNullPointerException on glyph number ${Integer.toHexString(chr.toInt()).toUpperCase()}")
|
println("KotlinNullPointerException on glyph number ${Integer.toHexString(chr.toInt()).toUpperCase()}")
|
||||||
System.exit(1)
|
//System.exit(1)
|
||||||
|
W_LATIN_WIDE // failsafe
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (zeroWidthSheets.contains(ctype))
|
else if (zeroWidthSheets.contains(ctype))
|
||||||
|
|||||||
@@ -132,15 +132,14 @@ open class GameFontBase : Font {
|
|||||||
val chr = s[i]
|
val chr = s[i]
|
||||||
val ctype = getSheetType(s[i])
|
val ctype = getSheetType(s[i])
|
||||||
|
|
||||||
if (chr.toInt() == 0x21B) // Romanian t; HAX!
|
if (variableWidthSheets.contains(ctype)) {
|
||||||
len += 6
|
len += try {
|
||||||
else if (variableWidthSheets.contains(ctype)) {
|
asciiWidths[chr.toInt()]!!
|
||||||
try {
|
|
||||||
len += asciiWidths[chr.toInt()]!!
|
|
||||||
}
|
}
|
||||||
catch (e: kotlin.KotlinNullPointerException) {
|
catch (e: kotlin.KotlinNullPointerException) {
|
||||||
println("KotlinNullPointerException on glyph number ${Integer.toHexString(chr.toInt()).toUpperCase()}")
|
println("KotlinNullPointerException on glyph number ${Integer.toHexString(chr.toInt()).toUpperCase()}")
|
||||||
System.exit(1)
|
//System.exit(1)
|
||||||
|
W_LATIN_WIDE // failsafe
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (zeroWidthSheets.contains(ctype))
|
else if (zeroWidthSheets.contains(ctype))
|
||||||
|
|||||||
Reference in New Issue
Block a user