[solved] dwm + conky + mpd

I have the following .conkyrc:
background no
out_to_console yes
update_interval 2
total_run_times 0
use_spacer none
TEXT
$if_mpd_playing ^i(/home/hithere/.dwm/dzen/xbm8x8/note.xbm) ${mpd_smart}$endif • ^i(/home/hithere/.dwm/dzen/xbm8x8/cpu.xbm) ${cpu}% • ^i(/home/hithere/.dwm/dzen/xbm8x8/mem.xbm) ${memperc}% • ^i(/home/hithere/.dwm/dzen/xbm8x8/fs_01.xbm) /sda1: ${fs_used_perc /}% | /sda2: ${fs_used_perc /home}% • ^i(/home/hithere/.dwm/dzen/xbm8x8/net_down_03.xbm) ${downspeedf eth0} ^i(/home/hithere/.dwm/dzen/xbm8x8/net_up_03.xbm) ${upspeedf eth0} • ^fg(\#696969)${time %H:%M}^fg()
When I play a music file via ncmpc++, the conky display gets shifted to the right, thus hiding my download/upload speeds, clock, etc. Is there a way to anchor my conky display information and have mpd fill the music file information to the left?
Last edited by ntness (2010-05-30 06:13:38)

Ok, played with -x and -w a bit. Increasing -w truncates the clock/up and down speed/drive information (apparently shifting things off the screen to the right). Decreasing -w truncates almost everything and shifts the code towards the center of the screen. The same holds for increasing and decreasing the value of -x; increasing shifts everything to the right (off screen) and decreasing shifts everything towards the center (albeit, with no truncation). Now I'm positive this would all work out merrily if I had my cpu information in the top left and so could put the mpd code at the end of my file

Similar Messages

  • [SOLVED] dwm + dzen2 + conky-cli misconfigured

    I have been trying to pipe conky status to dzen2 and it is doing my head in.
    My .xinitrc
    #!/bin/sh
    # ~/.xinitrc
    setxkbmap -option terminate:ctrl_alt_bksp &
    eval `cat ~/.fehbg` &
    numlockx &
    xscreensaver -no-splash &
    # Dzen & conky
    conky | dzen2 -fg '#dcdcdc' -bg '#3f3f3f' -ta r -fn '-*-terminus-*-r-normal-*-*-120-*-*-*-*-iso8859-*' &
    # Start dwm
    exec ck-launch-session ~/Scripts/dwm-start
    .conkyrc
    background no
    out_to_console yes
    update_interval 2
    total_run_times 0
    use_spacer none
    double_buffer yes
    TEXT
    ${if_existing /sys/class/power_supply/BAT0/present}^fg(#999999)BAT^fg()${battery_percent}%${else}AC${endif} * CPU ${cpu cpu1}% RAM ${memperc}% * / ${fs_used_perc /}% /home ${fs_used_perc /home}% * PKG ${execpi 900 ~/Scripts/pacman-up.pl} * ${if_existing /proc/net/route ra0}Down ${downspeedf ra0}K/s Up ${upspeedf ra0}K/s ${else} ${if_existing /proc/net/route eth0} Down ${downspeedf ra0}K/s Up ${upspeedf ra0}K/s${endif} ${endif}* ${time %I:%M%P}
    Start dwm script
    conky | while read line; do
    xsetroot -name "$line";
    done | while true; do
    dwm > /dev/null; done;
    Could anyone point me at what I am doing wrong? I have tried following examples in the forums, including this one and this one -- but I either end up with dwm 5.7.2 in the corner, or conky prints out the ^fg etc...
    Any help would be appreciated at this point...
    Last edited by jasonwryan (2009-11-20 06:11:51)

    Thanks for the suggestions Skanky. The broken line in conky was a copy/paste error into the browser - it is a single line conky (I've edited the OP to reflect that).
    I think it is a problem with the way conky-cli and dzen work together. If I run:
    echo "testing" | dzen2 -fg '#dcdcdc' -bg '#3f3f3f' -ta r -fn '-*-terminus-*-r-normal-*-*-120-*-*-*-*-iso8859-*' -p
    it prints as expected.
    Similarly, if I comment the conky | dzen2 line in .xinintrc and just run conky-cli from the start script it works...
    Trying to get then to work together, however, is another matter.
    /edit
    Some progress: it seems that it is being drawn - if I Mod-Shift-q the dwm status bar briefly disappears and I can see conky momentarily. I tried starting conky | dzen2 after dwm but that didn't work.
    I have also added some options, which seem to have helped, my .xinintrc entry now looks like:
    conky | dzen2 -x '500' -e '' -fg '#dcdcdc' -bg '#3f3f3f' -ta r -fn '-*-terminus-*-r-normal-*-*-120-*-*-*-*-iso8859-*' -p &
    Last edited by jasonwryan (2009-11-19 16:57:13)

  • [SOLVED]Compton, Conky and RXVT-Unicode not playing nicely

    Hello. I'm having some problems making my desktop how I want it. My window manager is fluxbox.
    First problem is just a minor inconvenience, but annoying. When I login, a transparent terminal spawns to my specification, but it is skewed.
    http://i.imgur.com/hrEEh3H.jpg
    However, as soon as I open any window it fixes itself
    http://i.imgur.com/WXQZ9e3.jpg
    Second problem is that I can't figure out how to remove the shadow under conky. I know that it is coming from the slit, but it just won't go away. I can get it to go away if I set conky to desktop instead of panel, but then when I launch any window it overlaps with the conky bar, and that is unaceptable. Maybe there is a fluxbox configuration option that reserves some space so nothing can overlap it? But I couldn't find anything.
    Here are the config files I think are relevant:
    .Xdefaults:
    urxvt*.transparent:true
    urxvt*scrollBar:false
    urxvt*borderLess:true
    urxvt*foreground:blue
    urxvt*.highlightColor: yellow
    urxvt*.colorUL: #4682B4
    urxvt*.cursorBlink: 1
    urxvt*font: xft:Terminus:pixelsize=12
    urxvt*.perl-ext-common: default,matcher,tabbedex,readline,clipboard
    urxvt*.url-launcher: /usr/bin/firefox
    urxvt*.matcher.button: 1
    URxvt.tabbed.autohide:true
    .conkyrc:
    #avoid flicker
    double_buffer yes
    #own window to run simultanious 2 or more conkys
    own_window yes
    own_window_transparent yes
    own_window_class conky
    own_window_type panel
    own_window_hints undecorate,above,sticky,skip_taskbar,skip_pager
    #borders
    draw_borders no
    #shades
    draw_shades no
    #position
    gap_x 6
    gap_y 6
    alignment top_left
    #behaviour
    update_interval 1
    #colour
    default_color 8f8f8f
    wn_window_colour 262626
    #font
    use_xft yes
    xftfont terminus:pixelsize=10
    #to prevent window from moving
    use_spacer left
    minimum_size 1600 0
    short_units yes
    pad_percents 2
    #mpd
    #mpd_host localhost
    #mpd_port 6600
    imap localhost [email protected] xxxxxxx -i 120
    #color = e0e0e0
    TEXT
    ${voffset -1} Cpu: ${color 000000}${font}${cpu}% ${color} Mem: ${color 000000}${font}${mem} ${color} | ${color} Uptime: ${color 000000}${font}${uptime_short}${color} | ${color} Download Speed: ${color 000000}${font}${downspeed wlp0s26u1u4}/s ${color}Total Downloaded: ${color 000000}${totaldown wlp0s26u1u4} ${color} | ${color} Upload Speed: ${color 000000}${upspeed wlp0s26u1u4}/s ${color} Total Uploaded: ${color 000000}${totalup wlp0s26u1u4} ${color} | ${color}Root: ${color 000000}${font}${fs_free /} ${color} Home: ${color 000000}${font}${fs_free /home} ${color} | ${color} Arch-pkg: ${color 000000}${font}${execi 300 perl /home/lucas/.scripts/conky-updates.pl}${color} | Email: ${color 000000}${imap_unseen} new messages ${color} | ${color} Weather: ${color 000000} ${weather http://weather.noaa.gov/pub/data/observations/metar/stations/ SBBR temperature}°C ${color}
    .compton
    shadow = true;
    no-dnd-shadow = true;
    no-dock-shadow = true;
    clear-shadow = true;
    shadow-radius = 7;
    shadow-offset-x = -7;
    shadow-offset-y = -7;
    shadow-exclude = [ "name = 'Notification'", "class_g = 'URxvt'", "class_g = 'Conky'", "class_g ?= 'Notify-osd'", "class_g = 'Cairo-clock'" ];
    shadow-ignore-shaped = false;
    # Opacity
    menu-opacity = 0.8;
    inactive-opacity = 0.8;
    frame-opacity = 0.7;
    inactive-opacity-override = false;
    alpha-step = 0.06;
    blur-kern = "3x3box"
    blur-background-exclude = [ "window_type = 'dock'", "window_type = 'desktop'" ];
    opacity-rule = [ ]
    # Fading
    fading = true;
    fade-in-step = 0.03;
    fade-out-step = 0.03;
    fade-exclude = [ ];
    # Other
    backend = "glx"
    mark-wmwin-focused = true;
    mark-ovredir-focused = true;
    detect-rounded-corners = true;
    detect-client-opacity = true;
    refresh-rate = 0;
    vsync = "opengl-swc";
    dbe = false;
    paint-on-overlay = true;
    focus-exclude = [ "class_g = 'Cairo-clock'" ];
    detect-transient = true;
    detect-client-leader = true;
    invert-color-include = [ ];
    # GLX backend
    glx-no-stencil = true;
    glx-copy-from-front = false;
    glx-no-rebind-pixmap = true;
    glx-swap-method = "undefined";
    # Window type settings
    wintypes:
    tooltip = { fade = true; shadow = false; opacity = 0.75; focus = true; };
    Last edited by Chetyre (2014-04-10 16:51:23)

    using lowercase conky in compton doesn't change anything. I'm pretty sure that shadow is not from conky, but from the slit. When I set the slit to autohide in the init file, the shadow hides as well. And there is no shadow in any other conky window type I've tried, except type panel. Unfortunately, it is the only one so far with the behavior I want.
    I would like to use true transparency in urxvrt, since that does solve the skew issue and I think it looks better. However, in doing so the terminal is quite useless since there is a lot of text that I can't see, because the font becomes the same color as certain backgrounds. Unless there is a way to separate it? I want it to look like the one on the left (left = fake transparency, right = true transparency).
    http://i.imgur.com/lUwk4F4.jpg
    Last edited by Chetyre (2014-04-09 02:50:27)

  • [SOLVED] dwm-status.sh, possible to include scripts within the script?

    I have 'dwm-status.sh' printing some basic info (mpd, vol, date) into the status bar. Is it possible to make it include eg. gmail, weather, and battery scripts in a similar way that conky would? (execpi 60 python ~/.scripts/gmail.py)
    Also, off topic: How can I see which other special characters represent which icons in Ohsnap font? e.g. "Ñ" "Î" "¨" "¹" "ê" "í" "È represent cpu, memory, hdd, vol, clock.... how about the rest?
    dwm-status.sh:
    #!/bin/sh
    icons=("Ñ" "Î" "¨" "¹" "ê" "í" "È")
    getMusic() {
    msc="$(ncmpcpp --now-playing '{%a - %t}|{%f}')"
    if [ ! $msc ]; then
    echo -ne "\x0A${icons[4]}\x01 music off"
    else
    echo -ne "\x0A${icons[4]}\x01 ${msc}"
    fi
    getVolume() {
    vol="$(amixer get Master | egrep -o "[0-9]+%" | head -1 | egrep -o "[0-9]*")"
    echo -ne "\x0A${icons[5]}\x01 ${vol}"
    getDate() {
    dte="$(date '+%b %d %a')"
    echo -ne "\x0A${icons[1]}\x01 ${dte}"
    getTime() {
    tme="$(date '+ %H:%M')"
    echo -ne "\x0A${icons[6]}\x01 ${tme}"
    while true; do
    xsetroot -name "$(getMusic) $(getVolume) $(getDate) $(getTime)"
    sleep 1
    done
    Last edited by Winston-Wolfe (2013-06-26 13:10:11)

    Thanks guys, I've managed to get my notification scripts printing by simply not using execpi:
    getMail() {
    mai="$(~/.scripts/gmail.py)"
    echo -ne "\x0A${icons[3]}\x01 ${mai}"
    But like you said, I now have a calling frequency challenge.
    Trilby, that looks great. I've got it partially working, but I'm at a loss on how to go about printing the variables in the loop for those blocks that happen periodically.
    otherwise your email indicator (for example) will only pop up for one second every 5 minutes.
    ^ exactly what's currently happening.
    Is there something that just prints the variable without calling for an update like $(getMail) does that I could put into the loop?
    let loop=0
    while true; do
    # stuff that happens every second here
    xsetroot -name "$(getMusic) $(getVolume) $(getDate) $(getTime)"
    if [[ $loop%60 -eq 0 ]]; then
    #stuff that happens every minute here
    xsetroot -name "$(getMusic) $(getMail) $(getVolume) $(getDate) $(getTime)"
    fi
    if [[ $loop%300 -eq 0 ]]; then
    # stuff that happens every 5 minutes here
    xsetroot -name "$(getMusic) $(getMail) $(getWeather) $(getVolume) $(getDate) $(getTime)"
    let loop=0 #this prevents an eventual overflow
    fi
    let loop=$loop+1
    sleep 1
    done
    Last edited by Winston-Wolfe (2013-06-26 08:54:47)

  • [SOLVED] [dwm] Can't start dwm

    Hi!
    I've recently entered the world of tiling WM and started with dwm.
    Since I'm kinda insecure, and wanted to keep gnome as well, I've followed every single step in the wiki article and used the ~/.Xclients way, so I could start dwm from gdm (I've followed also the steps in the discussion page as well).
    Then, when I tried to startup dwm from gdm, it doesn't start, and goes back again to gdm.
    My ~/.Xclients file is the following:
    setxkbmap -layout pt
    #relogio
    while true; do
    xsetroot -name "$( date +"%F %R" )"
    sleep 1m # Update time every minute
    done &
    # #estado da bateria
    # while true; do
    # batt=$(LC_ALL=C acpi -b)
    # case $batt in
    # *Discharging*)
    # batt="${batt#* * * }"
    # batt="${batt%%, *} "
    # batt=""
    # esac
    # xsetroot -name "$batt$(date +%R)"
    # sleep 60
    # done &
    #conky bar
    conky | while read -r; do xsetroot -name "$REPLY"; done &
    #executar o dwm
    exec dwm
    It's all things copied from the wiki page, just for testing if everything was fine...
    My /usr/share/xsessions/dwm.desktop file is:
    [Desktop Entry]
    Encoding=UTF-8
    Name=Dwm
    Comment=Dynamic window manager
    Exec=/usr/local/bin/dwm
    Icon=dwm
    Type=XSession
    And I've created a /usr/share/xsessions/user.desktop file that looks like this:
    [Desktop Entry]
    Encoding=UTF-8
    Name=User XSession script
    Comment=Runs your ~./Xsession script
    Exec=/etc/X11/Xsession
    Type=Application
    Thanks in advance for any help, I've searched the forums and used google and couldn't find any answer to this problem :S
    Last edited by Aeriel (2011-09-01 17:19:02)

    haxit, thanks I've managed to solve the problem!
    I've installed SLiM and set up everything in .xinitrc.
    The dwm.desktop doesn't match with yours because I've changed somethings and because I didn't backup the file (I know, it's super dumb and stupid) I had to paste the defaults I found in the web.
    Thanks.
    Fellow gdm and dwm users, an advice, put everything in .xinitrc. It's easier.
    Last edited by Aeriel (2011-09-01 17:19:30)

  • Conky+MPD remotely

    I'm trying to connect to my desktop computers MPD with laptop's conky.
    Everything work great, but I don't know how to check, if MDP is running on my desktop computer.
    Locally I check it like this: "${if_running mpd}", but I don't know how it works remotely.

    I've solved my problem after extensive goolging, and here is the line in .conkyrc, should anyone else need it.
    ${if_match "${mpd_status}" =="Playing"}$mpd_smart $else${mpd_status}$endif\
    This only displays the Artist and Title of the song if it is PLAYING, if it's paused or stopped, it will display so respectively.

  • [SOLVED!] Conky won't run undecorated, please assist.

    Greetings,
    As suggested in my other thread, I have been working on customizing a conky script that simply shows the time, date, calendar, current weather, and forecast, and I have completed it.
    However I have ran into a problem. Up until I basically had it completed, it would run fine undecorated without any window borders and the like. But now it won't, and it laughs at me instead. If I want to see my conky, I have to have it decorated in the window border, which is a pain and something I don't want. I want it to simply blend in with my desktop.
    Anyways, I am hoping someone can help me solve this. I know it runs. If I set it to decorate, it pops up, info and all. If I set it to undecorate, it laughs at me, but shows up lxtask and htop.
    Here's my .conkyrc
    # Use Xft?
    use_xft yes
    xftfont cure:size=6
    # Update interval in seconds
    update_interval 1
    # This is the number of times Conky will update before quitting.
    # Set to zero to run forever.
    total_run_times 0
    # Create own window instead of using desktop (required in nautilus)
    own_window yes
    own_window_transparent yes
    own_window_type widget
    own_window_hints undecorate,sticky,above,skip_taskbar,skip_pager
    # Use double buffering (reduces flicker, may not work for everyone)
    double_buffer yes
    # Minimum size of text area
    minimum_size 280 5
    maximum_width 187
    # Draw shades?
    draw_shades no
    # Draw outlines?
    draw_outline no
    # Draw borders around text
    draw_borders no
    # Stippled borders?
    stippled_borders 0
    # border margins
    border_margin 5
    # border width
    border_width 0
    # Default colors and also border colors
    default_color 4d4d4d
    #default_shade_color white
    #default_outline_color black
    own_window_colour 262626
    # Text alignment, other possible values are commented
    alignment top_left
    #alignment top_right
    #alignment bottom_left
    #alignment bottom_right
    # Gap between borders of screen and text
    # same thing as passing -x at command line
    gap_x 1180
    gap_y 24
    # Subtract file system buffers from used memory?
    no_buffers yes
    # set to yes if you want all text to be in uppercase
    uppercase no
    # number of cpu samples to average
    # set to 1 to disable averaging
    cpu_avg_samples 2
    # number of net samples to average
    # set to 1 to disable averaging
    net_avg_samples 2
    # Force UTF8? note that UTF8 support required XFT
    override_utf8_locale yes
    # Add spaces to keep things from moving about? This only affects certain objects.
    use_spacer yes
    #Email:
    #${pop3_unseen **SERVER NAME** **USERNAME** **PASSWORD**} new messages
    TEXT
    ${offset 100}${alignc}${font openlogos-archupdate:size=40}${color blue}B${font}${color}
    ${color FFFFFF}${font DejaVu Sans:style=Bold:pixelsize=25}${alignc}${time %r}${font Snap.se:size=8}
    ${color FFFFFF}${alignr}${time %A, %B %e %G}
    ${color FFFFFF}${font Aerial:style=Bold:pixelsize=12}CALENDAR${font Snap.se:size=8}${hr 1}
    ${color FFFFFF}${font DejaVu Sans Mono :size=12}${pre_exec cal}
    ${color FFFFFF}${font DejaVu Sans Mono :size=6}${pre_exec cal -3 | cut -c23-44 --complement}
    ${color FFFFFF}${font Aerial:style=Bold:pixelsize=12}WEATHER${font Snap.se:size=8}${hr 1}
    ${color FFFFFF}${alignr 43}${font DejaVu Sans:size=12}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=CN}${font}
    ${color FFFFFF}${alignr 43}${font Weather:size=46}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=WF -i}${font}
    ${color EE6363}${voffset -30}${font Aerial:style=Bold:pixelsize=12}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=HT -i}${font}
    ${color 00A54E}Low: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=LT -i --startday=1 --endday=1} ${font DejaVu Sans Mono:size=6}» ${font}${alignr}${color 00A54E}High: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=HT -i --startday=1 --endday=1}
    ${color 00AEED}Conditions: ${color FFFFFF}${alignr}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=CC -i}
    ${color 00AEED}Wind: ${color FFFFFF}${alignr}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=WS -i}
    ${color 00AEED}Humidity: ${color FFFFFF}${alignr}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=HM -i}
    ${color 00AEED}Chance of Precipitation: ${color FFFFFF}${alignr}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=PC -i}
    ${color FAF519}Sun Rise: ${color FFFFFF}}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=SR -i --startday=1 --endday=1} ${font DejaVu Sans Mono:size=6}» ${font}${alignr}${color FAF519}Sun Set:${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=SS -i --startday=1 --endday=1}
    ${color FFFFFF}${font Aerial:style=Bold:pixelsize=12}FORECAST${font Snap.se:size=8}${hr 1}
    ${color FF0000}${alignr}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=DW -i --startday=1 --endday=1}
    ${color 00A54E}Low: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=LT -i --startday=2 --endday=2} ${font DejaVu Sans Mono:size=6}» ${font}${alignr}${color 00A54E}High: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=HT -i --startday=2 --endday=2}
    ${color FAF519}Sun Rise: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=SR -i --startday=2 --endday=2} ${font DejaVu Sans Mono:size=6}» ${font}${alignr}${color FAF519}Sun Set:${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=SS -i --startday=2 --endday=2}
    ${color FF0000}${alignr}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=DW -i --startday=2 --endday=2}
    ${color 00A54E}Low: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=LT -i --startday=3 --endday=3} ${font DejaVu Sans Mono:size=6}» ${font}${alignr}${color 00A54E}High: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=HT -i --startday=3 --endday=3}
    ${color FAF519}Sun Rise: ${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=SR -i --startday=3 --endday=3} ${font DejaVu Sans Mono:size=6}» ${font}${alignr}${color FAF519}Sun Set:${color FFFFFF}${execi 3600 python ~/scripts/conkyForecast.py --location=USOH0311 --datatype=SS -i --startday=3 --endday=3}
    Again, all I need help with is having it run undecorated without any window decoration. I am running Fluxbox as my WM. If you need any other info, please let me know. Thanks.
    Last edited by mythus (2009-04-25 01:02:23)

    Yes that works! Thanks!
    About the widget; I used Sid's conky script from the conky screenshot as my base, it was the first conky I had tried. Though I only ended up keeping the forecast portion after editing it massively...
    I think it must have been the own_window_hints throwing me off.

  • [SOLVED]Lose Conky window shadows...

    I have Xfce set to display shadows under windows, which looks great until I run Conky.  Any tips on how I can get rid of Conky's shadow and keep the rest?
    Last edited by crisnoh (2008-05-04 20:16:06)

    You most likely can solve this with the correct combination of the own_window and own_window_type parameters in your .conkyrc file. While I don't use XFCE I believe this problem is the same under most compositors. Try the following to solve the problem:
    own_window yes
    own_window_transparent yes
    own_window_type desktop
    If this doesn't work, you might try using "override" for the own_window_type.
    Good luck,
    j

  • [SOLVED]Getting Conky to display Chinese

    How do I get my conky to display Chinese? I have some Chinese songs and the mpd thing in conky just shows the artist's names as boxes. I have scim pinyin installed, by the way.
    Also, on pypanel, it won't display the chinese fonts as well, though it displays the words correctly on the sonata program and title itself.
    Last edited by zephyrus17 (2008-10-15 14:46:35)

    It didn't work. Chinese fonts are still showing boxes and special characters. Here's my conkyrc, just for reference, with the mpd part at the bottom.
    ###Configuration###
    # maintain spacing between certain elements
    use_spacer right
    # set to yes if you want conky to be forked in the background
    background yes
    use_xft yes
    override_utf8_locale no
    # Xft font when Xft is enabled
    xftfont Sans-12
    #xftfont DejaVu Sans-8
    #xftfont wenquanyi-zenhei:size=8
    #xftfont DejaVu Sans Mono-8
    #xftfont Bitstream Vera Sans Mono:size=8
    #xftfont Andale Mono-9
    #xftfont Clean-8
    #xftfont cubicfive10:pixelsize=9
    #xftfont squaredance10:pixelsize=14
    #xftfont swf!t_v02:pixelsize=10
    # Text alpha when using Xft
    xftalpha 1
    mail_spool $MAIL
    # Update interval in seconds
    update_interval 1
    # Create own window instead of using desktop (required in nautilus)
    own_window yes
    own_window_transparent yes
    own_window_type override
    own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
    # Use double buffering (reduces flicker, may not work for everyone)
    double_buffer yes
    # Minimum size of text area
    #minimum_size 1200 0
    #maximum_width 1490
    # Draw shadows for the text?
    draw_shades yes
    # Draw outlines that amplifies text?
    draw_outline no
    # Draw borders around text
    draw_borders no
    # Stippled borders?
    stippled_borders 0
    # border margins
    border_margin 0
    # border width
    border_width 0
    # Default colors and also border colors, grey90 == #e5e5e5
    default_color white
    default_shade_color black
    default_outline_color DarkGrey
    color3 white
    color1 black
    color2 888888 #dark grey
    color3 CECECE #white-ish
    # Text alignment, other possible values are commented
    alignment tm
    #alignment top_left
    alignment top_right
    #alignment bottom_left
    #alignment bottom_right
    #alignment middle_right
    #alignment bottom_left
    # Gap between borders of screen and text
    gap_x 25
    gap_y 60
    # Subtract file system buffers from used memory?
    no_buffers yes
    # set to yes if you want all text to be in uppercase
    uppercase no
    short_units 1
    ###End of configuration###
    # stuff after 'TEXT' will be formatted on screen
    TEXT
    ${font bulletballs aoe:size=17}b$font ${user_names}@$nodename
    ${font stylebats:size=17}2$font ${uptime}
    ${font stylebats:size=17}y$font ${battery_percent}%
    ${font stylebats:size=17}q$font ${ibm_temps 0}C
    ${font stylebats:size=17}p$font ${cpu cpu0}%
    ${font stylebats:size=17}h$font $memperc%
    ${font pizzadude bullets:size=17}r$font ${fs_used /}/ ${fs_size}
    ${font pizzadude bullets:size=17}z$font ${fs_used /home}/ ${fs_size /home}
    ${font pizzadude bullets:size=17}N$font ${upspeed eth0}kb/s
    ${font pizzadude bullets:size=17}T$font ${downspeed eth0}kb/s
    ${font WenQuanYi Zenhei:size=10}${mpd_artist}$font
    Last edited by zephyrus17 (2008-10-14 11:01:05)

  • [solved]DWM apply systray patch

    [solved]I am trying to appply the systray6.1 patch to dwm. The "patch" goes fine but when I make I get the below errors:
        dwm build options:
        CFLAGS   = -std=c99 -pedantic -Wall -Wno-deprecated-declarations -Os -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=2     -DVERSION="6.1" -DXINERAMA
        LDFLAGS  = -s -L/usr/X11R6/lib -lX11 -lXinerama -lfontconfig -lXft
        CC       = cc
        CC drw.c
        CC dwm.c
        dwm.c: In function ‘clientmessage’:
        dwm.c:589:26: error: incompatible types when assigning to type ‘long unsigned int’ from type ‘XftColor’
        swa.background_pixel  = scheme[SchemeNorm].bg->rgb;
                              ^
        dwm.c: In function ‘updatesystray’:
        dwm.c:2221:18: error: incompatible type for argument 9 of ‘XCreateSimpleWindow’
       systray->win = XCreateSimpleWindow(dpy, root, x, m->by, w, bh, 0, 0, scheme[SchemeSel].bg->rgb);
                      ^
        In file included from dwm.c:36:0:
        /usr/include/X11/Xlib.h:1621:15: note: expected ‘long unsigned int’ but argument is of type ‘XftColor’
        extern Window XCreateSimpleWindow(
                   ^
        dwm.c:2224:24: error: incompatible types when assigning to type ‘long unsigned int’ from type ‘XftColor’
        wa.background_pixel  = scheme[SchemeNorm].bg->rgb;
                            ^
        dwm.c:2244:24: error: incompatible types when assigning to type ‘long unsigned int’ from type ‘XftColor’
        wa.background_pixel  = scheme[SchemeNorm].bg->rgb;
                            ^
        dwm.c:2263:2: error: incompatible type for argument 3 of ‘XSetForeground’
        XSetForeground(dpy, drw->gc, scheme[SchemeNorm].bg->rgb);
        ^
        In file included from dwm.c:36:0:
        /usr/include/X11/Xlib.h:3227:12: note: expected ‘long unsigned int’ but argument is of type ‘XftColor’
         extern int XSetForeground(
                ^
        Makefile:18: recipe for target 'dwm.o' failed
        make: *** [dwm.o] Error 1
    I haven't applied any other patches. Any idea what I am doing wrong? I can go into dwm.c and see the lines the error is refering to but I am not sure what the problem is.
    Thanks
    Last edited by derrickcope (2015-05-01 02:30:45)

    I just got the latest one off of the repo at git.suckless.org/dwm. the page says 6.0 but my config.mk says version 6.1. I did try the 6.0 version but the patch had errors. I am a little confused. The other patches come back with errors too. I am using an unpatched version at the moment so I would think most patches should work.
    What should I do?

  • [SOLVED] DWM+pertag+bstack error

    hi
    i'm trying to compile dwm with pertag diff patch and bstack.c
    i get an error while compiling it:
    CC dwm.c
    In file included from config.h:42,
    from dwm.c:254:
    bstack.c: En la función 'bstack':
    bstack.c:7: error: puntero deferenciado a tipo de dato incompletoº
    bstack.c:11:error:puntero..
    make: *** [dwm.o] Error 1
    ==> ERROR: Falló la compilación.ª
    Abortando...
    º means: dereference pointer to incomplete data type
    ª means: Compilation failed.
    it sucks 'cos i want to read pdf on top of my 10" screen and write documents at bottom, without the problem of change to another desktop and have to move to another layout, i.e., floating for gimp
    another thing: for write this post i must to write the code manually, 'cos a don't know how to copy from urxvt and paste it to firefox.. yep, that's a newbie question
    Edit: solved here
    Last edited by kismet010 (2010-02-08 05:51:09)

    Looks like this workaround isn't enough to get it to compile on the latest hg clone.
    dwm build options:
    CFLAGS = -std=c99 -pedantic -Wall -Os -I. -I/usr/include -I/usr/include/X11 -DVERSION="5.8" -DXINERAMA
    LDFLAGS = -s -L/usr/lib -lc -L/usr/lib/X11 -lX11 -L/usr/lib/X11 -lXinerama
    CC = cc
    CC dwm.c
    dwm.c: In function 'gaplessgrid':
    dwm.c:262: error: dereferencing pointer to incomplete type
    dwm.c:276: error: dereferencing pointer to incomplete type
    dwm.c:276: error: dereferencing pointer to incomplete type
    dwm.c:279: error: dereferencing pointer to incomplete type
    dwm.c:282: error: dereferencing pointer to incomplete type
    dwm.c:282: error: dereferencing pointer to incomplete type
    dwm.c:283: error: dereferencing pointer to incomplete type
    dwm.c:284: error: dereferencing pointer to incomplete type
    make: *** [dwm.o] Error 1
    Line 262 for me is:
    for(n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next))
    I've tried many things and maybe i'm missing something very simple here.

  • [SOLVED] dwm: cannot open mixer

    I've been setting up dwm through the last hours and I had an issue with sound playback. Firstly, I can play any sound from the console or any other wm. The problem appears when I start dwm by using xinit but loading it through gdm seems to solve the problem but still I'm not satisfied with that solution. I think that gdm do something in order to grant access to the sound card but on the other hand I still have another problem with multiple running applications that playback sound, only the first opened application can.
    After starting dwm with xinit I get "amixer: Mixer attach default error: No such file or directory" and by running alsamixer I get "cannot open mixer: No such file or directory".
    Thanks in advance
    Last edited by russo (2011-06-20 04:01:15)

    Well, I checked those posts.
    /dev/mixer exists
    I tried to load the snd-pcm-oss but nothing changed.
    However I noticed that I can run alsamixer as root. I'm not sure but maybe having to run gdm as root while running xinit as user made the difference but still it doesn't make sense since I can run openbox with xinit and everything works fine. I'll keep trying
    EDIT: Finally, I tried to load openbox through xinit and had the same problem. Next I tried to reboot removing gdm from the daemons and start dwm directly with the xinitrc options. Now it seems to work fine. Maybe gdm blocked the sound card once it opened.
    Last edited by russo (2011-06-20 04:00:56)

  • [SOLVED]dwm bars

    I have some questions about dwm configuration. First of all how can I move the dwm bar to the bottom and make a new bar at the top where I can put my conky system monitor.
    Like how this guy did it with his nice plain desktop:
    Last edited by zowki (2009-06-19 15:55:55)

    I got conky to be rendered as a window thanks to your .conkyrc tip but I still can't get dwm to make that bottom gap.
    I tried "sh = DisplayHeight(dpy, screen) - BOTTOM_BAR_HEIGHT;" and defined BOTTOM_BAR_HEIGHT to 15 in config.h but it still didnt work.
    Edit:
    I have been doing some more hunting. Could any of these be the right variable?
    static int sx, sy, sw, sh; /* X display screen geometry x, y, width, height */
    static int by, bh, blw; /* bar geometry y, height and layout symbol width */
    static int wx, wy, ww, wh; /* window area geometry x, y, width, height, bar excluded */
    Edit 2:
    I FINALLY DID IT! It was in the updategeom() function. I did this:
    wh = showbar ? info[i].height - bh - BOTTOM_BAR_HEIGHT : info[i].height;
    Thank you guys for all your help!
    Last edited by zowki (2009-06-19 14:22:11)

  • [SOLVED]DWM using 100% cpu

    Does anyone know why DWM is eating 100% of my cpu ALL the time?
    I installed it as per instruction via the wiki, added a simple comky script and that's it. When I startx the cpu is maxed out. My laptop shut down once because of this.
    .xinitrc
    #!/bin/sh
    # ~/.xinitrc
    # Executed by startx (run your window manager from here)
    if [ -d /etc/X11/xinit/xinitrc.d ]; then
    for f in /etc/X11/xinit/xinitrc.d/*; do
    [ -x "$f" ] && . "$f"
    done
    unset f
    fi
    # exec gnome-session
    # exec startkde
    # exec startxfce4
    # ...or the Window Manager of your choice
    ## OpenBox Desktop
    #exec ck-launch-session dbus-launch openbox-session
    ## DWM Desktop
    feh --bg-scale /home/n1x4/images/wallpaper.jpg
    #conky | while read -r; do xsetroot -name "$REPLY"; done &
    conky -x 0 -y 0 -d
    while true
    do
    xsetroot -name "$(date +"%a %b %d %r")"
    done &
    wmname LG3D
    exec ck-launch-session dbus-launch dwm
    .conkyrc
    own_window yes
    own_window_type override
    own_window_colour 000000
    own_window_transparent no
    own_window_hints undecorated below sticky skip_taskbar skip_pager
    double_buffer yes
    cpu_avg_samples 2
    net_avg_samples 2
    use_xft no
    xftfont Terminus:size=8
    update_interval 0.1
    minimum_size 1280 10
    maximum_width 1280
    border_margin 4
    border_width 1
    draw_outline no
    default_color white
    alignment bottom_left
    use_spacer right
    no_buffers yes
    uppercase no
    TEXT
    ${alignc}$nodename ${color #0100ff}Uptime:${color white} $uptime ${color #0077ff}| CPU:${color #0077ff} ${color white}${cpu}%${freq}${color #0077ff} | FS: ${color lightgrey}${fs_used /}/${fs_size /}${color #0077ff} | /home: ${color lightgrey}${fs_used /home}/${fs_size /home}${color #0077ff} | RAM: ${color white}$mem ${color #0077ff}| Network:${color white} ${wireless_essid wlan0} ${color #0077ff}| Down: ${color white}${downspeed wlan0} ${color #0077ff}| Up: ${color white}${upspeed wlan0} ${color #0077ff}| Battery: ${color white}${battery BAT1} ${battery_time BAT1} ${color #0077ff}| Volume:${color white} ${exec amixer get Master | egrep -o "[0-9]+%" | head -1 | egrep -o "[0-9]*"}%
    Anything else you all would like to see please let me know.
    Thanks
    Last edited by n1x4 (2012-02-26 03:03:01)

    I thought that was what you were talking about. I never actually used that line before.. I added it then I changed my xsetroot setting and it clashed so i just commented it out.
    I just wrote a new pipe line and tested it. Same deal.
    Thanks for the advice man, I actually just copied the conkyrc from a user on here, i have also tested my personal conky scripts and they all (4) have the same issue but work fine on OpenBox. I'll go through and edit and play around with this and see if anything helps.
    I appreciate your time man, much abliged.
    .xinitrc conky pipeline
    conky | while true; do -x 0 -y 0 -d; sleep 1m; done &
    Screenshot of conky(new code) with 11% cpu usage.
    http://dl.dropbox.com/u/58127896/2012-0 … _scrot.png

  • [Solved] dwm status bar

    I am learning about DWM...slowly...
    So, I have conky piped to dzen2 as per the screenshot;
    But how do I now remove the 'dwm-6.0' from the status bar?
    Thanks for your patience.
    Last edited by ancleessen4 (2013-04-13 11:05:17)

    dzconky;
    #!/bin/sh
    FG='#aaaaaa'
    BG='#333333'
    FONT='-*-inconsolata-*-r-normal-*-*-90-*-*-*-*-iso8859-*'
    conky | dzen2 -e - -h '14' -w '1100' -ta r -x '750' -fg $FG -bg $BG -fn $FONT &
    conky;
    out_to_console yes
    #out_to_x no
    background no
    update_interval 2
    total_run_times 0
    use_spacer none
    TEXT
    #Arch 64 :: $kernel :: $uptime_short :: ^fg(\#60B48A)$mpd_smart ^fg():: ${cpu cpu1}% / ${cpu cpu2}% :: cpu0 ${execi 5 sensors | grep "Core 0" | cut -d "+" -f2 | cut -c1-2}C cpu1 ${execi 5 sensors | grep "Core 1" | cut -d "+" -f2 | cut -c1-2}C :: ^fg(\#DC8CC3)$memperc% ($mem) ^fg():: ${downspeed enp0s20} ${upspeed enp0s20} :: ${time %a %b %d %H:%M}
    $kernel :: Updates: ${if_match ${execi 1800 (checkupdates | wc -l)} == 0}${color2}up to date${color}${else}${color3}${execi 1800 (checkupdates | wc -l)} new packages${color}${endif} :: ^fg(\#60B48A)$mpd_smart ^fg():: ^fg(\#DC8CC3)$memperc% = $mem ^fg():: ${time %H:%M} :: ^fg(\#8CD0D3)${execi 300 /home/neil/bin/weather.sh "EUR|LU|LU001|Luxembourg"}
    I have tried changing '-x' and '-w' but no change to the layout...
    Just tried to recompile with '-x=850'...to try and push dzen output to the right but no change...
    makepkg -efi --skipinteg
    I am sure this is a simple solution that I am missing...

Maybe you are looking for

  • Mac mail headers appearing as gibberish

    My mac mail headers are suddenly appearing as gibberish. This happened to me once before and I think it had something to do with suitcase and helvetica fractions but I cannot remember how to fix it. I don't seem to have helvetica fractions turned on

  • New MacBook-How to move some files from Old iBook

    Hello All ... I just got a new MacBook and I would like to move a few things over from my old iBook. Mostly I need all my mail stuff and be able to connect to the internet and such. The rest would be files, pictures and other documents ... What would

  • HT200158 How do you to access Microsoft windows 7 files systems from OSX mountain lion

    http://support.apple.com/kb/HT4697 describes how to enable access to Microsoft windows file systems from an OSX lion system. Mountain lion does not have this entry. Now that I have a mac with Mountain LIon installed, how do acces the files on a Micro

  • Deplyoment - MS CRM connection by Javascript & HTML

    Hello everybody, I would love for my project work a small mobile client build (PhoneGap) which connects to the CRM and can read me a few records. Has anyone ever done this? I would be enough the part with connecting to the CRM and read a record. Than

  • Oracle form based authentication

    can anyone tell me how to do the simple form-based authentication with IIS in OAM10g ??? pls Edited by: 859749 on May 19, 2011 4:32 AM