0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

PlantUML を QuickLook するアプリケーション拡張を作りました

Posted at

PlantUML を QuickLook するアプリケーション拡張を作りました

 PlantUML を QuickLook で表示するアプリケーションプラグインです。

 ソースは GitHub に置きました(現在、ソースで配布するしかないという問題があります)。

 PlantUML は、編集中こそ Visual Studio Code などを使用して同時プレビューしながら作業が簡単です。しかし編集後は、ちょっと確認するためにエディタを起動するなど面倒です。QuickLook を使えるようにしたいです。

Environment

 開発に使用した環境は以下の通りです。

  • macOS Catalina 10.15.7
  • XCode 12.4(12D4e)
  • Swift 5.3.2

 これ以上の環境なら、おそらくビルドできるでしょう。

対応する拡張子

以下のファイル拡張子を PlantUML ファイルとして扱います。

  • pu
  • puml
  • plantuml
  • wsd
  • iuml

設定

 src/PlantUMLQuickLook/Info.plist にて、下記の設定を変更できます。

PlantUmlServer

 現在の設定は以下です。

http://www.plantuml.com/plantuml/png/

 ご自身で PlantUML サーバーを建てていたら、変更できます。その際は /png/ まで指定してください。/png/ しか対応していません。/svg/ としてもうまくいきません。

 またローカルコマンドを使用したい場合、ここに plantuml.jar へのフルパスを設定することもできます。例えば以下のように。

/Applications/plantuml.jar

javaCommandPath

 上記 PlantUmlServer 設定で、ローカルの .jar ファイルを選択した場合に使用します。

catCommandPath

 上記 PlantUmlServer 設定で、ローカルの .jar ファイルを選択した場合に使用します。

インストール?方法

 Xcode でビルドすると、上記拡張子が PlantUML として QuickLook できます。

TODO

参考

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?