{"id":17194197,"url":"https://github.com/xuchunyang/emacs-opencc","last_synced_at":"2025-04-13T20:12:17.009Z","repository":{"id":38271779,"uuid":"94415472","full_name":"xuchunyang/emacs-opencc","owner":"xuchunyang","description":"中文简繁转换 \u003c-\u003e 中文簡繁轉換","archived":false,"fork":false,"pushed_at":"2017-07-23T17:18:59.000Z","size":13,"stargazers_count":17,"open_issues_count":2,"forks_count":4,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-27T10:47:02.979Z","etag":null,"topics":["chinese","emacs","opencc"],"latest_commit_sha":null,"homepage":null,"language":"Emacs Lisp","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xuchunyang.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-15T08:03:36.000Z","updated_at":"2025-01-13T10:46:09.000Z","dependencies_parsed_at":"2022-08-18T15:21:32.888Z","dependency_job_id":null,"html_url":"https://github.com/xuchunyang/emacs-opencc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xuchunyang%2Femacs-opencc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xuchunyang%2Femacs-opencc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xuchunyang%2Femacs-opencc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xuchunyang%2Femacs-opencc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xuchunyang","download_url":"https://codeload.github.com/xuchunyang/emacs-opencc/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248774976,"owners_count":21159534,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chinese","emacs","opencc"],"created_at":"2024-10-15T01:46:16.105Z","updated_at":"2025-04-13T20:12:16.982Z","avatar_url":"https://github.com/xuchunyang.png","language":"Emacs Lisp","funding_links":[],"categories":[],"sub_categories":[],"readme":"# opencc.el [![MELPA](https://melpa.org/packages/opencc-badge.svg)](https://melpa.org/#/opencc)\n\n## 介绍\n\n`opencc.el` 利用 [OpenCC](https://github.com/BYVoid/OpenCC) 的命令行工具实现在 Emacs 内进行中文简繁转换。\n\n## 需求\n\n- Emacs 版本至少 24.4\n- OpenCC\n\n## 使用\n\n### `(opencc-string CONFIG STRING)`\n\n按配置文件 CONFIG 转换字符串 STRING。比如把简体转换成繁体：\n\n\n```el\n(opencc-string \"s2t\" \"简繁转换\")\n     =\u003e \"簡繁轉換\"\n```\n\n### `(opencc-region CONFIG START END)`\n\n按配置文件 CONFIG 转换 START 和 END 之间的文字。\n\n### `M-x opencc-message`\n\n从 minibuffer 读取配置和字符串，然后用 `message` 显示结果。使用举例：\n\n    M-x opencc-message s2t RET 简繁转换 RET\n\n会显示“簡繁轉換”。\n\n### `M-x opencc-replace-at-point`\n\n从 Minibuffer 读取配置，转换并替换选中区域内的中文。如果没有可用的选中区域，用光标下的一句话。\n\n### `M-x opencc-print-buffer`\n\n转化当前 Buffer 的内容，在另一个 Buffer 中显示转换的结果。\n\n### `M-x opencc-insert-mode`\n\n\n输入的简体自动转换层繁体。可通过选项 `opencc-insert-mode-config` 调整转换的方向。\n\n### `M-x opencc-isearch-mode`\n\n输入简体搜索对应的繁体。可通过 `opencc-isearch-mode-config` 调整转换的方向。\n\n## 备注\n\n### [OpenCC 预设配置文件](https://github.com/BYVoid/OpenCC#configurations-配置文件)\n\n| 配置 | 说明 | 说明 |\n| --- | --- | --- |\n| s2t      | 简体到繁体                                         | Simplified Chinese to Traditional Chinese                                               |\n| t2s      | 繁体到简体                                         | Traditional Chinese to Simplified Chinese                                               |\n| s2tw     | 简体到台湾正体                                     | Simplified Chinese to Traditional Chinese \u003cTaiwan Standard\u003e                             |\n| tw2s     | 台湾正体到简体                                     | Traditional Chinese \u003cTaiwan Standard\u003e to Simplified Chinese                             |\n| s2hk     | 简体到香港繁体（香港小学学习字词表标准）           | Simplified Chinese to Traditional Chinese \u003cHong Kong Standard\u003e                          |\n| hk2s     | 香港繁体（香港小学学习字词表标准）到简体           | Traditional Chinese \u003cHong Kong Standard\u003e to Simplified Chinese                          |\n| s2twp    | 简体到繁体（台湾正体标准）并转换为台湾常用词汇     | Simplified Chinese to Traditional Chinese \u003cTaiwan Standard\u003e with Taiwanese idiom        |\n| tw2sp    | 繁体（台湾正体标准）到简体并转换为中国大陆常用词汇 | Traditional Chinese \u003cTaiwan Standard\u003e to Simplified Chinese with Mainland Chinese idiom |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxuchunyang%2Femacs-opencc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxuchunyang%2Femacs-opencc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxuchunyang%2Femacs-opencc/lists"}