Class FxStudioShell
java.lang.Object
privbot.ui.fx.FxStudioShell
The PrivBot settings studio: an ink masthead (brand mark, name, product, optional running pill), underlined
section tabs, a large page heading, a scrolling workspace and a footer with the actions — the workspace look
Elorin Wilderness Slayer introduced, shared by every plugin.
Swing owns the JFrame and JFXPanel (created on the EDT); the Scene is built on the
JavaFX thread. Section bodies are built lazily on first selection and cached until the window is disposed.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classDescribes a studio;FxStudioShell.Builder.build()creates the window (hidden) on the EDT. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe standard studio height; seeSTANDARD_WIDTH.static final intThe studio size every plugin should use unless it has a reason not to. -
Method Summary
Modifier and TypeMethodDescriptionstatic FxStudioShell.Builderbuilder()A blank builder for bespoke studios: add pages withFxStudioShell.Builder.addConfigSections(net.runelite.client.config.Config, net.runelite.client.config.ConfigManager),FxStudioShell.Builder.addFxSection(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.util.function.Supplier<javafx.scene.Node>, boolean)orFxStudioShell.Builder.addSwingSection(java.lang.String, java.lang.String, java.lang.String, java.lang.String, javax.swing.JComponent, boolean).voiddispose()External teardown (e.g.static FxStudioShell.BuilderforConfig(String title, String subtitle, net.runelite.client.config.Config config, net.runelite.client.config.ConfigManager configManager) A complete studio for a plain@ConfigItemconfig: one tab per@ConfigSection(a single Settings page when the config declares none), every control generated byFxConfigPageBuilderand writing live, standard size, and a single Done action.getFrame()Studio host window.voidselectSection(String id) Selects a section by id.voidsetStatusMessage(String message) Shows a short message in the footer, beside the footer note.voidshow()Shows the window and brings it to the front, creating it again if it was disposed.
-
Field Details
-
STANDARD_WIDTH
public static final int STANDARD_WIDTHThe studio size every plugin should use unless it has a reason not to.- See Also:
-
STANDARD_HEIGHT
-
-
Method Details
-
getFrame
Studio host window. -
show
public void show()Shows the window and brings it to the front, creating it again if it was disposed. Safe from any thread (posted to the EDT when called elsewhere). -
dispose
public void dispose()External teardown (e.g. plugin shutdown); same reset as Save/Cancel so the shell can be reopened. -
setStatusMessage
Shows a short message in the footer, beside the footer note. Safe from any thread. -
selectSection
Selects a section by id. Safe from any thread; ignored for unknown ids. -
builder
A blank builder for bespoke studios: add pages withFxStudioShell.Builder.addConfigSections(net.runelite.client.config.Config, net.runelite.client.config.ConfigManager),FxStudioShell.Builder.addFxSection(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.util.function.Supplier<javafx.scene.Node>, boolean)orFxStudioShell.Builder.addSwingSection(java.lang.String, java.lang.String, java.lang.String, java.lang.String, javax.swing.JComponent, boolean). PreferforConfig(java.lang.String, java.lang.String, net.runelite.client.config.Config, net.runelite.client.config.ConfigManager)for a plain@ConfigItemconfig. -
forConfig
public static FxStudioShell.Builder forConfig(String title, String subtitle, net.runelite.client.config.Config config, net.runelite.client.config.ConfigManager configManager) A complete studio for a plain@ConfigItemconfig: one tab per@ConfigSection(a single Settings page when the config declares none), every control generated byFxConfigPageBuilderand writing live, standard size, and a single Done action.
-