//
//  Constants.h
//  TermKit
//
//  Created by Colin Caufield on 7/19/14.
//

#import <Foundation/Foundation.h>
#import "Debug.h"

typedef enum
{
    BlockCursorShape = 0,
    UnderlineCursorShape = 1,
    VerticalLineCursorShape = 2
}
CursorShape;

#ifdef TERMKIT_IOS
    #import <UIKit/UIKit.h>
#else
    #import <Cocoa/Cocoa.h>
#endif

#define DEFAULTS NSUserDefaults.standardUserDefaults

#ifdef TERMKIT_IOS
    #define ARCHIVE(x) [NSKeyedArchiver archivedDataWithRootObject:(x)]
    #define XXFont UIFont
    #define XXColor UIColor
    #define colorWithDeviceRed colorWithRed
#else
    #define ARCHIVE(x) [NSArchiver archivedDataWithRootObject:(x)]
    #define XXFont NSFont
    #define XXColor NSColor
#endif

// NSUserDefaults keys.

extern NSString* const TermKitBackgroundColor;
extern NSString* const TermKitCopyOnSelect;
extern NSString* const TermKitCursorColor;
extern NSString* const TermKitCursorShape;
extern NSString* const TermKitDeleteSendsControlH;
extern NSString* const TermKitFont;
extern NSString* const TermKitForegroundColor;
extern NSString* const TermKitMiddleClickPaste;
extern NSString* const TermKitSelectionColor;
extern NSString* const TermKitShouldAntiAlias;
extern NSString* const TermKitTerminalIdentifier;
extern NSString* const TermKitUseOptionAsMeta;
extern NSString* const TermKitInitialDirectory;
extern NSString* const TermKitFavoriteKeys;

// NSAttributedString custom attributes.

extern NSString* const UserColorAttributeName;
extern NSString* const CursorAttributeName;
extern NSString* const BlinkAttributeName;
