mirror of
https://github.com/JetBrains/intellij-sdk-code-samples.git
synced 2025-07-30 02:07:50 +08:00
Add Plugin Icon page + images & references
This commit is contained in:
parent
a40789f815
commit
7810f7f174
@ -32,6 +32,7 @@
|
||||
* [Plugin Actions](basics/plugin_structure/plugin_actions.md)
|
||||
* [Plugin Services](basics/plugin_structure/plugin_services.md)
|
||||
* [Plugin Configuration File](basics/plugin_structure/plugin_configuration_file.md)
|
||||
* [Plugin Icon](basics/plugin_structure/plugin_icon_file.md)
|
||||
* [Plugin Dependencies](basics/plugin_structure/plugin_dependencies.md)
|
||||
* [Kotlin for Plugin Developers](tutorials/kotlin.md)
|
||||
* [IDE Development Instances](basics/ide_development_instance.md)
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 85 KiB |
13
basics/plugin_structure/img/kotlin40.svg
Normal file
13
basics/plugin_structure/img/kotlin40.svg
Normal file
@ -0,0 +1,13 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40">
|
||||
<defs>
|
||||
<linearGradient id="kotlin-a" x1="2.195%" x2="91.789%" y1="91.369%" y2="0%">
|
||||
<stop offset="0%" stop-color="#8F67FF" stop-opacity=".987"/>
|
||||
<stop offset="56.707%" stop-color="#F9A02F" stop-opacity=".993"/>
|
||||
<stop offset="100%" stop-color="#F7861E"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
<g fill="none" fill-rule="evenodd">
|
||||
<polygon fill="#0EAEFF" points="4 4 4 35.995 36.001 35.995 20.045 19.925 36.001 4"/>
|
||||
<polygon fill="url(#kotlin-a)" points="20.064 4 4 20.893 4 35.995 20.041 19.925 35.995 4"/>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 631 B |
BIN
basics/plugin_structure/img/resource_directory_structure.png
Normal file
BIN
basics/plugin_structure/img/resource_directory_structure.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 85 KiB |
@ -6,7 +6,12 @@ There are two possible ways of organizing plugin content:
|
||||
|
||||
1. A plugin consisting of one `.jar` file placed in the plugins directory:
|
||||
|
||||
The archive should contain the configuration file (`META-INF/plugin.xml`) and classes that implement the plugin functionality. The configuration file specifies the plugin name, description, version, vendor, the supported IntelliJ IDEA version, plugin components, actions and action groups, and action user interface placement.
|
||||
The archive should contain the configuration file (`META-INF/plugin.xml`),
|
||||
plugin icon files (`META-INF/pluginIcon*.svg`),
|
||||
and the classes that implement the plugin functionality. The configuration file
|
||||
specifies the plugin name, description, version, vendor, the supported IntelliJ IDEA version,
|
||||
plugin components, actions and action groups, and action user interface placement.
|
||||
See the [Plugin Icon File](plugin_icon_file.md) page for more information about plugin icon svg files.
|
||||
|
||||
```
|
||||
.IntelliJIDEAx0/
|
||||
@ -17,6 +22,8 @@ There are two possible ways of organizing plugin content:
|
||||
...
|
||||
META-INF/
|
||||
plugin.xml
|
||||
pluginIcon.svg
|
||||
pluginIcon_dark.svg
|
||||
```
|
||||
|
||||
|
||||
@ -35,6 +42,8 @@ There are two possible ways of organizing plugin content:
|
||||
...
|
||||
META-INF/
|
||||
plugin.xml
|
||||
pluginIcon.svg
|
||||
pluginIcon_dark.svg
|
||||
```
|
||||
|
||||
All jars from the `lib` folder are automatically added to the classpath.
|
||||
|
47
basics/plugin_structure/plugin_icon_file.md
Normal file
47
basics/plugin_structure/plugin_icon_file.md
Normal file
@ -0,0 +1,47 @@
|
||||
---
|
||||
title: Plugin Icon
|
||||
---
|
||||
|
||||
Beginning in version 2018.3, the IntelliJ Platform supports representing a plugin with an icon.
|
||||
A _Plugin Icon_ is intended to be a unique representation of a plugin's functionality, technology, or
|
||||
company.
|
||||
|
||||
Plugin Icons are shown in the Settings/Preferences [Plugin Manager](https://www.jetbrains.com/help/idea/managing-plugins.html) UI
|
||||
in JetBrains' products. Plugin Icons also appear in the [Plugins Repository](https://plugins.jetbrains.com/),
|
||||
and also in [MarketPlace](https://plugins.jetbrains.com/marketplace).
|
||||
|
||||
### Plugin Icon File Format
|
||||
All Plugin Icon images must be provided in SVG format.
|
||||
Plugin Icons will be displayed in 40px by 40px and 80px by 80px size. However, _only one
|
||||
size icon_ should be supplied because the IntelliJ Platform will automatically
|
||||
scale the image as needed.
|
||||
|
||||
| Icon Size | Example SVG Icon |
|
||||
| ------------- | ------------- |
|
||||
| 40x40 |  |
|
||||
|
||||
### Plugin Icon File Naming Convention
|
||||
Plugin Icon files are named according to the following conventions:
|
||||
* `pluginIcon.svg` for use with the default (light) JetBrains IDE theme
|
||||
* `pluginIcon_dark.svg` for use with the Darcula JetBrains IDE theme
|
||||
|
||||
### Adding Plugin Icons to a Plugin Project
|
||||
The Plugin Icon files must be in the `META-INF` folder of the plugin distribution file,
|
||||
i.e. the *.jar or *.zip file you upload to the plugin repository and install into
|
||||
a JetBrains IDE.
|
||||
|
||||
To include Plugin Icons in your distribution file, place the Plugin Icon files
|
||||
into a plugin project's `resources/META-INF` folder. Note this requirement
|
||||
is the same regardless of using DevKit or Gradle for developing a plugin. For example:
|
||||
|
||||

|
||||
|
||||
### Plugin Icons API
|
||||
If you need access to existing Plugin Icons you can acquire
|
||||
them through the Plugin Repository using the following URL format:
|
||||
`https://plugins.jetbrains.com/api/icon?pluginId=${PLUGIN_XMLID}&theme=${DEFAULT|DARCULA}`
|
||||
Note the`theme` parameter may be omitted when you are retrieving an icon for a DEFAULT
|
||||
theme.
|
||||
|
||||
An example URL to retrieve the Fortran Plugin Icon would be:
|
||||
`https://plugins.jetbrains.com/api/icon?pluginId=org.jetbrains.fortran&theme=DEFAULT`
|
@ -87,7 +87,7 @@ This will clean any existing IntelliJ IDEA configuration files and generate a ne
|
||||
### 1.5 Running a Simple Plugin
|
||||
|
||||
Now add a new `HelloAction` class to the Java folder, and `plugin.xml` and `pluginIcon.svg` files in the `META-INF` folder.
|
||||
for more information about `pluginIcon.svg` files, see the [Plugin Icon File](/basics/plugin_structure/plugin_icon_file.md) section.
|
||||
For more information about `pluginIcon.svg` files, see the [Plugin Icon](/basics/plugin_structure/plugin_icon_file.md) page.
|
||||
|
||||
<img src="img/gradle_directory_structure.png" alt="Gradle directory structure" width="374px"/>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user