- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Directories
- Examples

- Class List
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Friends

# QBrush Class Reference

Search for all occurrences

## Detailed Description

Definition at line 76 of file qbrush.h.

`#include <qbrush.h>`

List of all members.

## Public Types
typedef QScopedPointer < QBrushData, QBrushDataPointerDeleter > | DataPtr
## Public Member Functions
| QBrush ()
| QBrush (Qt::BrushStyle bs)
| QBrush (const QColor &color, Qt::BrushStyle bs=Qt::SolidPattern)
| QBrush (Qt::GlobalColor color, Qt::BrushStyle bs=Qt::SolidPattern)
| QBrush (const QColor &color, const QPixmap &pixmap)
| QBrush (Qt::GlobalColor color, const QPixmap &pixmap)
| QBrush (const QPixmap &pixmap)
| QBrush (const QImage &image)
| QBrush (const QBrush &brush)
| QBrush (const QGradient &gradient)
| ~QBrush ()
QBrush & | operator= (const QBrush &brush)
| operator QVariant () const
Qt::BrushStyle | style () const
void | setStyle (Qt::BrushStyle)
const QMatrix & | matrix () const
void | setMatrix (const QMatrix &mat)
QTransform | transform () const
void | setTransform (const QTransform &)
QPixmap | texture () const
void | setTexture (const QPixmap &pixmap)
QImage | textureImage () const
void | setTextureImage (const QImage &image)
const QColor & | color () const
void | setColor (const QColor &color)
void | setColor (Qt::GlobalColor color)
const QGradient * | gradient () const
bool | isOpaque () const
bool | operator== (const QBrush &b) const
bool | operator!= (const QBrush &b) const
bool | isDetached () const
DataPtr & | data_ptr ()
## Friends
class | QRasterPaintEngine
class | QRasterPaintEnginePrivate
struct | QSpanData
class | QPainter
bool Q_GUI_EXPORT | qHasPixmapTexture (const QBrush &brush)

## Member Typedef Documentation

typedef QScopedPointer<QBrushData, QBrushDataPointerDeleter> DataPtr

Search for all occurrences

Definition at line 145 of file qbrush.h.

## Constructor & Destructor Documentation

QBrush | ( |  | ) |

QBrush | ( | Qt::BrushStyle | bs | ) |

QBrush | ( | const QColor & | color,
|  | Qt::BrushStyle | bs = `Qt::SolidPattern`
| ) |  |

QBrush | ( | Qt::GlobalColor | color,
|  | Qt::BrushStyle | bs = `Qt::SolidPattern`
| ) |  |

QBrush | ( | const QColor & | color,
|  | const QPixmap & | pixmap
| ) |  |

QBrush | ( | Qt::GlobalColor | color,
|  | const QPixmap & | pixmap
| ) |  |

QBrush | ( | const QPixmap & | pixmap | ) |

QBrush | ( | const QImage & | image | ) |

QBrush | ( | const QBrush & | brush | ) |

QBrush | ( | const QGradient & | gradient | ) |

~QBrush | ( |  | ) |

## Member Function Documentation

QBrush& operator= | ( | const QBrush & | brush | ) |

operator QVariant | ( |  | ) | const

Qt::BrushStyle style | ( |  | ) | const `[inline]`

Search for all occurrences

Definition at line 176 of file qbrush.h.

    { return d->style; }

void setStyle | ( | Qt::BrushStyle |  | ) |

Search for all occurrences

const QMatrix & matrix | ( |  | ) | const `[inline]`

Search for all occurrences

Definition at line 178 of file qbrush.h.

    { return d->transform.toAffine(); }

void setMatrix | ( | const QMatrix & | mat | ) |

Search for all occurrences

QTransform transform | ( |  | ) | const `[inline]`

Search for all occurrences

Definition at line 179 of file qbrush.h.

    { return d->transform; }

void setTransform | ( | const QTransform & |  | ) |

Search for all occurrences

QPixmap texture | ( |  | ) | const

Search for all occurrences

void setTexture | ( | const QPixmap & | pixmap | ) |

Search for all occurrences

QImage textureImage | ( |  | ) | const

Search for all occurrences

void setTextureImage | ( | const QImage & | image | ) |

Search for all occurrences

const QColor & color | ( |  | ) | const `[inline]`

Search for all occurrences

Definition at line 177 of file qbrush.h.

    { return d->color; }

void setColor | ( | const QColor & | color | ) |

Search for all occurrences

void setColor | ( | Qt::GlobalColor | color | ) | `[inline]`

Search for all occurrences

Definition at line 149 of file qbrush.h.

    { setColor(QColor(acolor)); }

const QGradient* gradient | ( |  | ) | const

Search for all occurrences

bool isOpaque | ( |  | ) | const

Search for all occurrences

bool operator== | ( | const QBrush & | b | ) | const

bool operator!= | ( | const QBrush & | b | ) | const `[inline]`

Definition at line 121 of file qbrush.h.

    { return !(operator==(b)); }

bool isDetached | ( |  | ) | const `[inline]`

Search for all occurrences

Definition at line 180 of file qbrush.h.

    { return d->ref == 1; }

DataPtr& data_ptr | ( |  | ) | `[inline]`

Search for all occurrences

Definition at line 146 of file qbrush.h.

    { return d; }

## Friends And Related Function Documentation

friend class QRasterPaintEngine `[friend]`

Search for all occurrences

Definition at line 133 of file qbrush.h.

friend class QRasterPaintEnginePrivate `[friend]`

Search for all occurrences

Definition at line 134 of file qbrush.h.

friend struct QSpanData `[friend]`

Search for all occurrences

Definition at line 135 of file qbrush.h.

friend class QPainter `[friend]`

Search for all occurrences

Definition at line 136 of file qbrush.h.

bool Q_GUI_EXPORT qHasPixmapTexture | ( | const QBrush & | brush | ) | `[friend]`

Search for all occurrences

The documentation for this class was generated from the following file:

- QtGui/qbrush.h

QBrush QBrush QBrush QBrush QBrush QBrush QBrush QBrush QBrush QBrush
QBrush QBrush QBrush QBrush QBrush QBrush QBrush QBrush QBrush QBrush