/// <summary> /// Modify the space between groups /// </summary> /// <param name="olv"></param> /// <returns></returns> protected int SetGroupSpacing() { if (this.ListView.SpaceBetweenGroups <= 0) { return(0); } NativeMethods.LVGROUPMETRICS metrics = new NativeMethods.LVGROUPMETRICS(); metrics.cbSize = ((uint)Marshal.SizeOf(typeof(NativeMethods.LVGROUPMETRICS))); metrics.mask = (uint)GroupMetricsMask.LVGMF_BORDERSIZE; metrics.Bottom = (uint)this.ListView.SpaceBetweenGroups; return(NativeMethods.SetGroupMetrics(this.ListView, this.GroupId, metrics)); }
/// <summary> /// Modify the space between groups /// </summary> /// <param name="olv"></param> /// <returns></returns> protected int SetGroupSpacing() { if (this.ListView.SpaceBetweenGroups <= 0) return 0; NativeMethods.LVGROUPMETRICS metrics = new NativeMethods.LVGROUPMETRICS(); metrics.cbSize = ((uint)Marshal.SizeOf(typeof(NativeMethods.LVGROUPMETRICS))); metrics.mask = (uint)GroupMetricsMask.LVGMF_BORDERSIZE; metrics.Bottom = (uint)this.ListView.SpaceBetweenGroups; return NativeMethods.SetGroupMetrics(this.ListView, this.GroupId, metrics); }