home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / sgi / 12688 < prev    next >
Encoding:
Text File  |  1992-08-20  |  2.4 KB  |  60 lines

  1. Newsgroups: comp.sys.sgi
  2. Path: sparky!uunet!kithrup!stanford.edu!ames!haven.umd.edu!darwin.sura.net!sgiblab!sgigate!odin!fido!bedlam.asd.sgi.com!davis
  3. From: davis@bedlam.asd.sgi.com (Tom Davis)
  4. Subject: Re: Zip tab settings
  5. Message-ID: <oqq61b8@fido.asd.sgi.com>
  6. Sender: news@fido.asd.sgi.com (Usenet News Admin)
  7. Organization: sgi
  8. References:  <1171@deere.com>
  9. Date: Thu, 20 Aug 1992 21:13:38 GMT
  10. Lines: 48
  11.  
  12. In article <1171@deere.com>, jrh@de.deere.com (John R. Howell) writes:
  13. |> I read in my documentation for zip that tab stops can be set at values
  14. |> other than 8 using the .ziprc file.  However, that doesn't really change
  15. |> the tab size, it still uses 8 character tabs, but will use spaces to
  16. |> "fake" a different tab size.
  17. |> 
  18. |> I have files that get edited on other machines in addition to the sgi and
  19. |> I use a tab size of 4.  However, no matter what I put in .ziprc, these
  20. |> existing tabs will be displayed as 8 character stops.
  21. |> 
  22. |> Is this correct? Is there anyway around this?
  23. |> 
  24.  
  25. There is a way around it.  In your .ziprc, include a line like this:
  26.  
  27.     hardtabsize 4
  28.  
  29. In this mode, zip will advance to the column of the next multiple of 4.
  30. The tabsize entry in the .ziprc controls how far (in columns) the cursor
  31. will advance with each press of the tab key, so if you only change the
  32. hardtabsize to 4, pressing tab will still advance up to 8 positions (and
  33. may insert 2 raw tabs into the file).  So if you set your hardtabsize to 4,
  34. you'll probably want to set your tabsize to 4 as well.
  35.  
  36. |> Is there an option that says "whenever I hit the tab key, insert spaces
  37. |> to pad to the next tab stop"?
  38.  
  39. There's a hack to do this.  Just set the hardtabsize to be enormous (say 10000000),
  40. and zip will only insert a tab character when it needs to get to columns
  41. 10000000, 20000000, etc., which rarely occurs.  I suppose you could get nailed
  42. in giant binary files ...
  43.  
  44. O.K.  Those are the technical details.  Now for the sermon.  In my experience,
  45. hard tab sizes of anything other than 8 will cause you no end of trouble.  Too
  46. many other programs "know" that tabs are 8 wide.  I used to think of all sorts
  47. of horrible things that ought to be done to people who used non-8-wide tabs, but
  48. in my kinder and gentler dotage, I merely think they should all be taken out and
  49. shot.  The devil made me add hardtabsize to zip.
  50.  
  51. I have no objections to using spaces exclusively, however.
  52.  
  53.   -- Tom Davis
  54.  
  55. |> 
  56. |> Thanks.
  57. |> 
  58. |> John
  59. |> 
  60.