3

In the Xcode26 beta (currently beta 2) the "+" Button to open the code snippets window in the window title bar is gone. There is still a "Create Code Snippet" menu point in the Editor menu, which opens the code snippets window when creating a new snippet, so the window (and snippets) is still there.

But is there any way to open (and use) the snippets window without creating a new snippet?

Am I missing something or is this "just a bug"?

1 Answer 1

5

Xcode 26 does seem to eliminate the + icon in the window titlebar. Oddly, when editing a storyboard, the + for the Objects library was moved to a new location in the bottom-left corner of the storyboard editor area. But there's no corresponding moved + icon when editing code.

The "Editor" | "Create Code Snippet..." menu does open the snippets window without creating a new snippet as long as there's no current text selection.

Right-clicking in the code editor includes a "Create Code Snippet..." context menu but doing that does add a new snippet in addition to opening the snippet window because, annoyingly, right clicking in a code editor always selects something as the context menu appears.

The simplest solution would be to assign a hotkey to the "Create Code Snippet..." shortcut. Go to Xcode -> Settings -> Shortcuts. In the Shortcuts pane, enter "snippet" into the search (filter) field. Click in the empty area to the right of the "Create Code Snippet..." shortcut. This activates a text field where you can enter your desired shortcut. Enter something like Ctrl-Option-S or whatever you like.

Now while working on any code, type the hotkey you set and the snippets window will appear. The only caveat is that you want to ensure you have no selected text when you enter the hotkey. If there's any selected text when the hotkey is typed then the snippet window will open with a new snippet added for the selected text. If you do this by mistake, it's easy enough to delete the new snippet.

Sign up to request clarification or add additional context in comments.

2 Comments

This Xcode UX is ridiculous but the shortcut trick does works. Thank you!
Thanks, mate. It looks like Apple is forcing us to use AI in Xcode 26 instead of all the good snippets

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.