Skip to main content Link Search Menu Expand Document (external link)

selector.frame

description

Defines the style of the frame around the selected element. By default, it is set to solid 2px green.

syntax

getSelector(ELEMENT_NAME).frame(border style)
  • border style :

example(s)


@newImage("square", "square.png")
@,
@newImage("triangle", "triangle.png")
@    .before( getImage("square") )
@    .print()
@,
@newSelector("shapes")
@    .add( getImage("square") , getImage("triangle") )
$    .frame("dashed 3px violet")
@    .wait()
  • Adds two images side by side, waits for a click on either one of them and then prints a button. Until the button is clicked, the selected image appears in a dashed, violet, 3px-wide frame.