Image 01
profile-image

RockeGomp

Amund Stavestrand
Various KDE 1.-4. Improvements
test
Uplisting

Amarok 1.x Scripts 20 comments

by eean
Score 50.0%
Feb 12 2005
Ok, I guess it's just my computer being weird then :)

Anyway I wrote my own uplist script in python/bash, which suits my needs pretty well. Thanks for checking out my config file theory anyhow, and for inspiration to make my own script. - May 06 2005
BTW: I'm using kde-3.4.0 and amarok 1.3-cvs, I have ruby, smoke, korundum installed. All on Gentoo GNU/Linux. - May 01 2005
I want to use this for my webpage, but it won't work properly for me. When I try to run it an error message come and tell me

The script 'uplisting.rb' exited with error code: 1

Details:

IO failed: No such file or directory - /home/amund/.kde3.4/share/apps/amarok/scripts-data/uplistingrc/usr/lib/ruby/1.8/rexml/parsers/baseparser.rb:133:in `stream=': Array is not a valid input stream. It must be (RuntimeError)either a String, IO, StringIO or Source. from /usr/lib/ruby/1.8/rexml/parsers/baseparser.rb:100:in `initialize' from /usr/lib/ruby/1.8/rexml/parsers/streamparser.rb:6:in `new' from /usr/lib/ruby/1.8/rexml/parsers/streamparser.rb:6:in `initialize' from /usr/lib/ruby/1.8/rexml/document.rb:171:in `new' from /usr/lib/ruby/1.8/rexml/document.rb:171:in `parse_stream' from ./xtemplate/lib/xtemplate/xml.rb:343:in `parse' from ./xtemplate/lib/xtemplate.rb:31:in `initialize' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:216:in `new' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:216:in `initialize' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:511:in `new' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:511:in `initialize' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:533:in `new' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:533


Looking closer I saw that it was looking for a scripts-data/uplistingrc file. I created an empty uplistingrc file, but this only gave me a new error message.

The script 'uplisting.rb' exited with error code: 1

Details:

/home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:486:in `load': End of file reached (EOFError) from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:486:in `load' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:485:in `open' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:485:in `load' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:508:in `initialize' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:533:in `new' from /home/amund/.kde3.4/share/apps/amarok/scripts/uplisting/uplisting.rb:533



Looks like I don't get anywhere without a proper configfile. Could someone please send me a working uplistingrc file, so I can started using this script. I am currently using a php script to retrieve the last played songs from audioscrobbler, but it is often very slow, using this uplisting script seems like a much better solution. - May 01 2005
Window thumbnails idea

Various KDE 1.-4. Improvements 8 comments

Score 50.0%
Feb 21 2005
In your first post you said you didn't know how to catch XEvents, after studying the kde and qt api documentation for some time I think I may have found what you're looking for. From http://doc.trolltech.com/3.3/qapplication.html:

bool QApplication::x11EventFilter ( XEvent * ) [virtual]
This virtual function is only implemented under X11.

If you create an application that inherits QApplication and reimplement this function, you get direct access to all X events that the are received from the X server.

Return TRUE if you want to stop the event from being processed. Return FALSE for normal event dispatching.



I'm no expert, but doesn't it say "direct access to all X events"? - Feb 22 2005
I was thinking that an option could be to have all open windows drawn (both minimized and normal) that way one wouldn't have to mind about the XEvent you mentioned, just create the thumbnail when a window is created, and remove it when the window is closed. - Feb 22 2005
I'm thinking about something like the pager window, only without the window, just a thumbnail of the currently minimized windows placed directly on the desktop. Look at the top left of the screenshot in the download. - Feb 22 2005
SpiffiLyrics (Juk + xmms + amarok)

Karamba & Superkaramba 21 comments

Score 50.0%
Sep 30 2004
Fixed it myself :)

There error was due to some autoformat in KEdit. So I deleted the hole thing, untarred it again, edited it with nano instead, and now it works perfectly. - Oct 01 2004
Changing myPlayer to amarok gives me this error:

[output]
File "/home/amund/income/SpiffiJukLyrics/SpiffiJukLyrics.py", line 254
Page = re.sub('< B >','', Page)
^
IndentationError: unindent does not match any outer indentation level
------------------------------------------------------
What does ImportError mean?

It means that I couldn't load a python add-on for SpiffiJukLyrics.theme
If this is a regular theme and doesn't use python
extensions, then nothing is wrong.
[/output]

I'm using KDE-3.3.0 and amaroK-1.1-beta2

ps. had to add two spaces in the < B > . Stupid html tags - Oct 01 2004