Sets the icon for the file or directory at the specified path.
Original signature is '- (BOOL)setIcon:(NSImage *)image forFile:(NSString *)fullPath options:(NSWorkspaceIconCreationOptions)options'
Available in Mac OS X v10.4 and later.
Declaration Syntax
C# | Visual Basic | Visual C++ |
public virtual bool SetIconForFileOptions( NSImage image, NSString fullPath, NSWorkspaceIconCreationOptions options )
Public Overridable Function SetIconForFileOptions ( _ image As NSImage, _ fullPath As NSString, _ options As NSWorkspaceIconCreationOptions _ ) As Boolean
public: virtual bool SetIconForFileOptions( NSImage^ image, NSString^ fullPath, NSWorkspaceIconCreationOptions options )
Parameters
- image (NSImage)
- The image to use as the icon for the file or directory.
- fullPath (NSString)
- The full path of the file or directory.
- options (NSWorkspaceIconCreationOptions)
- The icon representations to generate from the image. You specify this value by combining the appropriate “Workspace icon creation options” constants, using the C bitwise OR operator. Specify 0 if you want to generate icons in all available icon representation formats.
Return Value
YES if the icon was set; otherwise, NO.
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)