SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#5926 2013-08-12 11:36:46

Nili
#! Die Hard
From: 127.0.0.1
Registered: 2013-03-20
Posts: 811
Website

Re: Conky v1.9 Thread

Thank you very much for your code Sector11


# Debian GNU/Linux 8:8.2 (netinst/stable)
# Packages Installed: 541
# Linux debian 3.16.0-4-686-pae #1 SMP Debian 3.16.7-ckt11-1+deb8u4 (2015-09-19) i686 GNU/Linux
# Startup finished in 2.850s (kernel) + 6.473s (userspace) = 9.324s

Offline

Be excellent to each other!

#5927 2013-08-18 20:14:11

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.9 Thread

Nili wrote:

Thank you very much for your code Sector11

You're welcome.


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#5928 2013-08-18 20:18:50

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.9 Thread

Quite here ... room is getting dusty.

I did some more playing with farinet's Crunchbang conky and Teo's weather.  Larger font and still under 800 pixels in height.

I don't need Swap - I don't have one but it's there anyway and I added the three CPU's I have to the Average.
2013_08_18_16_32_46_1920x1080_Sector11.jpg
... and there we have it.

You'll need Teo's weather: Conky weather scripts using Accuweather/WUnderground/NWS/Weather.com

# killall conky && conky -c /media/5/conky/farinet-2.cb.conky &
###  Begin Window Settings  ##################################################
own_window yes
own_window_type normal
own_window_transparent yes
own_window_hints undecorated,below,skip_taskbar,skip_pager
own_window_class Conky
own_window_title S11
#own_window_colour gray

### ARGB can be used for real transparency
### NOTE that a composite manager is required for real transparency.
### This option will not work as desired (in most cases) in conjunction with
### own_window_type normal
# own_window_argb_visual yes # Options: yes or no

### When ARGB visuals are enabled, this use this to modify the alpha value
### Use: own_window_type normal
### Use: own_window_transparent no
### Valid range is 0-255, where 0 is 0% opacity, and 255 is 100% opacity.
# own_window_argb_value 0

# Use the Xdbe extension? (eliminates flicker)
# It is highly recommended to use own window with this one
# so double buffer won't be so big.
double_buffer yes

minimum_size 280 850	## width, height
maximum_width 280	## width

gap_x 15	### l|r
gap_y 15	### u|d

alignment tl
####################################################  End Window Settings  ###
###  Font Settings  ##########################################################
# Use Xft (anti-aliased font and stuff)
use_xft yes
xftfont Monofur:bold:size=11

# X font when Xft is disabled, you can pick one with program xfontsel
#font 5x7
#font 6x10conky -c /media/5/Conky/S11-Top_Left.conky &
#font 7x13
#font 8x13
#font 9x15
#font *mintsmild.se*
#font -*-*-*-*-*-*-34-*-*-*-*-*-*-*

# Alpha of Xft font. Must be a value at or between 1 and 0 ###
xftalpha 1
# Force UTF8? requires XFT ###
override_utf8_locale yes

uppercase no
######################################################  End Font Settings  ###
###  Color Settings  #########################################################
draw_shades yes #no # amplifies text if yes
default_shade_color 000000

draw_outline no # amplifies text if yes
default_outline_color 000000

default_color DCDCDC #220 220 220 Gainsboro
#default_color C0C0C0 #192 192 192 Silver
#default_color B0E0E6 #176 224 230 PowderBlue
color0 8FBC8F #143 188 143 DarkSeaGreen
color1 778899 #119 136 153 LightSlateGray
color2 B0E0E6 #176 224 230 PowderBlue
color3 9ACD32 #154 205  50 YellowGreen
color4 FFA07A #255 160 122 LightSalmon
color5 FFDEAD #255 222 173 NavajoWhite
color6 00BFFF #  0 191 255 DeepSkyBlue
color7 5F9EA0 # 95 158 160 CadetBlue
color8 BDB76B #189 183 107 DarkKhaki
color9 CD5C5C #205  92  92 IndianRed
#####################################################  End Color Settings  ###
###  Borders Section  ########################################################
draw_borders no
# Stippled borders?
stippled_borders 0
# border margins
border_inner_margin 9
border_outer_margin 0
# border width
border_width 0
# graph borders
draw_graph_borders #no
#default_graph_size 15 40
#####################################################  End Borders Secton  ###
###  Miscellaneous Section  ##################################################
# Boolean value, if true, Conky will be forked to background when started.
background yes

# Adds spaces around certain objects to stop them from moving other things
# around, this only helps if you are using a mono font
# Options: right, left or none
use_spacer none

# Default and Minimum size is 256 - needs more for single commands that
# "call" a lot of text IE: bash scripts
text_buffer_size 256

# Subtract (file system) buffers from used memory?
no_buffers yes

# change GiB to G and MiB to M
short_units yes

# Like it says, ot pads the decimals on % values
# doesn't seem to work since v1.7.1
pad_percents 2

# Imlib2 image cache size, in bytes. Default 4MiB Increase this value if you use
# $image lots. Set to 0 to disable the image cache.

imlib_cache_size 0

#   Maximum size of user text buffer, i.e. layout below TEXT line in config file
#  (default is 16384 bytes)
# max_user_text 16384

# Desired output unit of all objects displaying a temperature. Parameters are
# either "fahrenheit" or "celsius". The default unit is degree Celsius.
# temperature_unit Fahrenheit

##############################################  End Miscellaneous Section  ###
###  LUA Settings  ###########################################################
## Above and After TEXT - requires a composite manager or blinks.
##
# lua_load /media/5/Conky/LUA/draw-bg.lua
#TEXT
# ${lua conky_draw_bg 125 0 0 0 0 0x000000 0.2}
#
## ${lua conky_draw_bg corner_radius x_position y_position width height color alpha}
##
## OR Both above TEXT (No composite manager required - no blinking!)
#
#--------------------------------
#lua_load /media/5/Conky/LUA/draw-bg.lua
#lua_draw_hook_pre draw_bg 20 0 0 0 0 0x000000 0.4
#lua_draw_hook_post draw_bg 20 0 0 0 0 0x000000 0.2
#
# TEXT
# ${lua conky_draw_bg 20 0 0 0 0 0x000000 0.2}
##
#
### mount.lua ################################################################
#
##instructions
##load script
##lua_load ~/path_to/mounted.lua
#  lua_load /media/5/Conky/LUA/mounted.lua
## first lua command below text:
## ${lua get_mounted_data interval}, where interval is a number.  This starts data gathering
## to get output:
## ${lua mount partition_number data_type}, where partition number is a number
## data_type can be
## total - shows total number of partitions mounted, requires a partition_number also, use 1, could be used in an if_match
## fsys - shows filesystem
## size - shows space used in appropriate units
## free - shows free space in appropriate units
## use% - shows % used
## mount - shows mountpoint
### clock_easysid_conkyrc ####################################################
# lua_load /media/5/Conky/LUA/clock_easysid_conkyrc.lua
# lua_draw_hook_pre main
#lua_draw_hook_post main
############################################ End clock_easysid_conkyrc.lua ###
#######################################################  End LUA Settings  ###


update_interval 1

TEXT
${color8}S Y S T E M    I N F O ${color2}${hr}${color}

Host${alignr}${nodename}
Time${alignr}${time %T}
Date${alignr}${time %x}
Uptime${alignr}${uptime}
RAM${alignr}${mem} of ${memmax}
Swap usage${alignr}${swap} of ${swapmax}
Root usage${alignr}${fs_used /} of ${fs_size /}
Home usage${alignr}${fs_used /home} of ${fs_size /home}
CPU usage${alignr}${if_match ${cpu cpu1}<10}${color1}  ${color1}${cpu cpu1}\
${else}${if_match ${cpu cpu1}<100}${color1} ${color7}${cpu cpu1}\
${else}${color9}${cpu cpu1}${endif}${endif}${color}\
 | ${if_match ${cpu cpu2}<10}${color1}  ${color1}${cpu cpu2}\
${else}${if_match ${cpu cpu2}<100}${color1} ${color7}${cpu cpu2}\
${else}${color9}${cpu cpu2}${endif}${endif}${color}\
 | ${if_match ${cpu cpu3}<10}${color1}  ${color1}${cpu cpu3}\
${else}${if_match ${cpu cpu3}<100}${color1} ${color7}${cpu cpu3}\
${else}${color9}${cpu cpu3}${endif}${endif}${color}\
${color} Avg ${color1}${if_match ${cpu cpu0}<10}${color1}  ${color1}${cpu cpu0}\
${else}${if_match ${cpu cpu0}<100}${color1} ${color7}${cpu cpu0}\
${else}${color9}${cpu cpu0}${endif}${endif}${color}
eth0   Up   ${upspeed eth0} ${goto 157}|  Down${alignr}${downspeed eth0}

${color8}S H O R T C U T    K E Y S ${color2}${hr}${color}

Alt+F2${alignr} Run Dialog
Alt+F3${alignr} Alt Menu
Super+Space${alignr} Main Menu
Super+n${alignr} Network Setup
Super+t${alignr} Terminal
Super+f${alignr} File Manager
Super+g${alignr} Editor (Geany)
Super+m${alignr} Media Player
Super+w${alignr} Web Browser
Super+e${alignr} E-Mail
Super+h${alignr} Task Manager
Super+k${alignr} Kalender
Super+l${alignr} Lock Screen
Super+v${alignr} Volume Control
Super+x${alignr} Logout
PrtSc${alignr} Screenshot

${color8}W E A T H E R ${color2}${hr}${color}${execi 600 bash $HOME/1a_accuweather_conkyweather_font/1a}

${goto 50}${color7}CURRENTLY${goto 135}${execpi 600 sed -n '4p' $HOME/1a_accuweather_conkyweather_font/curr_cond}°\
${goto 15}${color1}${font conkyweather:size=20}${execi 600  sed -n '2p' ~/1a_accuweather_conkyweather_font/curr_cond}${font}${color}\
${goto 50}${font Monofur:bold:size=9}${execpi 600 sed -n '3p' $HOME/1a_accuweather_conkyweather_font/curr_cond}${font}

${goto 50}${color7}${execpi 600 sed -n '1p' $HOME/1a_accuweather_conkyweather_font/tod_ton}\
	${goto 185}${execpi 600 sed -n '6p' $HOME/1a_accuweather_conkyweather_font/tod_ton}\
${goto 15}${color1}${font conkyweather:size=20}${execi 600  sed -n '2p' ~/1a_accuweather_conkyweather_font/tod_ton}\
	${goto 150}${execi 600  sed -n '7p' ~/1a_accuweather_conkyweather_font/tod_ton}${font}${color}\
${goto 50}${color9}${execpi 600 sed -n '4p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°${color5}\
 | ${color2}${execpi 600 sed -n '5p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°\
	${goto 185}${color9}${execpi 600 sed -n '9p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°${color5}\
 | ${color2}${execpi 600 sed -n '10p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°

${goto 50}${color7}${execpi 600 sed -n '11p' $HOME/1a_accuweather_conkyweather_font/tod_ton}\
	${goto 185}${execpi 600 sed -n '16p' $HOME/1a_accuweather_conkyweather_font/tod_ton}\
${goto 15}${color1}${font conkyweather:size=20}${execi 600  sed -n '12p' ~/1a_accuweather_conkyweather_font/tod_ton}\
	${goto 150}${execi 600  sed -n '17p' ~/1a_accuweather_conkyweather_font/tod_ton}${font}${color}\
${goto 50}${color9}${execpi 600 sed -n '14p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°${color5}\
 | ${color2}${execpi 600 sed -n '15p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°\
	${goto 185}${color9}${execpi 600 sed -n '19p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°${color5}\
 | ${color2}${execpi 600 sed -n '20p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°

${goto 50}${color7}${execpi 600 sed -n '21p' $HOME/1a_accuweather_conkyweather_font/tod_ton}\
	${goto 185}${color7}${execpi 600 sed -n '1p' $HOME/1a_accuweather_conkyweather_font/last_days}\
${goto 15}${color1}${font conkyweather:size=20}${execi 600  sed -n '22p' ~/1a_accuweather_conkyweather_font/tod_ton}\
	${goto 150}${execi 600  sed -n '2p' ~/1a_accuweather_conkyweather_font/last_days}${font}${color}\
${goto 50}${color9}${execpi 600 sed -n '20p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°${color5}\
 | ${color2}${execpi 600 sed -n '20p' $HOME/1a_accuweather_conkyweather_font/tod_ton}°\
	${goto 185}${color9}${execpi 600 sed -n '4p' $HOME/1a_accuweather_conkyweather_font/last_days}°${color5}\
 | ${color2}${execpi 600 sed -n '5p' $HOME/1a_accuweather_conkyweather_font/last_days}°

${goto 50}${color7}${execpi 600 sed -n '6p' $HOME/1a_accuweather_conkyweather_font/last_days}\
	${goto 185}${color7}${execpi 600 sed -n '11p' $HOME/1a_accuweather_conkyweather_font/last_days}\
${goto 15}${color1}${font conkyweather:size=20}${execi 600  sed -n '7p' ~/1a_accuweather_conkyweather_font/last_days}\
	${goto 150}${execi 600  sed -n '12p' ~/1a_accuweather_conkyweather_font/last_days}${font}${color}\
${goto 50}${color9}${execpi 600 sed -n '9p' $HOME/1a_accuweather_conkyweather_font/last_days}°${color5}\
 | ${color2}${execpi 600 sed -n '10p' $HOME/1a_accuweather_conkyweather_font/last_days}°\
	${goto 185}${color9}${execpi 600 sed -n '14p' $HOME/1a_accuweather_conkyweather_font/last_days}°${color5}\
 | ${color2}${execpi 600 sed -n '15p' $HOME/1a_accuweather_conkyweather_font/last_days}°

${goto 50}${color7}${execpi 600 sed -n '16p' $HOME/1a_accuweather_conkyweather_font/last_days}\
	${goto 185}${color7}${execpi 600 sed -n '21p' $HOME/1a_accuweather_conkyweather_font/last_days}\
${goto 15}${color1}${font conkyweather:size=20}${execi 600  sed -n '17p' ~/1a_accuweather_conkyweather_font/last_days}\
	${goto 150}${execi 600  sed -n '22p' ~/1a_accuweather_conkyweather_font/last_days}${font}${color}\
${goto 50}${color9}${execpi 600 sed -n '19p' $HOME/1a_accuweather_conkyweather_font/last_days}°${color5}\
 | ${color2}${execpi 600 sed -n '20p' $HOME/1a_accuweather_conkyweather_font/last_days}°\
${goto 185}${color9}${execpi 600 sed -n '24p' $HOME/1a_accuweather_conkyweather_font/last_days}°${color5}\
 | ${color2}${execpi 600 sed -n '25p' $HOME/1a_accuweather_conkyweather_font/last_days}°

·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#5929 2013-08-20 18:16:30

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.9 Thread

Brought this here from another thread.

errorist wrote:

Hello !

As comprehensive the docs for conky are, I can't solve the problems I have
since a while.

The first one: Conky refuses to take place where I want it to.
And even worse, it shows a different behaviour, depending on how it gets
started !

The width is 1020 px, and it should sit at the bottom middle of my 1024x768
display, with 2 px margins to the screen edges.

Here is the conkyrc:

background yes
use_xft yes
xftfont Bitstream Vera Sans Mono:size=8
xftalpha 1
update_interval 1.0
total_run_times 0
own_window yes
own_window_type desktop
own_window_transparent yes
own_window_argb_visual no
own_window_argb_value 100
own_window_colour 000063
own_window_hints undecorated,below,sticky,skip_pager,skip_taskbar
double_buffer yes
maximum_width 1020
minimum_size 1020 34
draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no
stippled_borders 0
default_outline_color 0D009F
border_width 1
alignment bottom_middle
gap_x 2
gap_y 2
default_color 000063
no_buffers yes
uppercase no
cpu_avg_samples 1
net_avg_samples 1
override_utf8_locale no
use_spacer right

# Colours
color0 C4C4F8
color1 65A8E9

# Templates
template0 ${font Bitstream Vera Sans Mono:bold:size=8}

TEXT
${image ~/.config/conky/Grafiken/bg_peptide_hard.png}\
${color1}${goto 56}${voffset +12}$uptime_short${voffset -12}\
${goto 142}${voffset +5}${freq 1}Mhz ${goto 196}${cpu cpu1} %\
${goto 264}${color0}${template0}1m    5m   15m ${color1}$font\
${goto 419}${color0}${template0}Mem :${color1}$font\
$memmax${goto 504}${color0}${template0}/${color1}$font${goto 513}$mem\
${color0}${goto 600}${template0}Home:${color1}$font\
${fs_size /home}${color0}${template0}${goto 686}/${goto 695}${color1}$font${fs_free /home}\
${goto 780}$upspeed\
${goto 866}$downspeed\
${voffset +12}${goto 142}${freq 2}Mhz ${goto 196}${cpu cpu2} %${goto 260}$loadavg %\
${color0}${template0}${goto 419}Swap:${color1}$font$swapmax${goto 504}${color0}${template0}/${color1}\
${goto 513}$font$swapfree${color0}${goto 600}${template0}Town:${color1}$font\
${fs_size /town}${color0}${template0}${goto 686}/${goto 695}${color1}$font${fs_free /town}\
${goto 780}$totalup${goto 866}$totaldown

With conkywonky (OB-menu) or the same commands in a term, it has 5px margins
on the left and the bottom edges, leaving the screen on the right side.

Editing and saving the conkyrc leads to a 0px margin on the left side, and
the intended 2px margin on the bottom edge.
And since a while, I have to edit and save the conkyrc 2 times to restart
conky !

The second one: Which settings I have to take for reserving space along the
bottom edge ?

Neighter own_window_type = panel ( Conky at the top edge, with a border ),
nor setting the margins in the OB-rcxml ( Conky above the OB-margin ) are
doing the job.

Where are my mistakes here, has anyone a solution for that ?

Any help is really appreciated !


Cheers,

errorist

Hi errorist.

It seems to be fine here.
I simply started it with: conky -c /media/5/conky/errorist.conky &

I get an error as I don't have the image and I had to change /town to /media/5 to suit my PC but there it is:
2013_08_20_15_11_45_1920x1080_Sector11.jpg

The second one: Which settings I have to take for reserving space along the bottom edge ?

Do you mean screen margin?

In OpenBox » Settings » Openbox » GUI Config Tool » Margins

See image above.

If I didn't understand the problem please ask again.

Last edited by Sector11 (2013-08-20 18:19:05)


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#5930 2013-08-20 20:16:02

chameleon
UK #! Guy
From: Luxembourg
Registered: 2009-01-13
Posts: 719
Website

Re: Conky v1.9 Thread

Calling all conky experts.
I would like to display the contents of this 'now playing' page in conky.

http://www.lounge-radio.com/code/pushed_files/now.html

There is a picture of the album art, artist, album and track.

Does anybody have a cool solution for this?

Thanks in advance for any tips.

Offline

#5931 2013-08-20 20:41:41

arclance
#! Die Hard
Registered: 2012-03-29
Posts: 987

Re: Conky v1.9 Thread

^ The easiest way to do it (if the page does not have something hiding in javascript) is to download the page as html with a program like curl, wget, or using a scripting languages native network api.
Then you can parse the html with a script of some kind (bash, python, Lua, etc.) to get the information you want to display in conky delivered to it in a format it can understand.
In this case you would also need to grab the url of the album art from the page and download it separately to get the image file.

You have to be careful doing this so that downloading the page does not cause conky to freeze until it is done.
You also want to limit how often you check the page with the script or you could get your IP address banned from the site.

There are two was to do that.

1. Have the script that updates from the page be run at a set interval (either by leaving it running as a loop that sleeps until it should start again or using cron) and write its result out to a text file and image file that can be read by a conky function or lua script.

2. Use ${texeci} or os.execute to run the script that updates from the page at a set interval and read the resulting text and image file in every update with another conky or lua function.
  You can send the text data directly to ${texeci} if you don't want ${execpi} style formating in the output.

Last edited by arclance (2013-08-20 20:55:13)

Offline

#5932 2013-08-20 20:48:14

chameleon
UK #! Guy
From: Luxembourg
Registered: 2009-01-13
Posts: 719
Website

Re: Conky v1.9 Thread

@arclance
Thanks for taking the time to outline a strategy to achieve this.
My scripting skills are quite limited so I am still looking for a basic solution from someone for me to build on.

Thanks again for your input.

Offline

#5933 2013-08-20 21:33:56

errorist
#! CrunchBanger
Registered: 2012-05-24
Posts: 100

Re: Conky v1.9 Thread

@Sector11 : Thanks for spending your time with this.

I : Here is the Conky after 2 times editing and saving the conkyrc
( after the first edit & save there is no restart since a while ):

2013_08_20_1377031176_1024x768_scrot.jpg

It should have a gap_x = 2 at both vertical edges ( also beeing middled
at the bottom ), with a gap_y = 2, which it likes to follow when restarted
through edit & save.

With commandline, I get 5px left and bottom gaps.

The image has exactly the 1020px width, like the conky.

What is it that makes it positioned incorrectly ?

And why do I have to edit & save 2 times to get conky restarted ?

II : Yes, the screen margin is meant. Regardless, whether I set it in the
OB-rcxml or with Obconf, Conky behaves like other windows, beeing displayed
above the margin.

With own_window_type = panel there should be a margin set automatically,
but that doesn't work.
Conky then appears at the top screen edge, with no gaps, but a border !

How can I save Conky from getting covered by other windows ?


Cheers,

errorist

Last edited by errorist (2013-08-21 17:24:34)

Offline

#5934 2013-08-21 00:16:55

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.9 Thread

errorist wrote:

@Sector11 : Thanks for spending your time with this.

First: Thumbnails:
2013_08_20_1377031176_1024x768_scrot.jpg
While looking at your image below it I see:

free image hosting | image search | show codes | report abuse or request deletion

I clicked on show codes and: Forum BB Code (1)
2013_08_20_21_04_54_1920x1080_Sector11.jpg

Just after uploading an image choose: Thumbnail for Forums (2)

Can you upload the image you use please to make it more complete and I'll try your conky again.

Also try this little test:

Open the ~/.conkyrc and save it as: /myconky

Then in a terminal:

killall conky && conky -c ~/myconky

Do you have the same problem?

EDIT:  BTW; don't just edit and save, do:

killallconky && conky

Last edited by Sector11 (2013-08-21 00:22:39)


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#5935 2013-08-21 03:01:34

PackRat
#! Die Hard
From: USA
Registered: 2011-03-03
Posts: 1,572

Re: Conky v1.9 Thread

@errorist -

I think you need to edit the ${image -} part of your conkyrc to specify the position and scale - see the documentation

so this -

${image ~/.config/conky/Grafiken/bg_peptide_hard.png}\

will look like -

${image ~/.config/conky/Grafiken/bg_peptide_hard.png -p 0,0 -s 1220xHeight} \

without specifying the position and scale, I think your image is (layman's terms here) getting misplaced and dragging the conky window with it. I have had issues with background images in the past - mainly a position of 0,0 not actually coinciding with the upper left corner of the conky window.

Last edited by PackRat (2013-08-21 03:03:03)


"It does not require many words to speak the truth." - Chief Joseph, Nez Perce tribe

Offline

#5936 2013-08-21 03:58:23

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.9 Thread

@ PackRat

Actually size and position are optional:
Takes 4 optional arguments: a position, a size, a no-cache switch, and a cache flush interval.

By not using size or position the ${image /path/to/image.png} will use the image at full size and put it at 0,0.

Where you may have seen a problem is if you used:
A - One of these:
border_inner_margin 0
border_outer_margin 0
border_width 0
- - with a values greater than 0, or

B - an image with a slight transparent edge around it

Putting an image that is say 500x500 in a conky that is:

maximum_width 400
${image /path/to/500.png}
will only show the left most 400 pixels of that image.

Sample: conky set to 210x210 with a 1920x1080 wallpaper:

2013_08_21_00_49_01_1920x1080_Sector11.jpg

and with the full wallpaper:
2013_08_21_00_49_55_1920x1080_Sector11.jpg


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#5937 2013-08-21 10:54:49

Naik
#! Die Hard
From: Leipzig
Registered: 2012-11-16
Posts: 595

Re: Conky v1.9 Thread

@ chameleon:

save following script as loungeradio.sh wherever you want and make it executable:

#!/bin/bash
#pulling info from loung-radio.com for conky

wget http://www.lounge-radio.com/code/pushed_files/now.html -O ~/loungeradio.html >/dev/null 2>&1 &&

artist=$(awk '/id="artist"/{getline; print}' ~/loungeradio.html | sed "s/<div>\|<\/div>//g")
album=$(awk '/id="album"/{getline; print}' ~/loungeradio.html | sed "s/<div>\|<\/div>//g")
track=$(awk '/id="track"/{getline; print}' ~/loungeradio.html | sed "s/<div>\|<\/div>//g")

###image-ripping doesn`t work for me due to prohibition - uncomment the next 3 lines to give it a try
#img-src=$(awk '/id="covercontainer"/{print}' ~/loungeradio.html | sed -r 's/.*src="(.*)" width=.*/\1/')
#wget http://www.lounge-radio.com/code/pushed_files/$img-scr -O ~/loungradio.jpg>/dev/null 2>&1 &&
#echo '${img ~/loungeradio.jpg -p 42,42 -s 123x123 }' 

echo 'Artist:' $artist;
echo 'Track:' $track;
echo 'Album:' $album;

exit

and call it in conky via

${execi 42 /path/to/loungeradio.sh}

where "/path/to/" needs to be the path to the script and "42" is the interval in which this will be repeated (in seconds).

as you see there will be no image! as i uderstood i am simply not allowed to save it to my hdd but maybe i made some other mistake?
'---> calling the rest here for solutions.
is conky capable of showing images direktly from the web?

hope this helped -naik

Last edited by Naik (2013-08-21 10:55:50)


*kaum macht man es richtig, funktioniert es sofort*

Offline

#5938 2013-08-21 12:46:41

chameleon
UK #! Guy
From: Luxembourg
Registered: 2009-01-13
Posts: 719
Website

Re: Conky v1.9 Thread

@ Naik

Thansk so much for the input.
Yes, this does work to print out Atist,track and album  cool

However, this is the errror I get regarding saving an image;

Conky: desktop window (266) is root window
Conky: window type - override
Conky: drawing to created window (0x1e00001)
Conky: drawing to double buffer
/home/neil/loungeradio.sh: line 11: img-src=playlist_sam342/az_B6239811_hefner: No such file or directory

A jpeg is stored in my home folder of 0bytes.

Close....

Offline

#5939 2013-08-21 13:07:50

Naik
#! Die Hard
From: Leipzig
Registered: 2012-11-16
Posts: 595

Re: Conky v1.9 Thread

^ok, i played a little more and i think you could try this script instead!


*kaum macht man es richtig, funktioniert es sofort*

Offline

#5940 2013-08-21 14:25:24

PackRat
#! Die Hard
From: USA
Registered: 2011-03-03
Posts: 1,572

Re: Conky v1.9 Thread

@Sector11 - yes, I know they are optional; however, in the past, if I didn't set the image position and the other variables you mention, I've had alignment issues.

What I forgot to ask errorist is - how does the conky align if he doesn't use the image? I tried it without the image and it looked fine on my system, just like it did on yours.

Last edited by PackRat (2013-08-21 14:27:17)


"It does not require many words to speak the truth." - Chief Joseph, Nez Perce tribe

Offline

#5941 2013-08-21 14:45:52

chameleon
UK #! Guy
From: Luxembourg
Registered: 2009-01-13
Posts: 719
Website

Re: Conky v1.9 Thread

@Naik
This is getting exciting!
The image is now updating in my home folder...However, the image does not appear in conky.
Artist,track and album text are present.

conky says;
${image ~/loungeradio.jpg -p 42,42 -s 123x123}

but no image................

Last edited by chameleon (2013-08-21 14:49:21)

Offline

#5942 2013-08-21 16:36:29

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.9 Thread

PackRat wrote:

@Sector11 - yes, I know they are optional; however, in the past, if I didn't set the image position and the other variables you mention, I've had alignment issues.

What I forgot to ask errorist is - how does the conky align if he doesn't use the image? I tried it without the image and it looked fine on my system, just like it did on yours.

conky is getting more temperamental in the past year or so.  I've never had problems with images ... so I'll make myself a note that you have, probably others, and try to be  more aware.

That's why I asked for the image, because without it, it seems to be working as advertised here.  Need to eliminate all possibles.


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#5943 2013-08-21 17:58:48

errorist
#! CrunchBanger
Registered: 2012-05-24
Posts: 100

Re: Conky v1.9 Thread

First, thumbnail issue now solved. Was in a hurry posting the image, so
I forgot to disable NoScripts restrictions.

And here is the Conky image :

https://www.dropbox.com/s/sr0g7tok3g46k … e_hard.png


Partly, I've solved the positioning problem.

I changed "alignment bottom_middle" to "alignment bottom", and now at least
with edit&save Conky is well placed.

The pure bottom alignment is not documented in my Conky configuration settings
manual, maybe out of date.

But I have to edit&save once, nothing happens, and then edit&save the second
time, then Conky gets restarted correctly.

With either Conkywonky or the same command directly in the terminal, the
behaviour is the same as before:

At the left screen edge a 5px gap, cutting Conky at the right screen edge.

At the bottom screen edge also a 5px gap.

There are actually 2 different positioning schemes, one for the (double)
edit&save, the other for invocation through commandline or script.


Preserving the screen space, where conky is placed, does still not work.

Just saw your new posts, will test it without the image soon.


The Conky position is the same with or without the image.

2013_08_21_1377108548_553x679_scrot.jpg

I deleted the complete line with the image command.

Any other suggestion ?

Last edited by errorist (2013-08-21 18:21:07)

Offline

#5944 2013-08-21 18:31:44

Naik
#! Die Hard
From: Leipzig
Registered: 2012-11-16
Posts: 595

Re: Conky v1.9 Thread

@chameleon:

EDIT: updated the script on pastebin
just add this lines to your conky:

${execi 13 ~/scripts/loungeradio.sh}
${image ~/.loungeradio -p 130,342 -s 36x36}

remember to edit the path of the script and the positioning of your picture and it should work!

greetz -naik

Last edited by Naik (2013-08-21 18:54:19)


*kaum macht man es richtig, funktioniert es sofort*

Offline

#5945 2013-08-21 18:55:08

arclance
#! Die Hard
Registered: 2012-03-29
Posts: 987

Re: Conky v1.9 Thread

^ You should set "imlib_cache_size" to "0" in your .conkyrc if you want images to update when the file changes.

imlib_cache_size
    Imlib2 image cache size, in bytes. Defaults to 4MiB. Increase this value if you use $image lots. Set to 0 to disable the image cache.

You can also try adding a "-n" to your ${image} command but I seem to remember than not being as reliable as "imlib_cache size 0".

image     <path to image> (-p x,y) (-s WxH) (-n) (-f interval)
    ... If you specify the no-cache flag (-n), the image will not be cached. ...

Last edited by arclance (2013-08-21 18:55:35)

Offline

#5946 2013-08-21 18:57:52

Naik
#! Die Hard
From: Leipzig
Registered: 2012-11-16
Posts: 595

Re: Conky v1.9 Thread

^ah... forgot about that! thanks arclance! +1


*kaum macht man es richtig, funktioniert es sofort*

Offline

#5947 2013-08-21 19:22:04

chameleon
UK #! Guy
From: Luxembourg
Registered: 2009-01-13
Posts: 719
Website

Re: Conky v1.9 Thread

2013_08_21_211936_1920x1080_scrot.jpg

I have an image in conky...waiting for an update...
What is the exact command for imlib_cache size 0 ?

Thanks Guys so far you are STARS  yikes

EDIT:
imlib_cache_size 0


waiting for an update...lounge radio can go on and on and on........

Last edited by chameleon (2013-08-21 19:29:53)

Offline

#5948 2013-08-21 19:27:36

arclance
#! Die Hard
Registered: 2012-03-29
Posts: 987

Re: Conky v1.9 Thread

^ You just put "imlib_cache size 0" in the configuration section at the top of your .conkyrc above the "TEXT" section (where you have "gap_x", "gap_y", etc.).
Then kill and restart your conky to make sure the configuration change is properly used by conky.

Offline

#5949 2013-08-21 19:30:52

chameleon
UK #! Guy
From: Luxembourg
Registered: 2009-01-13
Posts: 719
Website

Re: Conky v1.9 Thread

@arclance
Thanks... I was a bit slow...keep u posted guys.....

Offline

Be excellent to each other!

#5950 2013-08-21 19:32:40

PackRat
#! Die Hard
From: USA
Registered: 2011-03-03
Posts: 1,572

Re: Conky v1.9 Thread

^ it's not a command, it's a setting above the TEXT

edit - I too am a bit slow on the keyboard  8o

Last edited by PackRat (2013-08-21 19:35:25)


"It does not require many words to speak the truth." - Chief Joseph, Nez Perce tribe

Offline

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: acrobat

Debian Logo