Custom SF Symbols | raywenderlich.com


This is a companion discussion topic for the original entry at https://www.raywenderlich.com/6485147-drawing-in-ios-with-swiftui/lessons/14
1 Like

I appreciate the tutorial. A lot of great stuff!

I found I was able to use the custom symbol directly as an image by calling:

Image("crayon")
    .imageScale(.medium)
    .font(.system(size: 60, weight: .medium))

This was a lot simpler than creating the UIImage.SymbolConfiguration. Changing the font weight or image scale would select the paperclip image elsewhere in the imported symbol file. It also appeared to honor the baseline offsets in the template file.

On the negative side, the .font modifier erases the type to some View making it unusable in the crayonImage property in CellView.

1 Like

@rocketdocaz Thank you for sharing your solution - much appreciated!