home *** CD-ROM | disk | FTP | other *** search
/ OpenStep 4.2 / Openstep-4.2-Intel-Developer.iso / NextLibrary / Frameworks / AppKit.framework / Versions / B / Headers / NSHelpManager.h < prev    next >
Text File  |  1996-10-17  |  2KB  |  72 lines

  1. /*
  2.     NSHelpManager.h
  3.     Application Kit
  4.     Copyright (c) 1995-1996, NeXT Software, Inc.
  5.     All rights reserved.
  6. */
  7.  
  8. #ifndef STRICT_OPENSTEP
  9.  
  10. #import <Foundation/NSObject.h>
  11. #import <Foundation/NSMapTable.h>
  12. #import <Foundation/NSGeometry.h>
  13. #import <Foundation/NSBundle.h>
  14. #import <AppKit/AppKitDefines.h>
  15. #import <AppKit/NSApplication.h>
  16.  
  17. @class NSString;
  18. @class NSAttributedString;
  19. @class NSArray;
  20. @class NSWindow;
  21.  
  22. @interface NSHelpManager : NSObject
  23. {
  24.     NSMapTable        *_helpMapTable;
  25.     NSMapTable        *_keyMapTable;
  26.     NSMapTable        *_bundleMapTable;
  27.     NSWindow        *_helpWindow;
  28.     NSWindow        *_shadowWindow;
  29.     NSWindow        *_evtWindow;
  30.     NSBundle        *_helpBundle;
  31. }
  32.  
  33. + (NSHelpManager *)sharedHelpManager;
  34. + (void)setContextHelpModeActive:(BOOL)active;
  35. + (BOOL)isContextHelpModeActive;
  36.  
  37. - (void)setContextHelp:(NSAttributedString *)attrString forObject:(id)object;
  38. - (void)removeContextHelpForObject:(id)object;
  39. - (NSAttributedString *)contextHelpForObject:(id)object;
  40.  
  41. - (BOOL)showContextHelpForObject:(id)object locationHint:(NSPoint)pt;
  42.  
  43. @end
  44.  
  45. //
  46. // Notifications for the activation/deactivation of the context help mode
  47. //
  48.  
  49. APPKIT_EXTERN NSString *NSContextHelpModeDidActivateNotification;
  50. APPKIT_EXTERN NSString *NSContextHelpModeDidDeactivateNotification;
  51.  
  52. //
  53. //  Conveniences for accessing Help.plist
  54. //
  55.  
  56. @interface NSBundle(NSBundleHelpExtension)
  57. - (NSAttributedString *)contextHelpForKey:(NSString *)key;    /* return nil if not found */
  58. @end
  59.  
  60. //
  61. //  Convenience methods on NSApplication
  62. //
  63.  
  64. @interface NSApplication(NSApplicationHelpExtension)
  65. - (void)activateContextHelpMode:(id)sender;
  66.   // Target method cover for [NSHelpManager setContextHelpModeActive:YES];
  67. - (void)showHelp:(id)sender;
  68. @end
  69.  
  70. #endif
  71.  
  72.