分享

spark二次开发会议列表乱码解决思路

 WindySky 2016-02-18

修改BookMarkItem.java中

 

 

Java代码  收藏代码
  1. public BookmarkItem() {  
  2.        setLayout(new GridBagLayout());  
  3.   
  4.        imageLabel = new JLabel();  
  5.        nameLabel = new JLabel();  
  6.        descriptionLabel = new JLabel();  
  7.   
  8.   
  9.        descriptionLabel.setFont(new Font("微软雅黑", Font.PLAIN, 12));  
  10.        descriptionLabel.setForeground((Color)UIManager.get("ContactItemDescription.foreground"));  
  11.        descriptionLabel.setHorizontalTextPosition(JLabel.LEFT);  
  12.        descriptionLabel.setHorizontalAlignment(JLabel.LEFT);  

 descriptionLabel.setFont(new Font("微软雅黑", Font.PLAIN, 12));

修改JiveTreeCellRenderer.java中

Java代码  收藏代码
  1. JiveTreeNode node = (JiveTreeNode)value;  
  2.    if (node.getAllowsChildren()) {  
  3.        setFont(new Font("微软雅黑", Font.BOLD, 12));  
  4.    }  
  5.    else {  
  6.        setFont(new Font("微软雅黑", Font.PLAIN, 12));  
  7.    }  

主要是编码造成的问题,同样的可以修改自定义状态中的乱码问题

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约