TerminalView.st
changeset 6225 78205369e872
parent 6211 c922d4b60f5c
child 6233 347f4ba07ade
--- a/TerminalView.st	Mon Feb 03 19:21:30 2020 +0100
+++ b/TerminalView.st	Tue Feb 04 12:33:59 2020 +0100
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "
  COPYRIGHT (c) 1998 by eXept Software AG
               All Rights Reserved
@@ -1679,7 +1677,7 @@
 !
 
 initialize
-    |osIsWindows cp|
+    |osIsWindows|
 
     super initialize.
 
@@ -1705,16 +1703,7 @@
     outputIsUTF8 ifTrue:[
         outputEncoding := CharacterEncoder encoderForUTF8
     ] ifFalse:[
-        osIsWindows ifTrue:[
-            cp := OperatingSystem getConsoleOutputCP.
-            "/ should handle more codePages via GetConsoleOutputCP
-            outputEncoding := CharacterEncoder encoderNamed:('cp%1' bindWith:cp).
-            outputEncoding isNullEncoder ifTrue:[
-                "/ no encoder for code page
-                Logger warning:'no encoder for CP%1' with:cp.
-                outputEncoding := nil.
-            ].
-        ]
+        outputEncoding := OperatingSystem characterEncoderForConsoleOutput.
     ].
     translateNLToCRNL := osIsWindows.
     autoWrapFlag := true.