#include <APPLE/AppKit/NSTextView.h>

/*NSFindPanelAction

These constants define the tags for performFindPanelAction:.

typedef enum {
   NSFindPanelActionShowFindPanel = 1,
   NSFindPanelActionNext = 2,
   NSFindPanelActionPrevious = 3,
   NSFindPanelActionReplaceAll = 4,
   NSFindPanelActionReplace = 5,
   NSFindPanelActionReplaceAndFind = 6,
   NSFindPanelActionSetFindString = 7,
   NSFindPanelActionReplaceAllInSelection = 8
} NSFindPanelAction;
Constants
NSFindPanelActionShowFindPanel

Displays the find panel.

Available in Mac OS X v10.3 and later.
NSFindPanelActionNext

Finds the next instance of the queried text.

Available in Mac OS X v10.3 and later.
NSFindPanelActionPrevious

Finds the previous instance of the queried text.

Available in Mac OS X v10.3 and later.
NSFindPanelActionReplaceAll

Replaces all query instances within the text view.

Available in Mac OS X v10.3 and later.
NSFindPanelActionReplace

Replaces a single query instance within the text view.

Available in Mac OS X v10.3 and later.
NSFindPanelActionReplaceAndFind

Replaces a single query instance and finds the next.

Available in Mac OS X v10.3 and later.
NSFindPanelActionSetFindString

Sets the query string to the current selection.

Available in Mac OS X v10.3 and later.
NSFindPanelActionReplaceAllInSelection

Replaces all query instances within the selection.

Available in Mac OS X v10.3 and later.
NSFindPanelActionSelectAll

Selects all query instances in the text view.

Available in Mac OS X v10.4 and later.
NSFindPanelActionSelectAllInSelection

Selects all query instances within the selection.

Available in Mac OS X v10.4 and later.
Availability
Available in Mac OS X v10.3 and later.
Declared In
NSTextView.h*/
typedef enum {
   NSFindPanelActionShowFindPanel = 1,
   NSFindPanelActionNext = 2,
   NSFindPanelActionPrevious = 3,
   NSFindPanelActionReplaceAll = 4,
   NSFindPanelActionReplace = 5,
   NSFindPanelActionReplaceAndFind = 6,
   NSFindPanelActionSetFindString = 7,
   NSFindPanelActionReplaceAllInSelection = 8
} NSFindPanelAction;

@interface  NSTextView (ADD)

/*setUsesFindPanel:

Specifies whether the receiver allows for a find panel.

- (void)setUsesFindPanel:(BOOL)flag
Parameters
flag

YES to allow the use of a find panel, NO otherwise.
Availability
Available in Mac OS X v10.3 and later.
See Also
– usesFindPanel*/
- (void)setUsesFindPanel:(BOOL)flag;

/*setAllowsDocumentBackgroundColorChange:

Sets whether the receiver allows its background color to change.

- (void)setAllowsDocumentBackgroundColorChange:(BOOL)flag
Parameters
flag

YES if the receiver allows the background color to change, otherwise NO.
Discussion

This corresponds to the background color of the entirety of the text view, not just to a selected range of text.
Availability
Available in Mac OS X v10.3 and later.
See Also
– allowsDocumentBackgroundColorChange
– changeDocumentBackgroundColor:*/
- (void)setAllowsDocumentBackgroundColorChange:(BOOL)flag;

/*setDefaultParagraphStyle:

Sets the receiver’s default paragraph style.

- (void)setDefaultParagraphStyle:(NSParagraphStyle *)paragraphStyle
Parameters
paragraphStyle

The new default paragraph style.
Availability
Available in Mac OS X v10.3 and later.
See Also
– defaultParagraphStyle*/
- (void)setDefaultParagraphStyle:(NSParagraphStyle *)paragraphStyle;

/*breakUndoCoalescing

Informs the receiver that it should begin coalescing sucessive typing operations in a new undo grouping.

- (void)breakUndoCoalescing
Discussion

Typically this is invoked when saving the receiver’s contents.
Availability
Available in Mac OS X v10.4 and later.*/
- (void)breakUndoCoalescing;

@end
