Custom radio button icons

BNig bernd.niggemann at
Tue Oct 13 18:00:43 EDT 2015

Hi Jacque,

this works for iconGravity left and keeps the distance of the right aligned
text at a constant distance from the icon.

on mouseUp
   ask "text for label of btn"
   if it is "" then exit mouseUp
   lock screen
   put "b1" into tBtnName
   set the label of button tBtnName to it
   put the width of button tBtnName into tButtonWidth
   put the leftMargin of button tBtnName into tLeftMargin
   put the formattedWidth of image id (the icon of btn tBtnName) into
   put measureText(the label of btn tBtnName, button tBtnName) into
   put 5 into tDistance -- change distance from Icon here
   put tButtonWidth - tLeftMargin - tImageWidth - tTextWidth - tDistance
into tRight
   set the rightMargin of button tBtnName to tRight
   unlock screen
end mouseUp

Kind regards

View this message in context:
Sent from the Revolution - User mailing list archive at

More information about the use-livecode mailing list