From 1f939b260be731f6165ca6f94cca094028d9ca9b Mon Sep 17 00:00:00 2001 From: Masahiro FUJIMOTO Date: Tue, 12 Oct 2021 12:00:27 +0900 Subject: CSS ルビレイアウトの各プロパティの変換準備 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- files/ja/web/css/ruby-position/index.md | 115 ++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 files/ja/web/css/ruby-position/index.md (limited to 'files/ja/web/css/ruby-position/index.md') diff --git a/files/ja/web/css/ruby-position/index.md b/files/ja/web/css/ruby-position/index.md new file mode 100644 index 0000000000..6cb66cd58d --- /dev/null +++ b/files/ja/web/css/ruby-position/index.md @@ -0,0 +1,115 @@ +--- +title: ruby-position +slug: Web/CSS/ruby-position +tags: + - CSS + - CSS プロパティ + - CSS ルビ + - リファレンス +translation_of: Web/CSS/ruby-position +--- +
{{CSSRef}}{{SeeCompatTable}}
+ +

CSS の ruby-position プロパティは、ベース要素に対するルビ要素の位置を定義します。要素の上方 (over)、下方 (under)、文字の間の右側 (inter-character) に配置できます。

+ +
/* キーワード値 */
+ruby-position: over;
+ruby-position: under;
+ruby-position: inter-character;
+
+/* グローバル値 */
+ruby-position: inherit;
+ruby-position: initial;
+ruby-position: unset;
+
+ +

{{cssinfo}}

+ +

構文

+ +

+ +
+
over
+
over の例ルビをメインテキストの上 (横書きの場合) または右 (縦書きの場合) に配置することを示すキーワードです。
+
under
+
under の例ルビをメインテキストの下 (横書きの場合) または左 (縦書きの場合) に配置することを示すキーワードです。
+
inter-character
+
ルビをそれぞれの文字の間に配置することを示すキーワードです。
+
+ +

形式文法

+ +{{csssyntax}} + +

+ +

この HTML は、 ruby-position のそれぞれの値でレンダリングします。

+ +
<ruby>
+  <rb>超電磁砲</rb>
+  <rp>(</rp><rt>レールガン</rt><rp>)</rp>
+</ruby>
+
+ +

テキストの上に配置したルビ

+ + + +
ruby {
+    ruby-position:over;
+}
+ +

結果は以下のとおりです。

+ +

{{EmbedLiveSample("Ruby_positioned_over_the_text", 100, 40)}}

+ +

テキストの下に配置したルビ

+ + + +
ruby {
+    ruby-position:under;
+}
+ +

結果は以下のとおりです。

+ +

{{EmbedLiveSample("Ruby_positioned_under_the_text", 100, 40)}}

+ +

仕様書

+ + + + + + + + + + + + + + + + +
仕様書状態備考
{{SpecName('CSS3 Ruby', '#rubypos', 'ruby-position')}}{{Spec2('CSS3 Ruby')}}初回定義
+ +

ブラウザーの対応

+ +

{{Compat("css.properties.ruby-position")}}

+ +

関連情報

+ + -- cgit v1.2.3-54-g00ecf