Netbeans messing accent

2

For a few days now, I've noticed that Netbeans has been changing accented characters in my code. Apparently, it only does this in the class that was left open when I closed Netbeans. That is, I am editing two classes and I close Netbeans. When I reopen, the class that is in evidence (open) has the accented characters messed up.

FacesContext.getCurrentInstance().addMessage(null, new FacesMessage("Mês/Ano inválido!"));
  • Netbeans 8.0.1
  • Windows 7 64bit
  • Source code encoding: UTF-8

What can this be?

    
asked by anonymous 24.09.2014 / 14:53

1 answer

4

As the @gabrielhof tip, I added the -J-Dfile.encoding = UTF-8 switch in the netbeans_default_options switch in the NetBeans configuration file $ DIRETORIO_NETBEANS / etc / netbeans.conf

netbeans_default_options="-J-client -J-Xss2m -J-Xms32m -J-XX:PermSize=32m -J-Dapple.laf.useScreenMenuBar=true -J-Dapple.awt.graphics.UseQuartz=true -J-Dsun.java2d.noddraw=true -J-Dsun.java2d.dpiaware=true -J-Dsun.zip.disableMemoryMapping=true -J-Dfile.encoding=UTF-8"
    
24.09.2014 / 16:31