Skip to content

Latest commit

 

History

History
118 lines (80 loc) · 5.15 KB

File metadata and controls

118 lines (80 loc) · 5.15 KB

KStateMachine Visual

IntelliJ plugin for KStateMachine — visualize and navigate state machines straight from your source.


Build Version Downloads IntelliJ Platform Slack

💾 Install  ·  ✨ Features  ·  🗺️ Roadmap  ·  🏗️ Build  ·  💬 Discussions


KStateMachine Visual is the IDE plugin for the KStateMachine Kotlin library.

It statically analyzes your Kotlin source — including if / when branches that the runtime PlantUML export cannot see — and shows every state machine in the current file as both a navigable tree and a rendered UML state diagram.

Click any tree node to jump to its declaration; move the editor caret and the tree selection follows. Gutter icons mark every createStateMachine / state / transition call. The diagram updates live as you type, and the PlantUML source can be copied or exported as SVG.

Note

Early development — feedback on real-world DSL usage especially welcome.


✨ Features

  • Recursive parsing of nested DSL — any depth, including states inside if / when branches
  • Tree view with per-kind icons (initial, final, choice, history, data, mutable data, parallel, …)
  • Bidirectional editor ↔ tree navigation
  • Rendered PlantUML & Mermaid state diagram in-panel (JS layout — no Graphviz needed)
  • Editable Playground tab for ad-hoc PlantUML (e.g. runtime exports)
  • Editor gutter icons next to every KStateMachine DSL call
  • Live, debounced refresh while typing
  • Copy PlantUML source / Export diagram as SVG
  • Open the current diagram in an online editor (plantuml.com / mermaid.live)

demo.mp4

💾 Install

From MarketplaceSettingsPluginsMarketplace → search "KStateMachine Visual", or open the plugin page and click * Install*.

Manual — download the .zip from Releases and use SettingsPlugins⚙️Install plugin from disk….

Compatibility: IntelliJ Platform 2026.2 (Community or Ultimate), bundled Kotlin + Java plugins required. On 2026.1 install version 0.2.0 — the Marketplace serves it automatically.


🗺️ Roadmap

Planned

  • Project-wide tab listing every machine across the project
  • Rename refactoring of state names via the tree
  • Inspection: unreachable states and missing initial states
  • In-editor preview balloon anchored to the machine

🏗️ Build

./gradlew buildPlugin     # marketplace-ready ZIP in build/distributions/
./gradlew runIde          # launch sandbox IDE with the plugin loaded
./gradlew verifyPlugin    # check against IntelliJ guidelines

🤝 Contributing & support

PRs and issues welcome. Reports with a minimal reproducible DSL snippet are the most actionable.

Channel Best for
Slack #kstatemachine Quick questions
GitHub Issues Bug reports, features
GitHub Discussions Longer-form questions
KStateMachine library Questions about the library

Licensed under the MIT License