[Plugin] ScriptDock - Interactive Python Script Launcher & Parameter Inspector Docker

Hello Krita Community,

I am new to both creating art and Krita. I consider myself as a good programmer and am as skilled as my cat when it comes to art.

And for my hobby game art, I had to perform many tasks related to resizing, aligning layers, exporting with specific dimensions, compiling large number of images into a sheet etc.. So, I turned to scripting all of these repetition tasks. But executing scripts through scripter or ten scripts has not been optimal. tenscripts does not auto reload scripts if the script itself changes/gets-fixed and has a limit of 10 scripts!.

That is where I had to build this plugin. ‘ScriptDock’. Designed to make discovering, customizing, and running Python scripts seamless and friendly.

If you frequently run scripts in Krita or write custom automation tools, ScriptDock brings everything together into a clean sidebar Docker panels
  • ScriptDock is a docker panel which you can manage/display in your workspace as you wish.
  • Tell ScriptDock a folder to monitor for scripts
  • Choose the script you want to execute from a dropdown
  • Customize/Override any parameters that the script can take
  • Execute
  • Check logs inside the panel itself if needed.
  • Hit refresh if you add new scripts to the directory using your normal OS file manager

Other:

  • One-Click Refresh: Added a new script to your folder externally? Click the
    refresh button to update the dropdown instantly without restarting Krita.
  • Dynamic Parameter Inspector: Automatically inspects parameter dictionaries
    (PARAMS = {...}) inside scripts and generates interactive PyQt controls:
    • Numbers ➔ Interactive Spinboxes
    • Booleans ➔ Checkboxes
    • Hex Colors ➔ Native PyQt Color Picker buttons
    • Strings ➔ Line Text Editors
  • Import Script Button: Easily upload/import external .py files straight into
    your scripts folder via a native file dialog.
  • Integrated Console Output: Real-time stdout (print()) logs and error
    tracebacks directly in the Docker’s collapsible console drawer.

How It Works (Example Script Format)

You can write simple scripts with a `PARAMS` block at the top, and ScriptDock automatically turns them into interactive UI sliders/inputs:

```python
from krita import Krita

# Expose parameters to ScriptDock UI
PARAMS = {
    "watermark_text": "Created with Krita",
    "font_size": 36,
    "opacity": 80,
    "primary_color": "#ff5500",
    "add_background": True
}

app = Krita.instance()
doc = app.activeDocument()

if doc:
    print(f"Applying '{PARAMS['watermark_text']}' with opacity {PARAMS['opacity']}%") 
──────

Quick Installation

  1. The code is opensource (MIT) at: GitHub - sudhir-asuracore/krita-scriptdock · GitHub
  2. Download script_runner.zip from the Latest Release on GitHub Release ScriptDock v1.0.1 · sudhir-asuracore/krita-scriptdock · GitHub .
  3. Install in Krita (Tools > Scripts > Import Python Plugin from File)

License: MIT License

Feedback, feature suggestions, and script contributions are very welcome! Let me know if
you run into any issues or have ideas for future updates. Happy painting!

And Thank you Krita.

1 Like