~kst-plot/kst/debian-xenial

« back to all changes in this revision

Viewing changes to src/libkstapp/labelcreator.cpp

  • Committer: Steven Benton
  • Date: 2012-11-04 22:45:35 UTC
  • mfrom: (1.2.10)
  • Revision ID: stevebenton@rogers.com-20121104224535-mnnvrp4mhvuz0h2p
* New upstream release.
* Non-maintainer upload.
* Remove patches that have been resolved upstream:
  - desktop-entry-contains-encoding-key.diff
  - desktop-entry-lacks-main-category.diff
    - upstream uses Education category rather than Graphics
  - fix-qreal-vs-double-for-arm.diff
* kst package Replaces and Conflicts with kst2 -- for old PPA users only

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
#include "document.h"
19
19
 
20
20
#include "applicationsettings.h"
 
21
#include "dialogdefaults.h"
 
22
 
21
23
 
22
24
namespace Kst {
23
25
 
37
39
 
38
40
  _labelText->setObjectStore(kstApp->mainWindow()->document()->objectStore());
39
41
 
40
 
  QFont defaultFont(ApplicationSettings::self()->defaultFont());
41
 
  _family->setCurrentFont(defaultFont);
42
 
  _bold->setChecked(defaultFont.bold());
43
 
  _italic->setChecked(defaultFont.italic());
44
 
  _labelColor->setColor(ApplicationSettings::self()->defaultFontColor());
45
 
  _labelFontScale->setValue(ApplicationSettings::self()->defaultFontScale());
 
42
  QFont font;
 
43
  font.fromString(_dialogDefaults->value("label/font",font.toString()).toString());
 
44
  _family->setCurrentFont(font);
 
45
  _bold->setChecked(font.bold());
 
46
  _italic->setChecked(font.italic());
 
47
 
 
48
  _labelColor->setColor(_dialogDefaults->value("label/color",QColor(Qt::black)).value<QColor>());
 
49
  _labelFontScale->setValue(_dialogDefaults->value("label/fontScale",12).toDouble());
 
50
  if (_dialogDefaults->value("label/fixLeft",true).toBool()) {
 
51
    _left->setChecked(true);
 
52
  } else {
 
53
    _right->setChecked(true);
 
54
  }
 
55
  _lockPosToData->setChecked(dialogDefaultsLockPosToData("label"));
 
56
  _saveAsDefault->show();
 
57
 
 
58
  _Label_11->setProperty("si","Font &size:");
 
59
  _Label_12->setProperty("si","Font famil&y:");
46
60
}
47
61
 
48
62
 
72
86
  return font;
73
87
}
74
88
 
 
89
bool LabelCreator::fixLeft() const {
 
90
  return _left->isChecked();
 
91
}
 
92
bool LabelCreator::lockPosToData() const {
 
93
  return _lockPosToData->isChecked();
 
94
}
 
95
 
75
96
}
76
97
 
77
98
// vim: ts=2 sw=2 et