Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    ListGrid bottom/top padding

    Hi Isomorphic,

    I'd like to ask whether there is a way to get rid off padding at the bottom and the top of a listGrid cell.
    Given this code
    Code:
    @Override
        public void onModuleLoad() {
    
            final ListGrid countryGrid = new ListGrid();
            countryGrid.setBaseStyle("");
            countryGrid.setWidth(600);
            countryGrid.setHeight(224);
            countryGrid.setCellPadding(0);
    
            countryGrid.setVirtualScrolling(false);
    
            ListGridField nameField = new ListGridField("countryName", "Country");
            ListGridField capitalField = new ListGridField("capital", "Capital");
            ListGridField continentField = new ListGridField("continent", "Continent");
    
            countryGrid.setFields(nameField, capitalField, continentField);
    
            ListGridRecord[] records = new ListGridRecord[10];
            for(int i=0; i<10; i++) {
                ListGridRecord record = new ListGridRecord();
                record.setAttribute("continent", "Cont");
                record.setAttribute("countryName", "country");
                record.setAttribute("capital", "capital");
                records[i] = record;
            }
    
            countryGrid.setData(records);
    
            countryGrid.draw();
        }
    and no CSS provided (see attachment), there still pertains padding of 2px at the bottom and top of a cell.
    Using the listGrid.setCellPadding(0) only removes the left and right padding it seems.

    The reason why we would like to remove the padding is to get rid off the thick area between the cells inside of group summaries.

    Thanks a lot in advance

    SmartClient Version: v11.1p_2018-03-21/Pro Deployment (built 2018-03-21)
    Chrome 65.0.3325.181
    Attached Files
    Last edited by admin@seacomp.cz; 9 Apr 2018, 03:19. Reason: updated attachments

    #2
    It looks like someone has been hacking around with CSS in an invalid way here - you've got a style that is not coming from our software, with border-collapse:separate and a grey color configured. Remove this and setting the background to white will work as expected.

    Comment

    Working...
    X