Kross (software)
Kross is a scripting framework for KDE Frameworks. Kross was originally designed for use in KOffice but eventually became the official scripting framework in KDE Software Compilation 4 before being dropped in Frameworks 6. The Kross scripting framework is not a scripting language itself; it is an interface for developers to support scripting by specifying functions, which the user will then script using a language that Kross supports. It currently supports Python, Ruby, JavaScript, and the Falcon Programming Language. Support for other languages can be added with modules.
Comparison with other scripting frameworks
SWIG: Simplified Wrapper and Interface Generator
- Kross currently has fewer supported scripting languages.
- Kross is built on top of Qt/KDE. This allows access to Qt/KDE things without needing extra effort to wrap them.
- Applications supporting Kross do not require as much code as to support SWIG.
- With SWIG, the set of supported scripting languages is determined at the time of compiling the application: each supported language must either have code in the application to invoke that language's interpreter, and/or have a shared library specific to that application–language pair whereas Kross doesn't need to know until runtime.
AppleScript
- OSA can be used with IPC, allowing a script to be in a separate process, whereas Kross scripts always run in the same process as the main application. In practical terms, using IPC allows a script to interface between several already-running applications; Kross does not.
- While Kross allows the scripter to write scripts in a language of their choice, AppleScript is one given language, though it can be called from within other languages.
- Kross always requires code added to the application explicitly for Kross, whereas many macOS applications have basic scriptability just because of their choice of GUI toolkit . “Basic scriptability” here means at least being able to click on buttons and menus and access information provided to accessibility software such as Screen readers.
Applications using Kross
- Calligra Suite
- Kexi
- Krita
- KDevelop
- KTorrent
- Kopete
- Plasma