-
Notifications
You must be signed in to change notification settings - Fork 0
/
Slider.ctxt
19 lines (19 loc) · 2.1 KB
/
Slider.ctxt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#BlueJ class context
comment0.target=Slider
comment0.text=\r\n\ Write\ a\ description\ of\ class\ Slider\ here.\r\n\ \r\n\ @author\ (your\ name)\ \r\n\ @version\ (a\ version\ number\ or\ a\ date)\r\n
comment1.params=x\ y\ width\ height\ colour\ r\ min\ max\ handleColour\ handleBorderColour\ borderColour\ border
comment1.target=Slider(int,\ int,\ int,\ int,\ greenfoot.Color,\ int,\ double,\ double,\ greenfoot.Color,\ greenfoot.Color,\ greenfoot.Color,\ int)
comment1.text=\r\n\ Constructor\ for\ Slider\r\n\ \r\n\ @param\ x\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Top\ left\ coordinate\ x\r\n\ @param\ y\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Top\ left\ coordinate\ y\r\n\ @param\ width\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Width\ of\ slider\r\n\ @param\ height\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Height\ of\ slider\r\n\ @param\ colour\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Background\ colour\ of\ slider\r\n\ @param\ r\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Radius\ of\ slider\ handle\r\n\ @param\ min\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Minimum\ value\ of\ the\ slider\r\n\ @param\ max\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Maxiumum\ value\ of\ the\ slider\r\n\ @param\ handleColour\ \ \ \ \ \ \ \ \ \ Colour\ of\ the\ handle\r\n\ @param\ handleBorderColour\ \ \ \ Border\ colour\ of\ the\ handle\r\n\ @param\ borderColour\ \ \ \ \ \ \ \ \ \ Border\ colour\ of\ the\ slider\r\n\ @param\ border\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Border\ width\r\n
comment2.params=
comment2.target=void\ act()
comment2.text=\r\n\ Listen\ for\ a\ mouse\ drag\r\n
comment3.params=mouseX
comment3.target=void\ drag(int)
comment3.text=\r\n\ Update\ the\ value\ of\ the\ slider\ based\ on\ the\ mouse's\ x-position\r\n\ \r\n\ @param\ mouseX\ \ \ \ The\ x-coordinate\ of\ the\ mouse\r\n
comment4.params=
comment4.target=void\ createImage()
comment4.text=\r\n\ Draw\ the\ rectangle\ and\ border\ for\ the\ slider\r\n\ Draw\ the\ circle\ and\ border\ for\ the\ handle\r\n
comment5.params=
comment5.target=double\ getValue()
comment5.text=\r\n\ Get\ the\ value\ of\ the\ slider\r\n\ \r\n\ @return\ \ \ \ \ \ The\ value\ of\ the\ slider\ rounded\ to\ 2\ decimal\ places\r\n
numComments=6