<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    隨筆-50  評論-55  文章-8  trackbacks-0
    ?在使用java默認的lokandfeel的 時候,要想讓JTree不同的行顯示行高,只需要cellRenderer的組件設置大小就可以了,而換作windowlookandfeel的時候,不僅要設置組件大小,對樹還要設置 setRowHeight(0);
    請看如下解釋:
    The tree component's row height property controls the height of every displayed node. If the row height is greater than 0, all rows will be given the specified height. However, if the rows can be of differing heights, it is necessary to set the row height to 0. With a 0 row height, all heights of all rows are computed individually.
        // Create tree
        JTree tree = new JTree();
        
        // All rows will be given 15 pixels of height
        tree.setRowHeight(15);
        
        // Have the row height for each row computed individually
        tree.setRowHeight(0);
        
        // If the row height is 0 and the height of a row has dynamically changed, it is necessary
        // to flush the internal cache of row heights. The following calls flush the internal cache.
        if (tree.getRowHeight() <= 0) {
            // Temporary change to non-zero height
            tree.setRowHeight(1);
        }
        tree.setRowHeight(0);
    以上解釋來自:http://www.javaref.cn/egs/javax.swing.tree/RowHeight.html

    ?Related Examples
    posted on 2007-11-26 10:28 蔣家狂潮 閱讀(550) 評論(0)  編輯  收藏 所屬分類: Swing

    只有注冊用戶登錄后才能發表評論。


    網站導航:
     
    主站蜘蛛池模板: 亚洲最大视频网站| 亚洲va中文字幕无码久久| 亚洲一区在线视频| 日本免费一区二区在线观看| 日韩精品一区二区亚洲AV观看| 久久九九全国免费| 亚洲五月激情综合图片区| 99精品热线在线观看免费视频| 久久精品国产精品亚洲艾| 久久久久免费精品国产小说| 色婷婷六月亚洲婷婷丁香| 99久久久精品免费观看国产| 亚洲av午夜精品无码专区| 24小时日本在线www免费的| 欧美亚洲国产SUV| 亚洲国产aⅴ综合网| 日韩av无码免费播放| 亚洲精品亚洲人成在线观看麻豆| 人妻视频一区二区三区免费| 亚洲中文字幕久久无码| 日韩精品成人亚洲专区| 免费福利在线视频| 亚洲无码一区二区三区| 亚洲免费在线观看| 精品无码无人网站免费视频| 亚洲性无码一区二区三区| 亚洲天堂免费在线视频| 久久青草91免费观看| 亚洲综合激情五月色一区| 亚洲国产成人精品女人久久久| 免费成人高清在线视频| 亚洲中文字幕无码爆乳app| 久久乐国产精品亚洲综合| 69精品免费视频| 老司机午夜在线视频免费观| 亚洲国产精品一区二区第一页| 97在线线免费观看视频在线观看 | 午夜国产大片免费观看| 久久国产精品免费一区二区三区 | 亚洲A丁香五香天堂网| 久久99国产乱子伦精品免费|