Debian Codegraph @

hiro/cocoa/widget/label.hpp

raw
1 #if defined(Hiro_Label)
2
3 @interface CocoaLabel : NSView {
4 @public
5 hiro::mLabel* label;
6 }
7 -(id) initWith:(hiro::mLabel&)label;
8 -(void) resetCursorRects;
9 -(void) drawRect:(NSRect)dirtyRect;
10 -(void) mouseButton:(NSEvent*)event down:(BOOL)isDown;
11 -(void) mouseEntered:(NSEvent*)event;
12 -(void) mouseExited:(NSEvent*)event;
13 -(void) mouseMove:(NSEvent*)event;
14 -(void) mouseDown:(NSEvent*)event;
15 -(void) mouseUp:(NSEvent*)event;
16 -(void) mouseDragged:(NSEvent*)event;
17 -(void) rightMouseDown:(NSEvent*)event;
18 -(void) rightMouseUp:(NSEvent*)event;
19 -(void) rightMouseDragged:(NSEvent*)event;
20 -(void) otherMouseDown:(NSEvent*)event;
21 -(void) otherMouseUp:(NSEvent*)event;
22 -(void) otherMouseDragged:(NSEvent*)event;
23 @end
24
25 namespace hiro {
26
27 struct pLabel : pWidget {
28 Declare(Label, Widget)
29
30 auto minimumSize() const -> Size override;
31 auto setAlignment(Alignment alignment) -> void;
32 auto setBackgroundColor(Color color) -> void;
33 auto setForegroundColor(SystemColor color) -> void;
34 auto setForegroundColor(Color color) -> void;
35 auto setText(const string& text) -> void;
36
37 CocoaLabel* cocoaLabel = nullptr;
38 };
39
40 }
41
42 #endif