Skip to content

Releases: swhitty/SwiftDraw

0.24.0 Small, Medium & Large Symbol Sizes

29 Aug 23:04
dbb4ef9
Compare
Choose a tag to compare

What's Changed

  • support small, medium and large SFSymbols by @swhitty in #92
  • Support CSS declarations with multiple selectors by @swhitty in #95
  • Resolve clipPaths via stylesheet by @swhitty in #96
  • convert Mask to GraphicsElement by @swhitty in #98

Full Changelog: 0.23.1...0.24.0

0.23.1

29 Aug 23:07
a535740
Compare
Choose a tag to compare

0.23.0

07 Aug 20:39
a535740
Compare
Choose a tag to compare

Updates the alignment of SFSymbols and left/right guides to precisely align to the supplied insets. When --insets auto the left/ight guides are closer to official SFSymbols:

default

When --insets 10 20 10 20 are supplied, the left/right guides are now precisely aligned to these insets:

insets

Pass the --legacy option to use the original, less precise alignment logic from earlier SwiftDraw versions.

What's Changed

New Contributors

Full Changelog: 0.22.0...0.23.0

0.22.0 SwiftDOM / Swift 5.9

29 May 02:19
a195947
Compare
Choose a tag to compare

Drop support for Swift 5.8.

Moves all DOM files to new SwiftDOM module. All types are exposed with package access control so nothing can actually be used publicly.

What's Changed

  • Moving DOM files to SwiftDOM Module by @swhitty in #80
  • fix: visionos in podspec by @EyreFree in #81
  • SwiftDOM is now published to cocoapods

0.21.0 Swift 6 Language Mode

16 Apr 12:12
2a36e6c
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 0.20.1...0.21.0

0.20.1 SwiftUI SVGView

23 Feb 11:28
90f94b8
Compare
Choose a tag to compare

SwiftUI

Adds native SwiftUI support with SVGView:

var body: some View {
    SVGView(named: "sample.svg")
        .aspectRatio(contentMode: .fit)
        .padding()
}

Pass a SVG instance for better performance:

var image: SVG

var body: some View {
    SVGView(svg: image)
}

Transformation

SVG is now a struct and gains the ability to transform the image, updating its size before rasterization:

let svg = SVG(name: "fish.svg")!   // 100x100 
    .expanded(left: 10, right: 10) // 120x100
    .scaled(2)                     // 240x200

imageView.image = svg.rasterize()  // 240x200

Note: @objc(SVGImage) has been removed. SVG is now a struct and incompatible with ObjectiveC. Users can write their own objc wrapper to continue use.

0.19.0 Nested SVG

19 Feb 08:55
a3553a4
Compare
Choose a tag to compare

Adds support for Nested <svg> images within an existing image #67

0.18.3 Fix quad and ARC path segments

14 Feb 07:35
2cfd97c
Compare
Choose a tag to compare

Includes 2 separate fixes for issues within Paths

  • Rendering issue with some Quad segments #63
  • Crash with some Arc segments #65

0.18.2 Fix clip-path transforms

11 Feb 09:36
feb12e3
Compare
Choose a tag to compare

Fixes transform when used within clip-path #61

0.18.1 Fix display: block

21 Nov 05:50
65d5db7
Compare
Choose a tag to compare

Adds support for:

  • display: block #53
  • Public init for SVG.Insets #56

🙏🏻 @alpennec