Skip to content

Translate library/calendar part 2/2 #618

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Sep 2, 2023

Conversation

mindihx
Copy link
Collaborator

@mindihx mindihx commented Aug 24, 2023

issue #587

@mattwang44 mattwang44 requested a review from weijay0804 August 27, 2023 19:14
@@ -288,80 +288,92 @@ msgstr ""
msgid ""
":class:`!HTMLCalendar` has the following attributes you can override to "
"customize the CSS classes used by the calendar:"
msgstr ""
msgstr ":class:`!HTMLCalendar` 可以覆寫以下屬性來客製日曆所使用的 CSS 類別:"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

這邊的 CSS classes 翻譯成 CSS 樣式 會不會比較貼近一點?

Suggested change
msgstr ":class:`!HTMLCalendar` 可以覆寫以下屬性來客製日曆所使用的 CSS 類別:"
msgstr ":class:`!HTMLCalendar` 可以覆寫以下屬性來客製日曆所使用的 CSS 樣式:"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

它的屬性都是給 CSS class 名稱而不是給實際的樣式
所以覺得這裡維持用類別就可以了~


#: ../../library/calendar.rst:256
msgid ""
"A list of CSS classes used for each weekday. The default class list is::"
msgstr ""
msgstr "一週每一天使用的 CSS 類別的串列。預設的串列內容為: ::"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
msgstr "一週每一天使用的 CSS 類別的串列。預設的串列內容為: ::"
msgstr "一個對應一週每一天的 CSS 樣式的串列。預設的串列內容為: ::"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我改成 對應一週每一天 CSS 類別的串列
同上維持使用類別


#: ../../library/calendar.rst:260
msgid "more styles can be added for each day::"
msgstr ""
msgstr "可以在每一天增加更多樣式: ::"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
msgstr "可以在每一天增加更多樣式: ::"
msgstr "可以針對每一天增加更多樣式: ::"


#: ../../library/calendar.rst:269
msgid "The CSS class for a weekday occurring in the previous or coming month."
msgstr ""
msgstr "前一個或下一個月份的一週每一天的 CSS 類別。"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

這邊應該是指說如果日期發生在前面一個月,或後一個月時發生的空格的 CSS 樣式

使用 cssclass_noday 屬性:
截圖 2023-08-30 上午12 43 39

生成的 HTML:
截圖 2023-08-30 上午12 44 29
截圖 2023-08-30 上午12 44 58
可以看到空缺的日期的 css class 會是我們指定的樣式

在瀏覽器上的樣子:
截圖 2023-08-30 上午12 45 43

Suggested change
msgstr "前一個或下一個月份的一週每一天的 CSS 類別。"
msgstr "表示如果日期發生在前一個或後一個月時的 CSS 樣式。"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我的理解跟你的一樣~ 不過我硬要把 weekday 翻出來就變那樣
我改一下~

Comment on lines +315 to +316
"在標題列中一週每一天名稱的 CSS 類別的串列。預設內容和 :attr:`cssclasses` 相"
"同。"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"在標題列中一週每一天名稱的 CSS 類別的串列。預設內容和 :attr:`cssclasses` 相"
"同。"
"在標題列中的星期名稱的 CSS 樣式的串列。預設內容和 :attr:`cssclasses` 相"
"同。"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

因為我整份文件的 week 都翻譯成 "週",只有這裡用"星期"會有點不一致

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK 這裡是我的疏忽,抱歉!


#: ../../library/calendar.rst:308
msgid ""
"The CSS class for the table head for the whole year (used by :meth:"
"`formatyear`). The default value is ``\"year\"``."
msgstr ""
"整年表格標題的 CSS 類別(:meth:`formatyear` 會用到),預設值是 ``\"year\"``。"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"整年表格標題的 CSS 類別(:meth:`formatyear` 會用到),預設值是 ``\"year\"``。"
"整年表格標題的 CSS 樣式(由 :meth:`formatyear` 使用),預設值是 ``\"year\"``。"

@@ -370,10 +382,13 @@ msgid ""
"*locale*. Because the current locale is a process-wide setting, they are not "
"thread-safe."
msgstr ""
"這兩個類別的建構函式、:meth:`formatweekday` 及 :meth:`formatmonthname` 方法會"
"把 ``LC_TIME`` 語系暫時改成給定的 *locale*。因為目前的語系是屬於整個行程的設"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

這邊的 process-wide 因為是專用術語,所以把原文也寫上去會比較清楚

Suggested change
"把 ``LC_TIME`` 語系暫時改成給定的 *locale*。因為目前的語系是屬於整個行程的設"
"把 ``LC_TIME`` 語系暫時改成給定的 *locale*。因為目前的語系是屬於整個行程 (process-wide) 的設"


#: ../../library/calendar.rst:375
msgid ""
"Returns the number of leap years in the range from *y1* to *y2* (exclusive), "
"where *y1* and *y2* are years."
msgstr ""
msgstr "回傳從 *y1* 到 *y2* (不包含)間有幾個閏年,其中 *y1* 和 *y2* 是年份。"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

這邊應該不需要空格

Suggested change
msgstr "回傳從 *y1* 到 *y2* (不包含)間有幾個閏年,其中 *y1* 和 *y2* 是年份。"
msgstr "回傳從 *y1* 到 *y2*(不包含)間有幾個閏年,其中 *y1* 和 *y2* 是年份。"


#: ../../library/calendar.rst:389
msgid ""
"Return a header containing abbreviated weekday names. *n* specifies the "
"width in characters for one weekday."
msgstr ""
msgstr "回傳包含一週每一天的名稱縮寫的標題。*n* 指定每一天的寬度即字元數。"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
msgstr "回傳包含一週每一天的名稱縮寫的標題。*n* 指定每一天的寬度即字元數。"
msgstr "回傳包含一週每一天的名稱縮寫的標題。*n* 指定每一天的字元寬度。"

Comment on lines 449 to 450
"回傳代表一個月份日曆的矩陣。每一列為一週;該月以外的日期以 0 表示。除非在 :"
"func:`setfirstweekday` 有設定,每一週以週一開始。"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

小小的修改一下

Suggested change
"回傳代表一個月份日曆的矩陣。每一列為一週;該月以外的日期以 0 表示。除非在 :"
"func:`setfirstweekday` 有設定,每一週以週一開始"
"回傳代表一個月份日曆的矩陣。每一列為一週;該月以外的日期以 0 表示。每一週以"
"週一開始,除非使用 :func:`setfirstweekday` 改變設定"

@mindihx
Copy link
Collaborator Author

mindihx commented Aug 31, 2023

@weijay0804 我改好了,再麻煩你了,謝謝~
CSS class 要不要翻譯成 CSS 樣式有需要再討論一下嗎還是就維持翻譯成類別?

@mindihx mindihx requested a review from weijay0804 August 31, 2023 02:22
@weijay0804
Copy link
Contributor

@weijay0804 我改好了,再麻煩你了,謝謝~
CSS class 要不要翻譯成 CSS 樣式有需要再討論一下嗎還是就維持翻譯成類別?

根據你上面提到的,我覺得你說的比較正確,一樣維持類別好了
還是你覺得直接寫 CSS class 會比較好?

@mindihx
Copy link
Collaborator Author

mindihx commented Aug 31, 2023

@weijay0804 我改好了,再麻煩你了,謝謝~
CSS class 要不要翻譯成 CSS 樣式有需要再討論一下嗎還是就維持翻譯成類別?

根據你上面提到的,我覺得你說的比較正確,一樣維持類別好了 還是你覺得直接寫 CSS class 會比較好?

我覺得就維持叫類別好了~ 謝謝

@weijay0804
Copy link
Contributor

@mindihx LGTM~~
辛苦你了~

@mindihx mindihx merged commit 05f7c46 into python:3.12 Sep 2, 2023
@mindihx mindihx deleted the library_calendar_part2 branch September 2, 2023 05:58
beccalzh pushed a commit to beccalzh/python-docs-zh-tw that referenced this pull request Sep 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants