To create new wiki account, please join us on #znc at Libera.Chat and ask admins to create a wiki account for you. You can say thanks to spambots for this inconvenience.

Translate

From ZNC
Revision as of 18:36, 17 December 2011 by DarthGandalf (talk | contribs) (Created page with "{{External Module}} This module acts as a translator between people, neither of whom know each other's language. Each person can just write in his/her preferred language, and...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This module acts as a translator between people, neither of whom know each other's language. Each person can just write in his/her preferred language, and this module will take care of translating both sides and seamlessly displaying the translated text to both parties. Module works for:

  • private messages between you and another person;
  • channels, between you and all other people on that channel;
  • channels, between you and one particular other person on that channel.

The module uses Google Translate via its API.

Installing

The code for this module can be found here. Follow the Compiling modules page to compile it.

Usage

Arguments

This user module takes no arguments.

Read loading modules to learn more about loading modules.

Configuration

Configuration is done via *translate

Commands

+---------+------------------------------+------------------------------------------------------+
| Command | Arguments                    | Description                                          |
+---------+------------------------------+------------------------------------------------------+
| my      | <xy>                         | Set your default language                            |
| set     | <channel> <xy> [<my>]        | Set language of channel                              |
| set     | <nick> <xy> [<my>]           | Set language of private messages for nick            |
| set     | <channel>/<nick> <xy> [<my>] | Set language for nick on channel                     |
| unset   | <channel or nick>            | Don't translate target anymore                       |
| clear   |                              | Clear all targets                                    |
| list    |                              | Show list of configured targets with their languages |
| help    |                              | Show this text                                       |
+---------+------------------------------+------------------------------------------------------+

You can use set #channel/nick to translate messages only to/from that nick on this channel. Messages to them have one of these forms (assuming, we speak to Nicky):

  • Nicky hello
  • Nicky, hello
  • Nicky: hello

set command has 1 optional parameter in the end - your language for translating conversations. If it's empty, using default, which is specified with my command.

Example:

set #znc/Nicky de bg

if you want to speak with Nicky (who is German) on #znc using Bulgarian.

Version history

2010-06-25

Fixed compilation errors for ZNC 0.090.

2010-04-22

Add support for set #channel/nick.

2009-12-01

First version.

Note

Contact DarthGandalf on irc://irc.freenode.net/#znc, or DGandalf on irc://irc.efnet.org/#znc for bug reports and suggestions.