Author Topic: Option to allow horizontal scroll bar when needed when scrollModel.autofit=true  (Read 177 times)

jplevene

  • Pro Ultimate
  • Jr. Member
  • *
  • Posts: 99
    • View Profile
Code: [Select]
colModel: {
   ...
   colModel : [
      {dataIndx:"ID", minWidth:"60", maxWidth:80},
      {dataIndx:"TITLE", minWidth:"200"},
      {dataIndx:"ALT_TITLE", minWidth:"200"},
      {dataIndx:"LOCATION", minWidth:"200"},
      {dataIndx:"DESCRIPTION", minWidth:"200},
      {dataIndx:"PART_NUMBER", minWidth:"100"},
      {dataIndx:"LAST_UPDATE", minWidth:"100"}
   ],
   scrollModel:{autoFit:true},
   flex: {on:true, all:false, one:false},
   width: "100%",
   height: "100%",
   ...
}

The issue is that minWidth is set and when the table is lets say 500 wide, I can sometimes "scroll" to the column by clicking on it if it is partially shown, but I don't have a horizontal scroll bar to scroll to it or the ones past that.

Request an option as another value in scrollModel.autoFitScrollbar=true or something that ONLY displays the horizontal scroll bar when it is needed due to column minWidth values oversizing.  If the grid is wide enough to contain all minWidth values, then there is no scroll bar and it acts like before.

I feel this needs to be an option and not a default behaviour due to backwards compatibility.

This is also very important for adaptive pages, as when switching to vertical mobile, this would be necessary.  This feature would make pqGrid more adaptive compatible.
« Last Edit: August 03, 2024, 05:31:18 am by jplevene »