「Eclipse」の版間の差分

提供: ArchWiki
ナビゲーションに移動 検索に移動
22行目: 22行目:
 
=== デフォルトのアップデートサイトを追加 ===
 
=== デフォルトのアップデートサイトを追加 ===
   
あなたの使用している Eclipse のバージョンにあった、デフォルトのアップデートサイトが設定されていることを確認してください。プラグインが依存するパッケージは自動的にインストールされます。Eclipse の最新バージョンは Luna で、デフォルトのアップデートサイトは次になります: http://download.eclipse.org/releases/luna 。Go to Help > Install new Software > Add, fill the name to easily identify the update site later - for instance, Luna Software Repository - and fill the location with the url.
+
あなたの使用している Eclipse のバージョンにあった、デフォルトのアップデートサイトが設定されていることを確認してください。プラグインが依存するパッケージは自動的にインストールされます。Eclipse の最新バージョンは Luna で、デフォルトのアップデートサイトは次になります: http://download.eclipse.org/releases/luna 。Help > Install new Software > Add を選択して、後でアップデートサイトがわかるように名前を付けて下さい。例えば: Luna Software Repository。そして url を入力します。
   
 
=== Eclipse Marketplace ===
 
=== Eclipse Marketplace ===
   
  +
{{Note|あらかじめ[[#デフォルトのアップデートサイトを追加|デフォルトのアップデートサイトの追加]]セクションに従ってアップデートサイトを追加しておいて下さい。}}
{{Note|make sure you have followed the [[#Add the default update site|Add the default update site]] section.}}
 
To use the Eclipse Marketplace, install it first: go to Help > Install new software > Switch to the default update site > General Purpose Tools > Marketplace Client. Restart Eclipse and it will be available in Help > Eclipse Marketplace.
+
Eclipse Marketplace を使用するには、まずインストールを行ってください: Help > Install new software > Switch to the default update site > General Purpose Tools > Marketplace Client を開きます。Eclipse を再起動すれば Help > Eclipse Marketplace から使用することができるようになります。
   
 
=== プラグインマネージャ ===
 
=== プラグインマネージャ ===
   
  +
{{Note|あらかじめ[[#デフォルトのアップデートサイトを追加|デフォルトのアップデートサイトの追加]]セクションに従ってアップデートサイトを追加しておいて下さい。}}
{{Note|make sure you have followed the [[#Add the default update site|Add the default update site]] section.}}
 
 
Use Eclipse's plugin manager to download and install plugins from their original repositories: in this case you have to find the needed repository in the plugin's website, then go to ''Help > Install New Software...'', enter the repository in the ''Work with'' field, select the plugin to install from the list below and follow the instructions.
 
Use Eclipse's plugin manager to download and install plugins from their original repositories: in this case you have to find the needed repository in the plugin's website, then go to ''Help > Install New Software...'', enter the repository in the ''Work with'' field, select the plugin to install from the list below and follow the instructions.
   
76行目: 76行目:
 
=== オンライン版 ===
 
=== オンライン版 ===
   
  +
マシンから常時インターネットに接続している場合、オンラインドキュメントを使うことができます:
If you have constant Internet access on your machine, you can use the on-line documentation:
 
   
# Go to ''Window > Preferences'', then go to ''Java > Installed JREs''.
+
# ''Window > Preferences'' から、''Java > Installed JREs'' を開いて下さい。
  +
# "Standard VM" タイプの "java" が存在するので、それを選択して ''Edit'' をクリック。
# There should be one named "java" with the type "Standard VM". Select this and click ''Edit''.
 
# Select the {{ic|/opt/java/jre/lib/rt.jar}} item under "JRE system libraries:", then click ''Javadoc Location...''.
+
# "JRE system libraries:" の下の {{ic|/opt/java/jre/lib/rt.jar}} アイテムを選択して、''Javadoc Location...'' をクリック。
# Enter "http://docs.oracle.com/javase/7/docs/api/" in the "Javadoc location path:" text field.
+
# "Javadoc location path:" テキストフィールドに "http://docs.oracle.com/javase/7/docs/api/" と入力します。
   
 
=== オフライン版 ===
 
=== オフライン版 ===
   
You can store the documentation locally by installing the {{Pkg|openjdk8-doc}} package. Eclipse may be able to find the javadocs automatically. If that doesn't work, set Javadoc location for rt.jar to {{ic|file:/usr/share/doc/java8-openjdk/api}}.
+
{{Pkg|openjdk8-doc}} パッケージをインストールすることでドキュメントをローカルに保存することが可能です。Eclipse javadocs を自動的に検出します。自動検出が行われない場合、rt.jar Javadoc の位置を {{ic|file:/usr/share/doc/java8-openjdk/api}} に設定してください。
   
 
== トラブルシューティング ==
 
== トラブルシューティング ==
91行目: 91行目:
 
=== 最初の起動時や ''Help > Welcome'' を選択するとクラッシュする ===
 
=== 最初の起動時や ''Help > Welcome'' を選択するとクラッシュする ===
   
Add the following line to {{ic|/usr/share/eclipse/eclipse.ini}}:
+
以下の行を {{ic|/usr/share/eclipse/eclipse.ini}} に追加してください:
   
 
-Dorg.eclipse.swt.browser.UseWebKitGTK=true
 
-Dorg.eclipse.swt.browser.UseWebKitGTK=true
   
  +
Firefox をインストールしている場合は、以下も試して下さい:
If Firefox is installed try also:
 
   
 
-Dorg.eclipse.swt.browser.DefaultType=mozilla
 
-Dorg.eclipse.swt.browser.DefaultType=mozilla
121行目: 121行目:
 
=== Gnome 3.6 Adwaita テーマを使っている場合にツールチップの背景色が暗くなる ===
 
=== Gnome 3.6 Adwaita テーマを使っている場合にツールチップの背景色が暗くなる ===
   
Comment out the second-to-last line in {{ic|/usr/share/themes/Adwaita/gtk-2.0/gtkrc}} like this
+
{{ic|/usr/share/themes/Adwaita/gtk-2.0/gtkrc}} の最後から2番目の行を以下のようにコメントアウトしてください:
   
 
#widget "gtk-tooltip*" style "tooltips"
 
#widget "gtk-tooltip*" style "tooltips"
   
  +
関連するバグ:
Related bugs:
 
   
 
* https://bugzilla.gnome.org/show_bug.cgi?id=688285
 
* https://bugzilla.gnome.org/show_bug.cgi?id=688285
132行目: 132行目:
 
=== トグルボタンの状態が選択している時も選択していない時も変わらない ===
 
=== トグルボタンの状態が選択している時も選択していない時も変わらない ===
   
Comment out the last line in {{ic|/usr/share/themes/Adwaita/gtk-2.0/gtkrc}} like this
+
{{ic|/usr/share/themes/Adwaita/gtk-2.0/gtkrc}} の最後の行を以下のようにコメントアウトしてください:
   
 
#widget "*swt*toolbar*" style "null"
 
#widget "*swt*toolbar*" style "null"
   
  +
修正済みのテーマを適用するには、{{ic|gnome-tweak-tool}} で一度違うテーマを選択してから Adwaita に戻します。
To apply the fixed theme, use {{ic|gnome-tweak-tool}} to select a different theme and cycle back to Adwaita.
 
   
  +
関連するバグ:
Related bugs:
 
   
 
* https://bugzilla.gnome.org/show_bug.cgi?id=687519
 
* https://bugzilla.gnome.org/show_bug.cgi?id=687519
144行目: 144行目:
 
=== デフォルトのウィンドウタイトルのフォントサイズを変更 ===
 
=== デフォルトのウィンドウタイトルのフォントサイズを変更 ===
   
  +
Eclipse の設定からウィンドウタイトルのフォントサイズを変更することはできません。テーマの .css ファイルを編集する必要があります。Eclipse のアップデートで、変更した設定は戻ってしまうので注意してください。編集するファイルは以下のディレクトリにあります:
You can't change the window title font size using the Eclipse preferences, you must edit the actual theme .css files. Note, that you will have to redo this when you upgrade eclipse.
 
They are located under
 
 
/usr/share/eclipse/plugins/org.eclipse.platform_4.3.<your version number>/css
 
/usr/share/eclipse/plugins/org.eclipse.platform_4.3.<your version number>/css
  +
テキストエディタで適切なファイルを開いて下さい。例えば "GTK theme" を使用している場合、{{ic|e4_default_gtk.css}} を編集します。ファイルの中にある .MPartStack を探して、font-size を適当なサイズに変更してください:
Open the appropriate file with your text editor, ie e4_default_gtk.css if you are using the "GTK theme".
 
Search for .MPartStack, and change the font-size to your desired size
 
 
.MPartStack {
 
.MPartStack {
 
font-size: 9;
 
font-size: 9;

2015年7月3日 (金) 17:53時点における版

Eclipse はユニバーサルな開発プラットフォームを目指している、オープンソースコミュニティプロジェクトです。Eclipse プロジェクトはクロスプラットフォームの統合開発環境 (IDE) として広く知られています。Arch Linux パッケージ (とこのガイド) は IDE を扱っています。

Eclipse IDE は主として Java で書かれていますが Java, C/C++, PHP, Perl, Python など様々な言語によるアプリケーション開発に使うことができます。また、IDE は subversion をサポートしており、タスク管理もできます。

インストール

公式リポジトリから eclipse パッケージをインストールしてください。このベースパッケージには Java の開発サポートが組み込まれています。

Eclipse と Java

Java 開発者用の Eclipse IDE は AUR の eclipse-javaAUR パッケージでインストールできます。

プラグイン

pacman を使うことで多くのプラグインは簡単にインストールできます (詳しくは Eclipse プラグインパッケージガイドラインを見て下さい)。また、pacman を使うことでプラグインは最新状態に保たれます。他に、Eclipse Marketplace や Eclipse 内蔵のプラグインマネージャを使う方法もあります。

デフォルトのアップデートサイトを追加

あなたの使用している Eclipse のバージョンにあった、デフォルトのアップデートサイトが設定されていることを確認してください。プラグインが依存するパッケージは自動的にインストールされます。Eclipse の最新バージョンは Luna で、デフォルトのアップデートサイトは次になります: http://download.eclipse.org/releases/luna 。Help > Install new Software > Add を選択して、後でアップデートサイトがわかるように名前を付けて下さい。例えば: Luna Software Repository。そして url を入力します。

Eclipse Marketplace

ノート: あらかじめデフォルトのアップデートサイトの追加セクションに従ってアップデートサイトを追加しておいて下さい。

Eclipse Marketplace を使用するには、まずインストールを行ってください: Help > Install new software > Switch to the default update site > General Purpose Tools > Marketplace Client を開きます。Eclipse を再起動すれば Help > Eclipse Marketplace から使用することができるようになります。

プラグインマネージャ

ノート: あらかじめデフォルトのアップデートサイトの追加セクションに従ってアップデートサイトを追加しておいて下さい。

Use Eclipse's plugin manager to download and install plugins from their original repositories: in this case you have to find the needed repository in the plugin's website, then go to Help > Install New Software..., enter the repository in the Work with field, select the plugin to install from the list below and follow the instructions.

ノート:
  • If you install plugins with Eclipse's plugin manager, you are advised to launch Eclipse as root: this way the plugins will be installed in /usr/share/eclipse/plugins/; if you installed them as normal user, they would be stored in a version-dependent folder inside ~/.eclipse/, and, after upgrading Eclipse, they wouldn't be recognized any longer.
  • Do not use Eclipse as root for your everyday work.

プラグインマネージャでアップデート

Run Eclipse and select Help > Check for Updates. If you have installed them as root as advised in the section above, you have to run Eclipse as root.

For plugins to be updated, you should check to have their update repositories enabled in Window > Preferences > Install/Update > Available Software Sites: you can find each plugin's repository(es) on the respective project website. To add, edit, remove... repositories just use the buttons on the right of the Available Software Sites panel. For Eclipse 4.4 (Luna), check you have enabled this repository:

http://download.eclipse.org/releases/luna

To receive update notifications, go to Window > Preferences > Install/Update > Automatic Updates. If you want to receive notifications for plugins installed as root, you should run Eclipse as root, go to Window > Preferences > Install/Update > Available Software Sites, select the repositories related to the installed plugins and Export them, then run Eclipse as normal user and Import them in the same panel.

プラグイン一覧

  • AVR — AVR マイクロコントローラプラグイン。
http://avr-eclipse.sourceforge.net/wiki/index.php/The_AVR_Eclipse_Plugin || eclipse-avrAUR
  • Aptana — HTML5/CSS3/JavaScript/Ruby/Rails/PHP/Pydev/Django のサポート。スタンドアロンのアプリケーションとしても使えます。
http://www.aptana.com/ || eclipse-aptanaAUR aptana-studioAUR
  • Eclipse CDT — C/C++ のサポート。
http://www.eclipse.org/cdt/ || eclipse-cdt
  • Eclipse PDTPHP のサポート。
http://www.eclipse.org/pdt/ || eclipse-pdtAUR
  • EclipseFPHaskell のサポート。
http://eclipsefp.github.io/ || eclipse-eclipsefpAUR
  • EGitGit のサポート。
http://www.eclipse.org/egit || eclipse-egitAUR
  • EPIC — Perl のサポート。
http://www.epic-ide.org/ || eclipse-epicAUR
  • IvyDE — IvyDE 依存関係マネージャ。
https://ant.apache.org/ivy/ivyde/ || eclipse-ivydeAUR
  • Markdown — Eclipse 用の Markdown エディタプラグイン。
http://www.winterwell.com/software/markdown-editor.php || eclipse-markdownAUR
  • MercurialEclipseMercurial のサポート。
https://bitbucket.org/mercurialeclipse/main/wiki/Home || eclipse-mercurialAUR
  • Mylyn — タスクリストのサポート。
http://www.eclipse.org/mylyn/ || eclipse-mylynAUR
  • PHPEclipse — PHP のサポート。
http://www.phpeclipse.com/ || eclipse-phpeclipseAUR
  • PyDevPython のサポート。
http://pydev.org/ || eclipse-pydevAUR
http://subclipse.tigris.org/ || eclipse-subclipseAUR
  • Subversive — Subversion のサポート。
http://www.eclipse.org/subversive/ || eclipse-subversiveAUR
  • TestNG — TestNG のサポート。
http://testng.org/doc/eclipse.html || eclipse-testngAUR
  • TeXlipseLaTeX のサポート。
http://texlipse.sourceforge.net/ || texlipseAUR
  • Eclipse PTP — 並列プログラミング C/C++ のサポート。
http://www.eclipse.org/ptp/ || eclipse-ptpAUR

javadoc との統合を有効にする

Want to see API entries when hovering the mouse pointer over standard Java methods?

オンライン版

マシンから常時インターネットに接続している場合、オンラインドキュメントを使うことができます:

  1. Window > Preferences から、Java > Installed JREs を開いて下さい。
  2. "Standard VM" タイプの "java" が存在するので、それを選択して Edit をクリック。
  3. "JRE system libraries:" の下の /opt/java/jre/lib/rt.jar アイテムを選択して、Javadoc Location... をクリック。
  4. "Javadoc location path:" テキストフィールドに "http://docs.oracle.com/javase/7/docs/api/" と入力します。

オフライン版

openjdk8-doc パッケージをインストールすることでドキュメントをローカルに保存することが可能です。Eclipse は javadocs を自動的に検出します。自動検出が行われない場合、rt.jar の Javadoc の位置を file:/usr/share/doc/java8-openjdk/api に設定してください。

トラブルシューティング

最初の起動時や Help > Welcome を選択するとクラッシュする

以下の行を /usr/share/eclipse/eclipse.ini に追加してください:

-Dorg.eclipse.swt.browser.UseWebKitGTK=true

Firefox をインストールしている場合は、以下も試して下さい:

-Dorg.eclipse.swt.browser.DefaultType=mozilla

Ctrl+X で Eclipse が終了する

Part of this bug. Just look in ~/workspace/.metadata/.plugins/org.eclipse.e4.workbench/workbench.xmi and delete the wrong Ctrl+X combination. Usually it is the first one.

Eclipse 4 に暗い/カスタムした gtk テーマが反映されず背景が白くなる

4.2.0 と 4.3.0

Remove or move to backup sub folder all of the .css files from: /usr/share/eclipse/plugins/org.eclipse.platform_4.2.0.v201206081400/css/

Solution source: http://www.eclipse.org/forums/index.php/m/872214/

This also works with version 4.3.x (Kepler) by backing up the css folder from /usr/share/eclipse/plugins/org.eclipse.platform_4.3.xxx/css/

4.4.0 (Luna)

Luna Supplies a Dark theme which can be enabled in Preferences > Appearance and selecting the 'Dark' theme.

The dark theme uses its own colours rather than the GTK theme colours, if you prefer it to fully respect GTK colour settings, then remove or move to backup sub folder all of the .css files from: /usr/share/eclipse/plugins/org.eclipse.ui.themes_1.0.0.xxxx/css/

Gnome 3.6 Adwaita テーマを使っている場合にツールチップの背景色が暗くなる

/usr/share/themes/Adwaita/gtk-2.0/gtkrc の最後から2番目の行を以下のようにコメントアウトしてください:

#widget "gtk-tooltip*"  style "tooltips"

関連するバグ:

トグルボタンの状態が選択している時も選択していない時も変わらない

/usr/share/themes/Adwaita/gtk-2.0/gtkrc の最後の行を以下のようにコメントアウトしてください:

#widget "*swt*toolbar*" style "null"

修正済みのテーマを適用するには、gnome-tweak-tool で一度違うテーマを選択してから Adwaita に戻します。

関連するバグ:

デフォルトのウィンドウタイトルのフォントサイズを変更

Eclipse の設定からウィンドウタイトルのフォントサイズを変更することはできません。テーマの .css ファイルを編集する必要があります。Eclipse のアップデートで、変更した設定は戻ってしまうので注意してください。編集するファイルは以下のディレクトリにあります:

/usr/share/eclipse/plugins/org.eclipse.platform_4.3.<your version number>/css

テキストエディタで適切なファイルを開いて下さい。例えば "GTK theme" を使用している場合、e4_default_gtk.css を編集します。ファイルの中にある .MPartStack を探して、font-size を適当なサイズに変更してください:

.MPartStack {
       font-size: 9;
       swt-simple: false;
       swt-mru-visible: false;
}

参照