question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Appx build shows accent color behind the icon in the taskbar.

See original GitHub issue
  • Electron-Builder Version: 22.11.7

  • Node Version: v14.16.0

  • Electron Version: 13.2.0

  • Electron Type (current, beta, nightly):

  • Target: Windows (appx)

The appx build shows a background behind the logo when building an Appx. The NSIS build shows the icon correctly (without background colour).

wrong: image correct: image

my package.json is:

"build": {
   "protocols": {
     "name": "xxxxx",
   },
   "directories": {
     "buildResources": "Resources"
   },
   "extends": null,
   "productName": "xxxxx",
   "appId": "zz.yyyyyy.xxxxx",
   "files": [
     "build/**/*",
     "electron/*",
     "resources/**/*",
     "electron/icons/*",
     "icons/*"
   ],
   "appx": {
     "identityName": "yyyyyy.xxxx",
     "backgroundColor": "transparent",
     "publisher": "CN=...",
     "publisherDisplayName": "yyyy",
     "displayName": "xxxx"
   },
   "win": {
     "target": "nsis",
     "icon": "Resources/appx/StoreLogo.png",
     "publisherName": "yyyyy",
     "certificateFile": "certs/yyyy-CodeSigning.pfx",
     "certificatePassword": "...",
     "extraResources": [
       "electron/bin/*.exe"
     ],
     "verifyUpdateCodeSignature": true
   }
 }

my Resources/appx consists of: Square44x44Logo.png (size 44x44px) Square150x150Logo.png (size: 150x150px) StoreLogo.png (size: 256x256px) Wide310x150Logo.png (size: 310x150px)

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:3
  • Comments:5

github_iconTop GitHub Comments

3reactions
ci010commented, Jun 2, 2022

Has someone found a solution for this annoying issue?

I referred the translucentTB package, and found that we need many trailor to make it work in most cases.

My icons: https://github.com/Voxelum/x-minecraft-launcher/tree/master/xmcl-electron-app/icons

Note1: Ignore the thing before @. My build script will copy the light@SmallTile.scale-400_theme-light.png to SmallTile.scale-400_theme-light.png in final package.

Note2: Ignore the theme trailor. It just for different os theme and does not affect background.

I believe the unplated trailor in Square44x44Logo.targetsize-256_altform-unplated.png is the key to resolve background issue.

You can find the actual meaning of trailor: https://docs.microsoft.com/en-us/windows/uwp/app-resources/tailor-resources-lang-scale-contrast

Also the logo definition to verify my assumption about unplated: https://docs.microsoft.com/en-us/windows/apps/design/style/app-icons-and-logos

0reactions
Fabio286commented, Jun 2, 2022

I believe the unplated trailor in Square44x44Logo.targetsize-256_altform-unplated.png is the key to resolve background issue.

I can’t believe it, I can finally say goodbye to the background color. Thank you very much!

Read more comments on GitHub >

github_iconTop Results From Across the Web

[UWP][Desktop Bridge]unplated taskbar icons in ... - MSDN
How do we get unplated taskbar icons in UWP Desktop apps? ... get rid of the accent-color border, but it's always showing the...
Read more >
How to Fix Show Color on Taskbar Greyed Out on Windows 10
While trying to make changes to the Colors settings in Windows 10, the options are greyed out under Show accent color on the...
Read more >
Accent color in Windows 10 app taskbar icons - Martin Zikmund
I was wondering how this can be achieved. The transparent color is used to make the “transparent” portions of the icon, but the...
Read more >
color bars under taskbar icons - Windows 11 Forum
This changes the registry entries in [HKEY_CURRENT_USER\Control Panel\Colors]. If you are using a pre-built theme, the colors you see are ...
Read more >
How to change the accent color only in the taskbar on ...
Turn on the Show color on Start, taskbar, and action center toggle switch. Use the Windows key + R keyboard shortcut to open...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found