diff --git a/docs/0-requirements.md b/docs/0-requirements.md index 6c74ff3..85747bd 100644 --- a/docs/0-requirements.md +++ b/docs/0-requirements.md @@ -280,6 +280,7 @@ liplus-desktop の `stream_parser.rs` および `spawn_stream_pty` / `spawn_stre - 診断面のヘッダの実機確認。タブと行の連動、`✕` で面が畳まれセッションが残ること、終了したタブの `✕` での破棄、端末の文字サイズの梯子と再起動後の保持、桁数と行数がセッションへ伝わることはいずれも実装済みで CI の型検査は通っているが、実機での操作は未確認である。ヘッダの存在・角丸・枠の見た目は 2026-08-24 に実機で観察され、そこから色を敷かないこと・窓の名前「端末」・枠の余白を詰めることの三点が指示として戻っている。三点を反映した後の見た目は再度未確認である。 - 行の記号表示と終了の確認ダイアログの実機確認。三つの記号が Windows のフォントで揃って出ること、幅を固定した列で本人の行の名前が出ること、ダイアログの取消・終了・Escape はいずれも実装済みで CI の型検査は通っているが、実機での操作は未確認である。 - 操作の地色を揃えた後の見た目の実機確認。タイトルバー・入力欄・参加者の行・端末ヘッダ・アカウントのモーダルの操作を窓の地色へ揃え、選択中の端末タブも同じ地色にした(#75、下記「二つの地色」)。指示は 2026-08-24 の実機観察から戻っているが、反映後の見た目は未確認である。 +- 端末の下辺の帯を消した後の実機確認。`.xterm-viewport` を描画から外し、黒い帯とネイティブのスクロールバーの矢印が消えること、端末の使える面積と桁数・行数が変わらないことは、実際のスタイルシートから組んだ採寸用のページで確かめてあるが(#77、下記「診断面」)、WebView2 上の見た目は未確認である。 - 会話ログの永続化と観測 UI - plugin としての allowlist 掲載(配布の第二段階) @@ -422,6 +423,10 @@ liplus-desktop の `stream_parser.rs` および `spawn_stream_pty` / `spawn_stre **枠と端末の間の余白は詰める。** `0.15rem` である(実機観察、2026-08-24)。ここは余白ではなく端末が使っていない面積であり、CLI の桁数と行数は残った寸法から計算される。削った分は端末の面積になる。`0` にはしない——xterm はカーソルと選択を自分の箱の縁まで描くため、枠に密着させると縁が枠線の上へ乗る。 +**端末の下辺に帯を出さない。** xterm 6 のスクロールは `.xterm-scrollable-element` が持ち、`.xterm-viewport` は誰も測らない空の `div` として残っている。それでも xterm 自身のスタイルシートはこの要素へ二つの指定を当てたままであり、どちらも保守されていない——テーマの届かない `#000` の塗りと、ネイティブのスクロールバーを 15px 分確保する `overflow-y: scroll` である。端末の箱は面いっぱいへ伸ばしてあり、xterm が描くのは行の整数倍であるから、`行数 × 行の高さ` を引いた余りは誰も描かない帯として下辺に残る。そこをこの空の要素が黒で塗り、右端にはネイティブのスクロールバーの下向き矢印が出ていた(#77)。帯は割り算の余りであるから面の高さとともに動く——実測で 600〜900px の窓に対して 4.44px から 14.44px である。新しく生まれたものではない。#68 が 800px の窓で 6.63px から 14.44px へ動かし、矢印の高さに届かなかったものがちょうど一つ分になった時点で、縁ではなくスクロールバーとして読まれるようになった。 + +補正の側は壊れていない。`fit` が測るのは端末の枠(`.term`)であり、そこから出る桁数と行数は実際に描かれている面と一致する——修正の前後どちらでも 126×23 に対して 960×345 である。直すのは何も描かない要素であって測り方ではないため、`.xterm-viewport` を描画から外す。塗りや `overflow` をこちらから上書きする形は採らない。その形では、次の面の高さが作る余りの上に帯がまた立つ。 + **タブと参加者の行は連動する。** どちらを押しても同じ端末が画面に出る。同じ選択を二つの面が持つ形であり、#59 が名簿から外した重複とは逆を向く判断である(下記「受容したトレードオフ」)。タブが答えるのは「いまどの端末が開いているか」であり、行はそれを並べて読むことでしか答えない。二つは一つの描画から同時に出す。連動を実装の約束にせず、構造で成立させるためである。 **`✕` は面を畳む。セッションは終わらない。** 端末もリスナもスクロールバックも残り、開き直せば同じタブが並ぶ。ヘッダの `端末` ボタンは残す。畳まれた状態から開く手は `✕` の側に無く、二つは同じ操作の入口と出口である。セッションを終わらせる手は参加者の行の `終了` のままであり、端末側へは移さない。 diff --git a/src/styles.css b/src/styles.css index 7074182..78a36a6 100644 --- a/src/styles.css +++ b/src/styles.css @@ -802,13 +802,46 @@ body { } /* xterm sizes itself to the container, so the container must have a size of - its own rather than growing with the content. */ -#terminal .xterm, -#terminal .xterm-viewport, -#terminal .xterm-screen { + its own rather than growing with the content. + + Only `.xterm` is written here. `.xterm-viewport` and `.xterm-screen` stood in + this selector too and neither could change anything: the screen carries an + inline `height` from the renderer, which a stylesheet rule does not reach, and + the viewport is positioned to its container's four edges already. */ +#terminal .xterm { height: 100%; } +/* The empty element xterm 6 left behind, kept from painting. + + Scrolling moved to `.xterm-scrollable-element`, and `.xterm-viewport` is now + an empty `div` that nothing measures — but two declarations in xterm's own + stylesheet still land on it, and neither is maintained any more: a hard-coded + `#000` fill the theme no longer reaches, and `overflow-y: scroll`, which + reserves a native 15px scrollbar. + + Both were being drawn, because the rule above stretches the box to the pane + while xterm draws whole rows only. What is drawn is `rows × cell height`; the + remainder is a strip along the bottom edge that nothing else paints, and the + viewport was painting it black across the full width with the lower arrow of + that native scrollbar at its right end (#77). + + The strip is the division's remainder, so its height moves with the pane's: + 4.44px to 14.44px over a 600–900px window, measured. It is not new — #68 took + it from 6.63px to 14.44px at 800px, from under the height of an arrow to + exactly one, which is where it started reading as a scrollbar rather than as + an edge. + + The columns and rows are not what was wrong. The fit measures `.term`, and + what it reports is what is drawn — 126×23 against a 960×345 screen, before + this rule and after it. So the repair is the element that draws nothing, not + the measurement. `display: none` rather than a fill or an `overflow` of our + own: covering it would leave the strip standing at whatever height the next + pane produces, and this is the one value that holds at every height. */ +#terminal .xterm-viewport { + display: none; +} + /* ── the account dialog ──────────────────────────────────────────────────── */ /* In this webview, not an OS window: it is a step inside one act, and a second