TranslationPlugin README

The project's README from github.com/YiiGuxing/TranslationPlugin. As one markdown file: README.md.

TranslationPlugin TranslationPlugin

Plugin Homepage Build Status License GitHub releases Version Downloads Financial Contributors on Open Collective

Translation plugin for IntelliJ based IDEs/Android Studio.

screenshots




Getting Started 开始使用 はじめに 시작하기


Microsoft Translator      Google Translate      OpenAI Translator      DeepL Translator      Youdao Translate      Baidu Translate      Alibaba Translate


Features

Compatibility

Installation

Get from Marketplace

Restart the IDE after installation.

Using The Plugin

  1. Sign up for a translation service (optional)

    Most translation services require user registration to access their services (such as OpenAI, DeepL, Youdao Translate, etc.). Therefore, you may need to create an account, obtain an Authentication Key, and then bind the Authentication Key within the plugin:Preferences(Settings) > Tools > Translation > General > Translation Engine > Configure...

  2. Begin translating

    Select a text or hover the mouse over the text > Right-click > Translate

    Or use shortcuts for translation, as detailed in Actions.

  3. Replace with Translation

    Translate the target text and replace it. If the target language is English, the output has several formats: in camel case, with a word separator (when the output contains multiple words, the separator can be configured in the plugin configuration page: Translation Settings > Replace with Translation > Separator) and in the original format.

    Instructions: Select a text or hover the mouse over the text > Right-click > Replace with Translation (Or use shortcuts for translation, as detailed in Actions).

  4. Translate Documentation

    Quick Documentation and Inline Documentation can be translated via the context menu or shortcuts (detailed in Actions).

    Translation Settings > Other > Automatically translate documentation: When you check this option, the Quick Documentation will be automatically translated when you view it.

  5. Switch engines

    Click the engine widget in the status bar or use the shortcut Ctrl + Shift + S (macOS: Control + Meta + Y) to switch between the translation engine and the TTS engine quickly.

Actions

FAQ

If you have any questions, please ask here.

  1. What should I do if there is a network error or the network connection times out?

    A:

    • Check the network environment and make sure the network is running smoothly.
    • Check whether a proxy is preventing the plugin from accessing the translation API.
    • Check the IDE proxy configuration to see if that is the cause of the problem.
  2. What should I do if the translated content appears garbled?

    A: Garbled code generally appears when there is a lack of corresponding characters in the font. You can go to the Settings page of the plugin to modify the font in order to fix the garbled code (as shown below).

    screenshots

  3. What if I can't save the application key?

    A: You can try changing the way passwords are saved to In KeePass (Settings > Appearance & Behavior > System Settings > Passwords). For more details:

    • For macOS, please refer to #81
    • For Linux, please refer to #115
  4. What if the shortcuts don't work?

    A: The shortcut keys are most likely not working because they are being used in other plugins or external applications. You can reset shortcut keys for the corresponding operations.

Support and Donations

You can contribute and support this project by doing any of the following:

Thank you for your support!

Contributors

Technology Contributors

The CDN acceleration and security protection for this project are sponsored by Tencent EdgeOne.

Tencent EdgeOne

Code Contributors

This project exists thanks to all the people who contribute. [Contribute].

Financial Contributors

Become a financial contributor and help us sustain our community. [Contribute]

Backers

Thank you to all our backers! ❤️ [Become a backer]

Sponsors

Support this project by becoming a sponsor! Your logo will show up here with a link to your website. [Become a sponsor]

Donors

Name Website Amount
丿初音 475.00 CNY
剑平 120.00 CNY
山有扶苏 github.com/fobgochod 110.00 CNY
xudley xudley.cn 100.00 CNY
朱振山 100.00 CNY
丁云波 100.00 CNY
逆行 100.00 CNY
Kimmy 100.00 CNY
LiMingjun 100.00 CNY
DarknessTM github.com/darknesstm 100.00 CNY

More donors

TranslationPlugin (YiiGuxing/TranslationPlugin)

Searching Database…

这是什么?TranslationPlugin 是一款适用于基于 IntelliJ 的 IDE 和 Android Studio 的翻译插件,可让你使用多个翻译引擎,直接在编辑器中翻译文本、文档和代码符号。
它是独立的应用,还是 IDE 里的插件?它是一个插件,需要安装到现有的 JetBrains 系列 IDE(或 Android Studio、DevEco Studio)中,本身没有独立的应用程序。
使用它需要 API 密钥吗?大多数引擎开箱即用,但 OpenAI、DeepL 和有道翻译等服务需要先注册,并在插件设置中绑定 Authentication Key 才能使用。
安装或运行时有没有常见的坑?如果所选字体缺少相应字符,翻译结果可能显示为乱码;另外,应用密钥有时无法保存,除非你在 IDE 设置中把密码存储方式改为 KeePass;快捷键也可能与其他插件冲突。
它支持哪些 IDE?它适用于整个 JetBrains IDE 系列,以及 Android Studio 和华为 DevEco Studio,包括 IntelliJ IDEA、PyCharm、WebStorm、GoLand、CLion、PhpStorm、Rider、RubyMine、RustRover、DataGrip 等。
我的文本会发送到第三方服务器吗?会。翻译请求会发送到你选择的外部引擎(Microsoft、Google、DeepL、OpenAI、有道、百度或阿里巴巴),因此文本需要离开你的电脑才能完成翻译。
可以选择哪些翻译引擎?Microsoft Translator、Google Translate、DeepL Translator、OpenAI Translator、有道翻译、百度翻译和阿里翻译,另外还有 Microsoft Edge、Google 和 OpenAI 提供的 TTS。
除了选中的文本,它还能翻译其他内容吗?可以。除了选中或悬停的文本,它还能翻译快速文档(Quick Documentation)、行内文档(包括批量翻译文件中的所有行内文档)以及整个文档,并支持使用 Word Book 保存单词。
能用翻译后的文字替换代码标识符吗?可以。'Replace with Translation' 操作会翻译选中的文本,并可输出为 camelCase 格式(单词分隔符可配置),或保留原始格式,非常适合用来给变量命名。
如何快速切换翻译引擎?点击状态栏中的引擎小部件,或按 Ctrl+Shift+S(macOS 上为 Control+Meta+Y),即可在翻译引擎和 TTS 引擎之间切换,无需打开设置。
Creator
YiiGuxing
Size
24.7 MB
Stars
11.9K
Age
10y
Commits · 90 Days