Hi,
I've found a problem calculating height of RadioGroupItem, in fact there are two problems.
1. Height of horizontal items -> it was calculated as of vertical ones
2. Cellpadding of ContainerItem was not correctly added so there is a problem with exact aligning of DynamicForm.
Both problems resulted in larger height of DynamicForm leaving gap below all items.
I've created a patch in JavaScript that solves the problem.
I've highlighted changes from original source RadioGroupItem.js
Before I've worked this out by setCellHeight() but latest browsers cellpadding problem wasn't solved that way.
Hope that I can add this patch to source.
Best regards
Mariusz Goch
I've found a problem calculating height of RadioGroupItem, in fact there are two problems.
1. Height of horizontal items -> it was calculated as of vertical ones
2. Cellpadding of ContainerItem was not correctly added so there is a problem with exact aligning of DynamicForm.
Both problems resulted in larger height of DynamicForm leaving gap below all items.
I've created a patch in JavaScript that solves the problem.
Code:
isc.RadioGroupItem.addMethods({ getHeight : function () { [b]var cellPadding = isc.isA.Number(this.cellPadding) ? this.cellPadding : 0; if(!this.vertical) return this.itemHeight + cellPadding * 2;[/b] var valueMap = this.getValueMap(), numItems = 0; // if valueMap is an array, number of items is just the length of the array if (isc.isAn.Array(valueMap)) { numItems = valueMap.length; } else { for (var key in valueMap) { numItems++; } } return numItems * (this.itemHeight [b]+ cellPadding * 2)[/b]; } });
Before I've worked this out by setCellHeight() but latest browsers cellpadding problem wasn't solved that way.
Hope that I can add this patch to source.
Best regards
Mariusz Goch
Comment