[精讚] [會員登入]
816

在intellij IDEA解決檔案內容顯示為UTF-8字碼而不是中文的問題

how to show correct language content of file, instead of utf-8 encoded charactors

分享此文連結 //n.sfs.tw/15993

分享連結 在intellij IDEA解決檔案內容顯示為UTF-8字碼而不是中文的問題@外行中的外行
(文章歡迎轉載,務必尊重版權註明連結來源)
2023-10-02 16:06:29 最後編修
2022-12-02 22:18:07 By jung
 

IDEA 雖然好用,但有個無法顯示中文的問題,就算你的設定都改為UTF-8編碼,中文就是出不來

有二個地方要改

1.  在mac上的社群版,要到

Help > Edit Custom VM Options

就會開編輯器給你了,不用傻傻的到目錄下去找那個 intellij IDEA.app.vmoptions 檔案

然後加上-Dfile.encoding=UTF-8

2. 到 preferences(社群版是Settings) -> Editor -> File Encodings把所有編碼都設為UTF-8

 

3. 最重要的設定

這個 Transparent native-to-ascii conversion  功能一定要勾選

 

參考這二篇

https://blog.csdn.net/HaHa_Sir/article/details/122851700

https://stoneapp.tech/cavern/post.php?pid=792

 

END

你可能感興趣的文章

using google Appscript to send messages through LINE NOTIFY 使用google app script傳送LINE NOTIFY

如何用git log功能產生有固定格式的commit紀錄 how to create a git commit history log file with custom format

unknown issue after downgrade to intellij idea community version 使用社群版遇到的奇怪問題

testing gitlab and jenkins CI/CD on docker-1 在docker架設gitlab, jenkins 測試CI/CD pipeline第一章

how to make wicket web application runs under docker enviorment with correct encoding 在docker環境下,wicket web application 編碼錯誤的問題

openssl package update issue caused by cve-2022-2068 centos7 is at maintenance support phase2, only critical impact security issues will be patched

隨機好文

nginx+ssl+certbot安裝設定雜記 using certbot on nginx to setup https connection

centos7 apache ssl.conf設定狀況 在apache更新或重啟後可能遇到ssl.conf衝突問題

在新版谷歌協作平台嵌入edimax或lass空氣盒子讀取數值並視覺化 embeeded javascript to read and visualized lass json value on new google site

縣市端新增syncdata spi功能 為了讓部裡主機可以透過OAUTH2流程,呼叫縣市同步SYNCDATA 的API