[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: extragear/plasma/applets/notes
From: Sebastian Kügler <sebas () kde ! nl>
Date: 2008-04-25 14:21:31
Message-ID: 1209133291.616522.15424.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 801040 by sebas:
Enable all the stuff again, still no svg visible :/
M +17 -17 notes.cpp
--- trunk/extragear/plasma/applets/notes/notes.cpp #801039:801040
@@ -49,11 +49,11 @@
m_textEdit->setLineWrapMode(QTextEdit::WidgetWidth);
- //m_textEdit->setAttribute(Qt::WA_NoSystemBackground);
- //m_textEdit->setAutoFillBackground(false);
+ m_textEdit->setAttribute(Qt::WA_NoSystemBackground);
+ m_textEdit->setAutoFillBackground(false);
KConfigGroup cg = config();
- //m_textEdit->setDefaultText(i18n("Welcome to Notes Plasmoid! Type your notes here..."));
+ m_textEdit->setPlainText(i18n("Welcome to Notes Plasmoid! Type your notes here..."));
QString text = cg.readEntry("autoSave",QString());
if (! text.isEmpty()) {
m_textEdit->setPlainText(text);
@@ -65,19 +65,19 @@
m_textEdit->setFont(font);
m_textEdit->setTextColor(textColor);
- //m_textEdit->setTextBackgroundColor(QColor(0,0,0,0));
- //m_textEdit->viewport()->setAutoFillBackground(false);
- //m_textEdit->setStyleSheet("background: none");
+ m_textEdit->setTextBackgroundColor(QColor(0,0,0,0));
+ m_textEdit->viewport()->setAutoFillBackground(false);
+ m_textEdit->setStyleSheet("background: none");
m_proxy = new QGraphicsProxyWidget(this);
- //m_proxy->setWidget(m_textEdit);
- //m_proxy->show();
+ m_proxy->setWidget(m_textEdit);
+ m_proxy->show();
m_layout = new QGraphicsLinearLayout();
m_layout->setContentsMargins(0,0,0,0);
m_layout->setSpacing(0);
- //setLayout(m_layout);
- //m_layout->addItem(m_proxy);
+ setLayout(m_layout);
+ m_layout->addItem(m_proxy);
connect(m_textEdit, SIGNAL(textChanged()), this, SLOT(saveNote()));
//updateTextGeometry();
}
@@ -123,13 +123,13 @@
Q_UNUSED(option);
Q_UNUSED(contentsRect);
- kDebug() << "painting" << geometry();
+ //p->setRenderHint(QPainter::SmoothPixmapTransform);
+ //p->setRenderHint(QPainter::Antialiasing);
- m_notes_theme.resize((int)geometry().width(),
- (int)geometry().height());
- m_notes_theme.paint(p,
- (int)geometry().left(),
- (int)geometry().top());
+ //kDebug() << "painting" << geometry();
+ m_notes_theme.resize(geometry().size());
+
+ m_notes_theme.paint(p, geometry().topLeft());
}
void Notes::createConfigurationInterface(KConfigDialog *parent)
@@ -137,7 +137,7 @@
QWidget *widget = new QWidget();
ui.setupUi(widget);
parent->setButtons( KDialog::Ok | KDialog::Cancel | KDialog::Apply );
- parent->addPage(widget, parent->windowTitle(), "battery");
+ parent->addPage(widget, parent->windowTitle(), "notes");
connect(parent, SIGNAL(applyClicked()), this, SLOT(configAccepted()));
connect(parent, SIGNAL(okClicked()), this, SLOT(configAccepted()));
ui.textColorButton->setColor(m_textEdit->textColor());
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic