Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Icons for tabs keep colour when swiching tab #5310

Closed
2 tasks done
Jacalz opened this issue Dec 11, 2024 · 4 comments
Closed
2 tasks done

Icons for tabs keep colour when swiching tab #5310

Jacalz opened this issue Dec 11, 2024 · 4 comments
Labels
blocker Items that would block a forthcoming release bug Something isn't working

Comments

@Jacalz
Copy link
Member

Jacalz commented Dec 11, 2024

Checklist

  • I have searched the issue tracker for open issues that relate to the same problem, before opening a new one.
  • This issue only relates to a single bug. I will open new issues for any other problems.

Describe the bug

When selecting a tab, the text and icon switches to the primary colour and this should then revert back to previous state once a different tab is selected. The v2.5.3-rc6 release has a problem where the icon doesn't change colour when the selected tab changes.

How to reproduce

  1. Run the example code below and switch to the second tab.
  2. Notice that the icon for the first tab still has the primary colour.

Screenshots

Screencast.From.2024-12-11.14-39-40.webm

Example code

import (
	"fyne.io/fyne/v2/app"
	"fyne.io/fyne/v2/container"
	"fyne.io/fyne/v2/theme"
	"fyne.io/fyne/v2/widget"
)

func main() {
	a := app.New()
	w := a.NewWindow("Hello")

	tabs := container.NewAppTabs(
		container.NewTabItemWithIcon("1", theme.InfoIcon(), widget.NewEntry()),
		container.NewTabItemWithIcon("2", theme.MailSendIcon(), widget.NewEntry()),
	)

	w.SetContent(tabs)
	w.ShowAndRun()
}

Fyne version

v2.5.3-rc6

Go compiler version

1.23.3

Operating system and version

Fedora Silverblue 41

Additional Information

No response

@Jacalz Jacalz added bug Something isn't working blocker Items that would block a forthcoming release labels Dec 11, 2024
@Jacalz Jacalz added this to the E fixes (v2.5.x) milestone Dec 11, 2024
@Jacalz
Copy link
Member Author

Jacalz commented Dec 11, 2024

I don't think there were changes to the tab code in this release right? If this is a result of image refresh changes then we might have similar issues elsewhere (assuming that the tab code hasn't incorrectly been not refreshing images when it should).

@andydotxyz
Copy link
Member

Both of those statements are correct - it was caused by the image changes, but it is because we were not refreshing appropriately.
Other issues were found, and resolved, in check and radio earlier.

andydotxyz added a commit to andydotxyz/fyne that referenced this issue Dec 11, 2024
@andydotxyz
Copy link
Member

Fixed, if we can get this approved I'll roll another rc before I go sleep

@andydotxyz
Copy link
Member

Fixed in v2.5.3-rc7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocker Items that would block a forthcoming release bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants