info.icon in HAL

David Zeuthen david at fubar.dk
Tue Mar 6 18:00:44 PST 2007


On Tue, 2007-03-06 at 11:52 -0500, Rodney Dawes wrote:
> > For plain disks attached to hotpluggable ports on the systerm, it's
> > useful to see the connection type and having a nice logo that reflects
> > that (like in Mac OS X). Right now the main game in town is USB and
> > Firewire but we might want to add future connection types in the future
> 
> I suppose this can be useful for some people, sure. I don't think it is
> particularly so, though. At least in terms of usability. Some people do
> have weird preferences though. For what it's worth, the new motherboard
> I just got for my desktop PC, has an external SATA port on the back. :)
> Do those just show up as SCSI, or can we infer more information from
> them? It would be really awesome if we could determine what model of
> external disk is being connected to the USB, Firewire, or SATA ports.

In reality most physical disks attached to USB and Firewire enclosures
are IDE but most people don't care about that. I think the important
thing here is to show an icon that represents the _connection
mechanism_, be that USB, Firewire or SATA because that's what people
known about as they do connect the hardware themselves etc. Kay says
SATA is a mess to get right so lets just start with drive-firewire and
drive-usb. 

I've attached a patch for this.

> > For optical drives, people normally only care whether the drive can
> > burn. We omit whether it can burn CD-R's, DVD-R's or other types of
> > discs (ICBW and we could drop this and expand drive-optical-* instead)
> > 
> >  drive-optical
> >  drive-optical-recorder
> 
> I suppose this is fine. I think trying to be smart and show what formats
> the drive supports, though, is just going to cause problems. For
> example, if I have a BluRay drive, it supports pretty much everything
> but HD-DVD and DVD-RAM modules.

Yeah.

> > For removable media, it's useful to see what kind of media the drive
> > uses otherwise you end up with this kind of window
> > 
> >  http://people.freedesktop.org/~david/many-drives.png
> 
> This is still 100000x better than Windows XP, which simply lists them
> all as "Removable Disk" in "My Computer". At least I can see what format
> the drive expects, via the text labels, in Nautilus.
> 
> >  drive-removable-media
> >  drive-removable-media-jaz
> >  drive-removable-media-zip
> >  drive-removable-media-floppy
> >  drive-removable-media-tape
> >  drive-removable-media-flash
> >  drive-removable-media-flash-compactflash
> >  drive-removable-media-flash-memorystick
> >  drive-removable-media-flash-sdmmc
> >  drive-removable-media-flash-smartmedia
> 
> The drive-removable-media-flash-* icons should match the names for the
> media-flash-* icons, as per the device-names.txt on my
> people.freedesktop.org space. After a few more tweaks, and the closure
> of this particular discussion to get the icon_name property into the
> HAL spec, I will be writing up a more formal addendum in docbook, for
> the device icons.

OK, see attached patch.

> > Some drives are "special" (this is for USB key chain drives) but also
> > very common
> > 
> >  drive-keyfob
> 
> I don't think drive-* is appropriate for these devices. The "drive" in
> this case, is technically simply the usb port. The "media" is the
> keyfob. An appropriate name would probably be media-flash-disk-usb, as
> we could potentially have the same types of devices, working over other
> protocols. One of the goals with having the structure of icon names,
> that we do, in the Naming Spec, is to be able to work with as little
> change as possible, on future hardware and software platforms.

It is a "drive" if you define "drive" as a random access device you can
access and read/(write) data to. I've also got a Firewire thumb drive in
the office (believe it or not!). To be consistent with drive-harddisk*
I've called it drive-flashdisk*. See the patch.

> > This covers all the drives which is to say the enclosures for the media,
> > whether it's removable or not or how it's partitioned. For drives
> > without removable media we'll reuse the drive-* icon for volumes (e.g.
> > partitions) on that drive. Drives with removable media have distinct
> > icons as the media itself can change
> > 
> >  media-jaz
> >  media-zip
> >  media-floppy
> >  media-tape
> >  media-flash
> >  media-flash-compactflash
> >  media-flash-memorystick
> >  media-flash-sdmmc
> >  media-flash-smartmedia
> > 
> > Typically users wants to see a distinct icon for the disc type
> > 
> >  media-optical
> >  media-optical-dvd
> >  media-optical-blueray
> >  media-optical-hddvd
> >  media-optical-writable
> >  media-optical-writable-dvd
> >  media-optical-writable-dvd-plus
> >  media-optical-writable-blueray
> >  media-optical-writable-hddvd
> >  media-optical-rewritable
> >  media-optical-rewritable-dvd
> >  media-optical-rewritable-dvd-plus
> >  media-optical-rewritable-dvd-plus-duallayer
> >  media-optical-rewritable-blueray
> >  media-optical-rewritable-hddvd
> 
> These are all in the device-names.txt file in my people.freedesktop.org
> space already. Not as you named them exactly, but they are in that file,
> and some are even used as examples in the Naming Spec's Devices context
> description.

Perhaps that file is out of date (it says March 2nd). There's only

 media-optical-bd
 media-optical-cdrom
 media-optical-dvd
 media-optical-dvd-hd

as far as I can tell which doesn't account for at least whether a disc
is rewritable and recordable. Also, fwiw, HDDVD has nothing to do with
DVD (got as much in common as Bluray got with DVD) so the -hd extension
is not going to work.

> > I'm not at all suggesting that GNOME or KDE or whatever is going to ship
> > all these icons but I think it should be possible to create an icon
> > theme that uses all of them.
> 
> It should definitely be possible. I think the icon naming issues are
> probably better discussed in a separate thread on the XDG list though,
> rather than the HAL list.

Sure, but I just need to know what to put in the HAL properties :-)

Anyway, I've attached a patch with my suggested changes. Thoughts?

    David

-------------- next part --------------
A non-text attachment was scrubbed...
Name: device-names.patch
Type: text/x-patch
Size: 1647 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20070306/0b0d0d3d/device-names.bin


More information about the hal mailing list