Bug 114280 - Styles filter dropdown list doesnt share string between style types
Summary: Styles filter dropdown list doesnt share string between style types
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
(earliest affected)
Hardware: All All
: medium normal
Assignee: Not Assigned
Depends on:
Blocks: l10n-Optimization Sidebar-Styles-Filter
  Show dependency treegraph
Reported: 2017-12-06 11:58 UTC by Yousuf Philips (jay) (retired)
Modified: 2022-03-11 13:01 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Note You need to log in before you can comment on or make changes to this bug.
Description Yousuf Philips (jay) (retired) 2017-12-06 11:58:50 UTC
The strings 'All Styles', 'Hidden Styles', 'Applied Styles', 'Custom Styles' are used in all the style types in the styles sidebar deck, but they dont share the same string. The 'Hierarchial' string[1] is being shared.

The strings are in this file

[1] https://opengrok.libreoffice.org/xref/core/include/sfx2/strings.hrc#217
Comment 1 Buovjaga 2017-12-13 17:34:01 UTC
Let's put this to NEW
Comment 2 QA Administrators 2018-12-14 03:55:44 UTC Comment hidden (obsolete)
Comment 3 QA Administrators 2020-12-14 03:42:31 UTC Comment hidden (obsolete)
Comment 4 Julien Nabet 2022-03-11 12:45:13 UTC
Ilmari: Perhaps I missed something but I don't see any duplicates now.
git grep -in style include/sfx2/strings.hrc
include/sfx2/strings.hrc:58:#define STR_QRYTEMPL_MESSAGE                    NC_("STR_QRYTEMPL_MESSAGE", "The template '$(ARG1)' on which this document is based, has been modified. Do you want to update the styles of the current document, using the modified template?")
include/sfx2/strings.hrc:59:#define STR_QRYTEMPL_UPDATE_BTN                 NC_("STR_QRYTEMPL_UPDATE_BTN", "~Update Styles")
include/sfx2/strings.hrc:60:#define STR_QRYTEMPL_KEEP_BTN                   NC_("STR_QRYTEMPL_KEEP_BTN", "~Keep Old Styles")
include/sfx2/strings.hrc:222:#define STR_QUERY_OVERWRITE                     NC_("STR_QUERY_OVERWRITE", "Style already exists. Overwrite?")
include/sfx2/strings.hrc:226:#define STR_TABPAGE_INVALIDSTYLE                NC_("STR_TABPAGE_INVALIDSTYLE", "This Style does not exist.")
include/sfx2/strings.hrc:227:#define STR_TABPAGE_INVALIDPARENT               NC_("STR_TABPAGE_INVALIDPARENT", "This Style cannot be used as a base Style,\nbecause it would result in a recursive reference.")
include/sfx2/strings.hrc:228:#define STR_POOL_STYLE_NAME                     NC_("STR_POOL_STYLE_NAME", "Name already exists as a default Style.\nPlease choose another name.")
include/sfx2/strings.hrc:229:#define STR_DELETE_STYLE_USED                   NC_("STR_DELETE_STYLE_USED", "One or more of the selected styles is in use in this document.\nIf you will delete it, text or objects using these styles will revert to the parent style.\nDo you still wish to delete these styles?\n")
include/sfx2/strings.hrc:230:#define STR_DELETE_STYLE                        NC_("STR_DELETE_STYLE", "Styles in use: ")
include/sfx2/strings.hrc:239:#define STR_STYLE_FILTER_HIERARCHICAL           NC_("STR_STYLE_FILTER_HIERARCHICAL", "Hierarchical")
include/sfx2/strings.hrc:338:#define STR_STYLEUSEDBY                         NC_("STR_STYLEUSEDBY", "(used by: %STYLELIST)")

so no "Hidden Styles', 'Applied Styles', ...
About Hierarchial, I did a git grep on sw:
git grep -in HIERARCHICAL
IwyuFilter_sw.yaml:636:    - com/sun/star/container/XHierarchicalNameAccess.hpp
README.md:154:  hierarchical tree of numbered nodes.
inc/SwNumberTree.hxx:502:       Validates a child using hierarchical numbering.
inc/SwNumberTree.hxx:508:    void ValidateHierarchical(const SwNumberTreeNode* pNode) const;
source/core/SwNumberTree/SwNumberTree.cxx:126:void SwNumberTreeNode::ValidateHierarchical(const SwNumberTreeNode * pNode) const
source/core/SwNumberTree/SwNumberTree.cxx:293:            ValidateHierarchical(pNode);
source/filter/xml/XMLRedlineImportHelper.cxx:208:    // next redline info (for hierarchical redlines)
source/filter/xml/XMLRedlineImportHelper.cxx:420:    // 3b) we already have a redline with this name: hierarchical redlines
source/filter/xml/XMLRedlineImportHelper.cxx:723:    //    ( check presence and sanity of hierarchical redline info )
source/filter/xml/swxml.cxx:728:                pMedDescrMedium->GetItemSet()->GetItem(SID_DOC_HIERARCHICALNAME);
source/filter/xml/wrtxml.cxx:88:    OUString aDocHierarchicalName;
source/filter/xml/wrtxml.cxx:98:            pMediumItemSet->GetItem(SID_DOC_HIERARCHICALNAME);
source/filter/xml/wrtxml.cxx:100:            aDocHierarchicalName = pDocHierarchItem->GetValue();
source/filter/xml/wrtxml.cxx:235:        const OUString aName( !aDocHierarchicalName.isEmpty()
source/filter/xml/wrtxml.cxx:236:            ? aDocHierarchicalName
source/uibase/docvw/srcedtw.cxx:27:#include <com/sun/star/container/XHierarchicalNameAccess.hpp>

so no duplication too.

Should we put this one to WFM?
Comment 5 Buovjaga 2022-03-11 13:01:31 UTC
I believe you and will close