eromatiya/lightdm-webkit2-theme-glorious

Couldn't change the profile picture

mushi-nova opened this issue · 7 comments

I really love this theme but I was unable to change the profile picture that is being displayed at the very beginning. At the starting by default user.svg is used which is located in /assets/profiles. I tried to look into users-screen.js but couldn't deduce as to how to set the profile picture.
My path to the profile picture is set in the lightdm.conf. So is there anyway to use my profile picture in the greeter?

It's in the README.md.

If you're on a desktop environment like KDE Plasma and GNOME3, you can set your profile picture and real name in the settings. While if you're on a more minimal environment like window managers, you can install and use the program called mugshot.

Glad to receive your quick response and I looked into that software named mugshot but it didn't work out. I'm currently using Mugshot 0.4.2 and it's running pretty smoothly with no possible errors and I tried to set the profile image as root too. It could be a problem related to Mugshot itself or it could be an error within this application which I'm pretty unsure about. Hope you would be able to help me out with this.
Secondly, I was thinking about whether there could be a possible way to set the profile image directly by modifying the code so that no third party software is used for completing the task.

I was thinking about whether there could be a possible way to set the profile image directly by modifying the code so that no third party software is used for completing the task.

It's possible but implementing it will need a lot of work and kinda counterproductive. Right now, we are using the lightdm object to get the user data including the path to profile image.

I'm currently using Mugshot 0.4.2 and it's running pretty smoothly with no possible errors and I tried to set the profile image as root too. It could be a problem related to Mugshot itself or it could be an error within this application which I'm pretty unsure about. Hope you would be able to help me out with this.

Mugshot works fine here. I'm using 0.4.2-1. You can check if the lightdm object has the path to your profile picture by adding console.log(userProfileImage) under these lines https://github.com/manilarome/lightdm-webkit2-theme-glorious/blob/863791f22d70bccef85efc34007d7587f07a7298/js/users-screen.js#L226-L230

Then run lightdm-webkit2-greeter in your terminal. It should print the path to your profile image if there's any. You can also check if you have a profile picture by running feh /var/lib/AccountsService/icons/$(whoami). Just replace feh if it's not your image viewer.

Also, try to use png format.

Is it possible to reopen the issue? I'm running into the same problem.

Here's what I did:

  • Placed avatar.png in usr/share/background to ensure it could be read before i logged in
  • Configured mugshot using my user and root aswell
  • Ran lightdm-webkit2-greeter on terminal
  • Still no avatar

System:

  • Distro: Manjaro x86_64
  • Kernel: 5.4
  • WM: i3
  • Package installed from the AUR
  • Latest updates

Placed avatar.png in usr/share/background to ensure it could be read before i logged in

Well, that's the reason. You should use mugshot or your system settings(if supported) to update your profile image. Only wallpapers/backgrounds should go to /usr/share/background. Please consider reading the README.

Yeah I only did that because after leaving it in the default folder (which is a partition which is mounted by fstab) didn't work. So I thought maybe the file was only available after I log in, so I placed it in usr/share/avatars first and made it world readable, but it didn't work, so I tried /usr/share/backgrounds out of lack of ideas.

I did use mugshot and pointed to /usr/share/backgrounds/avatar.png. It even showed up as a possible wallpaper while browsing the settings inside the theme but it still wouldn't load as an avatar so it's clearly not a problem with it being world readable or not.

I did the whole mugshot thing exactly as specified in the README.md, I just changed the avatar location because I thought it might be it, but apparently it's not.