home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / gnu / epoch / misc / 713 < prev    next >
Encoding:
Text File  |  1992-07-22  |  1.8 KB  |  50 lines

  1. Newsgroups: gnu.epoch.misc
  2. Path: sparky!uunet!wupost!uwm.edu!ux1.cso.uiuc.edu!news.cso.uiuc.edu!void.ncsa.uiuc.edu!marca
  3. From: marca@void.ncsa.uiuc.edu (Marc Andreessen)
  4. Subject: Re: Using hiliting with cmushell mode
  5. References: <RICKB.92Jul22144428@farfle.farfle.asd.sgi.com>
  6. Message-ID: <Brtrwz.1nr@news.cso.uiuc.edu>
  7. Sender: usenet@news.cso.uiuc.edu (Net Noise owner)
  8. Organization: University of Illinois at Urbana
  9. Distribution: gnu
  10. Date: Thu, 23 Jul 1992 04:46:09 GMT
  11. Lines: 37
  12.  
  13. rickb@farfle.farfle.asd.sgi.com (Rick Braumoeller) writes:
  14. : Hiliting is one of the most useful features of Epoch, IMHO.  I would
  15. : like to use it in cmushell mode, for various reasons.  Thing is, I
  16. : don't how to describe the mode line for CMUshell --
  17. : (hilit::mode-list-update "CMU shell: run" cmushell-mode-hilit)
  18. : doesn't seem to work.  Does anybody know what I need to use for this?
  19.  
  20. You can try using this function, if you want to modify hilit.el:
  21.  
  22. ;; Author: Lynn Slater (lrs@indetech.com).
  23. (defun true-mode-name ()
  24.   "Returns the name of the mode in such a form that the mode may be
  25.   re-established by calling the function named by appending '-name' to
  26.   this string.  This differs from the variable called mode-name in that
  27.   this is guaranteed to work while the values held by the variable may
  28.   have embedded spaces or other junk."
  29.   (let ((major-mode-name (symbol-name major-mode)))
  30.     (substring major-mode-name 0
  31.                (or (string-match "-mode" major-mode-name)
  32.                    (length major-mode-name)))))
  33.  
  34. Using this instead of 'mode-name' will probably solve your problem.
  35. (Of course, the strings that mode-name and true-mode-name return
  36. are different.)  Lightbrite (another highlighting package) uses this,
  37. for this reason.
  38.  
  39. Hope this helps,
  40.  
  41. Marc
  42.  
  43. -- 
  44. Marc Andreessen
  45. Software Development Group
  46. National Center for Supercomputing Applications
  47. marca@ncsa.uiuc.edu
  48.