Package avail.environment

Types

Link copied to clipboard
data class AdaptiveColor(light: Color, dark: Color)

An abstraction for a color that's dependent on light versus dark mode.

Link copied to clipboard
class AvailEditor(val workbench: AvailWorkbench, moduleName: ModuleName) : JFrame
Link copied to clipboard
class AvailWorkbench : JFrame

AvailWorkbench is a simple user interface for the Avail builder.

Link copied to clipboard
class LayoutConfiguration(input: String = "")

Information about the window layout.

Link copied to clipboard
class MenuBarBuilder(val theMenuBar: JMenuBar)

A helper class for building the menu bar.

Link copied to clipboard
class MenuBuilder(val theMenu: JMenu)

A helper class for building menus.

Functions

Link copied to clipboard
fun codeSuitableTextPane(workbench: AvailWorkbench): JTextPane

Create a JTextPane, initializing it and its StyledDocument in a way that makes it suitable for displaying or editing Avail code. By default, make it editable.

Link copied to clipboard
fun Component.scroll(): JScrollPane

Either places the given component inside a JScrollPane or answers the JScrollPane that it's already inside.

Link copied to clipboard
fun JTextPane.scrollTextWithLineNumbers(): JScrollPane

Either places the receiver JTextArea inside a JScrollPane with line numbers presented as row headers, or answers the JScrollPane that it's already inside.

Link copied to clipboard
fun JTextComponent.showTextRange(rangeStart: Int, rangeEnd: Int)

Scroll the given JTextPane to ensure the given text range is visible, and preferably not jammed against the top or bottom border.