An open API service indexing awesome lists of open source software.

https://github.com/zonble/flutter_open_chinese_convert

Open Chinese Convert for Flutter
https://github.com/zonble/flutter_open_chinese_convert

Last synced: 11 months ago
JSON representation

Open Chinese Convert for Flutter

Awesome Lists containing this project

README

          

# flutter_open_chinese_convert

[![pub package](https://img.shields.io/pub/v/flutter_open_chinese_convert.svg)](https://pub.dev/packages/flutter_open_chinese_convert)
[![Build](https://github.com/zonble/flutter_open_chinese_convert/actions/workflows/ci.yml/badge.svg)](https://github.com/zonble/flutter_open_chinese_convert/actions/workflows/ci.yml)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://github.com/zonble/flutter_open_chinese_convert/blob/main/LICENSE)

flutter_open_chinese_convert bridges OpenCC (開放中文轉換) to your Flutter
projects. You can use the package to convert Traditional Chinese to Simplified
Chinese, and vise versa.

The package supports various conversion options:

- S2T: Simplified Chinese to Traditional Chinese.
- T2S: Traditional Chinese to Simplified Chinese.
- S2HK: Simplified Chinese to Traditional Chinese (Hong Kong Standard).
- HK2S: Traditional Chinese (Hong Kong Standard) to Simplified Chinese.
- S2TW: Simplified Chinese to Traditional Chinese (Taiwan Standard).
- TW2S: Traditional Chinese (Taiwan Standard) to Simplified Chinese.
- S2TWp: Simplified Chinese to Traditional Chinese (Taiwan Standard) with Taiwanese idiom.
- TW2Sp: Traditional Chinese (Taiwan Standard) to Simplified Chinese with Mainland Chinese idiom.

## Usage

All you need to do is to call `ChineseConverter.convert` with what you wan to
convert and a conversion option. For example:

```dart
import 'package:flutter_open_chinese_convert/flutter_open_chinese_convert.dart';

var text = '鼠标里面的硅二极管坏了,导致光标分辨率降低。';
var result = await ChineseConverter.convert(text, S2TWp());
// 滑鼠裡面的矽二極體壞了,導致游標解析度降低。
```

For further information, please visit:

- [OpenCC Project](https://github.com/BYVoid/OpenCC)
- [SwiftyOpenCC](https://github.com/ddddxxx/SwiftyOpenCC)
- [android-opencc](https://github.com/qichuan/android-opencc)