Plugin Development Overview
Noctalia Shell features a powerful plugin system that allows you to extend the shell with custom functionality. Plugins are written in QML and can integrate seamlessly with the shell’s UI and services.
What Can Plugins Do?
Section titled “What Can Plugins Do?”Plugins can provide several types of components, each serving different purposes:
Bar Widgets
Section titled “Bar Widgets”Add custom widgets to the top/bottom bar that provide quick access to information and actions.
Use cases:
- Display system information (CPU, memory, network)
- Show custom indicators (notifications, status)
- Quick action buttons (launcher, shortcuts)
- Status monitors (battery, time, weather)
Learn more: Bar Widget Development
Panels
Section titled “Panels”Create full-screen overlay panels that can be opened from bar widgets or triggered programmatically.
Use cases:
- Detailed information displays
- Complex UI interactions
- Configuration interfaces
- Content browsers and lists
Learn more: Panel Development
Main Component
Section titled “Main Component”Run background logic and handle IPC (Inter-Process Communication) commands. Optional component for plugins that need background processing.
Use cases:
- Process external commands via IPC
- Monitor system events
- Perform background tasks
- Integrate with external services
Learn more: IPC Guide
Settings UI
Section titled “Settings UI”Provide a settings interface that integrates with Noctalia’s settings panel, allowing users to configure your plugin.
Use cases:
- User configuration
- Plugin customization
- Feature toggles
- Preferences management
Learn more: Settings UI Guide (coming soon)
Plugin Architecture
Section titled “Plugin Architecture”Plugins in Noctalia follow a modular architecture:
your-plugin/├── manifest.json # Plugin metadata (required)├── preview.png # Preview image for plugin gallery (optional, recommended)├── Main.qml # Background logic with IPC handlers (optional)├── BarWidget.qml # Bar widget component (optional)├── Panel.qml # Panel overlay component (optional)├── Settings.qml # Settings UI component (optional)├── settings.json # User settings data (auto-generated)├── i18n/ # Translations (optional)│ ├── en.json│ └── es.json└── README.md # Plugin documentationPlugin Lifecycle
Section titled “Plugin Lifecycle”- Installation: Plugin is downloaded from a registry to
~/.config/noctalia/plugins/ - Registration: PluginRegistry scans the folder and validates the manifest
- Enabling: User enables the plugin in settings
- Loading: PluginService loads the plugin components and injects the Plugin API
- Running: Plugin components receive
pluginApiproperty with access to services - Settings: Users can configure the plugin through the integrated settings UI
- Unloading: When disabled, the plugin is cleanly unloaded
- Uninstallation: Plugin folder is removed from disk
Plugin API
Section titled “Plugin API”Every plugin component receives a pluginApi object that provides access to plugin functionality and Noctalia services.
Core Properties
Section titled “Core Properties”pluginId- Unique plugin identifierpluginDir- Plugin directory pathpluginSettings- User settings object (read/write)manifest- Plugin manifest datacurrentLanguage- Current UI language codemainInstance- Reference to the instantiated Main.qml component (null if not loaded)barWidget- Reference to the bar widget Component (null if not provided)
Core Functions
Section titled “Core Functions”saveSettings()- Persist settings to diskopenPanel(screen)- Open the plugin’s panelclosePanel(screen)- Close the plugin’s paneltr(key, interpolations)- Translate texttrp(key, count, ...)- Translate with pluralshasTranslation(key)- Check if translation exists
Noctalia Services
Section titled “Noctalia Services”Plugins have full access to Noctalia’s service ecosystem:
qs.Commons - Core utilities
Settings- Global Noctalia settingsI18n- InternationalizationLogger- Logging utilitiesStyle- Design system constantsColor- Theme-aware colors
qs.Services.UI - UI services
ToastService- Toast notificationsPanelService- Panel managementTooltipService- Tooltip display
qs.Services.System - System services
AudioService- Audio controlBatteryService- Battery informationNetworkService- Network status- And many more…
qs.Widgets - UI components
NButton,NIcon,NText,NTextInputNScrollView,NColorPicker, and more
Full API Reference
For complete API documentation, see the Plugin API Reference.
Learning Path
Section titled “Learning Path”Follow this recommended path to master plugin development:
-
Getting Started - Create your first plugin
- Set up your development environment
- Create a basic bar widget
- Understand the plugin structure
-
Manifest Reference - Understand plugin configuration
- Learn all manifest fields
- Configure entry points
- Set up default settings
-
Bar Widget Development - Build bar widgets
- Create interactive widgets
- Handle user interactions
- Style with Noctalia’s design system
-
Panel Development - Create overlay panels
- Build full-screen interfaces
- Handle panel lifecycle
- Create complex UIs
-
Plugin API Reference - Master the API
- Complete API documentation
- Service integration
- Advanced patterns
-
IPC Guide - Background processing
- Create IPC handlers
- Handle external commands
- Integrate with scripts and keybindings
-
Additional Topics (coming soon)
- Settings UI - Configuration interfaces
- Translations - Internationalization
- Styling Guide - Design system details
Example Plugins
Section titled “Example Plugins”Explore these example plugins in the official repository to see real-world implementations:
- hello-world - Demonstrates all plugin features (bar widget, panel, settings, IPC)
- launcher-button - Simple bar widget that opens the app launcher
- privacy-indicator - Shows when mic/camera/screen sharing is active
Next Steps
Section titled “Next Steps”Ready to start building? Head to the Getting Started guide to create your first plugin in just a few minutes!