[Kde-imaging] extragear/graphics/kipi-plugins
Valerio Fuoglio
valerio.fuoglio at gmail.com
Mon Sep 8 01:05:14 CEST 2008
SVN commit 858385 by vfuoglio:
Now filenames, captions and progress indicators can have transparent
background with OpenGL SlideShow as well.
CCMAIL: kde-imaging at kde.org
GUI:
M +2 -0 NEWS
M +12 -1 slideshow/slideshowconfig.cpp
M +1 -0 slideshow/slideshowconfig.h
M +30 -21 slideshow/slideshowconfigbase.ui
M +6 -3 slideshow/slideshowgl.cpp
M +1 -0 slideshow/slideshowgl.h
--- trunk/extragear/graphics/kipi-plugins/NEWS #858384:858385
@@ -12,6 +12,8 @@
GPSSync : New tool to edit GPS track list using googlemaps.
RAWConverter : Raw files are decoded in 16 bits color depth using same auto-gamma and auto-white
methods provided by dcraw with 8 bits color depth RAW image decoding.
+SlideShow : Now filenames, captions and progress indicators can have transparent
+ backgrounds with OpenGL SlideShow as well.
Kipi-plugins BUG FIXING from B.K.O (http://bugs.kde.org):
--- trunk/extragear/graphics/kipi-plugins/slideshow/slideshowconfig.cpp #858384:858385
@@ -129,6 +129,7 @@
connect(m_printCommentsCheckBox, SIGNAL(toggled(bool)), this, SLOT(slotPrintCommentsToggled()));
connect(m_commentsFontColor, SIGNAL(changed(const QColor &)), this, SLOT(slotCommentsFontColorChanged()));
connect(m_commentsBgColor, SIGNAL(changed(const QColor &)), this, SLOT(slotCommentsBgColorChanged()));
+ connect(m_transparentBgCheckBox, SIGNAL(toggled(bool)), this, SLOT(slotTransparentBgToggled()));
connect(m_useMillisecondsCheckBox, SIGNAL(toggled(bool)), SLOT(slotUseMillisecondsToggled()));
connect(m_delaySpinBox, SIGNAL(valueChanged(int)), this, SLOT(slotDelayChanged()));
connect(m_effectsComboBox, SIGNAL(activated(int)), this, SLOT(slotEffectChanged()));
@@ -186,6 +187,7 @@
slotSelection();
slotEffectChanged();
+ m_tabWidget->setCurrentIndex(0);
}
SlideShowConfig::~SlideShowConfig()
@@ -280,6 +282,7 @@
// Comments tab settings
uint commentsFontColor;
uint commentsBgColor;
+ bool transparentBg;
int commentsLinesLength;
QFont *savedFont = new QFont();
@@ -294,6 +297,7 @@
commentsFontColor = grp.readEntry("Comments Font Color", 0xffffff);
commentsBgColor = grp.readEntry("Comments Bg Color", 0x000000);
+ transparentBg = grp.readEntry("Transparent Bg", true);
commentsLinesLength = grp.readEntry("Comments Lines Length", 72);
@@ -334,6 +338,8 @@
m_commentsLinesLengthSpinBox->setValue(commentsLinesLength);
m_commentsFontColor->setColor(QColor(commentsFontColor));
m_commentsBgColor->setColor(QColor(commentsBgColor));
+ m_commentsBgColor->setEnabled(!transparentBg);
+ m_transparentBgCheckBox->setChecked(transparentBg);
m_commentsFontChooser->setFont(*savedFont);
delete savedFont;
@@ -390,7 +396,7 @@
uint commentsBgColorRGB = bgColor->rgb();
delete bgColor;
grp.writeEntry("Comments Bg Color", commentsBgColorRGB);
-
+ grp.writeEntry("Transparent Bg", m_transparentBgCheckBox->isChecked());
grp.writeEntry("Comments Lines Length", m_commentsLinesLengthSpinBox->value());
if (!m_openglCheckBox->isChecked()) {
@@ -555,6 +561,11 @@
slotEffectChanged();
}
+void SlideShowConfig::slotTransparentBgToggled()
+{
+ m_commentsBgColor->setEnabled(!m_transparentBgCheckBox->isChecked());
+}
+
void SlideShowConfig::slotDelayChanged()
{
ShowNumberImages( m_ImagesFilesListBox->count() );
--- trunk/extragear/graphics/kipi-plugins/slideshow/slideshowconfig.h #858384:858385
@@ -69,6 +69,7 @@
void slotPrintCommentsToggled();
void slotCommentsFontColorChanged();
void slotCommentsBgColorChanged();
+ void slotTransparentBgToggled();
void slotSelection();
void slotCacheToggled();
--- trunk/extragear/graphics/kipi-plugins/slideshow/slideshowconfigbase.ui #858384:858385
@@ -5,7 +5,7 @@
<rect>
<x>0</x>
<y>0</y>
- <width>566</width>
+ <width>578</width>
<height>660</height>
</rect>
</property>
@@ -22,14 +22,14 @@
</sizepolicy>
</property>
<property name="currentIndex" >
- <number>0</number>
+ <number>1</number>
</property>
<widget class="QWidget" name="mainTab" >
<property name="geometry" >
<rect>
<x>0</x>
<y>0</y>
- <width>550</width>
+ <width>562</width>
<height>588</height>
</rect>
</property>
@@ -672,14 +672,14 @@
<rect>
<x>0</x>
<y>0</y>
- <width>550</width>
- <height>524</height>
+ <width>562</width>
+ <height>588</height>
</rect>
</property>
<attribute name="title" >
<string>Comments</string>
</attribute>
- <layout class="QVBoxLayout" name="_14" >
+ <layout class="QVBoxLayout" name="verticalLayout_4" >
<item>
<widget class="KFontChooser" name="m_commentsFontChooser" >
<property name="sizePolicy" >
@@ -691,16 +691,16 @@
</widget>
</item>
<item>
- <layout class="QHBoxLayout" name="_15" >
+ <layout class="QHBoxLayout" name="horizontalLayout_2" >
<item>
<widget class="Q3GroupBox" name="groupBox7" >
<property name="title" >
<string>Colors</string>
</property>
- <layout class="QVBoxLayout" name="_16" >
+ <layout class="QVBoxLayout" name="verticalLayout_3" >
<item>
- <layout class="QHBoxLayout" name="_17" >
- <item>
+ <layout class="QGridLayout" name="gridLayout" >
+ <item row="0" column="0" >
<widget class="QLabel" name="textLabel1" >
<property name="text" >
<string>Font color :</string>
@@ -710,7 +710,7 @@
</property>
</widget>
</item>
- <item>
+ <item row="0" column="1" colspan="2" >
<spacer name="spacer62" >
<property name="orientation" >
<enum>Qt::Horizontal</enum>
@@ -726,7 +726,7 @@
</property>
</spacer>
</item>
- <item>
+ <item row="0" column="3" >
<widget class="KColorButton" name="m_commentsFontColor" >
<property name="text" >
<string/>
@@ -740,11 +740,7 @@
</property>
</widget>
</item>
- </layout>
- </item>
- <item>
- <layout class="QHBoxLayout" name="_18" >
- <item>
+ <item row="1" column="0" colspan="2" >
<widget class="QLabel" name="textLabel1_2" >
<property name="text" >
<string>Background color:</string>
@@ -754,7 +750,7 @@
</property>
</widget>
</item>
- <item>
+ <item row="1" column="2" >
<spacer name="spacer61" >
<property name="orientation" >
<enum>Qt::Horizontal</enum>
@@ -770,7 +766,7 @@
</property>
</spacer>
</item>
- <item>
+ <item row="1" column="3" >
<widget class="KColorButton" name="m_commentsBgColor" >
<property name="text" >
<string/>
@@ -783,6 +779,19 @@
</property>
</widget>
</item>
+ <item row="2" column="0" colspan="4" >
+ <widget class="QCheckBox" name="m_transparentBgCheckBox" >
+ <property name="sizePolicy" >
+ <sizepolicy vsizetype="Minimum" hsizetype="MinimumExpanding" >
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="text" >
+ <string>Transparent background</string>
+ </property>
+ </widget>
+ </item>
</layout>
</item>
</layout>
@@ -875,8 +884,8 @@
<rect>
<x>0</x>
<y>0</y>
- <width>550</width>
- <height>524</height>
+ <width>562</width>
+ <height>588</height>
</rect>
</property>
<attribute name="title" >
--- trunk/extragear/graphics/kipi-plugins/slideshow/slideshowgl.cpp #858384:858385
@@ -191,6 +191,7 @@
m_commentsFontColor = grp.readEntry("Comments Font Color", 0xffffff);
m_commentsBgColor = grp.readEntry("Comments Bg Color", 0x000000);
+ m_transparentBg = grp.readEntry("Transparent Bg", true);
m_commentsLinesLength = grp.readEntry("Comments Lines Length", 72);
@@ -581,7 +582,7 @@
//rect.setCoords( 0, 0, 2, 2 );
QPixmap pix(rect.width(),rect.height());
- pix.fill(Qt::black);
+ pix.fill(Qt::transparent);
QPainter p(&pix);
p.setPen(Qt::white);
@@ -611,7 +612,7 @@
rect.addCoords( 0, 0, 2, 2 );
QPixmap pix(rect.width(),rect.height());
- pix.fill(Qt::black);
+ pix.fill(Qt::transparent);
QPainter p(&pix);
@@ -694,7 +695,9 @@
rect.addCoords( 0, 0, 2, 2 );
QPixmap pix(rect.width(),rect.height());
- pix.fill(QColor(m_commentsBgColor));
+
+ if ( m_transparentBg ) pix.fill(Qt::transparent);
+ else pix.fill(QColor(m_commentsBgColor));
QPainter p(&pix);
p.setPen(QColor(m_commentsFontColor));
--- trunk/extragear/graphics/kipi-plugins/slideshow/slideshowgl.h #858384:858385
@@ -131,6 +131,7 @@
QFont* m_commentsFont;
uint m_commentsFontColor;
uint m_commentsBgColor;
+ bool m_transparentBg;
int m_commentsLinesLength;
bool m_enableMouseWheel;
More information about the Kde-imaging
mailing list