-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Description
Testing on Anki 25.07.2 for Windows. The issue has been present since around version 2.1.55, I believe.
Edit: also reproducible in version 25.08b1.
See, for example, this report: https://forums.ankiweb.net/t/anki-25-01-02-beta-rc/54490/50
Notice how the word Yes is partially cut off on both the left and right sides:
This could be related to the following code:
Lines 177 to 183 in c57b7c4
| QPushButton:default {{ | |
| border: 1px solid {tm.var(colors.BORDER_FOCUS)}; | |
| }} | |
| QPushButton:focus {{ | |
| border: 2px solid {tm.var(colors.BORDER_FOCUS)}; | |
| outline: none; | |
| }} |
- Changing the
QPushButton:focusborderto1pxseems to prevent the issue, but also alters the appearance of buttons, e.g., in the Editor. - Adding any
paddingtoQPushButton:focus, evenpadding: 0px;, also appears to prevent the issue. However, the underline below the "Y" in "Yes" changes slightly in length when the button is focused versus unfocused. Also, it breaks some styles, e.g., in some add-on created buttons. - Changing
QPushButton:default'sborderto2pxproduces a similar effect as the previous solution but also breaks some styles (e.g., theReset Window Sizesbutton in Preferences).
Here is how the Yes button appears after applying QPushButton:focus {{ padding: 0px; }} (the text is no longer cut off, but the underline under the "Y" is slightly longer):

Metadata
Metadata
Assignees
Labels
No labels