Re: [Rhythmbox-devel] How Can I Display Album Art



2009/11/3 Hideyuki Fukui <nqe37003 nifty com>:
>
> Thanks Peter.
>
> Can I change the plugin to read album names only in a simple way?
> I'm a newbie thus not sure how to tweak the plugin.
>
> If it is a complicated tweak, just mention so. In it is the case, I know I wou
> ld have to learn Python programming and Rhythmbox APIs....
>
> tokyo-joe

As a quick hack, I would try this:

(1) Find where the Rhythmbox plugins are, in particular file:

.../artdisplay/LocalCoverArtSearch.py

(2) Backup this file somewhere in case this goes wrong

(3) Open the file in a text editor

(4) Replace this line (about line number 102):

if f_root.find (artist) != -1 and f_root.find (album) != -1:

with:

if f_root.find (album) != -1 :

but you MUST keep the same indentation in Python.

(5) Save updated LocalCoverArtSearch.py file

(6) Start Rhythmbox

However, as you called yourself a newbie, this might be a bit
much, and there is a chance you'll break things. If I were you
I'd probably wait for someone else to fix this.

To the main developers - does the above seem a good idea
in general? As an aside, doing find != -1 seem very ugly.
I would write this:

if f_root.find (artist) != -1 and f_root.find (album) != -1:
as:

if artist in f_root and album in f_root:

I would also normalise underscores and spaces.

Peter


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]