×

Set Property

iOS 14 +

Notes

Set a property on a view.

Syntax

setProperty(property: <#Enumeration (Property)#>, backgroundView: <#Object (View)#>, backgroundAlignment: <#Object (Alignment)#>, overlayView: <#Object (View)#>, overlayAlignment: <#Object (Alignment)#>, foregroundColor: <#Object (View)#>, accentColor: <#Object (View)#>, padding: <#Double#>, opacity: <#Double#>, brightness: <#Double#>, contrast: <#Double#>, saturation: <#Double#>, grayscale: <#Double#>, font: <#Object (Font)#>, clipShape: <#Object (View)#>, mask: <#Object (View)#>, fixedFrameWidth: <#Double#>, fixedFrameHeight: <#Double#>, fixedFrameAlignment: <#Object (Alignment)#>, minimumScaleFactor: <#Double#>, relativeFrameWidth: <#Double#>, relativeFrameHeight: <#Double#>, relativeFrameAlignment: <#Object (Alignment)#>, relativeFrameRelativeTo: <#Object (RelativeFrameRelativeTo)#>, fixedSizeHorizontal: <#Boolean#>, fixedSizeVertical: <#Boolean#>, view: <#Object (View)#>)

Example

setProperty(property: background, backgroundView: View(identifier: "View1", displayString: "View One"), backgroundAlignment: Alignment(identifier: "Alignment", displayString: "Alignment"), overlayView: , overlayAlignment: , foregroundColor: , accentColor: , padding: , opacity: 100, brightness: 50, contrast: 50, saturation: 50, grayscale: 50, font: , clipShape: , mask: , fixedFrameWidth: 100, fixedFrameHeight: 100, fixedFrameAlignment: , minimumScaleFactor: 1.0, relativeFrameWidth: 100, relativeFrameHeight: 100, relativeFrameAlignment: Alignment(identifier: "Alignment", displayString: "Alignment"), relativeFrameRelativeTo: RelativeFrameRelativeTo(identifier: "Relative", displayString: "Relative"), fixedSizeHorizontal: 100, fixedSizeVertical: 100, view: )