Skip to content

DrawingElementPropertiesUpdate

Used to mutate the properties of one or drawing elements.

let model = await SketchUpApi.getActiveModel();
model.performOperation((op) => {
const faces = await model.entities.get({filterBy:{types:['Face']}});
const hide = {hidden: true};
faces.forEach((face) => {
op.drawingElementSetProperties(face, hide);
});
}, 'Hide Faces');

Operation.drawingElementSetProperties

optional castsShadows?: boolean

When not supplied the castsShadows flag is left unchanged. Other-wise the castsShadows flag is set to the supplied value.


optional hidden?: boolean

When not supplied the hidden flag is left unchanged. Other-wise the hidden flag is set to the supplied value.


optional receivesShadows?: boolean

When not supplied the receivesShadows flag is left unchanged. Other-wise the receivesShadows flag is set to the supplied value.