diff --git a/using/android.po b/using/android.po index 28bc67e7c5..17a593cc99 100644 --- a/using/android.po +++ b/using/android.po @@ -29,6 +29,10 @@ msgid "" "running a :program:`python` executable and entering commands at an " "interactive prompt, or by running a Python script." msgstr "" +"Android 上的 Python 與桌面版的 Python 不同。在桌面版上,Python 通常作為系統" +"資源安裝,供該台電腦上的任何使用者使用。使用者通常透過執行 :program:`python` " +"可執行檔並在互動式提示字元中輸入指令,或是直接執行 Python 腳本與 Python 互" +"動。" #: ../../using/android.rst:13 msgid "" @@ -36,6 +40,8 @@ msgid "" "unit of software distribution is an \"app\". There is also no console where " "you could run a :program:`python` executable, or interact with a Python REPL." msgstr "" +"在 Android 上,沒有將其安裝為系統資源的概念。唯一的軟體單位是 \"app\"。也沒有" +"可以執行 :program:`python` 可執行檔的控制台,或與 Python REPL 互動。" #: ../../using/android.rst:17 msgid "" @@ -46,6 +52,11 @@ msgid "" "standard library, and all your Python code is then packaged into your app " "for its own private use." msgstr "" +"因此,在 Android 上使用 Python 的唯一方式就是以嵌入模式運作 - 也就是撰寫一個" +"原生的 Android 應用程式,使用 ``libpython`` 嵌入 Python 直譯器,並透" +"過 :ref:`Python 嵌入式 API ` 呼叫 Python 程式碼。完整的 Python " +"直譯器、標準函式庫,以及你所有的 Python 程式碼,都會被打包進你的應用程式,供" +"該應用程式使用。" #: ../../using/android.rst:23 msgid "" @@ -53,6 +64,8 @@ msgid "" "Android. See the :ref:`API availability guide ` for " "details." msgstr "" +"Python 的標準函式庫在 Android 上有一些明顯的缺漏與限制。詳情請參考 :ref:`API " +"可用性指南 `。" #: ../../using/android.rst:28 msgid "Adding Python to an Android app" @@ -63,6 +76,8 @@ msgid "" "Most app developers should use one of the following tools, which will " "provide a much easier experience:" msgstr "" +"大多數的應用程式開發者應該使用下面其中一種工具,這些工具能提供更輕鬆的使用體" +"驗:" #: ../../using/android.rst:33 msgid "" @@ -93,10 +108,12 @@ msgid "" "the :source:`testbed app ` as a guide; each step below " "contains a link to the relevant file." msgstr "" +"如果你確定要全部手動操作,請繼續閱讀。你可以將 :source:`testbed app ` 作為參考;下面的每個步驟都包含相關檔案的連結。" #: ../../using/android.rst:43 msgid "First, acquire a build of Python for Android:" -msgstr "" +msgstr "首先,取得一個用於 Android 的 Python 建構:" #: ../../using/android.rst:45 msgid "" @@ -104,6 +121,8 @@ msgid "" "www.python.org/downloads/android/>`__. The ``prefix`` directory mentioned " "below is at the top level of the package." msgstr "" +"最簡單的方式是從 `python.org `__ " +"下載 Android 版本。下面提到的 ``prefix`` 目錄位於套件的最上層。" #: ../../using/android.rst:49 msgid "" @@ -111,6 +130,8 @@ msgid "" "`Android/README.md`. The ``prefix`` directory will be created under :samp:" "`cross-build/{HOST}`." msgstr "" +"或者如果你想自行建置它,請依照 :source:`Android/README.md` 中的操作。" +"``prefix`` 目錄將會建立在 :samp:`cross-build/{HOST}` 底下。" #: ../../using/android.rst:53 msgid "" @@ -118,10 +139,13 @@ msgid "" "kts>` file to copy the following items into your project. All except your " "own Python code can be copied from ``prefix/lib``:" msgstr "" +"在你的 :source:`build.gradle ` 檔案中加" +"入程式碼,將以下項目複製到你的專案中。除了你自己的 Python 程式碼外,其他項目" +"都可以從 ``prefix/lib`` 複製:" #: ../../using/android.rst:57 msgid "In your JNI libraries:" -msgstr "" +msgstr "在你的 JNI 函式庫:" #: ../../using/android.rst:59 msgid "``libpython*.*.so``" @@ -133,7 +157,7 @@ msgstr "``lib*_python.so``\\ (外部函式庫,例如 OpenSSL)" #: ../../using/android.rst:62 msgid "In your assets:" -msgstr "" +msgstr "在你的 assets:" #: ../../using/android.rst:64 msgid "``python*.*`` (the Python standard library)" @@ -148,6 +172,8 @@ msgid "" "Add code to your app to :source:`extract the assets to the filesystem " "`." msgstr "" +"在你的應用程式中加入程式碼,以 :source:`解壓縮資產到檔案系統 `。" #: ../../using/android.rst:70 msgid "" @@ -155,6 +181,8 @@ msgid "" "testbed/app/src/main/c/main_activity.c>`. This will need to be C code called " "via JNI." msgstr "" +"在你的應用程式中加入程式碼,以 :source:`嵌入模式啟動 Python `。這需要透過 JNI 呼叫的 C 語言程式碼。" #: ../../using/android.rst:75 msgid "Building a Python package for Android" @@ -168,3 +196,7 @@ msgid "" "setting up a cross-compilation environment, building the wheel, and testing " "it on an emulator." msgstr "" +"Python 套件可以為 Android 建置成 wheels 並發布到 PyPI。建議使用的工具是 " +"`cibuildwheel `__,它會自動設定交叉編譯環境、建置 wheel,以及在模擬器上測試等所有" +"細節。"