Skip to content

Commit ccd7393

Browse files
committed
/docs/reference/math/attachの翻訳
1 parent 18e39ac commit ccd7393

File tree

3 files changed

+25
-33
lines changed

3 files changed

+25
-33
lines changed

crates/typst-library/src/math/attach.rs

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use crate::foundations::{elem, Content, Packed};
22
use crate::layout::{Length, Rel};
33
use crate::math::{EquationElem, Mathy};
44

5-
/// A base with optional attachments.
5+
/// オプションのアタッチメントを持つベースとなる関数。
66
///
77
/// ```example
88
/// $ attach(
@@ -12,33 +12,30 @@ use crate::math::{EquationElem, Mathy};
1212
/// ```
1313
#[elem(Mathy)]
1414
pub struct AttachElem {
15-
/// The base to which things are attached.
15+
/// アタッチメントを取り付けるベース。
1616
#[required]
1717
pub base: Content,
1818

19-
/// The top attachment, smartly positioned at top-right or above the base.
19+
/// 右上かベースの上にスマート配置された上部アタッチメント。
2020
///
21-
/// You can wrap the base in `{limits()}` or `{scripts()}` to override the
22-
/// smart positioning.
21+
/// ベースを`{limits()}`か`{scripts()}`でラップするとスマート配置を上書きできます。
2322
pub t: Option<Content>,
2423

25-
/// The bottom attachment, smartly positioned at the bottom-right or below
26-
/// the base.
24+
/// 右下かベースの下にスマート配置された下部アタッチメント。
2725
///
28-
/// You can wrap the base in `{limits()}` or `{scripts()}` to override the
29-
/// smart positioning.
26+
/// ベースを`{limits()}`か`{scripts()}`でラップするとスマート配置を上書きできます。
3027
pub b: Option<Content>,
3128

32-
/// The top-left attachment (before the base).
29+
/// 左上のアタッチメント(ベースの前)。
3330
pub tl: Option<Content>,
3431

35-
/// The bottom-left attachment (before base).
32+
///左下のアタッチメント(ベースの前)。
3633
pub bl: Option<Content>,
3734

38-
/// The top-right attachment (after the base).
35+
/// 右上のアタッチメント(ベースの後)。
3936
pub tr: Option<Content>,
4037

41-
/// The bottom-right attachment (after the base).
38+
/// 右下のアタッチメント(ベースの後)。
4239
pub br: Option<Content>,
4340
}
4441

@@ -98,33 +95,32 @@ pub struct PrimesElem {
9895
pub count: usize,
9996
}
10097

101-
/// Forces a base to display attachments as scripts.
98+
/// アタッチメントを添え字として表示することをベースに強制。
10299
///
103100
/// ```example
104101
/// $ scripts(sum)_1^2 != sum_1^2 $
105102
/// ```
106103
#[elem(Mathy)]
107104
pub struct ScriptsElem {
108-
/// The base to attach the scripts to.
105+
/// 添え字を取り付けるベース。
109106
#[required]
110107
pub body: Content,
111108
}
112109

113-
/// Forces a base to display attachments as limits.
110+
/// アタッチメントをlimitsとして表示することをベースに強制。
114111
///
115112
/// ```example
116113
/// $ limits(A)_1^2 != A_1^2 $
117114
/// ```
118115
#[elem(Mathy)]
119116
pub struct LimitsElem {
120-
/// The base to attach the limits to.
117+
/// limitsを取り付けるベース。
121118
#[required]
122119
pub body: Content,
123120

124-
/// Whether to also force limits in inline equations.
121+
/// インライン数式でもlimits表示を強制するかどうか。
125122
///
126-
/// When applying limits globally (e.g., through a show rule), it is
127-
/// typically a good idea to disable this.
123+
/// (例えばshowルールを用いて)limitsをグローバルに適用する場合、通常は無効にすることをおすすめします。
128124
#[default(true)]
129125
pub inline: bool,
130126
}

docs/reference/groups.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -77,25 +77,21 @@
7777
path: ["math"]
7878
filter: ["attach", "scripts", "limits"]
7979
details: |
80-
Subscript, superscripts, and limits.
80+
下付き文字、上付き文字、limits
8181
82-
Attachments can be displayed either as sub/superscripts, or limits. Typst
83-
automatically decides which is more suitable depending on the base, but you
84-
can also control this manually with the `scripts` and `limits` functions.
82+
アタッチメントは下付き文字、上付き文字、limitsのいずれかで表示することができます。
83+
Typstはベースに応じてどれがよりふさわしいかを自動的に決定しますが、`scripts`および`limits`関数を用いて手動で制御もできます。
8584
86-
If you want the base to stretch to fit long top and bottom attachments (for
87-
example, an arrow with text above it), use the [`stretch`]($math.stretch)
88-
function.
85+
上部と下部の長いアタッチメント(例えば上部に文字がある矢印)に合うようにベースを伸縮させたい場合は[`stretch`]($math.stretch)関数を使用してください。
8986
90-
# Example
87+
#
9188
```example
9289
$ sum_(i=0)^n a_i = 2^(1+i) $
9390
```
9491
95-
# Syntax
96-
This function also has dedicated syntax for attachments after the base: Use
97-
the underscore (`_`) to indicate a subscript i.e. bottom attachment and the
98-
hat (`^`) to indicate a superscript i.e. top attachment.
92+
# 構文
93+
この関数にはベースの後ろのアタッチメントのための専用の構文があります。
94+
下付き文字、すなわち下部のアタッチメントにはアンダースコア(`_`)を、上付き文字、すなわち上部のアタッチメントにはサーカムフレックス(`^`)を使用してください。
9995
10096
- name: lr
10197
title: Left/Right

website/translation-status.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@
7979
"/docs/reference/text/upper/": "untranslated",
8080
"/docs/reference/math/": "untranslated",
8181
"/docs/reference/math/accent/": "translated",
82-
"/docs/reference/math/attach/": "untranslated",
82+
"/docs/reference/math/attach/": "translated",
8383
"/docs/reference/math/binom/": "untranslated",
8484
"/docs/reference/math/cancel/": "untranslated",
8585
"/docs/reference/math/cases/": "translated",

0 commit comments

Comments
 (0)