zoukankan      html  css  js  c++  java
  • 定制uniGUI Grid表头高度

    uniGUI的Grid表头,没有提供delphi属性来定制,原因是因为支持多级表头,需要自动计算。但如果不定制,造成表头高度与行高不致。通过css,可以定制表头高度,但对于多级表头来说,又无法自动计算了。这是个矛盾,怎么能两全其美呢?

    办法是有的,我们先定义一个固定高度表头的css,放到uniServerModule.CustomCSS中:

    .kls-grid .x-column-header
    {
        background-color: #F7F7F7;
        background-image:initial;
        /* border- 0px !important;  */
        border-right: 0px solid #e0e0e0;
        height:30px; 
    }
    
    .kls-grid .x-grid-header-ct{
        background-color: #F7F7F7;
        background-image:initial;
        border:initial;
        border-bottom-width: 1px !important;
        border-bottom-color: #E4E4E4 !important;
        border-bottom: 1px solid #E4E4E4 !important;
        height:30px; 
    }

    注意,这个启了名子:kls-grid

    对于非多级表头的Grid,我们设置他的属性:

    uniDBGrid.LayoutConfig.ComponentCls:='kls-grid'

    对于多级表头的Grid,我们不设置uniDBGrid.LayoutConfig.ComponentCls

  • 相关阅读:
    礼物
    Hibernate 笔记 HQL查询 条件查询,聚集函数,子查询,导航查询
    Hibernate get 和 load区别
    JS
    JS
    JS
    JS
    JS
    JS
    JS
  • 原文地址:https://www.cnblogs.com/kinglandsoft/p/13570757.html
Copyright © 2011-2022 走看看