Changeset View
Changeset View
Standalone View
Standalone View
kcms/kfontinst/kcmfontinst/KCmFontInst.cpp
Show First 20 Lines • Show All 223 Lines • ▼ Show 20 Line(s) | 223 | // toolbar->addAction(validateFontsAct); | |||
---|---|---|---|---|---|
224 | toolbar->setToolButtonStyle(Qt::ToolButtonFollowStyle); | 224 | toolbar->setToolButtonStyle(Qt::ToolButtonFollowStyle); | ||
225 | itsFilter=new CFontFilter(toolbarWidget); | 225 | itsFilter=new CFontFilter(toolbarWidget); | ||
226 | 226 | | |||
227 | // Details - Groups... | 227 | // Details - Groups... | ||
228 | itsGroupList=new CGroupList(groupWidget); | 228 | itsGroupList=new CGroupList(groupWidget); | ||
229 | itsGroupListView=new CGroupListView(groupWidget, itsGroupList); | 229 | itsGroupListView=new CGroupListView(groupWidget, itsGroupList); | ||
230 | 230 | | |||
231 | QPushButton *createGroup=new CPushButton(KGuiItem(QString(), "list-add", | 231 | QPushButton *createGroup=new CPushButton(KGuiItem(QString(), "list-add", | ||
232 | i18n("Create a new group")), | 232 | i18n("Create New Group...")), | ||
233 | groupWidget); | 233 | groupWidget); | ||
234 | 234 | | |||
235 | itsDeleteGroupControl=new CPushButton(KGuiItem(QString(), "edit-delete", | 235 | itsDeleteGroupControl=new CPushButton(KGuiItem(QString(), "list-remove", | ||
236 | i18n("Remove group")), | 236 | i18n("Remove Group...")), | ||
ngraham: This one doesn't need an ellipsis. If the window/dialog that pops up when you click on it is… | |||||
The HIG says "Indicate a command that needs additional information (including confirmation) by adding an ellipsis at the end of the button label." GB_2: The HIG says "Indicate a command that needs additional information (including confirmation) by… | |||||
Heh I think that may be a typo and the word was supposed to be "excluding". I specifically remember having a conversation about this and we concluded that confirmation prompts didn't count because then you would need to conditionally give ellipses to Close and a whole bunch of other things that don't really need it. ngraham: Heh I think that may be a typo and the word was supposed to be "excluding". I specifically… | |||||
GB_2: Ok, will change it.
Then we also need to update the HIG. | |||||
237 | groupWidget); | 237 | groupWidget); | ||
238 | 238 | | |||
239 | itsEnableGroupControl=new CPushButton(KGuiItem(QString(), "enablefont", | 239 | itsEnableGroupControl=new CPushButton(KGuiItem(QString(), "enablefont", | ||
240 | i18n("Enable all disabled fonts in the current group")), | 240 | i18n("Enable Fonts in Group...")), | ||
Same: no ellipsis when the "additional user input required" is just a confirmation dialog (and do we even need this confirmation dialog anyway???). ngraham: Same: no ellipsis when the "additional user input required" is just a confirmation dialog (and… | |||||
241 | groupWidget); | 241 | groupWidget); | ||
242 | 242 | | |||
243 | itsDisableGroupControl=new CPushButton(KGuiItem(QString(), "disablefont", | 243 | itsDisableGroupControl=new CPushButton(KGuiItem(QString(), "disablefont", | ||
244 | i18n("Disable all enabled fonts in the current group")), | 244 | i18n("Disable Fonts in Group...")), | ||
ngraham: Same | |||||
245 | groupWidget); | 245 | groupWidget); | ||
246 | 246 | | |||
247 | groupsLayout->addWidget(itsGroupListView, 0, 0, 1, 5); | 247 | groupsLayout->addWidget(itsGroupListView, 0, 0, 1, 5); | ||
248 | groupsLayout->addWidget(createGroup, 1, 0); | 248 | groupsLayout->addWidget(createGroup, 1, 0); | ||
249 | groupsLayout->addWidget(itsDeleteGroupControl, 1, 1); | 249 | groupsLayout->addWidget(itsDeleteGroupControl, 1, 1); | ||
250 | groupsLayout->addWidget(itsEnableGroupControl, 1, 2); | 250 | groupsLayout->addWidget(itsEnableGroupControl, 1, 2); | ||
251 | groupsLayout->addWidget(itsDisableGroupControl, 1, 3); | 251 | groupsLayout->addWidget(itsDisableGroupControl, 1, 3); | ||
252 | groupsLayout->addItem(new QSpacerItem(itsDisableGroupControl->width(), groupsLayout->spacing(), | 252 | groupsLayout->addItem(new QSpacerItem(itsDisableGroupControl->width(), groupsLayout->spacing(), | ||
Show All 33 Lines | |||||
286 | 286 | | |||
287 | itsAddFontControl=new CPushButton(KGuiItem(i18n("Install from File..."), "document-import", | 287 | itsAddFontControl=new CPushButton(KGuiItem(i18n("Install from File..."), "document-import", | ||
288 | i18n("Install fonts from a local file")), | 288 | i18n("Install fonts from a local file")), | ||
289 | fontControlWidget); | 289 | fontControlWidget); | ||
290 | itsGetNewFontsControl=new CPushButton(KGuiItem(i18n("Get New Fonts..."), "get-hot-new-stuff", | 290 | itsGetNewFontsControl=new CPushButton(KGuiItem(i18n("Get New Fonts..."), "get-hot-new-stuff", | ||
291 | i18n("Download new fonts")), | 291 | i18n("Download new fonts")), | ||
292 | fontControlWidget); | 292 | fontControlWidget); | ||
293 | 293 | | |||
294 | itsDeleteFontControl=new CPushButton(KGuiItem(i18n("Delete"), "edit-delete", | 294 | itsDeleteFontControl=new CPushButton(KGuiItem(QString(), "edit-delete", | ||
295 | i18n("Delete all selected fonts")), | 295 | i18n("Delete Selected Fonts...")), | ||
ngraham: Same | |||||
296 | fontControlWidget); | 296 | fontControlWidget); | ||
297 | 297 | | |||
298 | itsPreviewSplitter->addWidget(itsPreviewWidget); | 298 | itsPreviewSplitter->addWidget(itsPreviewWidget); | ||
299 | itsPreviewSplitter->setCollapsible(1, true); | 299 | itsPreviewSplitter->setCollapsible(1, true); | ||
300 | 300 | | |||
301 | itsStatusLabel = new QLabel(fontControlWidget); | 301 | itsStatusLabel = new QLabel(fontControlWidget); | ||
302 | itsStatusLabel->setAlignment(Qt::AlignVCenter|Qt::AlignRight); | 302 | itsStatusLabel->setAlignment(Qt::AlignVCenter|Qt::AlignRight); | ||
303 | itsListingProgress=new CProgressBar(fontControlWidget, itsStatusLabel->height()); | 303 | itsListingProgress=new CProgressBar(fontControlWidget, itsStatusLabel->height()); | ||
304 | itsListingProgress->setRange(0, 100); | 304 | itsListingProgress->setRange(0, 100); | ||
305 | 305 | | |||
306 | // Layout widgets... | 306 | // Layout widgets... | ||
307 | toolbarLayout->addWidget(toolbar); | 307 | toolbarLayout->addWidget(toolbar); | ||
308 | toolbarLayout->addItem(new QSpacerItem(toolbarLayout->spacing(), 2, QSizePolicy::MinimumExpanding, QSizePolicy::Fixed)); | | |||
309 | toolbarLayout->addWidget(itsFilter); | 308 | toolbarLayout->addWidget(itsFilter); | ||
310 | mainLayout->addWidget(toolbarWidget); | 309 | mainLayout->addWidget(toolbarWidget); | ||
311 | mainLayout->addWidget(itsGroupSplitter); | 310 | mainLayout->addWidget(itsGroupSplitter); | ||
312 | 311 | | |||
313 | fontControlLayout->addWidget(itsDeleteFontControl); | 312 | fontControlLayout->addWidget(itsDeleteFontControl); | ||
314 | fontControlLayout->addWidget(itsStatusLabel); | 313 | fontControlLayout->addWidget(itsStatusLabel); | ||
315 | fontControlLayout->addItem(new QSpacerItem(0, itsListingProgress->height()+4, | 314 | fontControlLayout->addItem(new QSpacerItem(0, itsListingProgress->height()+4, | ||
316 | QSizePolicy::Fixed, QSizePolicy::Fixed)); | 315 | QSizePolicy::Fixed, QSizePolicy::Fixed)); | ||
▲ Show 20 Lines • Show All 486 Lines • ▼ Show 20 Line(s) | |||||
803 | { | 802 | { | ||
804 | toggleFonts(false); | 803 | toggleFonts(false); | ||
805 | } | 804 | } | ||
806 | 805 | | |||
807 | void CKCmFontInst::addGroup() | 806 | void CKCmFontInst::addGroup() | ||
808 | { | 807 | { | ||
809 | bool ok; | 808 | bool ok; | ||
810 | QString name(QInputDialog::getText(this, i18n("Create New Group"), | 809 | QString name(QInputDialog::getText(this, i18n("Create New Group"), | ||
811 | i18n("Please enter the name of the new group:"), | 810 | i18n("Name of New Group:"), | ||
812 | QLineEdit::Normal, | 811 | QLineEdit::Normal, | ||
813 | i18n("New Group"), &ok)); | 812 | i18n("New Group"), &ok)); | ||
814 | 813 | | |||
815 | if(ok && !name.isEmpty()) | 814 | if(ok && !name.isEmpty()) | ||
816 | itsGroupList->createGroup(name); | 815 | itsGroupList->createGroup(name); | ||
817 | } | 816 | } | ||
818 | 817 | | |||
819 | void CKCmFontInst::removeGroup() | 818 | void CKCmFontInst::removeGroup() | ||
▲ Show 20 Lines • Show All 458 Lines • Show Last 20 Lines |
This one doesn't need an ellipsis. If the window/dialog that pops up when you click on it is nothing more than a confirmation box, we don't use ellipsis.
However the confirmation dialog that results from clicking on this could use better icons in its buttons for sure.