add config file setting to disable Fyne DPI detection
This commit is contained in:
@@ -52,6 +52,7 @@ type AppConfig struct {
|
|||||||
SkipSSLVerify bool
|
SkipSSLVerify bool
|
||||||
EnqueueBatchSize int
|
EnqueueBatchSize int
|
||||||
Language string
|
Language string
|
||||||
|
DisableDPIDetection bool
|
||||||
|
|
||||||
// Experimental - may be removed in future
|
// Experimental - may be removed in future
|
||||||
FontNormalTTF string
|
FontNormalTTF string
|
||||||
|
|||||||
@@ -47,6 +47,10 @@ func main() {
|
|||||||
os.Setenv("FYNE_SCALE", "1.1")
|
os.Setenv("FYNE_SCALE", "1.1")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if myApp.Config.Application.DisableDPIDetection {
|
||||||
|
os.Setenv("FYNE_DISABLE_DPI_DETECTION", "true")
|
||||||
|
}
|
||||||
|
|
||||||
// load configured app language, or all otherwise
|
// load configured app language, or all otherwise
|
||||||
lIdx := slices.IndexFunc(res.TranslationsInfo, func(t res.TranslationInfo) bool {
|
lIdx := slices.IndexFunc(res.TranslationsInfo, func(t res.TranslationInfo) bool {
|
||||||
return t.Name == myApp.Config.Application.Language
|
return t.Name == myApp.Config.Application.Language
|
||||||
|
|||||||
Reference in New Issue
Block a user