Skip to content

Commit 0618e02

Browse files
committed
Improve brand logo rendering
1 parent 686371d commit 0618e02

File tree

3 files changed

+11
-1
lines changed

3 files changed

+11
-1
lines changed

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1111
### Added
1212
- A new option to set a custom branding tray menu icon by specifying a base64 string of the icon using `TrayMenuBrandingIcon`. Note that the icon should be a monochrome icon to fit the design of the tray menu.
1313

14+
15+
### Changed
16+
- Additional options to the rendering of brand logos has been added that allows for a higher quality rendering of the logo as it in some cases could look blurry or jagged.
17+
1418
## [2.2.0] - 2025-01-07
1519
### Changed
1620
- A slight background has been added increasing visaibility of the text.

SupportCompanion/ContentView.swift

+3
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,11 @@ struct ContentView: View {
3131
if showLogo, let logo = brandLogo {
3232
logo
3333
.resizable()
34+
.interpolation(.high)
35+
.antialiased(true)
3436
.scaledToFit()
3537
.frame(maxWidth: 230)
38+
.drawingGroup()
3639
.fixedSize(horizontal: false, vertical: true)
3740
.padding(.top, 20) // Minimal padding
3841
.padding(.horizontal, 20)

SupportCompanion/Views/TrayMenu.swift

+4-1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ struct TrayMenuView: View {
2727
if showLogo, let logo = brandLogo {
2828
logo
2929
.resizable()
30+
.interpolation(.high)
31+
.antialiased(true)
32+
.drawingGroup()
3033
.scaledToFit()
3134
.frame(maxWidth: 150)
3235
.fixedSize(horizontal: false, vertical: true)
@@ -208,4 +211,4 @@ struct ButtonSection: View {
208211
.frame(maxWidth: .infinity, alignment: .leading)
209212
.padding(.horizontal, 5)
210213
}
211-
}
214+
}

0 commit comments

Comments
 (0)