diff --git a/resources/default_tweaks.py b/resources/default_tweaks.py index 9726ed3b09..b2133ed331 100644 --- a/resources/default_tweaks.py +++ b/resources/default_tweaks.py @@ -77,7 +77,7 @@ categories_use_field_for_author_name = 'author' # sort: the sort value. For authors, this is the author_sort for that author # category: the category (e.g., authors, series) that the item is in. categories_collapse_more_than = 50 -categories_collapsed_name_template = '{first.name:shorten(4,'',0)} - {last.name::shorten(4,'',0)}' +categories_collapsed_name_template = '{first.sort:shorten(4,'',0)} - {last.sort:shorten(4,'',0)}' categories_collapsed_rating_template = '{first.avg_rating:4.2f:ifempty(0)} - {last.avg_rating:4.2f:ifempty(0)}' categories_collapsed_popularity_template = '{first.count:d} - {last.count:d}' categories_collapse_model = 'first letter' diff --git a/src/calibre/gui2/tag_view.py b/src/calibre/gui2/tag_view.py index f04902283e..d6a7a6d604 100644 --- a/src/calibre/gui2/tag_view.py +++ b/src/calibre/gui2/tag_view.py @@ -738,7 +738,7 @@ class TagsModel(QAbstractItemModel): # {{{ category_key=category_node.category_key) else: if upper(tag.sort[0]) != collapse_letter: - collapse_letter = upper(tag.name[0]) + collapse_letter = upper(tag.sort[0]) sub_cat = TagTreeItem(parent=category, data = collapse_letter, category_icon = category_node.icon,