From kde-commits Mon Dec 31 17:56:13 2012 From: Pierre Stirnweiss Date: Mon, 31 Dec 2012 17:56:13 +0000 To: kde-commits Subject: [calligra/calligra/2.6] plugins/textshape/dialogs: Do not display default character style Message-Id: <20121231175613.48939A60C4 () git ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=135698112113685 Git commit 1307173f2cbada9dd923c7659bc003ed961595fe by Pierre Stirnweiss. Committed on 31/12/2012 at 18:53. Pushed by pstirnweiss into branch 'calligra/2.6'. Do not display default character style The default character style is shown as "Default" in the combo. This style is not supposed to be seen/used by the user. Note: this is not the special character style "None" used to apply the paragraph style's character properties. M +5 -3 plugins/textshape/dialogs/StylesModel.cpp http://commits.kde.org/calligra/1307173f2cbada9dd923c7659bc003ed961595fe diff --git a/plugins/textshape/dialogs/StylesModel.cpp b/plugins/textshape/= dialogs/StylesModel.cpp index 91f87fc..7e33775 100644 --- a/plugins/textshape/dialogs/StylesModel.cpp +++ b/plugins/textshape/dialogs/StylesModel.cpp @@ -377,9 +377,11 @@ void StylesModel::updateCharacterStyles() qSort(styles.begin(), styles.end(), sortCharacterStyleByName); = foreach(KoCharacterStyle *style, styles) { - m_styleList.append(style->styleId()); - m_styleMapper->setMapping(style, style->styleId()); - connect(style, SIGNAL(nameChanged(const QString&)), m_styleMapper,= SLOT(map())); + if (style !=3D m_styleManager->defaultCharacterStyle()) { //The de= fault character style is not user selectable. It only provides individual p= roperty defaults and is not a style per say. + m_styleList.append(style->styleId()); + m_styleMapper->setMapping(style, style->styleId()); + connect(style, SIGNAL(nameChanged(const QString&)), m_styleMap= per, SLOT(map())); + } } = endResetModel();