public TFluent SetPresetGeometry(OpenXmlPresetGeometry geometry) { OpenXmlElement shapeProperties = this.element.GetOrCreateShapeProperties(); PresetGeometry presetGeometry = shapeProperties.GetFirstChild <PresetGeometry>() ?? shapeProperties.AppendChild(new PresetGeometry()); presetGeometry.RemoveAllChildren(); presetGeometry.Preset = geometry.ShapeType; if (!geometry.AdjustValues.IsDefault) { presetGeometry.AppendChild(new AdjustValueList().AppendFluent(geometry.AdjustValues.Select(av => new ShapeGuide() { Name = av.Name, Formula = av.Formula }))); } return(this.result); }