SMART datagrid v.1 > Classes > ShapeCellRenderer

Back  Forward

DataLudi.ShapeCellRenderer.sizeRate  property

It specifies the size of shape which is drawn in the cell. 

If GridStyles.shapeSize value has not been determined, the size will be determined by multiplying the ratio set in this property by the minimum value of the width and height of cell. 

Defaults to 0.6.

Getter
function sizeRate(): Number
Setter
function setSizeRate(value: Number)
Code -1
    grid.setColumns([{
        name: "Quantity",
        fieldName: "Quantity",
        type: "data",
        width: 70,
        renderer: {
            type: "shape",
            sizeRate: "0.5"
        },
        styles: {
            textAlignment: "far"
        },
        dynamicStyles: [{
            expression: "value > 40",
            styles: {
                shapeName: "star",
                shapeColor: "#ff00ffcc",
                shapeLocation: "center"
            }
        }],
        header: {
            text: "Quantity"
        }
    },
    ...
    ]);
See Also
GridStyles.shapeSize
textVisible
Examples
Shape Cell Renderer