檢查和修復
質量檢查有助於發現常見的翻譯錯誤,確保翻譯質量良好。如果出現誤報,則可以忽略這些檢查。
提交未通過檢查的翻譯後,將立即向使用者顯示:

自動修正
除了 質量檢查 外,Weblate 還可以自動修復翻譯字串中的一些常見錯誤。謹慎使用它,不要使其增加翻譯錯誤。
也參考
質量檢查
Weblate 對字串進行了廣泛的質量檢查。以下部分將對它們進行更詳細的描述。還有針對特定語言的檢查。如果有錯誤報告,請將缺陷提交。
也參考
翻譯檢查
在每次翻譯更改時執行,幫助翻譯人員保持高質量的翻譯。
BBCode 標記
- 概要:
翻譯中的 BBCode 與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.BBCodeCheck
- 檢查標識符:
bbcode
- 忽略的標誌:
ignore-bbcode
BBCode 表示簡單的標記,例如以粗體或斜體突出顯示消息的重要部分。
此檢查確保在翻譯中也找到它們。
備註
當前檢測 BBCode 的方法非常簡單,因此此檢查可能會產生誤報。
連續重複單字
在 4.1 版本新加入.
- 概要:
文字在同一行中有兩個相同的單字:
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.duplicate.DuplicateCheck
- 檢查標識符:
duplicate
- 忽略的標誌:
ignore-duplicate
檢查翻譯中是否沒有連續重複的單詞。這通常表示翻譯錯誤。
提示
此檢查包括特定於語言的規則,以避免誤報。如果在您的情況下錯誤觸發,請告訴我們。請參閱 在 Weblate 中匯報問題。
與詞彙表不同
在 4.5 版本新加入.
- 概要:
翻譯未遵循詞彙表定義的字詞。
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.glossary.GlossaryCheck
- 檢查標識符:
check_glossary
- Flag to enable:
check-glossary
- 忽略的標誌:
ignore-check-glossary
此檢查必須使用“檢查詞彙表”標誌(參見:ref:“定制檢查”)。在啟用它之前請考慮以下操作:
它確實是精確的字串匹配,預計詞彙表將包含所有變體中的術語。
檢查每個字串針對詞彙表昂貴,它將減慢Weberate中的任何操作,涉及運行等待導入字串或翻譯。
兩個空白
- 概要:
翻譯含有兩個空白
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.DoubleSpaceCheck
- 檢查標識符:
double_space
- 忽略的標誌:
ignore-double-space
檢查翻譯中是否存在雙空格,以避免其他與空格相關的檢查出現誤報。
當在源中找到雙空格時,檢查為假,這意味著故意使用雙空格。
格式化字串
檢查字串格式是否在源和翻譯之間複製。在翻譯中省略格式字串通常會導致嚴重的問題,因此字串中的格式通常應與源匹配。
Weblate 支持檢查幾種語言的格式字串。僅當適當地標記了字串時(例如,C 格式為 c-format),才會自動啟用該檢查。 Gettext 會自動添加它,但是對於其他文件格式,或者如果您的 PO 文件不是由 xgettext 生成的,您可能必須手動添加它。
可以按每單位(請參閱 源字串另外的信息)或在 組件配置 中完成此操作。為每個組件定義它比較簡單,但是如果該字串未解釋為格式化字串,而碰巧使用了格式化字串語法,則可能導致誤報。
提示
如果 Weblate 中不提供特定格式的檢查,則可以使用通用 佔位符。
除了檢查,這也將高亮格式化字串,方便將它們插入到已翻譯字串:

AngularJS 插值字串
- 概要:
AngularJS 插值字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.angularjs.AngularJSInterpolationCheck
- 檢查標識符:
angularjs_format
- Flag to enable:
angularjs-format
- 忽略的標誌:
ignore-angularjs-format
- Named format string example:
您的餘額是{{ulity}} {{currency}}
C 格式
- 概要:
C 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.CFormatCheck
- 檢查標識符:
c_format
- Flag to enable:
c-format
- 忽略的標誌:
ignore-c-format
- Simple format string example:
這裡有 %d 顆蘋果
- Position format string example:
您的餘額是%1 $ d%2 $ s
C# 格式
- 概要:
C# 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.CSharpFormatCheck
- 檢查標識符:
c_sharp_format
- Flag to enable:
c-sharp-format
- 忽略的標誌:
ignore-c-sharp-format
- Position format string example:
這裡有 {0} 顆蘋果
也參考
ECMAScript 模板字面值
- 概要:
ECMAScript 模板字面值與來源不相符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.ESTemplateLiteralsCheck
- 檢查標識符:
es_format
- Flag to enable:
es-format
- 忽略的標誌:
ignore-es-format
- Interpolation example:
這裡有 ${number} 顆蘋果
也參考
i18next 插補
在 4.0 版本新加入.
- 概要:
i18next 插補與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.I18NextInterpolationCheck
- 檢查標識符:
i18next_interpolation
- Flag to enable:
i18next-interpolation
- 忽略的標誌:
ignore-i18next-interpolation
- Interpolation example:
這裡有 {{number}} 顆蘋果
- Nesting example:
這裡有 $t(number) 顆蘋果
ICU MessageFormat
在 4.9 版本新加入.
- 概要:
ICU MessageFormat 字串有語法錯誤或是佔位符不相符。
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.icu.ICUMessageFormatCheck
- 檢查標識符:
icu_message_format
- Flag to enable:
icu-message-format
- 忽略的標誌:
ignore-icu-message-format
- Interpolation example:
這裡有 {數量, 複數, 一 {一顆蘋果} 其他 {# 顆蘋果}}。
This check has support for both pure ICU MessageFormat messages as well as ICU with simple
XML tags. You can configure the behavior of this check by using icu-flags:*
, either by
opting into XML support or by disabling certain sub-checks. For example, the following flag
enables XML support while disabling validation of plural sub-messages:
icu-message-format, icu-flags:xml:-plural_selectors
|
Enable support for simple XML tags. By default, XML tags
are parsed loosely. Stray |
|
Enable support for strict XML tags. All |
|
Disable highlighting placeholders in the editor. |
|
Disable requiring sub-messages to have an |
|
Skip checking that sub-message selectors match the source. |
|
Skip checking that placeholder types match the source. |
|
Skip checking that no placeholders are present that were not present in the source string. |
|
Skip checking that no placeholders are missing that were present in the source string. |
Additionally, when strict-xml
is not enabled but xml
is enabled, you can use the
icu-tag-prefix:PREFIX
flag to require that all XML tags start with a specific string.
For example, the following flag will only allow XML tags to be matched if they start with
<x:
:
icu-message-format, icu-flags:xml, icu-tag-prefix:"x:"
This would match <x:link>click here</x:link>
but not <strong>this</strong>
.
Java 格式
- 概要:
Java 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.JavaFormatCheck
- 檢查標識符:
java_printf_format
- Flag to enable:
java-printf-format
- 忽略的標誌:
ignore-java-printf-format
- Simple format string example:
這裡有 %d 顆蘋果
- Position format string example:
您的餘額是%1 $ d%2 $ s
在 4.14 版本變更: This used to be toggled by java-format
flag, it was changed for consistency with GNU gettext.
Java MessageFormat
- 概要:
Java MessageFormat 字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.JavaMessageFormatCheck
- 檢查標識符:
java_format
- Flag to enable unconditionally:
java-format
- Flag to enable autodetection:
auto-java-messageformat
enables check only if there is a format string in the source- 忽略的標誌:
ignore-java-format
- Position format string example:
這裡有 {0} 顆蘋果
在 4.14 版本變更: This used to be toggled by java-messageformat
flag, it was changed for consistency with GNU gettext.
This check validates that format string is valid for the Java MessageFormat
class. Besides matching format strings in the curly braces, it also verifies
single quotes as they have a special meaning. Whenever writing single quote, it
should be written as ''
. When not paired, it is treated as beginning of
quoting and will not be shown when rendering the string.
也參考
JavaScript 格式
- 概要:
JavaScript 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.JavaScriptFormatCheck
- 檢查標識符:
javascript_format
- Flag to enable:
javascript-format
- 忽略的標誌:
ignore-javascript-format
- Simple format string example:
這裡有 %d 顆蘋果
Lua 格式
- 概要:
Lua 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.LuaFormatCheck
- 檢查標識符:
lua_format
- Flag to enable:
lua-format
- 忽略的標誌:
ignore-lua-format
- Simple format string example:
這裡有 %d 顆蘋果
Object Pascal 格式
- 概要:
Object Pascal 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.ObjectPascalFormatCheck
- 檢查標識符:
object_pascal_format
- Flag to enable:
object-pascal-format
- 忽略的標誌:
ignore-object-pascal-format
- Simple format string example:
這裡有 %d 顆蘋果
百分比佔位符
在 4.0 版本新加入.
- 概要:
百分比佔位符與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.PercentPlaceholdersCheck
- 檢查標識符:
percent_placeholders
- Flag to enable:
percent-placeholders
- 忽略的標誌:
ignore-percent-placeholders
- Simple format string example:
這裡有 %number% 顆蘋果
也參考
Perl 格式
- 概要:
Perl 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.PerlFormatCheck
- 檢查標識符:
perl_format
- Flag to enable:
perl-format
- 忽略的標誌:
ignore-perl-format
- Simple format string example:
這裡有 %d 顆蘋果
- Position format string example:
您的餘額是%1 $ d%2 $ s
PHP 格式
- 概要:
PHP 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.PHPFormatCheck
- 檢查標識符:
php_format
- Flag to enable:
php-format
- 忽略的標誌:
ignore-php-format
- Simple format string example:
這裡有 %d 顆蘋果
- Position format string example:
您的餘額是%1 $ d%2 $ s
也參考
:ref:“檢查格式”,“PHP Sprintf文件<https://www.php.net/manual/en/function.sprintf.php>`_,`php格式字串<https://www.gnu。組織/軟件/ GetText /手動/ html_node / php_002dformat.html>`_
Python 大括號格式
- 概要:
Python 大括號格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.PythonBraceFormatCheck
- 檢查標識符:
python_brace_format
- Flag to enable:
python-brace-format
- 忽略的標誌:
ignore-python-brace-format
- Simple format string:
這裡有 {} 顆蘋果
- Named format string example:
您的餘額是{COALE} {COMPORY}
Python 格式
- 概要:
Python 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.PythonFormatCheck
- 檢查標識符:
python_format
- Flag to enable:
python-format
- 忽略的標誌:
ignore-python-format
- Simple format string:
這裡有 %d 顆蘋果
- Named format string example:
Your balance is %(amount)d %(currency)s
Qt 格式
- 概要:
Qt 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.qt.QtFormatCheck
- 檢查標識符:
qt_format
- Flag to enable:
qt-format
- 忽略的標誌:
ignore-qt-format
- Position format string example:
這裡有 %1 顆蘋果
也參考
Qt 複數格式
- 概要:
Qt 複數格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.qt.QtPluralCheck
- 檢查標識符:
qt_plural_format
- Flag to enable:
qt-plural-format
- 忽略的標誌:
ignore-qt-plural-format
- Plural format string example:
``There are %Ln apple(s)``(譯註:無中文使用情境,因為蘋果我們不用加 s)
Ruby 格式
- 概要:
Ruby 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.ruby.RubyFormatCheck
- 檢查標識符:
ruby_format
- Flag to enable:
ruby-format
- 忽略的標誌:
ignore-ruby-format
- Simple format string example:
這裡有 %d 顆蘋果
- Position format string example:
您的餘額是%1 $ f%2 $ s
- Named format string example:
``您的餘額是%+。2 <COMPELL> S``的2 <金額>
- Named template string:
您的餘額是%{ulity}%{currency}
也參考
Scheme 格式
- 概要:
Scheme 格式字串與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.SchemeFormatCheck
- 檢查標識符:
scheme_format
- Flag to enable:
scheme-format
- 忽略的標誌:
ignore-scheme-format
- Simple format string example:
這裡有 ~d 顆蘋果
Vue I18n 格式
- 概要:
Vue I18n 格式與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.format.VueFormattingCheck
- 檢查標識符:
vue_format
- Flag to enable:
vue-format
- 忽略的標誌:
ignore-vue-format
- Named formatting:
這裡有 {count} 顆蘋果
- Rails i18n formatting:
這裡有 %{count} 顆蘋果
- Linked locale messages:
@:message.dio @:message.the_world!
也參考
格式化字串,』查看i18n格式<https://kazupon.github.io/vue-i18n/guide/formatting.html>`_,查看i18n鏈接本地消息<https:// kazupon。github .io / vue-i18n / guide / messages.html#linked-locale-messages>`_
已經翻譯過
- 概要:
字串之前已經有翻譯過
- 範圍:
all strings
- 檢查類:
weblate.checks.consistency.TranslatedCheck
- 檢查標識符:
translated
- 忽略的標誌:
ignore-translated
表示已經翻譯了一個字串。當翻譯在VCS中或否則丟失時,可能會發生這種情況。
不一致
- 概要:
此專案中的這個字串有一種以上的翻譯,或是在某些組件未翻譯。
- 範圍:
all strings
- 檢查類:
weblate.checks.consistency.ConsistencyCheck
- 檢查標識符:
inconsistent
- 忽略的標誌:
ignore-inconsistent
Weberate檢查項目中所有翻譯中相同字串的翻譯,以幫助您保持一致的翻譯。
檢查失敗了項目中的一個字串的不同轉換。這也可能導致顯示檢查中的不一致。您可以在以下網站上找到此字串的其他翻譯:Guilabel:“其他出現”選項卡。
This check applies to all components in a project that have 允許翻譯再用 turned on.
提示
For performance reasons, the check might not find all inconsistencies, it limits number of matches.
備註
This check also fires in case the string is translated in one component and not in another. It can be used as a quick way to manually handle strings which are untranslated in some components just by clicking on the Use this translation button displayed on each line in the Other occurrences tab.
您可以使用 自動翻譯 附加元件來自動翻譯從另一個組件中已翻譯字串到新添加而未翻譯的字串。
也參考
使用 Kashida letter
在 3.5 版本新加入.
- 概要:
不應該使用裝飾性的卡希達對齊字母
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.KashidaCheck
- 檢查標識符:
kashida
- 忽略的標誌:
ignore-kashida
裝飾kashida字母不應該在翻譯中使用。這些也稱為TatWeel。
Markdown 連結
在 3.5 版本新加入.
- 概要:
Markdown 連結與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.MarkdownLinkCheck
- 檢查標識符:
md-link
- Flag to enable:
md-text
- 忽略的標誌:
ignore-md-link
Markdown鏈接不匹配源。
也參考
Markdown 參照
在 3.5 版本新加入.
- 概要:
Markdown 連結參照與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.MarkdownRefLinkCheck
- 檢查標識符:
md-reflink
- Flag to enable:
md-text
- 忽略的標誌:
ignore-md-reflink
Markdown鏈接引用不匹配源。
也參考
Markdown 語法
在 3.5 版本新加入.
- 概要:
Markdown 語法與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.MarkdownSyntaxCheck
- 檢查標識符:
md-syntax
- Flag to enable:
md-text
- 忽略的標誌:
ignore-md-syntax
Markdown 語法與來源不符
翻譯最大長度
- 概要:
翻譯不該超過指定長度
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.MaxLengthCheck
- 檢查標識符:
max-length
- Flag to enable:
max-length
- 忽略的標誌:
ignore-max-length
檢查翻譯的長度是否可匹配可用的空間。這只檢查翻譯字符的長度。
與其他檢查不同,標誌應該被設置為“鍵:價值”(價值)對,如“Max-Length:100`”。
翻譯的最大長度
- 概要:
翻譯的呈現文字不該超過指定長度
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.render.MaxSizeCheck
- 檢查標識符:
max-size
- Flag to enable:
max-size
- 忽略的標誌:
ignore-max-size
在 3.7 版本新加入.
翻譯渲染文本不應超過給定的大小。它呈現出線包裝的文本,並檢查它是否適合給定邊界。
此檢查需要一個或兩個參數 - 最大寬度和最大行數。如果未提供行數,則考慮一行文本。
您還可以通過``font- *``指令配置已使用的字體(請參閱:ref:``custom-check`),例如隨圖的翻譯標誌說,使用ubuntu字體大小22呈現的文本應該適合兩行和500像素:
max-size:500:2, font-family:ubuntu, font-size:22
Mismatched \n
- 概要:
譯文中的換行數 \n 和源文不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EscapedNewlineCountingCheck
- 檢查標識符:
escaped_newline
- 忽略的標誌:
ignore-escaped-newline
Usually escaped newlines are important for formatting program output.
Check fails if the number of \n
literals in translation does not match the source.
冒號不相符
- 概要:
翻譯沒有和來源一致以冒號結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndColonCheck
- 檢查標識符:
end_colon
- 忽略的標誌:
ignore-end-colon
檢查冒號在源和翻譯之間複製冒號。還檢查了冒號的存在,以便他們不屬於哪種語言(中文或日語)。
刪節號不相符
- 概要:
翻譯沒有和來源一致以刪節號結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndEllipsisCheck
- 檢查標識符:
end_ellipsis
- 忽略的標誌:
ignore-end-ellipsis
檢查尾部橢圓在源和轉換之間複製尾部橢圓。這只檢查真正的省略號(...
)不適用於三個小點(...
)。
省略號通常比打印中的三個點更好,並且文本到語音更好地聽起來更好。
驚嘆號不相符
- 概要:
翻譯沒有和來源一致以驚嘆號結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndExclamationCheck
- 檢查標識符:
end_exclamation
- 忽略的標誌:
ignore-end-exclamation
檢查源和翻譯之間複製的感嘆號。還檢查了感嘆號的存在,他們不屬於哪種語言(中國,日語,韓國,亞美尼亞,林欄,緬甸或NKO)。
也參考
Wikipedia的感嘆號<https://en.wikipedia.org/wiki/exclamation_mark>`_
句號不相符
- 概要:
翻譯沒有和來源一致以句號結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndStopCheck
- 檢查標識符:
end_stop
- 忽略的標誌:
ignore-end-stop
檢查在源和翻譯之間複製完整停止。檢查全部停止的存在,以便他們不屬於哪種語言(中文,日語,Devanagari或Urdu)。
也參考
問號不相符
- 概要:
翻譯沒有和來源一致以問號結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndQuestionCheck
- 檢查標識符:
end_question
- 忽略的標誌:
ignore-end-question
檢查源和翻譯之間複製的問號。還檢查了問號的存在,以便他們不屬於哪些語言(亞美尼亞,阿拉伯語,中國,韓國,日語,埃塞俄比亞,vai或coptic)。
分號不相符
- 概要:
翻譯沒有和來源一致以分號結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndSemicolonCheck
- 檢查標識符:
end_semicolon
- 忽略的標誌:
ignore-end-semicolon
Checks that semicolons at the end of sentences are replicated between both source and translation.
斷列符不相配
- 概要:
譯文中的換行數和源文不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.NewLineCountCheck
- 檢查標識符:
newline-count
- 忽略的標誌:
ignore-newline-count
Usually newlines are important for formatting program output. Check fails if the number of new lines in translation does not match the source.
缺少複數形
- 概要:
有些複數形未翻譯
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.consistency.PluralsCheck
- 檢查標識符:
plurals
- 忽略的標誌:
ignore-plurals
檢查已翻譯所有復數形式的源字串。可以在字串定義中找到每個複數表單的具體細節。
在某些情況下,未能填寫複數表格將導致多種形式使用時顯示任何內容。
佔位符
在 3.9 版本新加入.
- 概要:
翻譯缺少一些佔位符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.placeholders.PlaceholderCheck
- 檢查標識符:
placeholders
- Flag to enable:
placeholders
- 忽略的標誌:
ignore-placeholders
在 4.3 版本變更: You can use regular expression as placeholder.
在 4.13 版本變更: With the case-insensitive
flag, the placeholders are not case-sensitive.
翻譯缺少一些佔位符。這些是從翻譯文件中提取的,或者使用````````手動定義,更多可以用冒號分開,可以引用帶空間的字串:
placeholders:$URL$:$TARGET$:"some long text"
如果您對占位符有一些語法,則可以使用正則表達式:
placeholders:r"%[^% ]%"
You can also have case insensitive placeholders:
placeholders:$URL$:$TARGET$,case-insensitive
也參考
標點符號間距
在 3.9 版本新加入.
- 概要:
兩個標點符號前沒有不斷行空格
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.PunctuationSpacingCheck
- 檢查標識符:
punctuation_spacing
- 忽略的標誌:
ignore-punctuation-spacing
檢查雙標點符號(驚嘆號,問號,分號和冒號)之前存在不可破壞的空間。此規則僅以少數選定的語言使用法語或BRETON,其中PARD標註符號前的空間是印刷規則。
正則表達式
在 3.9 版本新加入.
- 概要:
翻譯不符正則表達式
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.placeholders.RegexCheck
- 檢查標識符:
regex
- Flag to enable:
regex
- 忽略的標誌:
ignore-regex
翻譯與正則表達式不匹配。表達式要么從翻譯文件中提取,也可以使用`````````)來定義:
regex:^foo|bar$
相同複數形
- 概要:
有些複數形沒有以相同方式翻譯
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.consistency.SamePluralsCheck
- 檢查標識符:
same-plurals
- 忽略的標誌:
ignore-same-plurals
如果在翻譯中復制了一些複數,請檢查失敗。在大多數語言中他們必須不同。
開頭換列
- 概要:
翻譯沒有和來源一致以換列符開頭
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.BeginNewlineCheck
- 檢查標識符:
begin_newline
- 忽略的標誌:
ignore-begin-newline
紐丁通常出現在源字串中,有效原因,遺漏或添加可以導致翻譯文本使用時的格式化問題。
也參考
開頭空格
- 概要:
翻譯沒有和來源一致以相同數目的空格開頭
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.BeginSpaceCheck
- 檢查標識符:
begin_space
- 忽略的標誌:
ignore-begin-space
字串開頭的空間通常用於界面中的縮進,因此重要地保持。
換列結尾
- 概要:
翻譯沒有和來源一致以換列結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndNewlineCheck
- 檢查標識符:
end_newline
- 忽略的標誌:
ignore-end-newline
紐丁通常出現在源字串中,有效原因,遺漏或添加可以導致翻譯文本使用時的格式化問題。
也參考
空格結尾
- 概要:
翻譯沒有和來源一致以相同數目的空格結尾
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.EndSpaceCheck
- 檢查標識符:
end_space
- 忽略的標誌:
ignore-end-space
檢查尾隨空格是否在源和轉換之間複製。
尾隨空間通常用於空閒鄰居元素,因此刪除它可能會破壞佈局。
未更動的翻譯
- 概要:
翻譯與來源文字相同
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.same.SameCheck
- 檢查標識符:
same
- 忽略的標誌:
ignore-same
如果源和相應的轉換字串相同,則會發生到至少一個形式中。忽略所有語言中常見的一些字串,並剝離各種標記。這減少了誤報的數量。
此檢查可以幫助查找錯誤誤解的字串。
此檢查的預設行為是從檢查中從內置黑名單中排除單詞。這些是經常未被翻譯的單詞。這對於避免短串上的誤報是有用的,該虛假陽性僅由單個單詞組成,該單詞具有多種語言中的相同。通過添加“嚴格的”“標記至字串或組件,可以禁用此黑名單。
不安全的 HTML
在 3.9 版本新加入.
- 概要:
翻譯使用了不安全的 HTML 標示
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.SafeHTMLCheck
- 檢查標識符:
safe-html
- Flag to enable:
safe-html
- 忽略的標誌:
ignore-safe-html
翻譯使用不安全的HTML標記。必須使用“安全 - HTML”標誌(參見:ref:“定制檢查”)啟用此檢查。還有伴隨的AutoFixer,可以自動消毒標記。
提示
When md-text
flag is also used, the Markdown style links are also allowed.
也參考
The HTML check is performed by the Ammonia library.
網址
在 3.5 版本新加入.
- 概要:
此譯文未包含網址
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.URLCheck
- 檢查標識符:
url
- Flag to enable:
url
- 忽略的標誌:
ignore-url
翻譯不包含URL。僅在單位標記為包含URL時才會觸發這一點。在這種情況下,翻譯必須是有效的URL。
XML 標記
- 概要:
翻譯中的 XML 標籤與來源不符
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.XMLTagsCheck
- 檢查標識符:
xml-tags
- 忽略的標誌:
ignore-xml-tags
這通常意味著產生的輸出看起來不同。在大多數情況下,這不是改變翻譯的所需結果,但偶爾就是。
檢查源和翻譯之間是否複製XML標記。
The check is automatically enabled for XML like strings. You might need to add
xml-text
flag in some cases to force turning it on.
備註
This check is disabled by the safe-html
flag as the HTML cleanup done by
it can produce HTML markup which is not valid XML.
XML 語法
在 2.8 版本新加入.
- 概要:
翻譯標記為無效 XML
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.markup.XMLValidityCheck
- 檢查標識符:
xml-invalid
- 忽略的標誌:
ignore-xml-invalid
XML標記無效。
The check is automatically enabled for XML like strings. You might need to add
xml-text
flag in some cases to force turning it on.
備註
This check is disabled by the safe-html
flag as the HTML cleanup done by
it can produce HTML markup which is not valid XML.
零寬度空格
- 概要:
翻譯中包含有額外的零寬度的空白字元
- 範圍:
已翻譯好的字串
- 檢查類:
weblate.checks.chars.ZeroWidthSpaceCheck
- 檢查標識符:
zero-width-space
- 忽略的標誌:
ignore-zero-width-space
零寬度空間(<u + 200b>)字符用於打破單詞中的消息(Word包裝)。
由於它們通常被錯誤插入,因此在翻譯中存在後觸發此檢查。使用此字符時,某些程序可能會出現問題。
也參考
Source checks
源檢查可以幫助開發人員提高源字串的質量。
刪節號
- 概要:
該字串使用三個點(…)而非刪節號(…)
- 範圍:
來源字串
- 檢查類:
weblate.checks.source.EllipsisCheck
- 檢查標識符:
ellipsis
- 忽略的標誌:
ignore-ellipsis
當字串使用三個點時,這會失敗(...
)時,它應該使用省略號字符(````)。
在大多數情況下,使用Unicode字符更好的方法,看起來更好,並且文本到語音可能會更好地聽起來更好。
ICU MessageFormat 語法
在 4.9 版本新加入.
- 概要:
ICU MessageFormat 字串有語法錯誤。
- 範圍:
來源字串
- 檢查類:
weblate.checks.icu.ICUSourceCheck
- 檢查標識符:
icu_message_format_syntax
- Flag to enable:
icu-message-format
- 忽略的標誌:
ignore-icu-message-format
長期未翻譯
在 4.1 版本新加入.
- 概要:
字串很久都沒有翻譯
- 範圍:
來源字串
- 檢查類:
weblate.checks.source.LongUntranslatedCheck
- 檢查標識符:
long_untranslated
- 忽略的標誌:
ignore-long-untranslated
When the string has not been translated for a long time, it can indicate a problem in a source string making it hard to translate.
多項未通過查核
- 概要:
多個語言的翻譯有未通過查核的項目
- 範圍:
來源字串
- 檢查類:
weblate.checks.source.MultipleFailingCheck
- 檢查標識符:
multiple_failures
- 忽略的標誌:
ignore-multiple-failures
此字串的許多翻譯都沒有質量檢查。這通常是可以進行某些東西來改進源字串的指示。
此檢查失敗通常可以在句子末尾的缺失完整停止丟失或類似的次要問題傾向於在翻譯中解決,而在源字串中將其更好。
多個未命名變數
在 4.1 版本新加入.
- 概要:
字串中有多個未命名變數,翻譯者將難以重新排序
- 範圍:
來源字串
- 檢查類:
weblate.checks.format.MultipleUnnamedFormatsCheck
- 檢查標識符:
unnamed_format
- 忽略的標誌:
ignore-unnamed-format
字串中有多個未命名的變量,使翻譯是不可能重新排序的轉換器。
考慮使用命名變量,而不是允許翻譯器重新排序。
未複數化
- 概要:
該字串為複數,但沒有使用複數形
- 範圍:
來源字串
- 檢查類:
weblate.checks.source.OptionalPluralCheck
—- 檢查標識符:
optional_plural
- 忽略的標誌:
ignore-optional-plural
該字串用作複數,但不使用複數形式。如果您的翻譯系統支持此情況,您應該使用它的複數感知變體。
例如,在Python中用GetText可能是:
from gettext import ngettext
print(ngettext("Selected %d file", "Selected %d files", files) % files)