eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'TranslucentColor':

Home

everywhere
www.exept.de
for:
[back]

Class: TranslucentColor


Inheritance:

   Object
   |
   +--Color
      |
      +--TranslucentColor

Package:
stx:libview
Category:
Graphics-Support
Version:
rev: 1.3 date: 2007-06-06 16:58:02
user: cg
file: TranslucentColor.st directory: libview
module: stx stc-classLibrary: libview

Description:


TranslucentColor represents colors with an alpha (transparency)
channel.
This is experimental and not yet used by the system.

[Instance variables:]

  alpha           <Integer>       the internal alpha value (0..255)


Class protocol:

instance creation
o  red: r green: g blue: b alpha: alpha


Instance protocol:

accessing
o  alpha
return the alpha value (0..1),
where 0 is completely transparent and 1 is completely opaque

o  alpha: alphaFraction
set the alpha value (0..1),
where 0 is completely transparent and 1 is completely opaque

o  privateAlpha
return the internal alpha value (0..255),
where 0 is completely transparent and 255 is completely opaque

o  setAlphaByte: aByteValuedInteger
set the alpha value (0..255),
where 0 is completely transparent and 255 is completely opaque

printing & storing
o  storeOn: aStream
append a string representing an expression to reconstruct the receiver
to the argument, aStream

queries
o  isOpaque
return true, if I represent an opaque color

o  isTranslucent
return true, if I represent a translucent color;
that is: not completely opaque

o  isTranslucentColor
return true, if I represent a translucent color;
This means: self isTranslucent, but isTransparent not

o  isTransparent
return true, if I represent a completely transparent color



ST/X 6.1.1; WebServer 1.620 at exept:8081; Thu, 24 May 2012 04:37:06 GMT