igiCreateCodeEditor

Category: IGI (in-game GUI) — Code editor

Syntax:

igiCreateCodeEditor:Int()


Parameters

None



Returns

An editor handle.



Summary

Makes a code editor: a text box for code with syntax colouring, line numbers, undo and the usual editing keys. It keeps its own text, so make it once (in Main) and draw it with igiCodeEditor every frame.

This can be called any time, in Main or in the loop. The .lang file format is on its own page. See the IGI guide.



Example
Global editor:Int = igiCreateCodeEditor()
igiCodeEditorSetLanguage(editor, igiLoadLanguage("Media/bamboobasic.lang"))
igiCodeEditorSetText(editor, "Print " & Chr(34) & "Hello" & Chr(34))

BambooBasic © 2026 Michael Denathorn