[Seaside] Updated ColorValue>>fromString: to support 3-digit
notation
Philippe Marschall
philippe.marschall at gmail.com
Sat Jul 5 07:57:00 UTC 2008
http://code.google.com/p/seaside/issues/detail?id=88
2008/7/4, Boris Popov <boris at deepcovelabs.com>:
> I had just updated fromString method to support three-digit notation and
> pass the following test case, was thinking it might be useful to
> someone, but again, can't quite say if this is something Cincom folks
> need to integrate in their branch of Squeak-Extensions or something that
> should go into Squeak's version, so don't jump on my case for
> cross-posting please ;)
>
> testColorFromString
>
> self assert: (ColorValue fromString: 'ff0000') = ColorValue red.
> self assert: (ColorValue fromString: 'FF0000') = ColorValue red.
> self assert: (ColorValue fromString: '#ff0000') = ColorValue red.
> self assert: (ColorValue fromString: '#FF0000') = ColorValue red.
> self assert: (ColorValue fromString: 'f00') = ColorValue red.
> self assert: (ColorValue fromString: 'F00') = ColorValue red.
> self assert: (ColorValue fromString: '#f00') = ColorValue red.
> self assert: (ColorValue fromString: '#F00') = ColorValue red.
> self assert: (ColorValue fromString: 'red') = ColorValue red.
> self assert: (ColorValue fromString: 'RED') = ColorValue red.
> self assert: (ColorValue fromString: '#red') = ColorValue red.
> self assert: (ColorValue fromString: '#RED') = ColorValue red.
>
> Cheers,
>
> -Boris
>
> --
> +1.604.689.0322
> DeepCove Labs Ltd.
> 4th floor 595 Howe Street
> Vancouver, Canada V6C 2T5
> http://tinyurl.com/r7uw4
>
> boris at deepcovelabs.com
>
> CONFIDENTIALITY NOTICE
>
> This email is intended only for the persons named in the message
> header. Unless otherwise indicated, it contains information that is
> private and confidential. If you have received it in error, please
> notify the sender and delete the entire message including any
> attachments.
>
> Thank you.
>
>
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
>
>
More information about the seaside
mailing list