/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * * This file incorporates work covered by the following license notice: * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright * ownership. The ASF licenses this file to you under the Apache * License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
for (constauto& check : checkButton)
{ if (constauto pString = m_xBuilder->weld_check_button(check))
sAllStrings += pString->get_label() + " ";
}
return sAllStrings.replaceAll("_", "");
}
bool SvxAccessibilityOptionsTabPage::FillItemSet( SfxItemSet* )
{
std::shared_ptr<comphelper::ConfigurationChanges> batch( comphelper::ConfigurationChanges::create() ); if ( !officecfg::Office::Common::Accessibility::IsForPagePreviews::isReadOnly() )
officecfg::Office::Common::Accessibility::IsForPagePreviews::set(m_xPagePreviews->get_active(), batch); if ( !officecfg::Office::Common::Accessibility::AllowAnimatedGraphic::isReadOnly() )
officecfg::Office::Common::Accessibility::AllowAnimatedGraphic::set(m_xAnimatedGraphics->get_active(), batch); if ( !officecfg::Office::Common::Accessibility::AllowAnimatedOthers::isReadOnly() )
officecfg::Office::Common::Accessibility::AllowAnimatedOthers::set(m_xAnimatedOthers->get_active(), batch); if ( !officecfg::Office::Common::Accessibility::AllowAnimatedText::isReadOnly() )
officecfg::Office::Common::Accessibility::AllowAnimatedText::set(m_xAnimatedTexts->get_active(), batch); if ( !officecfg::Office::Common::Accessibility::IsAutomaticFontColor::isReadOnly() )
officecfg::Office::Common::Accessibility::IsAutomaticFontColor::set(m_xAutomaticFontColor->get_active(), batch); if ( !officecfg::Office::Common::Accessibility::IsSelectionInReadonly::isReadOnly() )
officecfg::Office::Common::Accessibility::IsSelectionInReadonly::set(m_xTextSelectionInReadonly->get_active(), batch); if ( !officecfg::Office::Common::Accessibility::HighContrast::isReadOnly() )
officecfg::Office::Common::Accessibility::HighContrast::set(m_xHighContrast->get_active(), batch);
constint nCount = m_xOptionsLB->n_children(); for (int i = 0; i < nCount; ++i)
{
OUString option = m_xOptionsLB->get_id(i); constauto& aIssues = std::find_if(
std::begin(options_list), std::end(options_list),
[option](constauto& p) { return p.first == option; })->second;
TriState const current = m_xOptionsLB->get_toggle(i);
TriState saved = m_aSavedOptions[aIssues.first]; if (current != saved)
{ boolconst bChecked(current != TRISTATE_FALSE); switch (aIssues.first)
{ case sfx::AccessibilityIssueID::DOCUMENT_TITLE:
officecfg::Office::Common::AccessibilityIssues::DocumentTitle::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::DOCUMENT_LANGUAGE:
officecfg::Office::Common::AccessibilityIssues::DocumentLanguage::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::DOCUMENT_BACKGROUND:
officecfg::Office::Common::AccessibilityIssues::DocumentBackground::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::STYLE_LANGUAGE:
officecfg::Office::Common::AccessibilityIssues::DocumentStyleLanguage::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::LINKED_GRAPHIC:
officecfg::Office::Common::AccessibilityIssues::LinkedGraphic::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::NO_ALT_OLE:
officecfg::Office::Common::AccessibilityIssues::NoAltOleObj::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::NO_ALT_GRAPHIC:
officecfg::Office::Common::AccessibilityIssues::NoAltGraphicObj::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::NO_ALT_SHAPE:
officecfg::Office::Common::AccessibilityIssues::NoAltShapeObj::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TEXT_NEW_LINES:
officecfg::Office::Common::AccessibilityIssues::TextNewLines::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TEXT_SPACES:
officecfg::Office::Common::AccessibilityIssues::TextSpaces::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TEXT_TABS:
officecfg::Office::Common::AccessibilityIssues::TextTabs::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TEXT_EMPTY_NUM_PARA:
officecfg::Office::Common::AccessibilityIssues::TextEmptyNums::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::DIRECT_FORMATTING:
officecfg::Office::Common::AccessibilityIssues::DirectFormattings::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TABLE_FORMATTING:
officecfg::Office::Common::AccessibilityIssues::TableFormattings::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TABLE_MERGE_SPLIT:
officecfg::Office::Common::AccessibilityIssues::TableMergeSplit::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HYPERLINK_IS_TEXT:
officecfg::Office::Common::AccessibilityIssues::HyperlinkText::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HYPERLINK_SHORT:
officecfg::Office::Common::AccessibilityIssues::HyperlinkShort::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HYPERLINK_NO_NAME:
officecfg::Office::Common::AccessibilityIssues::HyperlinkNoName::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::LINK_IN_HEADER_FOOTER:
officecfg::Office::Common::AccessibilityIssues::LinkInHeaderOrFooter::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::FAKE_FOOTNOTE:
officecfg::Office::Common::AccessibilityIssues::FakeFootnotes::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::FAKE_CAPTION:
officecfg::Office::Common::AccessibilityIssues::FakeCaptions::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::MANUAL_NUMBERING:
officecfg::Office::Common::AccessibilityIssues::ManualNumbering::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TEXT_CONTRAST:
officecfg::Office::Common::AccessibilityIssues::TextContrast::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::TEXT_BLINKING:
officecfg::Office::Common::AccessibilityIssues::TextBlinking::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HEADINGS_NOT_IN_ORDER:
officecfg::Office::Common::AccessibilityIssues::HeadingNotInOrder::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::NON_INTERACTIVE_FORMS:
officecfg::Office::Common::AccessibilityIssues::NonInteractiveForms::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::FLOATING_TEXT:
officecfg::Office::Common::AccessibilityIssues::Floatingtext::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HEADING_IN_TABLE:
officecfg::Office::Common::AccessibilityIssues::HeadingTable::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HEADING_START:
officecfg::Office::Common::AccessibilityIssues::HeadingStart::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::HEADING_ORDER:
officecfg::Office::Common::AccessibilityIssues::HeadingOrder::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::CONTENT_CONTROL:
officecfg::Office::Common::AccessibilityIssues::ContentControl::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::AVOID_FOOTNOTES:
officecfg::Office::Common::AccessibilityIssues::AvoidFootnotes::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::AVOID_ENDNOTES:
officecfg::Office::Common::AccessibilityIssues::AvoidEndnotes::set(bChecked, batch); break;
case sfx::AccessibilityIssueID::FONTWORKS:
officecfg::Office::Common::AccessibilityIssues::FontWorks::set(bChecked, batch); break;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.