eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'BeveledBorder':

Home

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

Class: BeveledBorder


Inheritance:

   Object
   |
   +--AbstractBorder
      |
      +--BeveledBorder

Package:
stx:libview
Category:
Graphics-Support
Version:
rev: 1.8 date: 2017/02/22 20:20:19
user: cg
file: BeveledBorder.st directory: libview
module: stx stc-classLibrary: libview
Author:
Claus Gittinger

Description:


This will replace the mixture of window-system supported borders and manually
drawn 3D levels (which is ugly, but served me well for almost 20years now).


Class protocol:

constants
o  inset
Answer the default beveled border with inset edges.
usage example(s):
     self inset

o  inset1
Answer the default beveled border with inset edges of thickness 1.

o  raised
Answer the default beveled border with raised edges.

o  raised1
Answer the default beveled border with raised edges of thickness 1.

instance creation
o  level: aNumber

o  level: aNumber color: aColor


Instance protocol:

accessing
o  color

o  color: aColor

o  level
(comment from inherited method)
get the 3D level

o  level: anInteger

o  level: aNumber color: aColor

displaying
o  displayOn: aGC forDisplayBox: aRectangle
View new
border:(BeveledBorder level:2 color:Color red);
open.


Examples:


     |top v b|

    
     top := StandardSystemView extent:100@100.
     v := View origin:10@10 corner:90@30 in:top.
     top openAndWait.

     b := BeveledBorder raised1.
     v border:b.
     Delay waitForSeconds:1.
     v border:(BeveledBorder level:2).
     Delay waitForSeconds:1.
     v border:(BeveledBorder level:3).
     Delay waitForSeconds:1.
     v border:(BeveledBorder level:-3).
     Delay waitForSeconds:1.
     v border:(BeveledBorder level:-2).
     Delay waitForSeconds:1.
     v border:(BeveledBorder level:-1).
     Delay waitForSeconds:1.
     v border:(BeveledBorder level:0).
     |top v b|

     top := StandardSystemView extent:100@100.
     v := View origin:10@10 corner:90@30 in:top.
     top openAndWait.

     b := BeveledBorder inset1.
     v border:b.


ST/X 7.1.0.0; WebServer 1.663 at exept.de:8081; Wed, 19 Sep 2018 03:01:54 GMT