2017-11-15 8 views
1

プロジェクトにドキュメントを追加していますが、ブロックコメントを追加するためのショートカットが見つかりません。私はMarkup Formatting Reference guideを読んだが、ショートカットを見つけることができませんでした。Xcode 9にブロックコメントを追加するキーボードショートカット?

私はOption ⌥ + Command ⌘ + /を使用してコメントを追加していますが、すべての行に///が追加されています。

/// Initializer 
    /// 
    /// - Parameters: 
    /// - userId: User Id 
    /// - userName: User Name 
    /// - applicationVersion: Applicarion Version 

    init(_ userId: String, withUserName userName: String, withApplicationVersion applicationVersion: String) 

私は以下のようにブロックコメント/** ....*/を追加したい:確かを2.MakeのAppleScript

を使用して

/** 
- parameters: 
    - cubes: The cubes available for allocation 
    - people: The people that require cubes 
*/ 

答えて

1

1.Create Automatorのサービス

チェックされている "出力は、選択したテキストを置き換えます"

3.次のコードを入力します。

on run {input, parameters} 
return "/*\n" & (input as string) & "*/" 
end run 

これで、Xcode - サービスメニューから、またはシステム環境設定のショートカットを使って、そのサービスにアクセスできます。

関連する問題