MCPcopy Create free account
hub / github.com/KDE/kid3 / fromFormatConfig

Method fromFormatConfig

src/gui/widgets/formatbox.cpp:80–91  ·  view source on GitHub ↗

* Set the values from a format configuration. * * @param cfg format configuration */

Source from the content-addressed store, hash-verified

78 * @param cfg format configuration
79 */
80void FormatBox::fromFormatConfig(const FormatConfig& cfg)
81{
82 m_formatEditingCheckBox->setChecked(cfg.formatWhileEditing());
83 m_caseConvComboBox->setCurrentIndex(cfg.caseConversion());
84 int localeIndex = m_localeComboBox->findText(cfg.localeName());
85 if (localeIndex == -1) {
86 localeIndex = 0;
87 }
88 m_localeComboBox->setCurrentIndex(localeIndex);
89 m_strRepCheckBox->setChecked(cfg.strRepEnabled());
90 m_strReplTableModel->setMap(cfg.strRepMap());
91}
92
93/**
94 * Store the values in a format configuration.

Callers 1

setConfigsMethod · 0.45

Calls 3

findTextMethod · 0.80
setMapMethod · 0.80
setCurrentIndexMethod · 0.45

Tested by

no test coverage detected