s&
About
The Project
infoAbout s&box mapRoadmap monitoringMetricsEngine startup and usage numbers
Updates
newspaperLatest News published_with_changesChangesRelease-by-release changelog
Games
Browse Games Discover Games
gamejamslive now

Game Jam III

Ends Fri 25 Sep
ThemeOne More Round

The jam is running. Build something, or play the entries.

£50,000
prizepool
View the jam
Workshop
Playable
sports_esportsGamesStandalone games and gamemodes
Assets
landscapeMaps view_in_arModels textureMaterials apparelClothing
appsEverythingEvery asset type in one list
Forum
Learn
Documentation
rocket_launchGetting Started docsDocumentation apiAPI Reference
Resources
schoolTutorials manage_searchCode Search
inputLog in with Steam chevron_leftChange Language
简体中文EnglishРусскийEspañolPortuguês-BrasilDeutsch日本語FrançaisPolskiTürkçe한국어PirateItalianoไทย繁體中文УкраїнськаČeštinaNederlandsMagyarDanskSuomiSvenskaNorskΕλληνικάRomânăБългарскиTiếng ViệtBahasa IndonesiaEspañol-Latinoaméricaالعربية
Api
Editor Classes
AutoComplete
chevron_left Editor Classes
class
AutoComplete

Constructors

functionsAutoComplete

Fields

crop_dinOnBuildOptionscrop_dinOnOptionSelected

Properties

data_objectHasAutocompleteOptionsdata_objectMinimumLengthdata_objectOpenOffset

Methods

functionsAddOptionfunctionsOnAutoCompletefunctionsOnGlobalMousePressedfunctionsOnParentBlurfunctionsOnParentKeyPressfunctionsOpenAbove
AutoComplete
class Editor .account_tree extends Menu
Sandbox.Tools

build Constructors 1

AutoComplete (parent)

crop_din Fields 2

OnBuildOptions
Action`2
The text has changed - fill in the options
OnOptionSelected
Action`1
You should hook this up to change the text on your control

data_object Properties 3

HasAutocompleteOptions
bool
MinimumLength
int
OpenOffset
Vector2

functions Methods 6

AddOption (name, icon, action, shortcut)
Option
Add an option for this autocomplete
OnAutoComplete (newPrefix, screenPosition)
OnGlobalMousePressed ()
Called when the mouse is pressed. Will hide this window if we clicked on anything except ourselves or our parent control.
OnParentBlur ()
Call this when the widget that spawns this blurs, so we can hide ourself
OnParentKeyPress (e)
You should call this from the parent when a key is pressed. Will forward the appropriate keys to us and accept the event.
OpenAbove (position)
Open above this position

Inheritance

QObject
Widget
Menu
AutoComplete
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.
Facepunch
  • News
  • Docs
  • Metrics
  • FAQ
  • Forum
  • Discord
  • Twitter