Help with Conky Customization Pls

So, I've managed to customize most of my conky HUD to my liking, but am having 2 issues. Hoping someone with more experience may be able to help.

@Aravisian

Here is the desktop:

1st issue is:
I can't get the Internal IP address to display inline. It will only show on the next line no matter what I do. Even if I remove the word "Internal IP and use a single character, it still defaults to the line below.

iplg

Here is the snippet of code:

${color}External IP: ${exec curl -s www.icanhazip.com}
${color}Internal IP: ${if_existing /proc/net/route eth0}

Is there any way to fix this? I'm baffled.

2nd Issue
Is there any way to change the color of live cpu usage and data transfer boxes ?(the white and blue inside showing usage, not the box itself) Which file? It doesn't seem to be called from the widget script.

Eg:

Here is the code

xftfont Agency FB:size=10
xftalpha 0.8
text_buffer_size 2048
update_interval 5.0
total_run_times 0
own_window yes
own_window_type normal
own_window_transparent no
own_window_hints undecorated,below,sticky,skip_taskbar
double_buffer yes
minimum_size 600 900
maximum_width 250
draw_shades no
draw_outline no
draw_borders no
stippled_borders 0
default_color 808169
color1 8F64A0
color2 D14DB3
color3 8F64A0
default_shade_color black
default_outline_color 808169
own_window_colour 000000
alignment middle_right
gap_x 0
gap_y 0
no_buffers yes
uppercase no
cpu_avg_samples 2
net_avg_samples 2
override_utf8_locale yes
use_spacer none

own_window_argb_visual yes
own_window_argb_value 0 

Really appreciate the help!

Yes, we can solve both issues.
It would be a lot easier on me if I have the full conky that I can load and tease out while running it.
Can you provide that (you can use pastebin.com)

Changing the color of elements is very easy - you can see in your snippet

default_color 808169
color1 8F64A0
color2 D14DB3
color3 8F64A0
default_shade_color black
default_outline_color 808169

You can define as many colors as you want, really... So you can add a color4 or a color5... Or alter one of the existing ones.
Once you have the colors defined as above, you can use the tag ${color(NUMBER)} in front of each and any element you wish to define a distinct color for.
For example;

${color}External IP: ${color3}${exec curl -s www.icanhazip.com}
${color}Internal IP: ${color1}${if_existing /proc/net/route eth0}
1 Like

Hi Aravisian, thanks for the reply!

The total file size for this conky is 43 MB. Best just to give you the direct link where I got it from.

Maybe I did not explain this well.

I'm pretty versed with Conky and know how to change/add color elements as I have already fully customized it.

The elements you are quoting in the script only change font color and line color. I want to change the color of the live feed inside these boxes (the white and blue). Not the box outline.

I cannot find where in Conky this live feed is being being formatted for color as it is not defined in the widget itself.

As for the Internal IP inline issue, I'll wait for you to install the conky to see if you can find what strange magic is forcing it onto the next line.

May the force be with you, lol.

Yes, the example I gave was merely an example.
The color is set for the output the same way.
As another example from my own conky:
${alignr}${color1}[${color} ${fs_bar 5,120 /} ${color1}]${color}
Default
conk1

Color change
conk2

1 Like

Gotchya... okay. So, based on your example I tried this :

${color}[${color2}${cpugraph cpu1 12,250 D6E8F2 14345B -l} ${color}]

But it didn't work. It just produced this pink outline...
pink

What did I do wrong?

It's usage as at one percent. I don't see any output to compare the color too.

I think that you can use ${color1 color2} With color1 being the outline for the graph and color2 being the graph...

Sorry, poor example.

I edited this...

${color}Inbound ${alignr} ${downspeed wlp4s0} kb/s
${color}[${color2}${downspeedgraph wlp4s0 10,250 D6E8F2 14345B -t} $[color}]${color}

But again, it only added a pink outline (which I don't want) while the live feed is still white and blue (which I want pink). Because there are 2 colors in that feed, I really think it is being formatted somewhere else in Conky outside of this widget script, but for the life of me can't find where.

When I added
${color color2}${downspeedgraph wlp4s0 10,250 D6E8F2 14345B -t}

I still got just a pink outline
whitefeed

ummm...
Are these: D6E8F2 14345B Hex Colors?

1 Like

Hahaha! OMG you mad genius!! Yes, they were. I couldn't see the forest through the trees.

It's working perfectly now! Girly pink, just the way I wanted.
fixed

Thank you!

Just need to fix this last issue with the alignment if possible... if you're willing. SO appreciate your help. :purple_heart:
iplg

PS: tried just commenting out the one line for Internal IP but when I do, this script won't run. It breaks the conky.

1 Like

Can you try:

${color}External IP: ${exec curl -s www.icanhazip.com}
${color}Internal IP:${if_existing /proc/net/route eth0}

Ya, nope. That's a fail.

...is a lotta stuff...

Which conky are you actually using?

It's a ridiculous amount of stuff. I only wanted the one widget. I extracted that folder into my .conky folder.

I believe it is just conky. Used: sudo apt install conky-all
And am running Conky Manager 2.72

Is it this one?

EDIT: Pretty sure it is... I grabbed the script itself and created a new conky on mine named tinks-test
and sure enough... the Internal IP: line is dropping down one line on mine, too.
I'm working on solving...

Try removing the white noise;

${color4}Network:  ${hr 1}
${color}External IP: ${exec curl -s www.icanhazip.com}
${color}Internal IP: ${if_existing /proc/net/route eth0}
_______________This space here____________
Inbound ${alignr}${downspeed eth0}kb/s
${downspeedgraph eth0 10,250 242424 101115 -t}
Outbound ${alignr}${upspeed eth0}kb/s
${upspeedgraph eth0 10,250 242424 101115 -t}
${else}
${addr eth0}${color3}  WLAN${color}

So that it looks like

${color4}Network:  ${hr 1}
${color}External IP: ${exec curl -s www.icanhazip.com}
${color}Internal IP: ${if_existing /proc/net/route eth0}
Inbound ${alignr}${downspeed eth0}kb/s
${downspeedgraph eth0 10,250 242424 101115 -t}
Outbound ${alignr}${upspeed eth0}kb/s
${upspeedgraph eth0 10,250 242424 101115 -t}
${else}
${addr eth0}${color3}  WLAN${color}
1 Like

This is what i use:
${if_match "${addr eno1}"!="No Address"}${addr eno1}

The whole Section

${color1}${font Font Awesome 6 Free:style=Solid:pixelsize=13}${font}${goto 30}Network

${font Font Awesome 6 Free:style=Solid:pixelsize=13}${font}${goto 30}${if_match "${addr eno1}"!="No Address"}${addr eno1}${endif}${if_match "${addr wlp5s0}"!="No Address"}${addr wlp5s0}${endif}${alignr}${font Font Awesome 6 Free:style=Solid:pixelsize=13} ${font} ${execi 3600 curl ipinfo.io/ip}
${if_match "${addr eno1}"!="No Address"}${color1}${font Font Awesome 6 Free:style=Solid:pixelsize=13}${font}${goto 30}${downspeedf eno1}k/s (${totaldown eno1})${alignr}${font Font Awesome 6 Free:style=Solid:pixelsize=13} ${font} ${upspeedf eno1}k/s (${totalup eno1})${endif}
${if_match "${addr wlp5s0}"!="No Address"}${color1}${font Font Awesome 6 Free:style=Solid:pixelsize=13}${font}${goto 30}${downspeedf wlp5s0}k/s (${totaldown wlp5s0})${alignr}${font Font Awesome 6 Free:style=Solid:pixelsize=13} ${font} ${upspeedf wlp5s0}k/s (${totalup wlp5s0})${endif}

Screenshot from 2022-10-11 16-58-07

Weird, as soon as I did that the internal ip address disappeared and it now says no address: WLAN
noaddress

I literally removed the one line of space, nothing more.
More frustrating is that I cannot just comment it out to hide it. The entire script breaks. I really only need the external ip.

I'm about to give up.

@seanhinkley thanks for the reply. Really appreciate it. :slightly_smiling_face:

The issue isn't with what code to use. It's about it not displaying in alignment.

Your set up looks great but it isn't quite how I want mine displayed. I don't know enough about code to piece your code into this script.

Try

${color}Internal IP: ${voffset -1}${alignr}${if_existing /proc/net/route eth0}${voffset 1}

$voffset is vertical offset so you're saying move this up one line, alignr is right align this is so it doesn't appear over the internal Ip text then we are adding a vertical offset back down so it doesn't offset everything else in the script further on