cui/source/options/fontsubs.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 12348430e0139b4f2e72984e8a1619baca842df6 Author: Stephan Bergmann <[email protected]> AuthorDate: Tue May 31 15:29:53 2022 +0200 Commit: Stephan Bergmann <[email protected]> CommitDate: Tue May 31 18:51:39 2022 +0200 Use a range-based for loop Change-Id: I50742cd64c63d6c81599ebda3ff2c093e722c91a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135190 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <[email protected]> diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx index 67a34dec489e..b5c98b76663b 100644 --- a/cui/source/options/fontsubs.cxx +++ b/cui/source/options/fontsubs.cxx @@ -204,10 +204,10 @@ void SvxFontSubstTabPage::Reset( const SfxItemSet* ) std::vector<SubstitutionStruct> aFontSubs = svtools::GetFontSubstitutions(); std::unique_ptr<weld::TreeIter> xIter(m_xCheckLB->make_iterator()); - for (sal_Int32 i = 0; i < static_cast<sal_Int32>(aFontSubs.size()); ++i) + for (auto const & i: aFontSubs) { m_xCheckLB->append(xIter.get()); - const SubstitutionStruct* pSubs = &aFontSubs[i]; + const SubstitutionStruct* pSubs = &i; m_xCheckLB->set_toggle(*xIter, pSubs->bReplaceAlways ? TRISTATE_TRUE : TRISTATE_FALSE, 0); m_xCheckLB->set_toggle(*xIter, pSubs->bReplaceOnScreenOnly ? TRISTATE_TRUE : TRISTATE_FALSE, 1); m_xCheckLB->set_text(*xIter, pSubs->sFont, 2);
