In [ ]:
import com.twosigma.beakerx.widget.Image
import java.nio.file.Files
byte[] picture = Files.readAllBytes(new File("../../../doc/resources/img/widgetArch.png").toPath());
image = new Image()
image.format='png'
image.value= picture
image.width=300
image.height=400
image
In [ ]:
import com.twosigma.beakerx.widget.DatePicker
datePicker = new DatePicker()
datePicker
In [ ]:
datePicker.value
In [ ]:
datePicker.value = '20181027'
In [ ]:
datePicker.description = 'happy day'
In [ ]:
datePicker.disabled = true
In [ ]:
import com.twosigma.beakerx.widget.ColorPicker
cp = new ColorPicker()
cp.value = "blue"
cp
In [ ]:
cp.value
In [ ]:
cp.value = 'red'
In [ ]:
cp.concise = true
In [ ]:
cp.concise = false
cp.description = 'happy color'
In [ ]:
cp.disabled = true
In [ ]:
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.IntProgress
import com.twosigma.beakerx.widget.VBox
is = new IntSlider(value:30)
ip = new IntProgress(value: 30)
v = new VBox([is, ip])
In [ ]:
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.IntProgress
import com.twosigma.beakerx.widget.HBox
is2 = new IntSlider(value:30)
ip2 = new IntProgress(value: 30)
h = new HBox([is2, ip2])
In [ ]:
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.IntProgress
import com.twosigma.beakerx.widget.Tab
is3 = new IntSlider(value:30)
ip3 = new IntProgress(value: 30)
tb = new Tab([is3, ip3], ['speed', 'time'])
In [ ]:
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.IntProgress
import com.twosigma.beakerx.widget.Accordion
is4 = new IntSlider(value:30)
ip4 = new IntProgress(value: 30)
ac = new Accordion([is4, ip4], ['speed', 'time'])
In [ ]:
import com.twosigma.beakerx.widget.Play
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.HBox
import com.twosigma.beakerx.widget.Link
slider1 = new IntSlider()
play1 = new Play(value : 10, min : 0, max : 100)
link1 = new Link(play1, "value", slider1, "value")
box1 = new HBox([play1, slider1])
In [ ]:
import com.twosigma.beakerx.widget.Play
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.HBox
import static com.twosigma.beakerx.widget.Link.jslink
slider2 = new IntSlider()
play2 = new Play(value : 20, min : 0, max : 100)
link2 = jslink(play2, "value", slider2, "value")
box2 = new HBox([play2, slider2])
In [ ]:
import com.twosigma.beakerx.widget.Play
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.HBox
import com.twosigma.beakerx.widget.DirectionalLink
slider3 = new IntSlider()
play3 = new Play(value : 30, min : 0, max : 100)
link3 = new DirectionalLink(play3, "value", slider3, "value")
box3 = new HBox([play3 ,slider3])
In [ ]:
import com.twosigma.beakerx.widget.Play
import com.twosigma.beakerx.widget.IntSlider
import com.twosigma.beakerx.widget.HBox
import static com.twosigma.beakerx.widget.DirectionalLink.jsdlink
slider4 = new IntSlider()
play4 = new Play(value : 40, min : 0, max : 100)
link4 = jsdlink(play4, "value", slider4, "value")
box4 = new HBox([play4, slider4])
In [ ]: