A<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
		<id>http://www.cppe.ru/index.php?action=history&amp;feed=atom&amp;title=C%2B%2B%2FQt%2FQPixmap</id>
		<title>C++/Qt/QPixmap - История изменений</title>
		<link rel="self" type="application/atom+xml" href="http://www.cppe.ru/index.php?action=history&amp;feed=atom&amp;title=C%2B%2B%2FQt%2FQPixmap"/>
		<link rel="alternate" type="text/html" href="http://www.cppe.ru/index.php?title=C%2B%2B/Qt/QPixmap&amp;action=history"/>
		<updated>2026-04-18T22:13:48Z</updated>
		<subtitle>История изменений этой страницы в вики</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>http://www.cppe.ru/index.php?title=C%2B%2B/Qt/QPixmap&amp;diff=1150&amp;oldid=prev</id>
		<title> в 14:21, 25 мая 2010</title>
		<link rel="alternate" type="text/html" href="http://www.cppe.ru/index.php?title=C%2B%2B/Qt/QPixmap&amp;diff=1150&amp;oldid=prev"/>
				<updated>2010-05-25T14:21:06Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Предыдущая&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Версия 14:21, 25 мая 2010&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; lang=&quot;ru&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(нет различий)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
			</entry>

	<entry>
		<id>http://www.cppe.ru/index.php?title=C%2B%2B/Qt/QPixmap&amp;diff=1151&amp;oldid=prev</id>
		<title>Admin: 1 версия:&amp;#32;Импорт контента...</title>
		<link rel="alternate" type="text/html" href="http://www.cppe.ru/index.php?title=C%2B%2B/Qt/QPixmap&amp;diff=1151&amp;oldid=prev"/>
				<updated>2010-05-25T10:24:58Z</updated>
		
		<summary type="html">&lt;p&gt;1 версия: Импорт контента...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==Create pixmal with QPixmap, save to png file==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;  &lt;br /&gt;
Foundations of Qt Development\Chapter07\paths\main.cpp&lt;br /&gt;
/*&lt;br /&gt;
 * Copyright (c) 2006-2007, Johan Thelin&lt;br /&gt;
 * &lt;br /&gt;
 * All rights reserved.&lt;br /&gt;
 * &lt;br /&gt;
 * Redistribution and use in source and binary forms, with or without modification, &lt;br /&gt;
 * are permitted provided that the following conditions are met:&lt;br /&gt;
 * &lt;br /&gt;
 *     * Redistributions of source code must retain the above copyright notice, &lt;br /&gt;
 *       this list of conditions and the following disclaimer.&lt;br /&gt;
 *     * Redistributions in binary form must reproduce the above copyright notice,  &lt;br /&gt;
 *       this list of conditions and the following disclaimer in the documentation &lt;br /&gt;
 *       and/or other materials provided with the distribution.&lt;br /&gt;
 *     * Neither the name of APress nor the names of its contributors &lt;br /&gt;
 *       may be used to endorse or promote products derived from this software &lt;br /&gt;
 *       without specific prior written permission.&lt;br /&gt;
 * &lt;br /&gt;
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS&lt;br /&gt;
 * &amp;quot;AS IS&amp;quot; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT&lt;br /&gt;
 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR&lt;br /&gt;
 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR&lt;br /&gt;
 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,&lt;br /&gt;
 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,&lt;br /&gt;
 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR&lt;br /&gt;
 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF&lt;br /&gt;
 * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING&lt;br /&gt;
 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS&lt;br /&gt;
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.&lt;br /&gt;
 *&lt;br /&gt;
 */&lt;br /&gt;
#include &amp;lt;QApplication&amp;gt;&lt;br /&gt;
#include &amp;lt;QPainter&amp;gt;&lt;br /&gt;
#include &amp;lt;QPainterPath&amp;gt;&lt;br /&gt;
#include &amp;lt;QPixmap&amp;gt;&lt;br /&gt;
int main( int argc, char **argv )&lt;br /&gt;
{&lt;br /&gt;
  QApplication app( argc, argv );&lt;br /&gt;
  &lt;br /&gt;
  QPixmap pixmap( 200, 200 );&lt;br /&gt;
  pixmap.fill( Qt::white );&lt;br /&gt;
    &lt;br /&gt;
  QPainterPath path;&lt;br /&gt;
  &lt;br /&gt;
  path.addEllipse( 80, 80, 80, 80 );&lt;br /&gt;
  &lt;br /&gt;
  path.moveTo( 120, 120 );&lt;br /&gt;
  path.lineTo( 120, 40 );&lt;br /&gt;
  path.arcTo( 40, 40, 160, 160, 90, 90 );&lt;br /&gt;
  path.lineTo( 120, 120 );&lt;br /&gt;
  &lt;br /&gt;
  QFont font = QApplication::font();&lt;br /&gt;
  font.setPixelSize( 40 );&lt;br /&gt;
  &lt;br /&gt;
  path.addText( 20, 180, font, &amp;quot;Path&amp;quot; );&lt;br /&gt;
  &lt;br /&gt;
  QPainter painter( &amp;amp;pixmap );&lt;br /&gt;
  painter.setRenderHint( QPainter::Antialiasing );&lt;br /&gt;
  &lt;br /&gt;
  painter.setPen( Qt::black );&lt;br /&gt;
  painter.setBrush( Qt::gray );&lt;br /&gt;
  &lt;br /&gt;
  painter.drawPath( path );&lt;br /&gt;
  &lt;br /&gt;
  pixmap.save( &amp;quot;path.png&amp;quot; );&lt;br /&gt;
  &lt;br /&gt;
  return 0;&lt;br /&gt;
}&lt;br /&gt;
   &lt;br /&gt;
    &lt;br /&gt;
  &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Create screen shot==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;  &lt;br /&gt;
/****************************************************************************&lt;br /&gt;
**&lt;br /&gt;
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).&lt;br /&gt;
** All rights reserved.&lt;br /&gt;
** Contact: Nokia Corporation (qt-info@nokia.com)&lt;br /&gt;
**&lt;br /&gt;
** This file is part of the examples of the Qt Toolkit.&lt;br /&gt;
**&lt;br /&gt;
** $QT_BEGIN_LICENSE:LGPL$&lt;br /&gt;
** Commercial Usage&lt;br /&gt;
** Licensees holding valid Qt Commercial licenses may use this file in&lt;br /&gt;
** accordance with the Qt Commercial License Agreement provided with the&lt;br /&gt;
** Software or, alternatively, in accordance with the terms contained in&lt;br /&gt;
** a written agreement between you and Nokia.&lt;br /&gt;
**&lt;br /&gt;
** GNU Lesser General Public License Usage&lt;br /&gt;
** Alternatively, this file may be used under the terms of the GNU Lesser&lt;br /&gt;
** General Public License version 2.1 as published by the Free Software&lt;br /&gt;
** Foundation and appearing in the file LICENSE.LGPL included in the&lt;br /&gt;
** packaging of this file.  Please review the following information to&lt;br /&gt;
** ensure the GNU Lesser General Public License version 2.1 requirements&lt;br /&gt;
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.&lt;br /&gt;
**&lt;br /&gt;
** In addition, as a special exception, Nokia gives you certain additional&lt;br /&gt;
** rights.  These rights are described in the Nokia Qt LGPL Exception&lt;br /&gt;
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.&lt;br /&gt;
**&lt;br /&gt;
** GNU General Public License Usage&lt;br /&gt;
** Alternatively, this file may be used under the terms of the GNU&lt;br /&gt;
** General Public License version 3.0 as published by the Free Software&lt;br /&gt;
** Foundation and appearing in the file LICENSE.GPL included in the&lt;br /&gt;
** packaging of this file.  Please review the following information to&lt;br /&gt;
** ensure the GNU General Public License version 3.0 requirements will be&lt;br /&gt;
** met: http://www.gnu.org/copyleft/gpl.html.&lt;br /&gt;
**&lt;br /&gt;
** If you have questions regarding the use of this file, please contact&lt;br /&gt;
** Nokia at qt-info@nokia.com.&lt;br /&gt;
** $QT_END_LICENSE$&lt;br /&gt;
**&lt;br /&gt;
****************************************************************************/&lt;br /&gt;
#ifndef SCREENSHOT_H&lt;br /&gt;
#define SCREENSHOT_H&lt;br /&gt;
#include &amp;lt;QPixmap&amp;gt;&lt;br /&gt;
#include &amp;lt;QWidget&amp;gt;&lt;br /&gt;
QT_BEGIN_NAMESPACE&lt;br /&gt;
class QCheckBox;&lt;br /&gt;
class QGridLayout;&lt;br /&gt;
class QGroupBox;&lt;br /&gt;
class QHBoxLayout;&lt;br /&gt;
class QLabel;&lt;br /&gt;
class QPushButton;&lt;br /&gt;
class QSpinBox;&lt;br /&gt;
class QVBoxLayout;&lt;br /&gt;
QT_END_NAMESPACE&lt;br /&gt;
&lt;br /&gt;
class Screenshot : public QWidget&lt;br /&gt;
{&lt;br /&gt;
    Q_OBJECT&lt;br /&gt;
public:&lt;br /&gt;
    Screenshot();&lt;br /&gt;
protected:&lt;br /&gt;
    void resizeEvent(QResizeEvent *event);&lt;br /&gt;
private slots:&lt;br /&gt;
    void newScreenshot();&lt;br /&gt;
    void saveScreenshot();&lt;br /&gt;
    void shootScreen();&lt;br /&gt;
    void updateCheckBox();&lt;br /&gt;
private:&lt;br /&gt;
    void createOptionsGroupBox();&lt;br /&gt;
    void createButtonsLayout();&lt;br /&gt;
    QPushButton *createButton(const QString &amp;amp;text, QWidget *receiver,&lt;br /&gt;
                              const char *member);&lt;br /&gt;
    void updateScreenshotLabel();&lt;br /&gt;
    QPixmap originalPixmap;&lt;br /&gt;
    QLabel *screenshotLabel;&lt;br /&gt;
    QGroupBox *optionsGroupBox;&lt;br /&gt;
    QSpinBox *delaySpinBox;&lt;br /&gt;
    QLabel *delaySpinBoxLabel;&lt;br /&gt;
    QCheckBox *hideThisWindowCheckBox;&lt;br /&gt;
    QPushButton *newScreenshotButton;&lt;br /&gt;
    QPushButton *saveScreenshotButton;&lt;br /&gt;
    QPushButton *quitScreenshotButton;&lt;br /&gt;
    QVBoxLayout *mainLayout;&lt;br /&gt;
    QGridLayout *optionsGroupBoxLayout;&lt;br /&gt;
    QHBoxLayout *buttonsLayout;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
#endif&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;QtGui&amp;gt;&lt;br /&gt;
#include &amp;quot;screenshot.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Screenshot::Screenshot()&lt;br /&gt;
{&lt;br /&gt;
    screenshotLabel = new QLabel;&lt;br /&gt;
    screenshotLabel-&amp;gt;setSizePolicy(QSizePolicy::Expanding,&lt;br /&gt;
                                   QSizePolicy::Expanding);&lt;br /&gt;
    screenshotLabel-&amp;gt;setAlignment(Qt::AlignCenter);&lt;br /&gt;
    screenshotLabel-&amp;gt;setMinimumSize(240, 160);&lt;br /&gt;
    createOptionsGroupBox();&lt;br /&gt;
    createButtonsLayout();&lt;br /&gt;
    mainLayout = new QVBoxLayout;&lt;br /&gt;
    mainLayout-&amp;gt;addWidget(screenshotLabel);&lt;br /&gt;
    mainLayout-&amp;gt;addWidget(optionsGroupBox);&lt;br /&gt;
    mainLayout-&amp;gt;addLayout(buttonsLayout);&lt;br /&gt;
    setLayout(mainLayout);&lt;br /&gt;
    shootScreen();&lt;br /&gt;
    delaySpinBox-&amp;gt;setValue(5);&lt;br /&gt;
    setWindowTitle(tr(&amp;quot;Screenshot&amp;quot;));&lt;br /&gt;
    resize(300, 200);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::resizeEvent(QResizeEvent * /* event */)&lt;br /&gt;
{&lt;br /&gt;
    QSize scaledSize = originalPixmap.size();&lt;br /&gt;
    scaledSize.scale(screenshotLabel-&amp;gt;size(), Qt::KeepAspectRatio);&lt;br /&gt;
    if (!screenshotLabel-&amp;gt;pixmap()&lt;br /&gt;
            || scaledSize != screenshotLabel-&amp;gt;pixmap()-&amp;gt;size())&lt;br /&gt;
        updateScreenshotLabel();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::newScreenshot()&lt;br /&gt;
{&lt;br /&gt;
    if (hideThisWindowCheckBox-&amp;gt;isChecked())&lt;br /&gt;
        hide();&lt;br /&gt;
    newScreenshotButton-&amp;gt;setDisabled(true);&lt;br /&gt;
    QTimer::singleShot(delaySpinBox-&amp;gt;value() * 1000, this, SLOT(shootScreen()));&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::saveScreenshot()&lt;br /&gt;
{&lt;br /&gt;
    QString format = &amp;quot;png&amp;quot;;&lt;br /&gt;
    QString initialPath = QDir::currentPath() + tr(&amp;quot;/untitled.&amp;quot;) + format;&lt;br /&gt;
    QString fileName = QFileDialog::getSaveFileName(this, tr(&amp;quot;Save As&amp;quot;),&lt;br /&gt;
                               initialPath,&lt;br /&gt;
                               tr(&amp;quot;%1 Files (*.%2);;All Files (*)&amp;quot;)&lt;br /&gt;
                               .arg(format.toUpper())&lt;br /&gt;
                               .arg(format));&lt;br /&gt;
    if (!fileName.isEmpty())&lt;br /&gt;
        originalPixmap.save(fileName, format.toAscii());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::shootScreen()&lt;br /&gt;
{&lt;br /&gt;
    if (delaySpinBox-&amp;gt;value() != 0)&lt;br /&gt;
        qApp-&amp;gt;beep();&lt;br /&gt;
    originalPixmap = QPixmap(); // clear image for low memory situations&lt;br /&gt;
                                // on embedded devices.&lt;br /&gt;
    originalPixmap = QPixmap::grabWindow(QApplication::desktop()-&amp;gt;winId());&lt;br /&gt;
    updateScreenshotLabel();&lt;br /&gt;
    newScreenshotButton-&amp;gt;setDisabled(false);&lt;br /&gt;
    if (hideThisWindowCheckBox-&amp;gt;isChecked())&lt;br /&gt;
        show();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::updateCheckBox()&lt;br /&gt;
{&lt;br /&gt;
    if (delaySpinBox-&amp;gt;value() == 0) {&lt;br /&gt;
        hideThisWindowCheckBox-&amp;gt;setDisabled(true);&lt;br /&gt;
        hideThisWindowCheckBox-&amp;gt;setChecked(false);&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
        hideThisWindowCheckBox-&amp;gt;setDisabled(false);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::createOptionsGroupBox()&lt;br /&gt;
{&lt;br /&gt;
    optionsGroupBox = new QGroupBox(tr(&amp;quot;Options&amp;quot;));&lt;br /&gt;
    delaySpinBox = new QSpinBox;&lt;br /&gt;
    delaySpinBox-&amp;gt;setSuffix(tr(&amp;quot; s&amp;quot;));&lt;br /&gt;
    delaySpinBox-&amp;gt;setMaximum(60);&lt;br /&gt;
    connect(delaySpinBox, SIGNAL(valueChanged(int)), this, SLOT(updateCheckBox()));&lt;br /&gt;
    delaySpinBoxLabel = new QLabel(tr(&amp;quot;Screenshot Delay:&amp;quot;));&lt;br /&gt;
    hideThisWindowCheckBox = new QCheckBox(tr(&amp;quot;Hide This Window&amp;quot;));&lt;br /&gt;
    optionsGroupBoxLayout = new QGridLayout;&lt;br /&gt;
    optionsGroupBoxLayout-&amp;gt;addWidget(delaySpinBoxLabel, 0, 0);&lt;br /&gt;
    optionsGroupBoxLayout-&amp;gt;addWidget(delaySpinBox, 0, 1);&lt;br /&gt;
    optionsGroupBoxLayout-&amp;gt;addWidget(hideThisWindowCheckBox, 1, 0, 1, 2);&lt;br /&gt;
    optionsGroupBox-&amp;gt;setLayout(optionsGroupBoxLayout);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::createButtonsLayout()&lt;br /&gt;
{&lt;br /&gt;
    newScreenshotButton = createButton(tr(&amp;quot;New Screenshot&amp;quot;),&lt;br /&gt;
                                       this, SLOT(newScreenshot()));&lt;br /&gt;
    saveScreenshotButton = createButton(tr(&amp;quot;Save Screenshot&amp;quot;),&lt;br /&gt;
                                        this, SLOT(saveScreenshot()));&lt;br /&gt;
    quitScreenshotButton = createButton(tr(&amp;quot;Quit&amp;quot;), this, SLOT(close()));&lt;br /&gt;
    buttonsLayout = new QHBoxLayout;&lt;br /&gt;
    buttonsLayout-&amp;gt;addStretch();&lt;br /&gt;
    buttonsLayout-&amp;gt;addWidget(newScreenshotButton);&lt;br /&gt;
    buttonsLayout-&amp;gt;addWidget(saveScreenshotButton);&lt;br /&gt;
    buttonsLayout-&amp;gt;addWidget(quitScreenshotButton);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
QPushButton *Screenshot::createButton(const QString &amp;amp;text, QWidget *receiver,&lt;br /&gt;
                                      const char *member)&lt;br /&gt;
{&lt;br /&gt;
    QPushButton *button = new QPushButton(text);&lt;br /&gt;
    button-&amp;gt;connect(button, SIGNAL(clicked()), receiver, member);&lt;br /&gt;
    return button;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void Screenshot::updateScreenshotLabel()&lt;br /&gt;
{&lt;br /&gt;
    screenshotLabel-&amp;gt;setPixmap(originalPixmap.scaled(screenshotLabel-&amp;gt;size(),&lt;br /&gt;
                                                     Qt::KeepAspectRatio,&lt;br /&gt;
                                                     Qt::SmoothTransformation));&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;QApplication&amp;gt;&lt;br /&gt;
#include &amp;quot;screenshot.h&amp;quot;&lt;br /&gt;
int main(int argc, char *argv[])&lt;br /&gt;
{&lt;br /&gt;
    QApplication app(argc, argv);&lt;br /&gt;
    Screenshot screenshot;&lt;br /&gt;
    screenshot.show();&lt;br /&gt;
    return app.exec();&lt;br /&gt;
}&lt;br /&gt;
   &lt;br /&gt;
    &lt;br /&gt;
  &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Set mask for QPixmap==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;  &lt;br /&gt;
/****************************************************************************&lt;br /&gt;
**&lt;br /&gt;
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).&lt;br /&gt;
** All rights reserved.&lt;br /&gt;
** Contact: Nokia Corporation (qt-info@nokia.com)&lt;br /&gt;
**&lt;br /&gt;
** This file is part of the documentation of the Qt Toolkit.&lt;br /&gt;
**&lt;br /&gt;
** $QT_BEGIN_LICENSE:LGPL$&lt;br /&gt;
** Commercial Usage&lt;br /&gt;
** Licensees holding valid Qt Commercial licenses may use this file in&lt;br /&gt;
** accordance with the Qt Commercial License Agreement provided with the&lt;br /&gt;
** Software or, alternatively, in accordance with the terms contained in&lt;br /&gt;
** a written agreement between you and Nokia.&lt;br /&gt;
**&lt;br /&gt;
** GNU Lesser General Public License Usage&lt;br /&gt;
** Alternatively, this file may be used under the terms of the GNU Lesser&lt;br /&gt;
** General Public License version 2.1 as published by the Free Software&lt;br /&gt;
** Foundation and appearing in the file LICENSE.LGPL included in the&lt;br /&gt;
** packaging of this file.  Please review the following information to&lt;br /&gt;
** ensure the GNU Lesser General Public License version 2.1 requirements&lt;br /&gt;
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.&lt;br /&gt;
**&lt;br /&gt;
** In addition, as a special exception, Nokia gives you certain additional&lt;br /&gt;
** rights.  These rights are described in the Nokia Qt LGPL Exception&lt;br /&gt;
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.&lt;br /&gt;
**&lt;br /&gt;
** GNU General Public License Usage&lt;br /&gt;
** Alternatively, this file may be used under the terms of the GNU&lt;br /&gt;
** General Public License version 3.0 as published by the Free Software&lt;br /&gt;
** Foundation and appearing in the file LICENSE.GPL included in the&lt;br /&gt;
** packaging of this file.  Please review the following information to&lt;br /&gt;
** ensure the GNU General Public License version 3.0 requirements will be&lt;br /&gt;
** met: http://www.gnu.org/copyleft/gpl.html.&lt;br /&gt;
**&lt;br /&gt;
** If you have questions regarding the use of this file, please contact&lt;br /&gt;
** Nokia at qt-info@nokia.com.&lt;br /&gt;
** $QT_END_LICENSE$&lt;br /&gt;
**&lt;br /&gt;
****************************************************************************/&lt;br /&gt;
#include &amp;lt;QtGui&amp;gt;&lt;br /&gt;
int main()&lt;br /&gt;
{&lt;br /&gt;
    int x, y;&lt;br /&gt;
    {&lt;br /&gt;
        QPixmap alpha(&amp;quot;image-with-alpha.png&amp;quot;);&lt;br /&gt;
        QPixmap alphacopy = alpha;&lt;br /&gt;
        alphacopy.setMask(alphacopy.mask());&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
   &lt;br /&gt;
    &lt;br /&gt;
  &amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	</feed>