KABC::Picture Class Reference

List of all members.

Detailed Description

Definition at line 30 of file picture.h.


Public Member Functions

 Picture ()
 Picture (const QString &url)
 Picture (const QImage &data)
 ~Picture ()
bool operator== (const Picture &) const
bool operator!= (const Picture &) const
void setUrl (const QString &url)
void setData (const QImage &data)
void setType (const QString &type)
bool isIntern () const
QString url () const
QImage data () const
QString type () const
QString asString () const

Friends

KABC_EXPORT QDataStreamoperator<< (QDataStream &, const Picture &)
KABC_EXPORT QDataStreamoperator>> (QDataStream &, Picture &)

Constructor & Destructor Documentation

Picture::Picture (  ) 

Consturctor.

Creates an empty object.

Definition at line 25 of file picture.cpp.

Picture::Picture ( const QString url  ) 

Consturctor.

Parameters:
url A URL that describes the position of the picture file.

Definition at line 30 of file picture.cpp.

Picture::Picture ( const QImage data  ) 

Consturctor.

Parameters:
data The raw data of the picture.

Definition at line 35 of file picture.cpp.

Picture::~Picture (  ) 

Destructor.

Definition at line 40 of file picture.cpp.


Member Function Documentation

void Picture::setUrl ( const QString url  ) 

Sets a URL for the location of the picture file.

When using this function, isIntern() will return 'false' until you use setData().

Parameters:
url The location URL of the picture file.

Definition at line 64 of file picture.cpp.

void Picture::setData ( const QImage data  ) 

Sets the raw data of the picture.

When using this function, isIntern() will return 'true' until you use setUrl().

Parameters:
data The raw data of the picture.

Definition at line 70 of file picture.cpp.

void Picture::setType ( const QString type  ) 

Sets the type of the picture.

Definition at line 76 of file picture.cpp.

bool Picture::isIntern (  )  const

Returns whether the picture is described by a URL (extern) or by the raw data (intern).

When this method returns 'true' you can use data() to get the raw data. Otherwise you can request the URL of this picture by url() and load the raw data from that location.

Definition at line 81 of file picture.cpp.

QString Picture::url (  )  const

Returns the location URL of this picture.

Definition at line 86 of file picture.cpp.

QImage Picture::data (  )  const

Returns the raw data of this picture.

Definition at line 91 of file picture.cpp.

QString Picture::type (  )  const

Returns the type of this picture.

Definition at line 96 of file picture.cpp.

QString Picture::asString (  )  const

Returns string representation of the picture.

Definition at line 101 of file picture.cpp.


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys