//
//  AMRollOverButton.h
//  PlateControl
//
//  Created by Andreas on Sat Jan 24 2004.
//  Copyright (c) 2004 Andreas Mayer. All rights reserved.
//
//	2005-06-02	- added shading support
//	2005-07-09	- added -tracksMouseInside and -setTracksMouseInside:
//					  (default is YES for compatibility reasons)
//	2008-04-29	- added controlShadow
//	2011-08-08	- appearance is now encapsulated inside AMRollOverBottonAppearance
//					  each subclass of AMRollOverButton has its own distinct appearance
//					  accessors are +appearance and +setAppearance:
//					- buttonType and bezelStyle are explicitely overwritten from NSButton


#import <AppKit/AppKit.h>
#import "AMRollOverButtonCell.h"
#import "AMRollOverButtonAppearance.h"


@interface AMRollOverButton : NSButton {
	NSButtonType am_buttonType; // there is no accessor for this in NSButton, so we keep track of the value here
	NSTrackingRectTag am_trackingRect;
	BOOL am_doesNotTrackMouseInside;
}

+ (AMRollOverButtonAppearance *)appearance;
+ (void)setAppearance:(AMRollOverButtonAppearance *)newAppearance;
+ (NSURL *)appearanceDataURL; // overwrite if you don't want to load the button data from the main bundle

- (id)initWithFrame:(NSRect)frameRect andTitle:(NSString *)title;

- (BOOL)tracksMouseInside;
- (void)setTracksMouseInside:(BOOL)flag;
// in case you don't need the roll over effect, set this to NO

// these are convienience methods that invoke the equally named cell methods

//- (NSString *)title;
//- (void)setTitle:(NSString *)newTitle;
//
//- (int)state;
//- (void)setState:(int)newState;
//
//- (BOOL)isBordered;
//- (void)setBordered:(BOOL)flag;

- (NSControlSize)controlSize;
- (void)setControlSize:(NSControlSize)newControlSize;

- (NSColor *)controlColor;
- (void)setControlColor:(NSColor *)newControlColor;

- (NSColor *)shadingColor;
- (void)setShadingColor:(NSColor *)newShadingColor;

- (NSColor *)frameColor;
- (void)setFrameColor:(NSColor *)newFrameColor;

- (NSColor *)textColor;
- (void)setTextColor:(NSColor *)newTextColor;

- (NSColor *)arrowColor;
- (void)setArrowColor:(NSColor *)newArrowColor;

- (NSColor *)mouseoverControlColor;
- (void)setMouseoverControlColor:(NSColor *)newMouseoverControlColor;

- (NSColor *)mouseoverShadingColor;
- (void)setMouseoverShadingColor:(NSColor *)newMouseoverShadingColor;

- (NSColor *)mouseoverFrameColor;
- (void)setMouseoverFrameColor:(NSColor *)newMouseoverFrameColor;

- (NSColor *)mouseoverTextColor;
- (void)setMouseoverTextColor:(NSColor *)newMouseoverTextColor;

- (NSColor *)mouseoverArrowColor;
- (void)setMouseoverArrowColor:(NSColor *)newMouseoverArrowColor;

- (NSColor *)highlightedControlColor;
- (void)setHighlightedControlColor:(NSColor *)newHighlightedControlColor;

- (NSColor *)highlightedShadingColor;
- (void)setHighlightedShadingColor:(NSColor *)newHighlightedShadingColor;

- (NSColor *)highlightedFrameColor;
- (void)setHighlightedFrameColor:(NSColor *)newHighlightedFrameColor;

- (NSColor *)highlightedTextColor;
- (void)setHighlightedTextColor:(NSColor *)newHighlightedTextColor;

- (NSColor *)highlightedArrowColor;
- (void)setHighlightedArrowColor:(NSColor *)newHighlightedArrowColor;

- (NSShadow *)controlShadow;
- (void)setControlShadow:(NSShadow *)newControlShadow;

- (NSShadow *)textShadow;
- (void)setTextShadow:(NSShadow *)newTextShadow;

- (NSShadow *)mouseoverTextShadow;
- (void)setMouseoverTextShadow:(NSShadow *)newMouseoverTextShadow;

- (NSShadow *)highlightedTextShadow;
- (void)setHighlightedTextShadow:(NSShadow *)newHighlightedTextShadow;

- (NSShadow *)highlightedControlShadow;
- (void)setHighlightedControlShadow:(NSShadow *)newHighlightedControlShadow;

- (double)popUpMenuDelay;
- (void)setPopUpMenuDelay:(double)newPopUpMenuDelay;

- (NSButtonType)buttonType;
- (void)setButtonType:(NSButtonType)newButtonType;

- (NSBezelStyle)bezelStyle;
- (void)setBezelStyle:(NSBezelStyle)newBezelStyle;

- (AMRollOverButtonShadingMode)shadingMode;
- (void)setShadingMode:(AMRollOverButtonShadingMode)newShadingMode;


@end
