diff src/name/blackcap/exifwasher/Files.kt @ 3:19c381c536ec

Code to make it a proper Mac GUI app. Untested!
author David Barts <n5jrn@me.com>
date Wed, 08 Apr 2020 20:29:12 -0700
parents db63d01a23c6
children dc1f4359659d
line wrap: on
line diff
--- a/src/name/blackcap/exifwasher/Files.kt	Wed Apr 01 14:23:54 2020 -0700
+++ b/src/name/blackcap/exifwasher/Files.kt	Wed Apr 08 20:29:12 2020 -0700
@@ -62,6 +62,8 @@
 
 /* make some usable objects */
 
+val CHARSET = "UTF-8"
+
 val DPROPERTIES = Properties().apply {
     OS::class.java.getResourceAsStream("default.properties").use { load(it) }
 }
@@ -69,11 +71,13 @@
 val PROPERTIES = Properties(DPROPERTIES).apply {
     PF_DIR.makeIfNeeded()
     PROP_FILE.createNewFile()
-    BufferedReader(InputStreamReader(FileInputStream(PROP_FILE), "UTF-8")).use  {
+    BufferedReader(InputStreamReader(FileInputStream(PROP_FILE), CHARSET)).use  {
         load(it)
     }
 }
 
+System.setProperty("java.util.logging.SimpleFormatter.format",
+    "%1$tFT%1$tT%1$tz %2$s%n%4$s: %5$s%6$s%n")
 val LOGGER = run {
     LF_DIR.makeIfNeeded()
     Logger.getLogger(LONGNAME).apply {