From cef335019bf361676c82606d407b2947ad44e156 Mon Sep 17 00:00:00 2001 From: Mike Wey Date: Sun, 23 Oct 2011 21:04:08 +0200 Subject: Alias the symbols from the headers that are used in DMagick, so the user doesn't have to import them separately. --- dmagick/Color.d | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'dmagick/Color.d') diff --git a/dmagick/Color.d b/dmagick/Color.d index 2ddaa64..c9ea1ee 100644 --- a/dmagick/Color.d +++ b/dmagick/Color.d @@ -74,7 +74,7 @@ class Color * Create a Color and set the internal pointer to this PixelPacket. * We can use this to change pixels in an image through Color. */ - this(PixelPacket* packet) + package this(PixelPacket* packet) { this.packet = packet; } @@ -92,6 +92,7 @@ class Color this.packet.opacity = packet.opacity; } + /** */ override bool opEquals(Object obj) { Color color = cast(Color)obj; @@ -102,6 +103,9 @@ class Color return pixelPacket == color.pixelPacket; } + /** + * Returns the value as a hex string. + */ override string toString() { static if ( MagickQuantumDepth == 8 ) -- cgit v1.2.3