LinkButton.st
branchjv
changeset 5067 3a0ae394e2a2
parent 5011 46de83b69b3d
parent 5045 50eb267766b2
child 5097 5fbbb3dbef78
--- a/LinkButton.st	Tue May 03 09:17:35 2016 +0200
+++ b/LinkButton.st	Wed May 04 08:23:53 2016 +0200
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "
  COPYRIGHT (c) 2006 by eXept Software AG
               All Rights Reserved
@@ -41,7 +39,8 @@
 documentation
 "
     Looks like a Label, but behaves like a button with individually clickable text components.
-    Can be used to create html-page-look-alike links in a view.
+    Can be used to create html-page-look-alike links in a view,
+    especially to make label-looking action buttons.
 
     [author:]
         cg (cg@CG-VOSTRO)
@@ -154,6 +153,11 @@
 
     labelsAndActions := aCollectionOfAssociations.
     self label:((aCollectionOfAssociations collect:[:assoc | assoc key]) asStringWith:'')
+!
+
+level:anInteger
+    enterLevel := leaveLevel := onLevel := offLevel := level := anInteger.
+    margin := level abs.
 ! !
 
 !LinkButton methodsFor:'initialization'!
@@ -267,7 +271,7 @@
 !
 
 drawStringLogo:aString x:x y:y
-    "redefined to draw the part under the mouse pointer with an underined emphasis"
+    "redefined to draw any anchor under the mouse pointer with an underlined emphasis"
 
     |str entered mousePoint start len emphasis|