home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / os / os2 / misc / 41146 < prev    next >
Encoding:
Internet Message Format  |  1993-01-04  |  2.5 KB

  1. Path: sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!rutgers!njitgw.njit.edu!hertz.njit.edu!dic5340
  2. From: dic5340@hertz.njit.edu (David Charlap)
  3. Newsgroups: comp.os.os2.misc
  4. Subject: Re: Mac Icons?
  5. Message-ID: <1993Jan4.222344.29422@njitgw.njit.edu>
  6. Date: 4 Jan 93 22:23:44 GMT
  7. References: <47762@ogicse.ogi.edu>
  8. Sender: news@njit.edu
  9. Organization: New Jersey Institute of Technology, Newark, N.J.
  10. Lines: 42
  11. Nntp-Posting-Host: hertz.njit.edu
  12.  
  13. In article <47762@ogicse.ogi.edu> francis@ese.ogi.edu (Francis Moraes) writes:
  14. >I would like to convert some Mac icons to OS/2; does anyone know of a
  15. >program that will do this? I haven't seen any posts on this subject and
  16. >no mention is made to this in the FAQ which seems strange since I would
  17. >think this would be a common enough thing to want to do...
  18.  
  19. This would be very difficult for the following reasons:
  20.  
  21. 1) Mac icons are not stored in individual files.  They are stored as
  22.    resources in other files.  Much like the way rc.exe binds icons to
  23. executables, but unlike OS/2, the icons can not stand on their own.
  24. This means you must (somehow) get the entire resource fork of a
  25. program into the PC, and parse the icon structure out of it.
  26.  
  27. 2) All mac icons are 32x32, but this is where the similarity ends.
  28.    Icons are stored as a variety of resource types.  There is type
  29. ICON, which is a black & white bitmap; there is ICN#, which is really
  30. two bitmaps: a b&w bitmap and a mask (so parts can be transparent);
  31. there is cicn, which is an 8-bit color bitmap with a mask; then there
  32. is cin4 and cin8, which are 4-bit and 8-bit color icons with masks.
  33. Etc.  So you need to convert each icon to it's respective "size" class
  34. in the .ICO file.  Note also that each icon resource may have it's own
  35. identifier constant, meaning you may have to read other resources to
  36. associate the different forms of an icon with each other.  This is a
  37. real pain, and I wouldn't want to do it.
  38.  
  39. In short, unless you've a lot of icons to do, you're probably better
  40. off sitting in front of the mac with ResEdit (the resource editor) and
  41. a piece of graph paper and just copy the bitmap that way.  I did the
  42. system 7 trash and Mac icons like this.
  43.  
  44. BTW, I could be in serious legal trouble if I posted these icons,
  45. couldn't I?  I'd like to share them, but I don't like threats of
  46. lawsuits, either.
  47.  
  48.  
  49.  
  50. -- 
  51.   |)  David Charlap          | .signature confiscated by FBI due to
  52.  /|_  dic5340@hertz.njit.edu | an ongoing investigation into the
  53. ((|,)                        | source of these .signature virusses
  54.  ~|~
  55.