"Top" default positions ignored when the panel is at the top of the screen – new notes always open top left
Maintainer thường phản hồi trong vòng 8 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 78/100
Hướng nghiên cứu
Xác định mã nguồn của applet Sticky Notes và kiểm tra get_direction() và find_note_location(). Tái hiện với panel ở trên cùng, sau đó xác minh rằng phép tính vị trí cộng workarea.x/workarea.y và rằng kiểm tra biên dùng chiều rộng và chiều cao của note theo đúng thứ tự. Hoàn thành nghĩa là Top Right/Top Center mở bên dưới panel trên cùng và fallback không còn kích hoạt nữa.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Distribution
Linux Mint 22.3
Package version
Cinnamon 6.6.9
Graphics hardware in use
No response
Frequency
Always
Bug description
With the Cinnamon panel at the top of the screen, setting Preferences → Notes → Default position to "Top Right" (or "Top Center") has no effect: every new note opens in the top left corner. "Center Right" and "Bottom Right" work as expected.
Steps to reproduce
- Move the Cinnamon panel to the top of the screen (panel height > 20 px).
- In Sticky Notes, set Default position to "Top Right".
- Create a new note from the tray icon.
Expected behavior
Expected: the note opens in the top right corner, below the panel.
Actual: the note opens in the top left corner.
Additional information
Cause
In get_direction() the position is computed from the workarea size only, without the workarea origin:
else:
y = 20
With a top panel, workarea.y equals the panel height, so y = 20 lies inside the panel. find_note_location() then fails the bounds check (y < min_y) and falls back to workarea.x + 20, workarea.y + 20, i.e. top left. The same applies to x with a panel on the left.
Suggested fix: add the workarea origin, e.g. x = workarea_rect.x + … and y = workarea_rect.y + 20.
Possibly related
In the bounds check of find_note_location(), width and height seem to be swapped:
x_end = x + default-height
y_end = y + default-width
System
- Linux Mint 22.3
- sticky 1.31
- Panel position: top
- Ngôn ngữ chính
- JavaScript
- Star
- 5.7k
- Fork
- 941
- Merge trung bình
- 6 ngày 18 giờ
- Pull request đã merge (30 ngày)
- 12
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của linuxmint/cinnamon
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 8 ngày
-
Sound applet: seek bar jumps back after seeking when player resends metadata (e.g. mpDris2/MPD)Đang mởBUG
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 8 ngày
-
Menu applet omits descriptions from search-provider resultsCó thể đã có người làm @ah682 đã nhận 8 ngày trước. Đang mởBUG
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
linuxmint/cinnamon#14104 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 8 ngày
-
xapp-status applet: status icon labels are ellipsized to "..." when the panel zone is a fraction of a pixel shortCó thể làm lại được @Priyeshshrivastav đã nhận 15 ngày trước và không có pull request nào đang mở. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
linuxmint/cinnamon#14096 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 8 ngày
-
Grouped Window List applet gets out of sync when a program is removed directly from Startup ApplicationsCó thể làm lại được @Aaqibhafeezkhan đã nhận 32 ngày trước và không có pull request nào đang mở. Đang mởBUG
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
linuxmint/cinnamon#14057 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 8 ngày
Tất cả issue của linuxmint/cinnamon
Issue tương tự
-
type: bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 66/100
fmhy/edit#7340 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
ai-amazon-bedrock: a tool result that isn't a JSON object fails the next requestCó thể đã có người làm @effect-bot đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 79/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[bug] Toolchain versions from `.prototools` are not inherited when moon runs from a subdirectoryĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Edit: Tele1 Logo [SV]Đang mởcheck:passed logos:edit
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày