MALIKA KAROUM

MALIKA KAROUM

  • Home
  • Inleiding
  • Unite Arab Emirates
  • Blog
  • video’s
  • Promotion
    • Worth for free now
    • Work from Home 2023
    • Gadgets
    • All about Windows
    • about Whatsapp
    • Whats the
    • About websites
    • New Ways
    • New Way of Watching
    • Virtual
    • Website
    • All about Video
    • How to Use
    • YouTube Info
    • All about Twitter
    • The Best of
    • About Apps
    • Google News
    • For Free
    • About This
    • Need More
    • Why should you
    • Iphone news
    • Interesting News
    • About Amazone
    • Some tips
    • About Netflix
    • All about Music
    • About Facebook
  • Marketing
    • Malika Karoum Strategie Modules
    • Malika Karoum Online Marketing
    • Malika Karoum Business Service
    • Malika Karoum Marketing Platform
    • Online business marketing
  • Luxury
    • The Indulgence Business site
    • The Luxury Web site
    • The Ultimate Indulgence
    • The Indulgence Site
    • The Ultimate Luxury Information site
    • Online luxury
  • Malika Karoum
    • Malika Karoum LinkedIn
    • Malika Karoum Facebook
    • Malika Karoum Instagram
    • Malika Karoum Business News
    • Adverteren grote fraude
    • Menu POS
    • Malika Karoum Evenementen
  • Security
  • Malika Karoum link
  • Home
  • Malika Karoum Global News
  • How to Save Time With Custom Keyboard Shortcuts on Raspberry Pi OS
October 1, 2023

How to Save Time With Custom Keyboard Shortcuts on Raspberry Pi OS

How to Save Time With Custom Keyboard Shortcuts on Raspberry Pi OS

by Malika Karoum / Sunday, 09 May 2021 / Published in Malika Karoum Global News

Raspberry Pi is a popular single-board computer (SBC) with a diverse set of applications. It conventionally runs on Raspberry Pi OS (formerly Raspbian), but you can install other operating systems on it as per your project requirements.

Like any other operating system, Raspberry Pi OS also has built-in keyboard shortcuts to help you perform operations quickly. Additionally, you get the ability to create custom keyboard shortcuts for running programs or performing certain actions on your Raspberry Pi.

Why Should You Create  Keyboard Shortcuts on Raspberry Pi?

With the Raspberry Pi OS (desktop environment), you typically run a program by locating it on the system and double-clicking it. Although this is totally acceptable, if you want to save yourself a few steps, you can assign a keyboard shortcut to the program/script you wish to run to execute it efficiently.

Likewise, you might also want to consider creating custom keyboard shortcuts if you have missing/broken keys on your keyboard. To this end, you can create a custom keybinding for the action linked to the broken/missing key and assign it to some other key on your keyboard.

For instance, if you use Scrot to take screenshots on Raspberry Pi and your keyboard doesn’t have the PrtScr (Print Screen) key, you can assign the program execution to your preferred key.

How to Create Custom Keyboard Shortcuts on Raspberry Pi OS

Openbox is the easiest way to create custom keyboard shortcuts on the Raspberry Pi OS. It is essentially a window manager for the X Window System — present on the Raspberry Pi OS (LXDE) — that lets you configure the behavior of almost every aspect of Pi OS’s desktop environment.

Related: The Best Linux Desktop Environment: LXDE vs. Xfce vs. MATE

One thing to note here, however, is that the keybindings you create with Openbox only work on Raspberry Pi OS desktop. So, you can’t trigger programs with these keybindings in the Terminal, be it in headless mode or over SSH (Secure SHell).

Following are the steps to create a keybinding in Openbox:

  1. Open the Terminal. You can either click on the Terminal icon (in the top bar) or use the CTRL + ALT + T shortcut to do this.
  2. Type sudo nano /etc/xdg/openbox/lxde-pi-rc.xml to open the configuration file that holds all the keybindings for the Raspberry Pi OS.
    openbox configuration file

  3. Scroll down to the section that reads Keybindings for running applications and use the following syntax to add a keybinding:
    <keybind key="keyboard_shortcut">
    <action name="action_to_perform">
    <command>command_name</command>
    </action>
    </keybind>

    Here’s how you can use the command:

    <keybind key="C-A-s">
    <action name="Execute">
    <command>gnome-screenshot --interactive</command>
    </action>
    </keybind>

    In the above example, we’ve assigned the CTRL + ALT + s shortcut to execute the GNOME Screenshot program. You can modify the above command to suit your requirements. Following are the key declarations you can use to create keybindings in Openbox:

    • A – ALT
    • C – CTRL
    • S – Shift
    • W – Super
    • M – Meta
    • space – Spacebar
    • Home – Home
    • End – End
    • Return – Enter
    • BackSpace – Backspace
    • Print – Print Screen
  4. Hit CTRL + O to write lines to the configuration file and CTRL + X to exit editing.
  5. Enter sudo reboot to reboot Raspberry Pi and apply your keybindings.

Aside from the key declarations, there are two more essential components in a keybinding command: actions and commands. By leveraging the two effectively, you can create keybindings for more complex operations on Raspberry Pi OS.

Actions

Actions are essentially operations that you tell the system to perform when their associated keyboard shortcuts are triggered. There are different kinds of actions to manipulate the Raspberry Pi OS desktop or its program windows.

One of the most commonly used actions is Execute, which lets you create keyboard shortcuts to run/launch programs. If you want to perform some other window action on a program, below are some more useful actions you can create keybindings for:

  • ToggleFullScreen: Makes the program run in full-screen view.
  • Iconify: Minimizes a program window.
  • ToggleMaximize: Maximizes/minimizes a window.
  • Close: Closes a program window.
  • PrevWindow: Cycles focus to the previous window.
  • NextWindow: Cycle focus to the next window.
  • ToggleShowDesktop: Hides all windows on the desktop.

These are, of course, only a handful of actions you can use with Openbox, and there are numerous other options for complex tasks that you can learn about over at Openbox’s wiki.

Commands

Commands are the most crucial component in creating keybindings. These are basically instructions that desktop shortcuts use to run their associated programs. You can enter these commands into the Terminal to verify if they work before using them in your keybindings.

Openbox keybindings leverage commands to perform your desired operations when the assigned keyboard shortcuts are triggered. To find the command for a program:

  1. Right-click on it (from the start menu) and go to Properties.
  2. Click on the Desktop Entry tab and select the value for the Command field.
    program file properties

Most programs have a simple command for their execution, but there are a few exceptions. For example, GNOME Screenshot requires you to use gnome-screenshot — interactive to run it with a custom keyboard shortcut.

Other commands for some of the commonly-used programs on Raspberry Pi:

  • pcmanfm: File Manager
  • lxterminal: Terminal
  • chromium-browser: Chromium browser
  • geany: Geany IDE
  • gnome-screenshot: GNOME Screenshot
  • gimp: GIMP

Similarly, in some programs, you may see commands with additional parameters like %U, %F in them. These parameters are for the Exec key in the .desktop files as part of the desktop entry specifications, and they determine how programs handle arguments.

But, unless you want to open programs in specific states, you won’t need to specify these parameters in their keybindings.

Using Custom Keyboard Shortcuts to Perform Tasks Efficiently

Using Openbox, you can create custom keyboard shortcuts to simplify a lot of your operations on the Raspberry Pi. If you prefer using your keyboard over the mouse for controlling and navigating operating systems, this is a great way to create key bindings that suit your similar needs on the Raspberry Pi OS.

But, a word of advice before you get too excited about custom keybindings: always ensure that the keybinding you’re creating isn’t already present in the Openbox configuration file. Also, verify that the action and the keyboard shortcut you intend to use in your keybinding aren’t already associated with another keybinding.

MUO – Feed

  • Tweet
Tagged under: Custom, Keyboard, Raspberry, Save, Shortcuts, Time

About Malika Karoum

What you can read next

What’s the Difference Between 4K and Ultra HD (UHD)?
Knowing These Google Tricks Will Make Your Genealogy Research Easy
How to Manually Add Album Art to iTunes

Malika Karoum Blog 2023

  • How to Delete the Last 15 Minutes of Your Google Search History

    There’s a quick way for you to clear your...
  • Lenovo Wants You to Know Its Yoga Pad Pro Can Be Used as a Portable Switch Display

    Sometimes, when playing with your Nintendo Swit...
  • The 5 Best Apps for Buying and Selling Pre-Owned Books

    We’ve all been at the point where we have...
  • Humble’s Recent "Heal Covid-19" Bundle Raised 1.2 Million for Charity

    To help raise money for COVID-19 relief in Indi...
  • Nintendo Partners With PlayVS to Make Its Games Recognized High School Varsity Athletics

    It’s odd—Nintendo gets a lot of flak for ...
  • The Pros and Cons of Playing Video Games on an Emulator

    If you’re a fan of playing retro video ga...
  • 5 Curators to Find the Best Articles Worth Reading on the Internet

    When anyone and everyone is a publisher, it isn...
  • Apple Could Unveil iPads With OLED Screens in 2023

    Apple only just switched from LCD to mini-LED d...
  • What Is Signal and How Does It Work?

    The chances are that you use at least one of th...
  • Samsung’s Upcoming Flagship Exynos Chipset Will Feature AMD’s RDNA2 GPU

    AMD confirmed its partnership with Samsung at C...
  • Atari Finally Reveals the Launch Date for the New Atari VCS Console

    At last, after what seems like an age (it pract...
  • Twitter Starts Testing Full-Screen Ads in Fleets

    Twitter has announced that it will be adding fu...
  • When Is Facebook Messenger Going to Offer End-to-End Encryption?

    Facebook Messenger is easy to use and has great...
  • Get Paid to Play Apps: How They Work and What You Risk

    You’ve probably seen advertisements for a...
  • When Will PS5 Production Ensure Supply Meets Demand?

    Despite the PS5’s launch taking place in ...
  • How to Manage Processes on Ubuntu Using System Monitor

    Linux, like most modern operating systems, is v...
  • How to Get Verified on Twitter and Finally Get That Blue Check Mark

    Twitter, like most social media platforms, offe...
  • 10 Street Photography Tips That Will Make You a Better Photographer

    Street photography is enjoyed by many enthusias...
  • Huawei Freebuds 4i Review: Quality ANC Earbuds for $100

    Huawei Freebuds 4i 8.00 / 10 Read Reviews Read ...
  • What Is Extended Reality (XR) and How Does It Work?

    We’re living in a digital age where the virtual...

MALIKA KAROUM ONLINE MARKETING PLATFORM

Office:
RME HOLDINGS SARL – DUBAI BRANCH

BUSINESS CENTER

Parcel ID: 345-835

Area: Bur Dubai

Sub Area: Burj Khalifa

UNITED ARAB EMIRATES

 

 

 

Malika Karoum Concept

Malika Karoum Projects

  • GET SOCIAL

© 2014 Malika Karoum -United Arab Emirate Dubai- All Rights Reserved

TOP