-
-
Notifications
You must be signed in to change notification settings - Fork 21.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AssetLib: Fix long plugin names breaking the UI
The UI was extending past the screen width when loading a page diplaying a plugin with an especially long title in the asset store plugin. I implemented a new `EditorAssetLibraryItem::clamp_width` method that checks that the title text is not longer than the column width minus some padding and truncates it if it is. I also noticed that the nav buttons for paginated results were causing the UI to extend past the screen width on higher editor scales since they were hardcoded to show ten page buttons if there were enough results. I modified the pagination slightly to display a dynamic number of nav buttons based on the editor scale in order to fix this other cause of the same problem. I had to use the font of the `title`, which is a `LinkButton` in order to determine the text width, so I added a public getter `get_button_font` to the `LinkButton` class.
- Loading branch information
Showing
4 changed files
with
30 additions
and
2 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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