public static Color CreateFrom(ArgbColor color) { int colorDifference; short colorIndex = DxfIndexedColorSet.GetColorIndex(color, out colorDifference); return(colorDifference != 0 ? Color.CreateFromRgb(color.Argb) : Color.CreateFromColorIndex(colorIndex)); }
public static short GetColorIndex( DxfIndexedColorSet indexedColors, ArgbColor color, out int colorDifference) { return(DxfIndexedColorSet.GetColorIndex(indexedColors.colors, color, out colorDifference)); }
internal static short smethod_14(Color color) { switch (color.ColorType) { case ColorType.ByLayer: return(256); case ColorType.ByBlock: return(0); case ColorType.None: return(257); default: return(DxfIndexedColorSet.GetColorIndex(color.ToArgbColor(DxfIndexedColorSet.AcadClassicIndexedColors))); } }
internal new static short GetColorIndex(ArgbColor color, out int colorDifference) { return(DxfIndexedColorSet.GetColorIndex(DxfIndexedColorSet.AcadClassicIndexedColors.colors, color, out colorDifference)); }
public new static short GetColorIndex(ArgbColor color) { int colorDifference; return(DxfIndexedColorSet.GetColorIndex(color, out colorDifference)); }