fix: improve macOS UX (HiDPI support and native key labels)#2
Open
Ryo722 wants to merge 1 commit intorotejin:masterfrom
Open
fix: improve macOS UX (HiDPI support and native key labels)#2Ryo722 wants to merge 1 commit intorotejin:masterfrom
Ryo722 wants to merge 1 commit intorotejin:masterfrom
Conversation
- Use QKeySequence.NativeText for undo/redo tooltips so they show Cmd+Z / Cmd+Shift+Z on macOS instead of Ctrl+Z / Ctrl+Y - Add devicePixelRatio handling in PreviewWidget and MaskCanvas for crisp rendering on Retina displays
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
macOSでのUXを改善する2つの修正を含みます。
1. Undo/Redoツールチップのネイティブ表記
Ctrl+Z/Ctrl+YとハードコードされていたツールチップをQKeySequence.NativeTextで動的生成するように変更⌘Z/⇧⌘Z、WindowsではCtrl+Z/Ctrl+Yと表示されます2. Retina(HiDPI)ディスプレイ対応
PreviewWidgetとMaskCanvasでdevicePixelRatioを考慮したスケーリングを追加Changes
mask_composer.py: ツールチップ修正parts_mixer.py: ツールチップ修正preview_widget.py: HiDPI対応(_device_pixel_ratio()メソッド追加、スケール計算修正)mask_canvas.py: HiDPI対応(scaled_pixmapにsetDevicePixelRatio設定)Test plan
⌘Z/⇧⌘Zと表示されることCtrl+Z/Ctrl+Yと表示されること