Slider.Tracking (gb.qt4)
Property Tracking As Boolean
Indica se la
Slider emette eventi
Change continuati quando viene spostata, o solo quando il pulsante del mouse viene rilasciato.
Example
'Copia il codice in un'applicazione grafica ed eseguilo
Slider1 As Slider
Label1 As Label
Panel1 As Panel
Panel2 As Panel
Button1 As Button
HBox1 As HBox
Public Sub Form_Open()
With Me
.Height = 130
.Width = 330
.Arrangement = Arrange.Vertical
.Padding = 5
.Title = "Move the slider.."
End With
Slider1 = New Slider(Me) As "Slider1"
Slider1.Height = 28
Label1 = New Label(Me) As "Label1"
With Label1
.Height = 28
.Alignment = Align.Center
.Font.Bold = True
.Font.Size = 14
End With
Panel1 = New Panel(Me)
Panel1.Expand = True
HBox1 = New HBox(Me)
HBox1.Height = 28
Panel2 = New Panel(HBox1)
Panel2.Expand = True
Button1 = New Button(HBox1) As "Button1"
With Button1
.Height = 28
.Width = 133
.Text = "&Tracking on"
End With
Slider1_Change
End
Public Sub Slider1_Change()
Label1.Text = Slider1.Value
End
Public Sub Button1_Click()
If Button1.Text = "&Tracking on" Then
Button1.Text = "&Tracking off"
Slider1.Tracking = False
Else
Button1.Text = "&Tracking on"
Slider1.Tracking = True
Endif
End