Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Tous les espaces de nom  ·  Toutes les classes  ·  Classes principales  ·  Annotées  ·  Classes groupées  ·  Modules  ·  Fonctions  · 

Qt 3 Support Members for QPixmap

The following class members are part of the Qt 3 support layer. They are provided to help you port old code to Qt 4. We advise against using them in new code.

Public Types

Public Functions

  • QPixmap ( const QString & fileName, const char * format, ColorMode mode )
  • QPixmap ( const QImage & image )
  • bool convertFromImage ( const QImage & image, ColorMode mode )
  • bool convertFromImage ( const QImage & image, Qt::ImageConversionFlags flags = Qt::AutoColor )
  • QImage convertToImage () const
  • bool load ( const QString & fileName, const char * format, ColorMode mode )
  • bool loadFromData ( const uchar * buf, uint len, const char * format, ColorMode mode )
  • void resize ( int width, int height )
  • void resize ( const QSize & size )
  • bool selfMask () const
  • QPixmap xForm ( const QMatrix & matrix ) const
  • QPixmap & operator= ( const QImage & image )

Member Type Documentation

enum QPixmap::ColorMode

This enum type defines the color modes that exist for converting QImage objects to QPixmap. It is provided here for compatibility with earlier versions of Qt.

Use Qt::ImageConversionFlags instead.

ConstantValueDescription
QPixmap::Auto0Select Color or Mono on a case-by-case basis.
QPixmap::Color1Always create colored pixmaps.
QPixmap::Mono2Always create bitmaps.


Member Function Documentation

QPixmap::QPixmap ( const QString & fileName, const char * format, ColorMode mode )

Use the constructor that takes a Qt::ImageConversionFlag instead.

QPixmap::QPixmap ( const QImage & image )

Constructs a pixmap from the QImage image.

Use the static fromImage() function instead.

bool QPixmap::convertFromImage ( const QImage & image, ColorMode mode )

Use the static fromImage() function instead.

bool QPixmap::convertFromImage ( const QImage & image, Qt::ImageConversionFlags flags = Qt::AutoColor )

This is an overloaded member function, provided for convenience.

Use the static fromImage() function instead.

QImage QPixmap::convertToImage () const

Use the toImage() function instead.

bool QPixmap::load ( const QString & fileName, const char * format, ColorMode mode )

This is an overloaded member function, provided for convenience.

Use the load() function that takes a Qt::ImageConversionFlag instead.

bool QPixmap::loadFromData ( const uchar * buf, uint len, const char * format, ColorMode mode )

This is an overloaded member function, provided for convenience.

Use the loadFromData() function that takes a Qt::ImageConversionFlag instead.

void QPixmap::resize ( int width, int height )

Use the QPixmap constructor that takes two ints (width and height) instead.

For example, if you have code like

 pixmap.resize(10, 20);

you can rewrite it as

 pixmap = QPixmap(10, 20);

void QPixmap::resize ( const QSize & size )

This is an overloaded member function, provided for convenience.

Use the QPixmap constructor that takes a QSize (size) instead.

For example, if you have code like

 pixmap.resize(size);

you can rewrite it as

 pixmap = QPixmap(size);

bool QPixmap::selfMask () const

Returns whether the pixmap is its own mask or not.

This function is no longer relevant since the concept of self masking doesn't exists anymore.

QPixmap QPixmap::xForm ( const QMatrix & matrix ) const

Use transformed() instead.

QPixmap::operator QImage () const

Returns the pixmap as a QImage.

Use the toImage() function instead.

QPixmap & QPixmap::operator= ( const QImage & image )

This is an overloaded member function, provided for convenience.

Converts the given image to a pixmap that is assigned to this pixmap.

Use the static fromImage() function instead.

Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. Qt 4.3
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD.
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP !
 
 
 
 
Partenaires

Hébergement Web