Uxntal
A Sublime Text 4 package for Drifblim-style Uxntal. Provides a language syntax, intelligent auto-completion, and a build system.
- 1 stars
Links
Versions
sublime-Uxntal
A Sublime Text 4 package for Drifblim-style Uxntal. Provides a language syntax, intelligent auto-completion, and a build system.
Feature List
- Syntax highlighting matching all valid Uxntal.
- Basic type detection for labels in Drifblim-style Uxntal.
- Intelligent auto-completion:
- Only shows valid names depending on the rune.
- Provides local references to labels in the same scope.
- Only suggests private labels and local forward references inside their scope.
- Suggests opcodes.
- Snippets for all default Varvara devices.
- Formatting on save via Uxnfor.
- Build systems for building and running Uxntal programs and for linting via Uxnlin.
Requirements
- An Uxn emulator.
- (Recommended) Uxncli (for running the below ROMs).
- ROMs for the following Uxn applications:
Setup
After installing this package, go to Preferences > Package Settings > Uxntal > Settings and set the paths to your Uxn emulator(s) and aforementioned ROMs.
Known issues and limitations
- Due to the way Sublime Text's
symbol.pyhandles words, the Goto Definition and Goto Reference commands do not work. This could only be fixed by either recreating said commands (à la LSP) or by monkey patching thesymbol_at_point()andreference_at_point()functions, both of which are outside of the scope of this package. (Note that Goto Symbol and Goto Symbol in Project are not affected by this and work correctly.) - Similarly, many inbuilt commands do not respect the
word_separatorssetting which might cause strange behaviour, especially in the presence of runes. (This issue has been raised here.) Care has been taken to try and work around this forauto_completein particular. - The auto-completion is not sophisticated enough to correctly handle labels defined inside of macros.
- If a name is defined multiple times across a project, sometimes as a macro and sometimes as a label, the auto-completion will handle it as a macro in all situations. (I strongly recommend you do not choose to do this!)