Version: 3.3 (using KDE 3.3.0, compiled sources) Compiler: gcc version 3.3.4 (Debian) OS: Linux (i686) release 2.4.21 I created an mp3 with xmms by streaming a radio station to HD (as well as listing to it). The resulting mp3 has all fields in the ID3 tag empty, no title, artist etc. Naturally the mp3-id3 tag metadata plugin also supplies things like bitrate and length. I, therefore, was surprised to see a tooltip in konq with 4 empty fields, and one filled field. I would appreciate it if fields that are empty are not shown in the tooltip.
Created attachment 7765 [details] tooltip with mostly empty rows. A picture describes it best.
> I would appreciate it if fields that are empty are not shown in the tooltip. They are not shown, your mp3 must contain some non-printing garbage.
The theory that they contain some non-printing stuff is incorrect. I just opened the properties for this dialog and put some little text in each field and pressed OK. Then I opened the dialog again and this time I removed all the texts and fields. The result was the same as the picture shows. So unless you also think the properties dialog puts non-printable garbage in my MP3, this theory is debunked. Next; I took a perfectly correct MP3 and removed all the fields with the same result (I only can't remove the Genre, but OK). No idea if its relevant; but doing the same thing on an ogg does have the correct result.
CVS commit by bhards: Handle empty (but not null) entries from mp3 files. I don't have a lot of mp3s, so I could only test with the ones from kbattleship :-) Thomas: can you update kdemultimedia/kfile-plugins/mp3 and test if this is still a problem? CCMAIL:90674@bugs.kde.org M +15 -5 kfile_mp3.cpp 1.71 --- kdemultimedia/kfile-plugins/mp3/kfile_mp3.cpp #1.70:1.71 @@ -154,11 +154,21 @@ bool KMp3Plugin::readInfo(KFileMetaInfo QString track = file.tag()->track() > 0 ? QString::number(file.tag()->track()) : QString::null; - appendItem(id3group, "Title", TStringToQString(file.tag()->title()).stripWhiteSpace()); - appendItem(id3group, "Artist", TStringToQString(file.tag()->artist()).stripWhiteSpace()); - appendItem(id3group, "Album", TStringToQString(file.tag()->album()).stripWhiteSpace()); + QString title = TStringToQString(file.tag()->title()).stripWhiteSpace(); + if (!title.isEmpty()) + appendItem(id3group, "Title", title); + QString artist = TStringToQString(file.tag()->artist()).stripWhiteSpace(); + if (!artist.isEmpty()) + appendItem(id3group, "Artist", artist); + QString album = TStringToQString(file.tag()->album()).stripWhiteSpace(); + if (!album.isEmpty()) + appendItem(id3group, "Album", album); appendItem(id3group, "Date", date); - appendItem(id3group, "Comment", TStringToQString(file.tag()->comment()).stripWhiteSpace()); + QString comment = TStringToQString(file.tag()->comment()).stripWhiteSpace(); + if (!comment.isEmpty()) + appendItem(id3group, "Comment", comment); appendItem(id3group, "Tracknumber", track); - appendItem(id3group, "Genre", TStringToQString(file.tag()->genre()).stripWhiteSpace()); + QString genre = TStringToQString(file.tag()->genre()).stripWhiteSpace(); + if (!genre.isEmpty()) + appendItem(id3group, "Genre", genre); }
Commit did indeed fix bug.