希伯来语在netbeans中出现问号 [英] hebrew appears as question marks in netbeans

查看:134
本文介绍了希伯来语在netbeans中出现问号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在两台计算机上使用netbeans 6.1。

I am using netbeans 6.1 on 2 computers.

其中一个程序:

public static void main(String argv[]) 
{
        System.out.println("שלום");
}

正常打印,另一个问号打印。

两种环境之间可能有什么区别?

prints normally, and the on the other question marks.
what can be the difference between the 2 environments?

编辑:两台计算机上的

控制面板\区域和语言选项\高级
设置为希伯来语


编辑:
谢谢Michael Burr,
但编码值已经是UTF-8。
也许是JVM的这个东西?


编辑:
我已经安装了Eclipse,问题就出现了。
我也尝试从具有相同结果的文件中读取希伯来语。


编辑:

System.getProperty(file.encoding);

返回Cp1252
我试过

System.setProperty(file.encoding, UTF-8)

但问号仍然存在。

edit: on both computers Control Panel \ Regional and Language Options \ Advanced is set to hebrew
edit: Thank you Michael Burr, but the value of the encoding is already UTF-8. Maybe this something with the JVM?
edit: I have installed Eclipse and the problem occurs there as well. I also tried reading the hebrew from a file with the same result.
edit: System.getProperty("file.encoding"); returns "Cp1252" I tried System.setProperty("file.encoding","UTF-8") but the question marks remains.

谢谢,

Ido

Thanks,
Ido

推荐答案

确保使用支持希伯来字符的编码设置NetBeans。来自 NetBeans Wiki

Make sure that NetBeans is set up with an encoding that supports Hebrew characters. From the NetBeans Wiki:


要更改项目的语言编码:

To change the language encoding for a project:


  1. 在项目窗口中右键单击项目节点,然后选择属性。

  2. 在源下,从编码下拉字段中选择一个编码值。


这篇关于希伯来语在netbeans中出现问号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆