home *** CD-ROM | disk | FTP | other *** search
/ Crawly Crypt Collection 1 / crawlyvol1.bin / program / books / dsktpinf / more.dsk < prev   
Text File  |  1991-01-30  |  8KB  |  165 lines

  1.  
  2. The few lines of desktop.inf before and including some application
  3. installation information are :
  4.  
  5. #F FF 04   @ *.*@
  6. #D FF 01   @ *.*@ 
  7. #G 03 FF   *.APP@ @ 
  8. #G 03 FF   *.PRG@ @ 
  9. #F 03 04   *.TOS@ @ 
  10. #P 03 04   *.TTP@ @ 
  11. #P 03 04   d:\FASTBAS.PRG@ *.BSC@
  12.  
  13. The action of the desktop is clearly to try matching a 'double-clicked'
  14. file against these templates, IN REVERSE ORDER.
  15. Once a match has been made, the desktop then takes either the specified
  16. action, or if none, the default action.
  17.  
  18. [ Thus if the bottom template is changed to d:\DUMP.TTP@ *.*@ then an
  19. attempt will be made to dump ALL files. Interestingly, not only will 
  20. .prg (etc) files not be executed, they will also not be displayed as
  21. executables on the desktop. ]
  22.  
  23. If no other match is found, the top line wakes up the SHOW|PRINT|CANCEL
  24. alert box from the standard desktop.  The simple solution is just to insert
  25. the name of one's favourite display routine, as below.
  26.  
  27. #F FF 04   d:\LESS.TTP@ *.*@ 
  28. #D FF 01   @ *.*@ 
  29. #G 03 FF   *.APP@ @ 
  30. #G 03 FF   *.PRG@ @ 
  31. #F 03 04   *.TOS@ @ 
  32. #P 03 04   *.TTP@ @ 
  33.  
  34. > In response to someones query about the desktop.inf.... tah dah -----
  35. > Everything you always wanted to know about desktop.inf, but were afraid to
  36. > ask.  Below is a typical desktop.inf file (with  a few changes added for
  37. > examples).  Below each line is a definition of what each value represents.
  38. > #a000100
  39. > This is the first desk accessory, the rs232 config.  Each 0 represents the
  40. > first column of buttons on the set rs232 config dialog box.  The first
  41. > 0 is column 1 row 1, the second 0 is coumn 1 row 2, etc.  A 1 value
  42. > indicates that a button in the second column was chosen.
  43. > #b000000
  44. > This is the set printer config.  It works the same way as the rs232 config.
  45. > #c7770007000600070055200505552220770557075055507703111103
  46. > This is the color palette.  The color value is set using 3 digits at a time,
  47. > representing the red, green and blue values.  The 3111103 at the end deals
  48. > with the keyboard repeat rate, and sensitivity.  (None of the above three
  49. > will do anything if the associated desk accessory is not loaded)
  50. > #d
  51. > This is apparently reserved for a fourth accessory, and does nothing at
  52. > this time (so far as I can see).
  53. > #E C4 02   (#E=Extras)
  54. > This is two things.  The first value has to do with both the Set Preference
  55. > dialog and the mouse double click rate.  The byte is broken down as follows
  56. > with the indicated bit set performing the noted action:
  57. > Bit       7       6       5       4       3    |   2       1        0
  58. > Value    128     64      32      16       8    |   4       2        1
  59. >      displays  sorted  sorted  confirm confirm |   double click rate
  60. >        TEXT      by      by    deletes copies  |   all three bits, values
  61. >    (if not set  size    date                   |   may only be from 0-4
  62. >      displays    \       /                     |   5-7 will turn off the
  63. >       icons)     both bits                     |   mouse buttons
  64. >                   sort by
  65. >                    type
  66. > If neither bit 5 or 6 is set the sort is by name
  67. > The second value is 03 for hi rez, 02 for medium rez, or 01 for low rez.
  68. > #W 00 00 02 0B 2A 0B 08 A:\*.*@        (#W=Window)
  69. > #W 00 01 0A 01 45 09 08 A:\TEST.C\*.*@
  70. > #W 00 00 0E 09 2A 0B 08 A:\*.INF@
  71. > #W 00 00 0F 0A 2A 0B 00 @
  72. > The above four are the window defs.  The first number is how far over the
  73. > horizontal slider is, the second is the vertical slider.  The third number
  74. > is the x coordinate of the left hand side of the window (this takes on even
  75. > values, with odd values the same as next lowest even value).  The fourth
  76. > number is the y coordinate (this takes single increments).  The fifth and
  77. > sixth numbers are the width and height, respectively.  The last number
  78. > indicates where on the screen the window will open from. (The window opens
  79. > with a different shape and from a different place with each number, but when
  80. > you close the window, it will go to another place on the screen.  I have not
  81. > hacked at this long enuf to figure it out.)  A zero or FF will not open the
  82. > window.  The text indicates which drive's contents will be displayed.  If
  83. > the drive does not exist, the window won't open, ie. drive bits not set.
  84. > Also, if the display validation is omitted, the window won't open.
  85. > The second def above will display the contents of the folder TEST.C, while
  86. > The third def above will open a window, and only display the .INF files
  87. > on drive A.  If you close and open the window, the files will display as
  88. > defined in the file and program defs below.  (NOTE: this only applies to
  89. > icon images, every file will display in text  -- except if the file bits
  90. > are marked to be hidden, system, volume, read/write and whatever other
  91. > bits there are, in which case it won't display at all, but if it is read
  92. > only, it will display -- strange HUH?)  The bottom-most open window in
  93. > the list will be the active window.
  94. > #M 00 02 00 FF D FLOPPY DISK@ @      (#M=iMage (?))
  95. > #M 00 00 00 FF A DRIVE A@ @
  96. > #M 00 01 00 FF B FLOPPY DISK@ @
  97. > These describe the icon attributes.  The first two numbers are the column
  98. > and row position of the icon.  The column can be from 0-7, the row 0-3.
  99. > The third number determines the icon image which will be displayed.  The
  100. > image number is the same for this and the remaining defs in desktop.inf, as
  101. > follows:
  102. > 0= disk drive (drawer)       1= folder (sub-directory)      2= trash can
  103. > 3= executable file (.PRG, .TOS, or .TTP)   4= text (stack of papers)
  104. > The fourth value doesn't seem to do anything, but must be a place holder for
  105. > an unimplemented function.  The single letter is the drive identifier, and
  106. > the text is the drive name.  The first @ indicates the end of the drive name.
  107. > The second @ does nothing, but we can speculate as described below for the
  108. > file identifiers.  The order in the list determines the visual heirarchy
  109. > of the icons, ie. which will display on top when moved over another icon.
  110. > #T 00 03 02 FF   BLACK HOLE@ @    (#T=Trash)
  111. > This is the same as the disk drive.  If you move a disk drive identifier
  112. > below this in the list, it will display on top of the trash if moved to the
  113. > same location.  The trash has no identifier letter, but you can put one in.
  114. > #F 03 04   @ *.INF@      (#F=Files)
  115. > #D FF 01   @ *.C@        (#D=Directories)
  116. > These two determine which type of file or directory will be displayed, when
  117. > displayed as icons.  The first line will make GEM display only .INF files
  118. > for use with the SHOW, PRINT, CANCEL alert box.  If you delete this line,
  119. > no icons will be shown for any file, except as defined below for programs.
  120. > The second line does the same for sub-directories, only .C folder icons will
  121. > show.  When files are displayed as text, all files will be there, but if
  122. > you single click on an 'undefined' file type, the sytem will reboot.  If you
  123. > double click, the name will be highlighted, but you can't do anything.
  124. > #G 03 FF   *.APP@ @      (#G=Gem)
  125. > #G 03 FF   *.PRG@ @
  126. > #F 02 04   *.TOS@ @      (#F=File)
  127. > #P 03 04   *.TTP@ @      (#P=Parameters)
  128. > The above four determine the types of files defined as executable images.
  129. > Notice that the #F, #D, #G and #P all have two @ symbols.  This is defined
  130. > as:  the text before the first @ tells GEM this is a def for an executable
  131. > file, while text after the first @ and before the second @ tells GEM that
  132. > this is a def for a SHOWable file (ASCII or object).  Note that if both are
  133. > specified, like    #G 03 04   1ST_WORD.PRG@ *.TXT@    then when you double
  134. > click on any .TXT file, the 1ST_WORD.PRG file will run, and the .TXT file
  135. > will be taken as a parameter.
  136. > The first number indicates the icon image for the file before the first @,
  137. > and the second number indicates the icon image for the file between the @'s.
  138. > Note that the disk drive def also has two @, which would indicate that the
  139. > FF is a def for the text in between the @'s, but I couldn't get anything
  140. > to happen.
  141. > Try playing around with your desktop.inf by placing different values for the
  142. > icon images (can be kinda fun).  Be forewarned, tho, you can thoroughly
  143. > confuse GEM, although no harm will result.
  144. > This concludes the desktop.inf tutorial (for disk based desktop.inf, there
  145. > are a couple of desktop.inf's in memory which can do things, too).
  146. > There may be more to it, but I haven't figured it out yet.
  147.  
  148.