s&
About
The Project
info
About s&box
map
Roadmap
monitoring
Metrics
Engine startup and usage numbers
Updates
newspaper
Latest News
published_with_changes
Changes
Release-by-release changelog
Games
Browse Games
Discover Games
gamejams
live now
Game Jam III
Ends
Fri 25 Sep
Theme
One More Round
The jam is running. Build something, or play the entries.
£
50,000
prizepool
View the jam
Workshop
Playable
sports_esports
Games
Standalone games and gamemodes
Assets
landscape
Maps
view_in_ar
Models
texture
Materials
apparel
Clothing
apps
Everything
Every asset type in one list
Forum
Learn
Documentation
rocket_launch
Getting Started
docs
Documentation
api
API Reference
Resources
school
Tutorials
manage_search
Code Search
input
Log in with Steam
chevron_left
Change Language
简体中文
English
Русский
Español
Português-Brasil
Deutsch
日本語
Français
Polski
Türkçe
한국어
Pirate
Italiano
ไทย
繁體中文
Українська
Čeština
Nederlands
Magyar
Dansk
Suomi
Svenska
Norsk
Ελληνικά
Română
Български
Tiếng Việt
Bahasa Indonesia
Español-Latinoamérica
العربية
Api
Classes
SliderControl
chevron_left
Classes
class
SliderControl
Constructors
functions
SliderControl
Properties
data_object
Fill
data_object
Max
data_object
Min
data_object
NumberFormat
data_object
OnValueChanged
data_object
ShowRange
data_object
ShowTextEntry
data_object
ShowValueTooltip
data_object
Step
data_object
SupportsMultiEdit
data_object
TickStep
data_object
Value
Methods
lock
OnMiddleClick
lock
OnMouseDown
lock
OnMouseMove
functions
Rebuild
functions
ScreenPosToValue
functions
Tick
SliderControl
A float control drawn as a draggable slider, optionally with a text entry.
class
Sandbox.UI
.
account_tree
extends
BaseControl
Sandbox.Engine
build
Constructors
1
SliderControl
(
)
data_object
Properties
12
Fill
SliderFill
Which part of the track is drawn filled - from the left up to the thumb by default.
Max
float
The right side of the slider.
Min
float
The left side of the slider.
NumberFormat
string
How to display numbers in this control
OnValueChanged
Action`1
ShowRange
bool
Show the range values above the slider
ShowTextEntry
bool
Show a text entry next to the slider
ShowValueTooltip
bool
When changing the value show the tooltip
Step
float
If set to 1, value will be rounded to 1's If set to 10, value will be rounded to 10's If set to 0.1, value will be rounded to 0.1's
SupportsMultiEdit
bool
TickStep
float
Draw a mark on the track every this many units, counting up from Sandbox.UI.SliderControl.Min. 0 for none.
Value
float
functions
Methods
6
OnMiddleClick
(
e
)
OnMouseDown
(
e
)
On mouse press jump to that position
OnMouseMove
(
e
)
If we move the mouse while we're being pressed then set the value
Rebuild
(
)
ScreenPosToValue
(
pos
)
float
Convert a screen position to a value. The value is clamped, but not snapped.
Tick
(
)
Inheritance
Panel
BaseControl
SliderControl
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.