Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
ユーザーの解像度が異なる場合にコントロールが台無しにならないようにコントロールを配置するなど、フルスクリーンフォームをデザインする最良の方法を知りたいです。
これは私のフルスクリーンコードです:
int w = Screen.PrimaryScreen.Bounds.Width; int h = Screen.PrimaryScreen.Bounds.Height; this.Location = new Point(0, 0); this.Size = new Size(w, h);
アンカーとドック。
アンカーはコントロールをバインドします。Dockプロパティは、拡張/縮小の方法を設定します。
したがって、ボタンアンカーを「上、左」に割り当てると、そのサイズと位置はそれらの側でロックされたままになります。したがって、フォームウィンドウを広くドラッグすると、オブジェクトは右方向と下方向に拡張されます。