eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'LabelAndTwoIcons':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: LabelAndTwoIcons


Inheritance:

   Object
   |
   +--ListEntry
      |
      +--ModelListEntry
         |
         +--LabelAndIcon
            |
            +--LabelAndTwoIcons

Package:
stx:libwidg2
Category:
Views-Support
Version:
rev: 1.5 date: 2016/08/09 10:47:13
user: stefan
file: LabelAndTwoIcons.st directory: libwidg2
module: stx stc-classLibrary: libwidg2

Description:


like a LabelAndIcon, but adds another image to the right of the string.

Notice:
    This is different from ST-80's LabelAndIcon class, which
    inherits from Label. Therefore, things may change in the future.

copyright

COPYRIGHT (c) 2009 by eXept Software AG All Rights Reserved This software is furnished under a license and may be used only in accordance with the terms of that license and with the inclusion of the above copyright notice. This software may not be provided or otherwise made available to, or used by, any other person. No title to or ownership of the software is hereby transferred.

Instance protocol:

accessing
o  image2
return my second image (right of string)

o  image2: anImage
set the image2 (right of string)

displaying
o  displayOn: aGC x: x y: y opaque: opaque
display the receiver on a GC

queries
o  heightOn: aGC
return the height of the receiver, if it is to be displayed on aGC

o  widthOn: aGC
return the width of the receiver, if it is to be displayed on aGC


Examples:


in a button/label:
  |top l image|

  image := Image fromFile:'../../goodies/bitmaps/xpmBitmaps/countries/brazil.xpm'.
  l := (LabelAndTwoIcons icon:image string:'brazil').
  l image2:image.

  top := Button label:l.
  top open.
two images in a button/label:
  |top l image1 image2|

  image1 := Image fromFile:'../../goodies/bitmaps/xpmBitmaps/countries/brazil.xpm'.
  image2 := Image fromFile:'../../goodies/bitmaps/xpmBitmaps/countries/germany.xpm'.
  l := (LabelAndIcon form:image1 image:image2 string:'directory').

  top := Button label:l.
  top open.


ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Mon, 18 Nov 2024 04:37:16 GMT