How can I access the total number of tracks on a CD? $track does not provide this information.

you can't currently
the problem is that there are a few possible values, that may not agree :
- value written in the tag with the track number (as in 01/12) (gmusicbrowser only write the track number currently, and so erase an existing total_number_of_tracks value)
- total number of tracks in the album as known to gmusicbrowser
- maximum number of the track number in the tracks from the album

So I'm not sure which one I should use.
Note that the last 2 will come naturally when I finally get back to my "subfield project"