LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


View Poll Results: What's your favorite wallpaper changer?
Cortina 0 0%
DesktopNova 0 0%
Drapes 0 0%
Nitrogen 2 12.50%
SyncWall 0 0%
Variety 3 18.75%
Wallch 1 6.25%
Wallpaper-Tray 0 0%
Wallpapoz 0 0%
Wally 0 0%
Webilder 0 0%
Other method - please comment. 10 62.50%
Voters: 16. You may not vote on this poll

Reply
  Search this Thread
Old 07-19-2017, 08:34 AM   #16
linustalman
LQ Guru
 
Registered: Mar 2010
Location: Ireland
Distribution: Debian 12 Bookworm
Posts: 5,717

Original Poster
Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
Exclamation


Quote:
Originally Posted by Myk267 View Post
Nitrogen seems to work okay. I usually download feh because I'm feeling a minimalist, but then I get lazy and also download nitrogen so I can just click on a picture to set as my desktop for a while.

Try feh?

Code:
while true; do
        feh --bg-max --randomize ~/Downloads/*.jpg # Just some example arguments from my own machine
        sleep 600 # seconds
done
In my home dir, there's a new file called .fehbg
It starts with:
Code:
#!/bin/sh
feh --image-bg black --bg-max ...
Why is the image bg set to black?

It does not seem to change when it should (I set it to every 6 seconds to test it). Also it shows a black background often.
 
Old 07-19-2017, 08:45 AM   #17
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by linustalman View Post
In my home dir, there's a new file called .fehbg
It starts with:
Code:
#!/bin/sh
feh --image-bg black --bg-max ...
Why is the image bg set to black?

It does not seem to change when it should (I set it to every 6 seconds to test it). Also it shows a black background often.
maybe bad images - try opening them up in gimp and saving over top of them to exporting them and using the exported image to see if that fixes the black image.

never mind you told it too.. gezz
 
Old 07-19-2017, 12:43 PM   #18
Myk267
Member
 
Registered: Apr 2012
Location: California
Posts: 422
Blog Entries: 16

Rep: Reputation: Disabled
Quote:
Originally Posted by linustalman View Post
Hi Myk267.

Thank you, I will give that a try. Some of my wallpapers are also .png files. How would that be incorporated into the script?
The lazy way is to simply give a plain path to feh.
feh --bg-fill ~/Path/To/Images/
If there are things inside that directory that feh can't read it will error and fail to set an image.

Otherwise, try an extended glob.
feh --bg-fill ~/Path/To/Images/*+(jpg|png)
The glob matches one or more occurrences of the options only, so if there's no jpg files it doesn't supply any of those to feh in the first place. I like this solution, but this nice website http://mywiki.wooledge.org/BashGuide/Patterns informs me that extended globs might not be enabled by default, but it is on my debian installs.

Quote:
Originally Posted by linustalman View Post
In my home dir, there's a new file called .fehbg
It starts with:
Code:
#!/bin/sh
feh --image-bg black --bg-max ...
Why is the image bg set to black?

It does not seem to change when it should (I set it to every 6 seconds to test it). Also it shows a black background often.
I think .fehbg stores the last feh command, so if feh dies (restart, logout, etc) you can simply run ./.fehbg & to restore your last desktop image. It's pretty convenient, when that's what you want.

I highly recommend reading the man pages for programs you run, when possible. You know, teach a person to fish, etc. Here's a quote from the section on --bg-max:
Quote:
--bg-max
Like --bg-fill, but scale the image to the maximum size that fits the screen with black borders on one side.
Though, I'm not sure why it says "one side". On my image, it does both sides. Huh. Well, anyway.

Since bg-max doesn't fill the entire screen, it has to put something on the sides of the image that don't fill the entire display. If you don't like that sort of letterbox effect, try bg-fill which will zoom in until the image fits the whole screen, or bg-scale which squashes the image into your screen size.

Try things out.
 
Old 07-19-2017, 01:23 PM   #19
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Myk267 View Post
The lazy way is to simply give a plain path to feh.
feh --bg-fill ~/Path/To/Images/
If there are things inside that directory that feh can't read it will error and fail to set an image.

Otherwise, try an extended glob.
feh --bg-fill ~/Path/To/Images/*+(jpg|png)
The glob matches one or more occurrences of the options only, so if there's no jpg files it doesn't supply any of those to feh in the first place. I like this solution, but this nice website http://mywiki.wooledge.org/BashGuide/Patterns informs me that extended globs might not be enabled by default, but it is on my debian installs.


I think .fehbg stores the last feh command, so if feh dies (restart, logout, etc) you can simply run ./.fehbg & to restore your last desktop image. It's pretty convenient, when that's what you want.

I highly recommend reading the man pages for programs you run, when possible. You know, teach a person to fish, etc. Here's a quote from the section on --bg-max:

Though, I'm not sure why it says "one side". On my image, it does both sides. Huh. Well, anyway.

Since bg-max doesn't fill the entire screen, it has to put something on the sides of the image that don't fill the entire display. If you don't like that sort of letterbox effect, try bg-fill which will zoom in until the image fits the whole screen, or bg-scale which squashes the image into your screen size.

Try things out.

Code:
mhsetroot -dcenter 1600x800 image.png

mhsetroot -dtile 300x1400 image.png
resizes your image to fit whatever size you tell it to. from 1x1 to however big your screen is set to.

screenSizeXscreenSize

if you want to tile your images that too takes whatever you give it to max screen size.

1920x1080 original image size displayed at 30x30 tiled with mhsetroot.
Attached Thumbnails
Click image for larger version

Name:	Screenshot_mhsetroot-tile-30x30-2017-07-19_13-31-47.png
Views:	23
Size:	99.5 KB
ID:	25510  

Last edited by BW-userx; 07-19-2017 at 01:36 PM.
 
Old 07-20-2017, 02:47 AM   #20
sbaynes
LQ Newbie
 
Registered: Oct 2014
Posts: 28

Rep: Reputation: Disabled
I don't use a wall paper changer.
 
Old 07-20-2017, 03:55 AM   #21
Trihexagonal
Member
 
Registered: Jul 2017
Posts: 362
Blog Entries: 1

Rep: Reputation: 334Reputation: 334Reputation: 334Reputation: 334
Quote:
Originally Posted by Myk267 View Post
I think .fehbg stores the last feh command...
Correct. Here's mine now:

Code:
!/bin/sh
feh  --bg-scale '/home/trihexagonal/images/green.jpg'
From the man feh page:

Quote:
feh is a mode-based image viewer. It is especially aimed at command line users who need a fast image viewer without huge GUI dependencies, though it can also be started by (graphical) file managers to view an image. By default (unless arguments or a filelist are specified), feh displays all files in the current directory

feh supports filelists, various image sorting modes, image captions, HTTP and more. Configurable keyboard and mouse shortcuts are used to control it.
You set it by right-clicking on the image to choose from File - Background - Set Tiled, Set Scaled, Set Centered, or Set Filled.
 
Old 07-20-2017, 07:39 AM   #22
linustalman
LQ Guru
 
Registered: Mar 2010
Location: Ireland
Distribution: Debian 12 Bookworm
Posts: 5,717

Original Poster
Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
Exclamation

Quote:
Originally Posted by BW-userx View Post
try using the semi-colon it is somewhat of a standard item to indicate a second command, or a separation between commands.

too, sleep defaults to seconds he could have easily put 10m instead of sleep 600
Code:
600/60=10
what feh is lacking is the ability to size the image to the users specifications. The user has to just settle with whatever the people that wrote feh decided on how big or small that image is shown on the desktop.
Code:
--bg-tile FILE
--bg-center FILE
--bg-max FILE
--bg-fill FILE
All of that programming they put into it to get it to do what it does and. that's it. That's all they got for a selection on how to display an image to a screen for background.

mod:
to better anser your question on getting it to use png
Code:
feh -b -z /home/userx/Pictures/vlc-images/ ; sleep 1
but it is only showing the image in a window on my desktop. not as a root image on my desktop.
and seep is not working. ( because that is not actually written properly) just hacking away at this.

but this is my "first" time using this feh in a long time, many years ago I tried it and didn't agree with how they where displaying the image on the back ground (desktop) so I did something about it.

that's better; run this in your command line and change the path to wherever you've got your images at.
Code:
while true ; do feh --bg-max  -z /home/userx/Pictures/vlc-images/*  ; sleep 1; done
The wallpapers are being changed but only a black background is shown. If I click on a blank area of the desktop and hold down and move around - I can see a bit of the wallpaper.
 
Old 07-20-2017, 07:46 AM   #23
linustalman
LQ Guru
 
Registered: Mar 2010
Location: Ireland
Distribution: Debian 12 Bookworm
Posts: 5,717

Original Poster
Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
Post

Quote:
Originally Posted by BW-userx View Post
maybe bad images - try opening them up in gimp and saving over top of them to exporting them and using the exported image to see if that fixes the black image.

never mind you told it too.. gezz
Hi BW-userx.

I'd need to do that with loads of images - not feasable. Anyway I doubt the images are bad as they work fine with Variety.
 
Old 07-20-2017, 08:52 AM   #24
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by linustalman View Post
The wallpapers are being changed but only a black background is shown. If I click on a blank area of the desktop and hold down and move around - I can see a bit of the wallpaper.
so when an image is set to your background, only that sometimes it is black and when you move your mouse pointer around you begin to see some of the image? if yes,
then that sound like a redraw problem. your desktop is not being redrawn properly for whatever reason(s) when it changes images.
 
Old 07-22-2017, 08:16 AM   #25
linustalman
LQ Guru
 
Registered: Mar 2010
Location: Ireland
Distribution: Debian 12 Bookworm
Posts: 5,717

Original Poster
Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
Quote:
Originally Posted by BW-userx View Post
so when an image is set to your background, only that sometimes it is black and when you move your mouse pointer around you begin to see some of the image? if yes,
then that sound like a redraw problem. your desktop is not being redrawn properly for whatever reason(s) when it changes images.
I think I will just stick with Variety - simple and works.
 
Old 08-16-2017, 03:08 PM   #26
Yves.legault
LQ Newbie
 
Registered: Dec 2012
Location: Montreal, Quebec, Canada
Distribution: Debian
Posts: 24

Rep: Reputation: Disabled
Favorite wallpaper changer...

I do not use wallpaper!
 
Old 08-16-2017, 08:52 PM   #27
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Yves.legault View Post
I do not use wallpaper!
mmm bucket of paint?
 
Old 03-22-2018, 10:08 AM   #28
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by linustalman View Post
I think I will just stick with Variety - simple and works.
but can it do things like this using one solid image of any size?
Attached Thumbnails
Click image for larger version

Name:	Screenshot_2018-03-22_10-02-30.png
Views:	28
Size:	152.1 KB
ID:	27247  
 
Old 03-22-2018, 08:41 PM   #29
Nobutarou
Member
 
Registered: May 2017
Posts: 43

Rep: Reputation: Disabled
Code:
xsetroot -solid "#151515"
 
Old 03-23-2018, 08:53 AM   #30
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
For the plain man who doesn’t like frills he just likes to know where his shorts are when he gets up in the morning.

Last edited by BW-userx; 03-23-2018 at 08:54 AM.
 
  


Reply

Tags
auto, wallpaper changer



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Cinammon Wallpaper Changer thund3rstruck Linux - Desktop 1 03-25-2013 08:52 AM
Desktop Wallpaper Changer theunixwizard Linux - Software 12 04-24-2010 02:01 PM
Dynamic wallpaper changer in gnome WhiskeyTangoFoxtrot Linux - Software 1 10-14-2006 12:42 AM
FTP wallpaper changer verbose Linux - Software 0 08-05-2005 09:43 PM
Automated Wallpaper Changer davethegenius Linux - Software 3 04-02-2005 04:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:43 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration