How to show a method description in Xcode auto-complete?

Asked

Viewed 54 times

0

I am developing a Framework and I would like when the user type himself and auto-complete suggest the method, below/above appear for what it serves. Like this:

inserir a descrição da imagem aqui

I thought I just said that:

/**
 * <Descrição aqui>
 */

1 answer

0

From Xcode 8.2 this is possible automatically, try placing the cursor on top of the function you want to document and then press the following button combination:

cmd + option + /

So he’ll present something like this:

/// <#Description#>
///
/// - parameter bar: <#bar description#>
///
/// - returns: <#return value description#>
  • cmd + option + / actually opens the emoji popup @Lucas :P

  • @Felipericieri what opens emojis is cmd + Ctrl + space

  • Check the version you are using of Xcode. What can be and what your keyboard shortcuts are changed. The shortcut supetão I mentioned is only to auto complete based on the method.

  • I was using the wrong shortcut, the command you passed really works. But he did not give me the behavior I wanted, illustrated in the figure above.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.