super_keyboard_layout
0.9.1, released a year ago by nativeshell.dev
Keyboard layout mapping and layout change notifications for Flutter applications.
WASM-readyQuiet but busy
What it does
Maps between physical keys, logical keys, and platform-specific key codes based on the current keyboard layout. It also provides notifications when the keyboard layout changes on supported desktop platforms.
AI-written summary of version 0.9.1, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to handle keyboard layout mapping in a desktop application.
- You need to detect keyboard layout changes dynamically at runtime.
Skip it when
- You are building a mobile-first app that does not require complex physical/logical key mappings.
- You want to avoid external native dependencies like Rust.
Strengths
- Supports mapping between physical keys, logical keys, and platform-specific key codes.
- Provides layout change notifications.
- Supports macOS, Windows, and Linux.
Weaknesses
- Uses Rust internally, requiring toolchain handling or automatic binary downloads.
- Plugin is in a very early stage of development and experimental.
Setup
- Kind
- Flutter widgets
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 1
Uses Rust internally. If Rust is not installed, precompiled binaries are downloaded automatically, or rustup can be used to build from source.
final manager = await KeyboardLayoutManager.instance();
if (manager.supported) {
manager.onLayoutChanged.addListener(() {
print('Keyboard layout changed');
});
}
final layout = manager.currentLayout;
final logicalKey = layout.getLogicalKeyForPhysicalKey(PhysicalKeyboardKey.digit1, shift: true);Works with
Packages commonly used together with super_keyboard_layout: ones it builds on, ones built on it, and its own family.
- super_native_extensionssuper_keyboard_layout depends on itLow level interface for native APIs such as clipboard and Drag and Drop
- super_clipboardSame familyComprehensive clipboard access package supporting rich text, images, and custom data formats.
- super_drag_and_dropSame familyNative drag and drop for Flutter across desktop, mobile and web.
- super_context_menuSame familyContext menu widget supporting native menus on platforms and drag & drop transitions on mobile.
- super_hot_keyBuilt on super_keyboard_layoutRegister global system-wide hot keys on macOS and Windows.