After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 407406 - Banshee should show an empty field for track==0
Banshee should show an empty field for track==0
Status: RESOLVED FIXED
Product: banshee
Classification: Other
Component: User Interface
git master
Other All
: Normal minor
: 2.x
Assigned To: Banshee Maintainers
Banshee Maintainers
Depends on:
Blocks:
 
 
Reported: 2007-02-13 09:53 UTC by Andrés G. Aragoneses (IRC: knocte)
Modified: 2010-11-17 21:50 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Displaying an empty box if value = 0 (1.51 KB, patch)
2010-11-11 18:21 UTC, Samuel Gyger (IRC: thinkabout)
needs-work Details | Review
Fixes SpinButton BPM to act like year and track (1.37 KB, patch)
2010-11-12 06:40 UTC, Samuel Gyger (IRC: thinkabout)
needs-work Details | Review
All the criticisim read and applied (2.59 KB, patch)
2010-11-17 21:44 UTC, Samuel Gyger (IRC: thinkabout)
committed Details | Review

Description Andrés G. Aragoneses (IRC: knocte) 2007-02-13 09:53:37 UTC
Banshee should show an empty field for track==0. This issue has been opened in regard to this WONTFIX: http://devzilla.novell.com/taglib-sharp/show_bug.cgi?id=1

Other information:
Just for the record, I'm pasting here the conversation between me and Brian Nickell on #banshee (just after the last messages in the bug at dnc mentioned above):

<knocte>	kerrick_: u there? what I'm trying to say in bug#1 of taglibsharp, is that the track field in ID3v1 is an integer, but in ID3v2 it's a string
<kerrick_>	knocte: TagLib# supports this with Track and TrackCount fields. In the case you mentioned, Tag.Track == 2; Tag.TrackCount == 24. The main problem is that banshee just doesn't show a track count field.
<kerrick_>	It would probably be best, UI-wise to have two spin buttons with a "/" or " of " between them to be, "[ 2] of [ 24]" or something like that.
<kerrick_>	But I have nothing to do with banshee's UI or what is stored in the database.
<knocte>	kerrick_: I see, but ID3v2 allows *any* string in the track field, not only "x/y", so how should banshee or taglib# react when it finds an MP3 with, for example, the string "undefined" or "last track" in that field?
<kerrick_>	I feel the appropriate thing to do in the case of a non-standard string is to label it as zero, especially in the case of an application like banshee which uses the track number to sort files.
<kerrick_>	TagLib# is very flexable internally when it comes to this sort of thing, however. It doesn't set the field until either Track or TrackCount is set, so a file could have a "foobar" track number which would be Track==0, but if the file is edited and saved, the "foobar" field would be unaffected.
<dj-fu>	would it be possible for it to guess which tracknumber the track actually is, and rewrite the tag accordingly?
<dj-fu>	or just pretend the string is actually what it's guessing it to be
<kerrick_>	Moreover, if non-standard track fields are important to Developer X, he could circumvent the Track value completely, and just work with the rawTextIdentificationFrame.
<knocte>	in conclusion, the bug should be opened for banshee..?
<kerrick_>	dj-fu: That would be business for banshee, as TagLib# just deals with basic tag reading/writing. A number of programs do support what you are describing though.
<kerrick_>	knocte: I think in regards to adding a "Track Count" field, but I don't see why banshee should be concerned with non-standard track fields. It's the purpose of a music player and tagging library to cater to the most standard usage.
<knocte>	kerrick_: ok, but now just talking about the "0" string returned from taglib#, should I open a bug for banshee to request for it to present an empty field in that case?
<knocte>	the thing is that most of my music is not sorted by albums so the track field is a non-sense for me
<knocte>	I don't need it
<kerrick_>	Yeah, that makes sense.
Comment 1 Ruben Vermeersch 2007-04-03 18:16:35 UTC
This is fixed, I guess?
Comment 2 Andrés G. Aragoneses (IRC: knocte) 2009-08-05 16:20:05 UTC
This is not fixed. But my guess is that maybe we should retarget it to gtk+, since it seems that there is no way (public API) for these widgets to show nothing. Can you confirm?
Comment 3 Samuel Gyger (IRC: thinkabout) 2010-11-10 06:35:46 UTC
Again here, as in Bug #623974, you could use invisible char and set it to 0, which means no output. So one could emulate the empty textentry. On change one could set back this property to show the change.
Comment 4 Samuel Gyger (IRC: thinkabout) 2010-11-11 18:21:10 UTC
Created attachment 174269 [details] [review]
Displaying an empty box if value = 0

This fixes this bug. The question is if this is a solution you like.
Comment 5 Andrés G. Aragoneses (IRC: knocte) 2010-11-11 21:28:16 UTC
Comment on attachment 174269 [details] [review]
Displaying an empty box if value = 0

Looks awesome!

But am not a maintainer so I recommend you to poke one :)

BTW having a similar patch for the BPM's SpinButton would even bring more consistency, if you have time for that too.
Comment 6 Samuel Gyger (IRC: thinkabout) 2010-11-12 06:40:28 UTC
Created attachment 174305 [details] [review]
Fixes SpinButton BPM to act like year and track

As supposed by Andrés, fix for the BPM Button too.
Comment 7 Gabriel Burt 2010-11-17 20:23:29 UTC
Review of attachment 174305 [details] [review]:

Change commit msg to:

[Bpm] Blank spin button when 0 (bgo#407406)
Comment 8 Gabriel Burt 2010-11-17 20:23:41 UTC
Review of attachment 174269 [details] [review]:

Add [tag] to commit msg, remove "Fixing " part, just do "(bgo#NNNNNN)"

http://live.gnome.org/Git/CommitMessages
Comment 9 Samuel Gyger (IRC: thinkabout) 2010-11-17 21:44:13 UTC
Created attachment 174721 [details] [review]
All the criticisim read and applied
Comment 10 Gabriel Burt 2010-11-17 21:50:23 UTC
Review of attachment 174721 [details] [review]:

Thanks, committed