Initializes a newly allocated ruler marker, associating it with (but not adding it to) a specified ruler view and assigning the attributes provided.
Original signature is '- (id)initWithRulerView:(NSRulerView *)aRulerView markerLocation:(CGFloat)location image:(NSImage *)anImage imageOrigin:(NSPoint)imageOrigin'
Available in Mac OS X v10.0 and later.
Declaration Syntax
C# | Visual Basic | Visual C++ |
public NSRulerMarker( NSRulerView aRulerView, CGFloat location, NSImage anImage, NSPoint imageOrigin )
Public Sub New ( _ aRulerView As NSRulerView, _ location As CGFloat, _ anImage As NSImage, _ imageOrigin As NSPoint _ )
public: NSRulerMarker( NSRulerView^ aRulerView, CGFloat location, NSImage^ anImage, NSPoint imageOrigin )
Parameters
- aRulerView (NSRulerView)
- The ruler view with which to associate the ruler marker. This method raises an NSInvalidArgumentException if aRulerView is nil.
- location (CGFloat)
- The x or y position of the marker in the client view’s coordinate system, depending on whether the ruler view is horizontal or vertical.
- anImage (NSImage)
- The image displayed at the marker location. This method raises an NSInvalidArgumentException if anImage is nil.
- imageOrigin (NSPoint)
- The point within the image positioned at the marker location, expressed in pixels relative to the lower-left corner of the image.
Return Value
An initialized ruler marker object.
Version Information
- Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later), 10.5 (For Mac OS X 10.5 and later)