支持文件类型 (Strings)

.QPH - Qt Phrase (Strings)

文本由 Phrase Language AI 从英语机器翻译而得。

文件扩展名 

.qph

API 扩展 

qph

导入 

导出 

复数形式支持 

描述支持 

Qt Phrase Book 是一种基于 XML 的文件格式,供 Qt Linguist 用于填充预译内容。其单元元素为 <phrase>,包含嵌套的 <source><target> 元素。

Qt Phrase Book (.QPH) 与 Qt Translation Source (.TS) 不同,.QPH 是一个术语表,而 .TS 是一种交换文件格式。.TS 用于 Qt 应用程序将本地化内容加载到软件中,而 .QPH 在 Qt Linguist 中用作术语库。

代码示例

<!DOCTYPE QPH>
<QPH language="en-GB">
  <phrase>
    <source>boolean_key</source>
    <target>--- true
</target>
  </phrase>
  <phrase>
    <source>empty_string_translation</source>
    <target/>
  </phrase>
  <phrase>
    <source>key_with_description</source>
    <target>“对这个键非常重要的描述!”(At least in some formats)</target>
  </phrase>
  <phrase>
    <source>key_with_line-break</source>
    <target>此译文包含
换行符。</target>
  </phrase>
  <phrase>
    <source>nested.deeply.key</source>
    <target>Wow, this key is nested even deeper.</target>
  </phrase>
  <phrase>
    <source>nested.key</source>
    <target>This key is nested inside a namespace.</target>
  </phrase>
  <phrase>
    <source>null_translation</source>
    <target/>
  </phrase>
  <phrase>
    <source>pluralized_key_one</source>
    <target>仅找到一只小猫。</target>
  </phrase>
  <phrase>
    <source>pluralized_key_other</source>
    <译文>哇,你有 %s 只小猫!</译文>
  </phrase>
  <phrase>
    <source>pluralized_key_zero</source>
    <译文>你没有小猫。</译文>
  </phrase>
  <phrase>
    <source>sample_collection</source>
    <target>---
- first item
- second item
- third item
</target>
  </phrase>
  <phrase>
    <source>simple_key</source>
    <译文>Simple key, simple message, so simple.</译文>
  </phrase>
  <phrase>
    <source>unverified_key</source>
    <译文>This translation is not yet verified and waits for it.(In some formats we also export this status)</译文>
  </phrase>
</QPH>
这篇文章有帮助吗?

Sorry about that! In what way was it not helpful?

The article didn’t address my problem.
I couldn’t understand the article.
The feature doesn’t do what I need.
Other reason.

Note that feedback is provided anonymously so we aren't able to reply to questions.
If you'd like to ask a question, submit a request to our Support team.
Thank you for your feedback.