add top corner radius swift
extension UIView {
func roundCorners(corners: UIRectCorner, radius: CGFloat) {
let path = UIBezierPath(roundedRect: bounds, byRoundingCorners: corners, cornerRadii: CGSize(width: radius, height: radius))
let mask = CAShapeLayer()
mask.path = path.cgPath
layer.mask = mask
}
}
Also in Swift:
- how to fetch data from server in swift
- tellraw minecraft
- swift double v float
- how to start on a programatic view swift
- how to dismiss keyboard swiftui
- how to pass state variable in swiftui
- swift subtract dates
- how to get appdelegate object in swift
- go to view controller programmatically swift
- how do i get a string from a float swift to 1 decimal swift
- swift programming language wikipedia
- swift swipe gesture
- fetch request core data
- context.fetch() in swift
- change font swiftui
- rounded ios button
- swift doc comments
- variadic parameters swift
- swift generate random number
- add shadow to collection view cell swift
- how to remove subview siwft 5
- how to know when text changed textfield swiftui
- how to use 2 alerts in swiftui
- swift list