Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Russian letters are displayed incorrectly in a file with UTF-8 encoding #67

Open
proffix4 opened this issue Feb 20, 2024 · 9 comments
Open
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@proffix4
Copy link

Снимок экрана 2024-02-20 101316

@proffix4
Copy link
Author

README.md

@proffix4
Copy link
Author

proffix4 commented Feb 20, 2024

TSN_Java_Lab1_2_2024

Создание простейшей визуальной программы на JAVA

screenshot

@moacirrf
Copy link
Owner

Hi, thanks for notification, i will try to fix.

@moacirrf
Copy link
Owner

moacirrf commented Feb 20, 2024

Its working on Linux( Fedora Kinoite), i will try on a windows VM soon, can you inform me:

  • Netbeans version
  • Operational System

thanks

@proffix4
Copy link
Author

proffix4 commented Feb 20, 2024 via email

@moacirrf moacirrf added bug Something isn't working help wanted Extra attention is needed labels Mar 5, 2024
@moacirrf
Copy link
Owner

moacirrf commented Mar 5, 2024

Hi
Strange, unfortunately i can't replicate this error.
I tried Netbeans 20,21 with oracle JDK 17, 18 and Open JDK, Windows 11
I will keep this issue open.

@proffix4
Copy link
Author

proffix4 commented Mar 5, 2024 via email

@hajdam
Copy link

hajdam commented Oct 19, 2024

Hi, I believe this is usually caused when binary to text conversion happens while encoding is not specified - in such case default encoding used by system is used which might behave differently for each user.

I believe NetBeans detects encoding of file and also has support for setting project specific encoding, so probably best approach would be to read charset from project somehow :-/ Or at least specify some charset.
I could try to find out more if you want...

Calls with unspecified charset I spotted:

  • fileObject.asText in MarkdownPreviewPane.FillEditorPaneWorker.doInBackground
  • outputStream.toString() in JEditorPaneImpl.getVisibleText

@moacirrf
Copy link
Owner

Thanks, I appreciate the tips.

Feel free to play around with the code if you want.
I've been pretty busy these past few weeks, so I won't have time to investigate these issues right now.

Hi, I believe this is usually caused when binary to text conversion happens while encoding is not specified - in such case default encoding used by system is used which might behave differently for each user.

I believe NetBeans detects encoding of file and also has support for setting project specific encoding, so probably best approach would be to read charset from project somehow :-/ Or at least specify some charset. I could try to find out more if you want...

Calls with unspecified charset I spotted:

* fileObject.asText in MarkdownPreviewPane.FillEditorPaneWorker.doInBackground

* outputStream.toString() in JEditorPaneImpl.getVisibleText

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

3 participants