public class NamedColorSpace extends Object implements Comparable<NamedColorSpace>
OutputPreviewOptions
.Constructor and Description |
---|
NamedColorSpace(ColorSpace cs,
String name,
boolean userColorSpace)
Create a new NamedColorSpace.
|
NamedColorSpace(File iccProfile,
boolean userColorSpace)
Create a new NamedColorSpace from an ICC Profile.
|
NamedColorSpace(InputStream iccProfile,
boolean userColorSpace,
String defaultName)
Create a new NamedColorSpace from an ICC Profile.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(NamedColorSpace o)
Compares NamedColorSpaces based on their ColorSpace, with RGB coming before CMYK which comes before custom/user color spaces.
|
ColorSpace |
getColorSpace()
Gets the ColorSpace.
|
static String |
getDescription(ICC_Profile prof)
Gets the description of the ICC Profile from the tagged data in the profile.
|
String |
getName()
The human readable name of the color space that will be referenced from
OutputPreviewOptions . |
boolean |
isUserColorSpace()
Returns true if this is a user (custom) color space.
|
String |
toString() |
public NamedColorSpace(ColorSpace cs, String name, boolean userColorSpace)
cs
- The ColorSpace.name
- The human readable name of the color space to be referenced from the OutputPreviewOptions
.userColorSpace
- Set to true if this is a user (custom) color space.public NamedColorSpace(File iccProfile, boolean userColorSpace) throws FileNotFoundException, IOException
iccProfile
- the ICC Profile file.userColorSpace
- Set to true if this is a user (custom) color space.FileNotFoundException
IOException
public NamedColorSpace(InputStream iccProfile, boolean userColorSpace, String defaultName) throws FileNotFoundException, IOException
iccProfile
- the ICC Profile file.userColorSpace
- Set to true if this is a user (custom) color space.FileNotFoundException
IOException
public static String getDescription(ICC_Profile prof)
prof
- The ICC Profilepublic String getName()
OutputPreviewOptions
.OutputPreviewOptions
.public ColorSpace getColorSpace()
public boolean isUserColorSpace()
public int compareTo(NamedColorSpace o)
compareTo
in interface Comparable<NamedColorSpace>