Page 50 of 58 FirstFirst ... 404849505152 ... LastLast
Results 491 to 500 of 572

Thread: Conky Rhythmbox Python Script

  1. #491
    Join Date
    Sep 2010
    Location
    Aotearoa
    Beans
    59

    Re: Conky Rhythmbox Python Script

    Now I get no cover art. I used the latest deb and sudo cp to get that .py into /usr/share/conkyrhythmbox, I then logged out and back in, that was all.
    When rhythmbox gets the coverart it seems to take it from the folder of the current song, so long as it matches the artist and album in the metadata in the music file.

    If it helps here is my conky, it is 1.8.0 (I think)

    Code:
    # Create own window instead of using desktop (required in nautilus)
    own_window no
    own_window_hints undecorated,below,skip_taskbar
    background no
    maximum_width 300
    
    ####
    ## Default sizes
    #
    default_bar_size 200 6
    
    ####
    ## Force images to redraw when they change.
    #
    imlib_cache_size 0
    
    # Use double buffering (reduces flicker, may not work for everyone)
    double_buffer yes
    
    # fiddle with window
    use_spacer right
    use_xft yes
    
    # Update interval in seconds
    update_interval 1.0
    
    # Minimum size of text area
    minimum_size 300 5
    
    # Draw shades?
    draw_shades yes
    
    # Text stuff
    draw_outline no # amplifies text if yes
    draw_borders no
    
    uppercase no # set to yes if you want all text to be in uppercase
    
    # Stippled borders?
    stippled_borders 8
    
    # border margins
    border_margin 4
    
    # border width
    border_width 1
    
    # Default colors and also border colors, grey90 == #e5e5e5
    default_color white
    default_shade_color black
    default_outline_color white
    
    own_window_colour brown
    own_window_transparent yes
    
    # 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
    gap_x 960
    gap_y 40
    
    # stuff after 'TEXT' will be formatted on screen
    
    override_utf8_locale
    xftfont Terminus:size=8
    xftalpha 0.8
    
    #lua_load /home/linus/scripts/.draw_bg.lua
    #lua_load /home/vehemoth/.conky/bargraph_small.lua
    ##lua_load /home/vehemoth/.conky/bargraph_small2.lua
    #lua_draw_hook_pre draw_bg
    ##lua_draw_hook_post main_bars
    
    TEXT
    ${image /home/vehemoth/.conky/debian.png -p 25,5}
    ${voffset -6}${offset 205}${color d60651}${font Terminus:size=30}6.0
    ${voffset -25}${offset 60}${color grey}${font Terminus:size=8.3}THE UNIVERSAL OPERATING SYSTEM
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}System${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${color slate grey}Kern:${color }$kernel
    ${voffset -13}${offset 150}${color slate grey}UpTime: ${color }$uptime
    ${color slate grey}Domain Name:${color }$nodename
    ${voffset -13}${offset 150}${color slate grey}SysName: ${color }$sysname
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}Processors${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${color slate grey}CPU:${color } $cpu%
    ${voffset -13}${offset 80}${color}${freq}MHz
    ${voffset -13}${offset 136}${color slate grey}Core 1:${color }${cpu cpu1}%
    ${voffset -13}${offset 220}${color slate grey}Core 2:${color }${cpu cpu2}%
    ${cpugraph 20,130 000000 ffffff}  ${color }${cpugraph cpu1 20,78 000000 ffffff}  ${color }${cpugraph cpu2 20,78 000000 ffffff}
    ${color slate grey}Processes:${color }$processes
    ${voffset -13}${offset 130}${color slate grey}Running:${color }$running_processes
    ${voffset -13}${offset 220}${color slate grey}Threads:${color }$running_threads
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}Memory${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${color slate grey}MEM:  ${color } $memperc% $mem/$memmax
    ${membar 3,100}
    ${voffset -26}${offset 164}${color slate grey}SWAP:  ${color }$swapperc% $swap/$swapmax
    ${offset 164}${swapbar 3,100}
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}HDD${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${color slate grey}ROOT:    ${color }${fs_free /}/${fs_size /}
    ${fs_bar 3,100 /}
    ${voffset -26}${offset 164}${color slate grey}HOME:  ${color }${fs_free /home}/${fs_size /home}
    ${offset 164}${fs_bar 3,100 /home}
    
    ${color slate grey}Disk I/O:${color }${diskio}
    ${voffset -13}${offset 136}${color slate grey}I/R:${color }${diskio_read}
    ${voffset -13}${offset 220}${color slate grey}O/W:${color }${diskio_write}
    ${diskiograph 20,130 000000 ffffff}  ${diskiograph_read 20,78 000000 ffffff}  ${diskiograph_write 20,78 000000 ffffff}
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}Top Processes${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${color slate grey}Highest CPU:
    ${color ddaa00} ${top name 1}
    ${color lightgrey} ${top name 2}
    ${color lightgrey} ${top name 3}
    ${color lightgrey} ${top name 4}
    ${voffset -52}${offset 105}${color ddaa00}${top cpu 1}
    ${offset 105}${color lightgrey}${top cpu 2}
    ${offset 105}${color lightgrey}${top cpu 3}
    ${offset 105}${color lightgrey}${top cpu 4}
    
    ${voffset -78}${offset 145}${color slate grey}Highest MEM:
    ${offset 145}${color ddaa00} ${top_mem name 1}
    ${offset 145}${color lightgrey} ${top_mem name 2}
    ${offset 145}${color lightgrey} ${top_mem name 3}
    ${offset 145}${color lightgrey} ${top_mem name 4}
    ${voffset -52}${offset 270}${color ddaa00}${top_mem mem 1}
    ${offset 270}${color lightgrey}${top_mem mem 2}
    ${offset 270}${color lightgrey}${top_mem mem 3}
    ${offset 270}${color lightgrey}${top_mem mem 4}
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}Network${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${color slate grey}Internal IP: ${color}${addr eth0}
    ${voffset -13}${offset 152}${color slate grey}External IP: ${color }${execi 3600 /home/vehemoth/.conky/wan.sh}
    ${color slate grey}Up: ${color }${upspeed eth0}
    ${voffset -13}${offset 152}${color slate grey}Down: ${color }${downspeed eth0}
    ${color}${upspeedgraph eth0 20,146 000000 ffffff}  ${downspeedgraph eth0 20,146 000000 ffffff}
    ${color slate grey}Connections:${color }${tcp_portmon 1 32767 count} in / ${tcp_portmon 32768 61000 count} out ${alignr} ${color slate grey}Service/Port:${color}
    ${voffset 5}${tcp_portmon 1 65535 rhost 0} ${alignr} ${tcp_portmon 1 65535 rservice 0} ${color ddaa00}${tcp_portmon 1 65535 rport 0}${color}
    ${tcp_portmon 1 65535 rhost 1} ${alignr} ${tcp_portmon 1 65535 rservice 1} ${color ddaa00}${tcp_portmon 1 65535 rport 1}${color}
    ${tcp_portmon 1 65535 rhost 2} ${alignr} ${tcp_portmon 1 65535 rservice 2} ${color ddaa00}${tcp_portmon 1 65535 rport 2}${color}
    ${tcp_portmon 1 65535 rhost 3} ${alignr} ${tcp_portmon 1 65535 rservice 3} ${color ddaa00}${tcp_portmon 1 65535 rport 3}${color}
    ${tcp_portmon 1 65535 rhost 4} ${alignr} ${tcp_portmon 1 65535 rservice 4} ${color ddaa00}${tcp_portmon 1 65535 rport 4}${color}
    
    ${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}Time${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    ${voffset -4}${font Terminus:size=32}${color3}${if_match ${time %l}<=9}${alignc 7}${time %l:%M%p}${else}${if_match ${time %l}>=10}${alignc -1}${time %l:%M%p}${endif}${endif}${font}
    ${font :size=10}${voffset 3}${alignc}${color ddaa00}${time %a,}${time %e %B %G}${voffset -15}
    
    ##################
    ##  RHYTHMBOX   ##
    ##################
    ${if_running rhythmbox}${font WenQuanYiMicroHei:bold:size=8.70}${color 4b74b4}Now Playing${color slate grey}${offset 8}${voffset -2}${hr 2}${font}${voffset 7}
    #Down to business
    ${exec ~/.conky/rhythmbox-ca.sh}${image /tmp/cover -p 0,780 -s 64x64}
    ${execp conkyRhythmbox --template=/home/vehemoth/.conky/first.template}
    ${execp conkyRhythmbox --template=/home/vehemoth/.conky/second.template}
    ${execp conkyRhythmbox --template=/home/vehemoth/.conky/third.template}
    ${voffset -75}${offset 78}${execbar conkyRhythmbox --datatype=PP}
    ${endif}
    rhythmbox-ca.sh
    Code:
    #!/bin/bash
    if test `conkyRhythmbox --datatype=CA`;
    then
        return
    else
        cp /home/vehemoth/.conky/none.png /tmp/cover
    fi
    and here is the verbose output of the CA datatype.

    Code:
    *** INITIAL OPTIONS:
        datatype: CA
        template: None
        ratingchar: *
        nounknownoutput: False
        secondsoutput: False
        maxlength: 0
        verbose: True
        errorlogfile: None
        infologfile: None
    INFO: Calling dbus interface for music data
    INFO: Setting up dbus interface
    INFO: Calling dbus interface for music data
    INFO: Preparing output for datatype:CA
    INFO: Linking coverart from /home/vehemoth/Music/ogg/Atomic cat - Trance Imagination -- Jamendo - OGG Vorbis q7 - 2010.07.19 [www.jamendo.com]/[cover] Atomic cat - Trance Imagination.jpg to /tmp/cover
    Traceback (most recent call last):
      File "/usr/share/conkyrhythmbox/conkyRhythmbox.py", line 228, in getOutputData
        self.getShellCommandOutput(linkcmd)
      File "/usr/share/conkyrhythmbox/conkyRhythmbox.py", line 479, in getShellCommandOutput
        self.logger.info("Running shell command '%s'"%shell_command)
    AttributeError: RhythmboxInfo instance has no attribute 'logger'
    ERROR: Unknown error when calling getOutputData:RhythmboxInfo instance has no attribute 'logger'
    "I don't have a problem with someone using their talents to become successful, I just don't think the highest calling is success." - Richard Stallman
    sudo apt-get mail
    package not found

  2. #492
    Join Date
    Feb 2008
    Location
    52°38'41.6"N/1°19'43.6"E
    Beans
    Hidden!

    Re: Conky Rhythmbox Python Script

    There was a bug in the tarballed py I posted recently, replace any "self.logger.info" for "self.logInfo"...there should be one in the new function I added...doh

    edit: attached zip with edited file (not on a linux box hence the .zip)
    Attached Files Attached Files

  3. #493
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Conky Rhythmbox Python Script

    Quote Originally Posted by kaivalagi View Post
    There was a bug in the tarballed py I posted recently, replace any "self.logger.info" for "self.logInfo"...there should be one in the new function I added...doh

    edit: attached zip with edited file (not on a linux box hence the .zip)
    Grabbed that and tried it ...

    Still get the [] vs the names.

    and:
    Code:
    # Force UTF8? note that UTF8 support required XFT
    override_utf8_locale yes   ###  CHANGED
    Also, not shown, no errors reported in terminal and no image.

  4. #494
    Join Date
    Sep 2010
    Location
    Aotearoa
    Beans
    59

    Re: Conky Rhythmbox Python Script

    Okay, I can't do python so here is the output (maybe you need to put speech mark things ' around the ln command, e.g. ln -s '/home/cover' )

    Code:
    *** INITIAL OPTIONS:
        datatype: CA
        template: None
        ratingchar: *
        nounknownoutput: False
        secondsoutput: False
        maxlength: 0
        verbose: True
        errorlogfile: None
        infologfile: None
    INFO: Calling dbus interface for music data
    INFO: Setting up dbus interface
    INFO: Calling dbus interface for music data
    INFO: Preparing output for datatype:CA
    INFO: Linking coverart from /home/vehemoth/Music/ogg/Magdalen Graal - Magdalen Graal -- Jamendo - OGG Vorbis q7 - 2010.03.08 [www.jamendo.com]/[cover] Magdalen Graal - Magdalen Graal.jpg to /tmp/cover
    INFO: Running shell command 'ln -s /home/vehemoth/Music/ogg/Magdalen Graal - Magdalen Graal -- Jamendo - OGG Vorbis q7 - 2010.03.08 [www.jamendo.com]/[cover] Magdalen Graal - Magdalen Graal.jpg /tmp/cover'
    ln: target `/tmp/cover' is not a directory
    /tmp/cover
    Last edited by vehemoth; May 23rd, 2011 at 06:18 AM. Reason: Fixed the code tags
    "I don't have a problem with someone using their talents to become successful, I just don't think the highest calling is success." - Richard Stallman
    sudo apt-get mail
    package not found

  5. #495
    Join Date
    Feb 2008
    Location
    52°38'41.6"N/1°19'43.6"E
    Beans
    Hidden!

    Re: Conky Rhythmbox Python Script

    Needs quotes around the paths atleast I'd say...not sure when I'll get to play again with this in the short term...it might have to wait until next weekend

  6. #496
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Conky Rhythmbox Python Script

    Here is my conky, as I said, a modified conkyRhythmbox Example as is my template:
    Code:
    # conky configuration
    # edited by kaivalagi
    # killall conky && conky -c ~/conky/rb/conkyrc
    
    # set to yes if you want Conky to be forked in the background
    background no
    
    # Use Xft?
    use_xft yes
    
    # Xft font when Xft is enabled
    xftfont monospace:size=9  ####  changed font
    
    # Text alpha when using Xft
    xftalpha 0.8
    
    # Update interval in seconds
    update_interval 1.0
    
    # 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 no
    
    # Use double buffering (reduces flicker, may not work for everyone)
    double_buffer yes
    
    # Minimum size of text area
    minimum_size 300 1000
    maximum_width 300
    
    # Draw shades?
    draw_shades yes
    
    # Draw outlines?
    draw_outline no
    
    # Draw borders around text
    draw_borders no
    draw_graph_borders yes
    
    # Stippled borders?
    stippled_borders 0
    
    # border margins
    border_inner_margin 0 ### needs "_inner_" or "_outer_" now to work
    
    # border width
    border_width 0
    
    # Default colors and also border colors
    default_color white
    default_shade_color black
    default_outline_color white
    
    # own window options
    own_window		yes
    own_window_transparent	yes
    own_window_type		override
    own_window_hints	undecorated,below,sticky,skip_taskbar,skip_pager
    
    # Text alignment, other possible values are commented
    #alignment top_left
    #alignment top_right
    #alignment bottom_left
    alignment top_left         #### changes
    
    # Gap between borders of screen and text
    # same thing as passing -x at command line
    gap_x 100
    gap_y 100
    
    # 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   ###  CHANGED
    
    # Add spaces to keep things from moving about?  This only affects certain objects.
    use_spacer right
    
    # colours
    color1 white
    # light blue
    color2 6892C6
    # orange
    color3 E77320
    # green
    color4 78BF39
    # red
    color5 CC0000
    
    # variable is given either in format $variable or in ${variable}. Latter
    # allows characters right after the variable and must be used in network
    # stuff because of an argument
    
    # stuff after 'TEXT' will be formatted on screen
    text_buffer_size 3048 ###  I needed to add this
    
    TEXT
    ${color4}${font monospace:style=Bold:size=14}@ ${font monospace:style=Bold:size=11}Rhythmbox${font}
    
    ${color1}${execp conkyRhythmbox --template=~/conky/rb/conkyRhythmbox.template}
    ~/conky/rb/conkyRhythmbox.template
    Code:
      Status: [--datatype=ST]
      Artist: [--datatype=AR]
       Album: [--datatype=AL]
       Title: [--datatype=TI]
    Position: [--datatype=PT] / [--datatype=LE] [--datatype=PP]%
      Rating: [--datatype=RT]
      Volume: [--datatype=VO]
    
          YR: [--datatype=YR]
    Track No: [--datatype=TN] 
    
    Cover:${image [--datatype=CA] -p 0,235 -s 100x100}
    There are 8 blank lines after:
    Code:
    Cover:${image [--datatype=CA] -p 0,235 -s 100x100}
    The original files are here:
    Code:
    /usr/share/conkyrhythmbox/example/conkyRhythmbox.template
    /usr/share/conkyrhythmbox/example/conkyrc

  7. #497
    Join Date
    Sep 2010
    Location
    Aotearoa
    Beans
    59

    Re: Conky Rhythmbox Python Script

    What os are you using,
    have you got utf8 enabled in the terminal
    did you install the latest version of conkyRhythmbox from the repos
    do you have the latest conky

    Your conkyrc works on mine so I'd say that the most likely thing is utf8 support in the terminal.

    And regarding that "yes" thing, I don't think use_utf8 need yes on the end but check in the conky man pages. I believe that they are also enabled by default so you could delete the line.
    "I don't have a problem with someone using their talents to become successful, I just don't think the highest calling is success." - Richard Stallman
    sudo apt-get mail
    package not found

  8. #498
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Conky Rhythmbox Python Script

    Quote Originally Posted by vehemoth View Post
    What os are you using,
    have you got utf8 enabled in the terminal
    did you install the latest version of conkyRhythmbox from the repos
    do you have the latest conky

    Your conkyrc works on mine so I'd say that the most likely thing is utf8 support in the terminal.

    And regarding that "yes" thing, I don't think use_utf8 need yes on the end but check in the conky man pages. I believe that they are also enabled by default so you could delete the line.
    • By works, do you mean you see the cover-art?
    • I'm using #! 10 - Statler, based on Debian Squeeze.
    • No DE, maybe that's a problem, just OpenBox.
    • I have the latest conkyRhythmbox from the repos AND the two that came after that, that kaivalagi edited and posted here in the thread to work on this problem.
    • I am using conky v1.8.0 - it is enough for this, and it is the same version kaivalagi uses.


    Code:
    override_utf8_locale
     	Force UTF8? requires XFT
    use_xft
     	Use Xft (anti-aliased font and stuff)
    
    xftalpha
     	Alpha of Xft font. Must be a value at or between 1 and 0.
    
    xftfont
     	Xft font to use.
    If you use "override_utf8_locale yes" you need to have use_xtf yes and xftfont set as I do.

    Now this is a new one for me:
    Quote Originally Posted by vehemoth View Post
    have you got utf8 enabled in the terminal
    How does one do that? I use "terminator". I'll have to look that up.

    I have also installed "rhythmbox-desktop-art v2.00"

    Now, one thing I did notice that when I check the "plugins" (Edit > Plugins) in Rhythmbox it is not accessible.



    I thought it was because I do not run a composite manager. Turning on composite manager doesn't help, that option is still not available to me.

    However that images explains why the coverart shows in Rhythmbox - it grabs it from the Internet, according to what it says, and turning it off, turns off the cover art.

    Just so you know, I have beta tested most of kaivalagi's apps from the beginning, using Ubuntu, Xubuntu and now Debian, not the google stuff though as I don't use those services. I may not be the smartest person going but I do try everything I can to eliminate problems from "the users point of view". I am not a programmer, K will tell you that, but sometimes I can look at things and see the "logic" and make changes to fix - OR REALLY BREAK - things. I've had to re-install my OS more than once because "I" broke it trying things.

    Everything I've done here is simply to help you. When the problem is fixed, whether I find the answer, you find the answer or someone else does, I'll remove Rhythmbox, conkyRhythmbox and rhythmbox-desktop-art.

  9. #499
    Join Date
    Feb 2008
    Location
    52°38'41.6"N/1°19'43.6"E
    Beans
    Hidden!

    Re: Conky Rhythmbox Python Script

    You don't need "rhythmbox-desktop-art v2.00" for a conky only solution as that provides an alternative to conky for cover art output on the desktop...might be the best option though!

    For conky all you should need is the cover art plugin enabled to get the cover art sorted as and when then conkyRhythmbox should find it on running....I don't get this though, cover art never comes back for me either. I Rhythmbox v2.90.1 installed, although I only use it for testing the script for others...mpd and sonata for me!

  10. #500
    Join Date
    Sep 2010
    Location
    Aotearoa
    Beans
    59

    Re: Conky Rhythmbox Python Script

    Quote Originally Posted by Sector11 View Post
    • By works, do you mean you see the cover-art?
    • I'm using #! 10 - Statler, based on Debian Squeeze.
    • No DE, maybe that's a problem, just OpenBox.
    • I have the latest conkyRhythmbox from the repos AND the two that came after that, that kaivalagi edited and posted here in the thread to work on this problem.
    • I am using conky v1.8.0 - it is enough for this, and it is the same version kaivalagi uses.


    Code:
    override_utf8_locale
         Force UTF8? requires XFT
    use_xft
         Use Xft (anti-aliased font and stuff)
    
    xftalpha
         Alpha of Xft font. Must be a value at or between 1 and 0.
    
    xftfont
         Xft font to use.
    If you use "override_utf8_locale yes" you need to have use_xtf yes and xftfont set as I do.

    Now this is a new one for me:

    How does one do that? I use "terminator". I'll have to look that up.

    I have also installed "rhythmbox-desktop-art v2.00"

    Now, one thing I did notice that when I check the "plugins" (Edit > Plugins) in Rhythmbox it is not accessible.



    I thought it was because I do not run a composite manager. Turning on composite manager doesn't help, that option is still not available to me.

    However that images explains why the coverart shows in Rhythmbox - it grabs it from the Internet, according to what it says, and turning it off, turns off the cover art.

    Just so you know, I have beta tested most of kaivalagi's apps from the beginning, using Ubuntu, Xubuntu and now Debian, not the google stuff though as I don't use those services. I may not be the smartest person going but I do try everything I can to eliminate problems from "the users point of view". I am not a programmer, K will tell you that, but sometimes I can look at things and see the "logic" and make changes to fix - OR REALLY BREAK - things. I've had to re-install my OS more than once because "I" broke it trying things.

    Everything I've done here is simply to help you. When the problem is fixed, whether I find the answer, you find the answer or someone else does, I'll remove Rhythmbox, conkyRhythmbox and rhythmbox-desktop-art.
    I'm not very good at communicating my ideas, sorry.

    But I was saying that all of the text showed up fine on my system.
    I use debian squeeze, so I'm assuming it's something to do with crunchbang's terminal as the conky and conkyRhythmbox should be the same.

    Maybe this page can help you with utf8 support http://crunchbanglinux.org/forums/to...t-please-help/
    "I don't have a problem with someone using their talents to become successful, I just don't think the highest calling is success." - Richard Stallman
    sudo apt-get mail
    package not found

Page 50 of 58 FirstFirst ... 404849505152 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •