Feature Request: Move to edge + offset or margin

オープン
#914 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
説明が足りない
活発さ
活発
領域
desktop

調査の方向性

No files or tests are named. Start by reviewing the existing Position settings, especially Custom Origin and Center Offset, then determine how X and Y should behave for each edge or corner. Done means the requested shortcuts support consistent offsets and define behavior for positive and empty values.

索引モデルが issue の本文から書いたものです。

説明

I'd love to create a shortcut that moves a window to a corner or edge but with a specified offset or margin. "Position: Custom Origin" basically does what I want but is limited to the bottom left.

An easy way to add this would be to add the existing "X" and "Y" input fields to all other "Position" options too. For instance:

Setting Value
Position Top Right
X: 100 Y: 100

This would place a window to the top right but with an offset of 100 px to the top and right edge.

This could actually replace some "Position" settings like "Custom Origin" and "Center Offset" (if "Center" basically does what "Center Offset" currently does).

Positions like "Right" could use the "Y" value to slightly move the window up or down.

Open questions

What does a positive "X" value mean when Position is "Right"?

I think that's a terminology question:

  • "X" and "Y" mean "offset" -> positive is always top/right
  • "X" and "Y" mean "margin" -> positive is always towards the center

The 2nd would be more work to implement but I think it's more what users expect.

If Position is "right" and "X" means "margin" then what does "Y" mean?

In that scenario there's no top/bottom edge that would be the reference point for a margin. So, "X" would be "margin", but "Y" would be offset. That can get very confusing.

So, I guess that would be an argument to use "offset" for everything. Or those settings won't be available in the first place.

What does an empty value do?

At first I thought it would be more difficult to answer but "Center Offset" already defaults an empty value to "0" which is what I would expect here. Unlike leaving width or height empty which leaves the current dimension untouched. So, that's perfectly fine.

主要言語
言語のデータがありません
スター
156
フォーク
1
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

rxhanson/RectanglePro-Community のほかの issue

rxhanson/RectanglePro-Community の issue をすべて見る

似ている issue

Desktop Dev の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。