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

mytetra: init at 1.42.2 #23922

Merged
merged 1 commit into from Apr 22, 2017
Merged

mytetra: init at 1.42.2 #23922

merged 1 commit into from Apr 22, 2017

Conversation

ghost
Copy link

@ghost ghost commented Mar 15, 2017

Motivation for this change

Add notes manager

Things done
  • Tested using sandboxing
    (nix.useSandbox on NixOS,
    or option build-use-sandbox in nix.conf
    on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • Linux
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@ttuegel
Copy link
Member

ttuegel commented Mar 17, 2017

When I put PNG icon, it works, but not the SVG. @ttuegel please help! :) wrapQtProgram doesn't make any change.

You still need wrapQtProgram or your users will get segfaults randomly.

I see you did include qtsvg, but is the .pro linking against it? If the PNG works, but not the SVG, that suggests qmake is building the PNG into the executable by mistake; you can check the .pro for that too, I believe.

@ghost
Copy link
Author

ghost commented Mar 17, 2017

Can't get tray icon to show. The program uses the following code
src/views/mainWindow/MainWindow.cpp

  QIcon icon = QIcon(":/resource/pic/logo.svg");
  trayIcon->setIcon(icon);
  setWindowIcon(icon);

When I put PNG icon, it works, but not the SVG. @ttuegel please help! :) wrapQtProgram doesn't make any change. Maybe it's just because I'm on 17.03-beta channel, and the package is built with the stuff from master, dunno.


@ttuegel Thank you! It's linking:

$ ldd bin/mytetra | grep -i svg
        libQt5Svg.so.5 => /nix/store/mr1l6i5wnvi1jlnm5f439jxyx51lcmfn-qt-5.7.1/lib/libQt5Svg.so.5 (0x00007f7700c39000)

libpng too, since some UI elements are png images

libpng16.so.16 => /nix/store/lbq1pdql98h7xh25j4rx8k7gyrvy77fa-libpng-apng-1.6.28/lib/libpng16.so.16 (0x00007f1a60d60000)

Also this program uses a lot of svg icons in the UI, they are rendered correctly. But tray icon is not visible - again svg is used for that, if I swap it with other format like png - then tray icon becomes visible

@ttuegel
Copy link
Member

ttuegel commented Mar 17, 2017

But tray icon is not visible - again svg is used for that, if I swap it with other format like png - then tray icon becomes visible

What tray are you using? It might not support SVG icons. In any case, it doesn't sound like a problem on the Qt side, if the rest of the SVG icons render correctly.

@ghost
Copy link
Author

ghost commented Mar 18, 2017

@ttuegel Standard KDE Plasma 5 tray

@ghost
Copy link
Author

ghost commented Mar 18, 2017

@ttuegel
Most other programs use either png icon for tray or QSvgRenderer
To keep things simple, I'll just make it use png icon and mark this PR as ready
Thanks

@ghost ghost changed the title [WIP] mytetra: init at 1.42.2 mytetra: init at 1.42.2 Mar 18, 2017
@ttuegel ttuegel merged commit e019978 into NixOS:master Apr 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants