Skip to content

Commit e7a7be4

Browse files
kimushun1101mkpoli
andauthored
Translate tutorial 3 advanced (#67)
Signed-off-by: Shunsuke Kimura <[email protected]> Co-authored-by: mkpoli <[email protected]>
1 parent 979cd9d commit e7a7be4

File tree

4 files changed

+24
-30
lines changed

4 files changed

+24
-30
lines changed

docs/tutorial/1-writing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
description: Typstのチュートリアルです。
2+
description: Typstチュートリアル
33
---
44
# Typstで執筆するには
55

docs/tutorial/2-formatting.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
description: Typst's tutorial.
2+
description: Typstチュートリアル
33
---
44

55
# 書式を設定する

docs/tutorial/3-advanced.md

Lines changed: 21 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
description: Typst's tutorial.
2+
description: Typstチュートリアル
33
---
44

55
# 高度なスタイリング
@@ -74,7 +74,7 @@ description: Typst's tutorial.
7474
また`{"(1/1)"}`と設定すると、カッコで囲まれた現在のページと総ページ数が表示されるでしょう。
7575
さらに、カスタム関数を用意して完全に好みの書式にすることも可能です。
7676

77-
## タイトルと要旨 { #title-and-abstract }
77+
## タイトルとアブストラクトの作成 { #title-and-abstract }
7878
それでは、タイトルとアブストラクトを追加しましょう。
7979
まずはタイトルを中央揃えにし、`[*stars*]`で囲んでフォントを太文字にします。
8080

@@ -231,23 +231,18 @@ grid関数はセルを指定するcontent引数を任意の数で受け取れま
231231
`title`変数にコンテンツを設定した後は、関数内やマークアップ内(関数のように接頭辞に`#`をつける)で使用できます。
232232
こうすることで、別のタイトルに決めた場合、一箇所で簡単に変更することができます。
233233

234-
## Adding columns and headings { #columns-and-headings }
234+
## 段組みと見出しの追加 { #columns-and-headings }
235235
上の論文は、残念ながら文字が単調にぎっしり詰まっていて読みにくい見た目をしています。
236-
これを修正するために、見出しを追加し、2段組のレイアウトに変更してみましょう。 Fortunately, that's
237-
easy to do: We just need to amend our `page` set rule with the `columns`
238-
argument.
239-
240-
241-
By adding `{columns: 2}` to the argument list, we have wrapped the whole
242-
document in two columns. However, that would also affect the title and authors
243-
overview. To keep them spanning the whole page, we can wrap them in a function
244-
call to [`{place}`]($place). Place expects an alignment and the content it
245-
should place as positional arguments. Using the named `{scope}` argument, we can
246-
decide if the items should be placed relative to the current column or its
247-
parent (the page). There is one more thing to configure: If no other arguments
248-
are provided, `{place}` takes its content out of the flow of the document and
249-
positions it over the other content without affecting the layout of other
250-
content in its container:
236+
これを修正するために、見出しを追加し、2段組のレイアウトに変更してみましょう。
237+
幸いなことに、setルールで`page``column`引数を追加することで簡単に行えます。
238+
239+
引数リストに`{columns: 2}`を加えることで、文書全体を2段組みとなります。
240+
しかし、これではタイトルと著者、アブストラクトにも影響が出てしまいます。
241+
それらを1段組みのままに維持するためには、[`{place}`]($place)関数を呼び出して囲みましょう。
242+
place関数は引数として配置とコンテンツを受け取ります。
243+
オプション引数である`{scope}`引数を使えば、現在の段組みとその親(ページ)のどちらに対して配置するかを決めることが可能です。
244+
これらに加えて、もうひとつ設定することがあります。
245+
オプション引数がない場合、`{place}`はそのコンテンツを文書の流れから外し、他のレイアウトに影響を与えることなく、他のコンテンツの上に配置します。
251246

252247
```example
253248
#place(
@@ -257,11 +252,11 @@ content in its container:
257252
#lorem(30)
258253
```
259254

260-
If we hadn't used `{place}` here, the square would be in its own line, but here
261-
it overlaps the few lines of text following it. Likewise, that text acts like as
262-
if there was no square. To change this behavior, we can pass the argument
263-
`{float: true}` to ensure that the space taken up by the placed item at the top
264-
or bottom of the page is not occupied by any other content.
255+
もしここで`{place}`を使わなければ、黒塗りの長方形は独立した行になるはずですが、
256+
`{place}`を使うと、それに続く数行のテキストの上に重なります。
257+
同様に、テキスト側もこの長方形がないかのように振る舞います。
258+
この動作を変更するには、引数`{float: true}`を渡してください。
259+
これにより`{place}`でページの上部または下部に配置されたアイテムが、他のコンテンツと重ならないように設定できます。
265260

266261
```example:single
267262
>>> #let title = [
@@ -323,10 +318,9 @@ or bottom of the page is not occupied by any other content.
323318
#lorem(200)
324319
```
325320

326-
In this example, we also used the `clearance` argument of the `{place}` function
327-
to provide the space between it and the body instead of using the [`{v}`]($v)
328-
function. We can also remove the explicit `{align(center, ..)}` calls around the
329-
various parts since they inherit the center alignment from the placement.
321+
この例では、`{place}` 関数の `clearance` 引数も使用しています。
322+
これにより、[`{v}`]($v)関数を使用する代わりに、本文との間にスペースを設けています。
323+
また、コンテンツはcenter引数を継承しているため、各パーツごとに行っていた明示的な `{align(center, ...)}` 呼び出しも削除できます。
330324

331325
最後に見出しのスタイルの設定をしましょう。
332326
ガイドラインに従うために、見出しは中央揃えにして、小さな大文字を使わなければなりません。

docs/tutorial/4-template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
description: Typst's tutorial.
2+
description: Typstチュートリアル
33
---
44

55
# テンプレートを作成する

0 commit comments

Comments
 (0)