Basic vending, will probably require R-devel soon to get external functions
[RExecServer.git] / RDevice.h
blobb5d90752ca69a60c36c78180922bbe71421b4a59
1 #import <Cocoa/Cocoa.h>
2 #include "RDeviceImpl.h"
4 @class RDevice;
6 @protocol RDeviceDelegate
7 - (void)willChangeDelegateForDevice:(RDevice*)aDevice;
8 - (void)didChangeDelegateForDevice:(RDevice*)aDevice;
10 - (void)didUpdateDevice:(RDevice*)aDevice;
11 - (void)didActivateDevice:(RDevice*)aDevice withNumber:(int)num;
12 - (void)didDeactivateDevice:(RDevice*)aDevice withNumber:(int)num;
14 @end
16 @interface RDevice : NSObject {
17 QuartzDesc_t desc;
18 NSString *target;
19 NSString *display;
20 id<RDeviceDelegate> delegate;
22 + (Class)deviceForDisplay:(NSString*)display;
23 + (void)registerDevice:(Class)cls forDisplay:(NSString*)display;
25 - (id<RDeviceDelegate>)delegate;
26 - (void)setDelegate:(id<RDeviceDelegate>)delegate;
28 - (id)initWithDevice:(NewDevDesc*)dd size:(NSSize)size pointSize:(double)ps display:(NSString*)aDisplay target:(NSString*)aTarget
29 background:(int)bg antialias:(BOOL)antialias;
30 - (BOOL)canResize;
31 - (BOOL)canLocate;
32 - (BOOL)canDrawInView;
34 - (void)finishOpening;
35 - (void)flushDrawing;
37 - (NSSize)size;
38 - (void)setSize:(NSSize)newSize;
40 - (void)drawInRect:(NSRect)aRect;
41 - (void)redraw;
43 - (NSData*)deviceRepresentationOfType:(NSString*)aType;
44 - (NSString*)target;
45 - (NSString*)display;
47 - (void)close;
48 @end