Question on Unicode characters display in PS native console.

Welcome Forums General PowerShell Q&A Question on Unicode characters display in PS native console.

Viewing 3 reply threads
  • Author
    Posts
    • #278718
      Participant
      Topics: 3
      Replies: 7
      Points: 55
      Rank: Member

      A little discussion on Unicode characters display in PS native console (not the one inside ISE)

      I’ve seen in another thread posted in 2015 that “(Microsoft) made some improvement to the W32Console in Windows 10″.  But we are end of 2020 and obviously, such support is still missing.

      For those who are interested:
      <p style=”padding-left: 40px;”>Create a ps1 file containing write-host “ção `n一二三”
      and save the file using UTF-16 BE with BOM

      Run the ps1 file to see the result which depends on your Windows’ regional settings</p>
      How is the Unicode support of PowerShell in Linux?

      Unicode characters display support is good inside ISE’s console.  Is it possible to use just the ISE’s console without the whole ISE?

      Thanks

       

       

    • #278778
      Participant
      Topics: 17
      Replies: 1951
      Points: 3,987
      Helping Hand
      Rank: Community Hero

      Take a look at Visual Studio Code. The ISE is as far as it’s going to go and it is an emulator and it is up to Powershell 5.1. Using VSCode and testing in Linux, you can test in Powershell 7+ to see if you see the same behavior. I use ISE when I need to do quick edits in on a server, but do 95% development in VSCode. With all of that said, I do not deal with UniCode characters, but test in VSCode + PS 7 to see if it works as expected.

      • #279060
        Participant
        Topics: 3
        Replies: 7
        Points: 55
        Rank: Member

        @Rob, yes, I also use VSCode from time to time.  But regarding the console inside VSCode, that’s the same situation as that inside ISE.  I just want the console to execute script.  I found no way to have only the console without VSCode.

    • #278817
      Participant
      Topics: 4
      Replies: 425
      Points: 748
      Helping Hand
      Rank: Major Contributor

      Windows Terminal is what you’re after.  Unicode support and much, much more besides:

      Introducing Windows Terminal

      https://aka.ms/terminal

      • #279066
        Participant
        Topics: 3
        Replies: 7
        Points: 55
        Rank: Member

        @Matt

        Wow!  Fantastic!  Exactly what I was looking for!  It opens so fast. And indeed it supports Unicode flawlessly. 👍👍

        I mainly run scripts inside Windows Server.  So I’m still looking at how to get it installed in Windows Server 2016 🤔  Seems like I have to do something with MSIX

    • #279456
      js
      Participant
      Topics: 32
      Replies: 852
      Points: 2,780
      Helping Hand
      Rank: Community Hero

      This guy on Stackoverflow provides plenty of information in this area: https://stackoverflow.com/a/49481797/6654942

      • #279765
        Participant
        Topics: 3
        Replies: 7
        Points: 55
        Rank: Member

        Thank you for your suggestion on Stackoverflow.

        But I still stick to Windows Terminal.  I don’t need to tinker around to have Unicode work natively.  And that guy’s article dated back to 2018.

        • This reply was modified 1 month ago by 庭豐 石.
Viewing 3 reply threads
  • You must be logged in to reply to this topic.