Reloading altered keyboard layout

When using Ukulele, how can I get an altered keyboard layout in ~/Library/Keyboard\ Layouts to be reloaded without rebooting?


According to a thread in the Ukelele group, changing the key layout ID before installing can cause OS X to load the new layout. This should be done on a working copy of the layout bundle, not an installed one, and may not work in newer versions of OS X (I could not get it to work under High Sierra). If changing the ID doesn't work for you, logging out and back in again should reload keyboard layouts.

Steps:

  1. Open a working copy of the layout bundle in Ukelele. Note this can't be an installed, active layout (i.e. one in a relevant "Library/Keyboard Layouts" folder).
  2. Generate a new ID:
    1. In Ukelele's list of keyboard layouts for the bundle, right-click the layout and choose "Set Keyboard Name and Script…".
    2. Change the script (e.g. from "Unicode" to "Roman"), taking note of the original value.
    3. Click OK
    4. Repeat the last 3 steps and change the script back to the original value.
    5. Save the layout.
  3. If an older copy of the layout is installed, remove it from the relevant "Keyboard Layout" folder.
  4. Copy the updated layout to the relevant "Keyboard Layout" folder.

Under the hood, this changes the "id" attribute of the root <keyboard> element in Contents/Resources/<name>.layout within the bundle.