|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.kde.koala.KPixmapSplitter
public class KPixmapSplitter
If you have a pixmap containing several items (icons), you can use this class to get the coordinates of each item. For example, if you have a pixmap with 25 items and you want to get the 4th item as a pixmap (every item being 20x10 pixels):
KPixmapSplitter splitter; splitter.setPixmap( somePixmap ); splitter.setItemSize( QSize( 20, 10 )); QPixmap item( 20, 10 ); item.fill( Qt.white ); QRect rect = splitter.coordinates( 4 ); if ( !rect.isEmpty() ) bitBlt( &item, QPoint(0,0), &somePixmap, rect, CopyROP );
Constructor Summary | |
---|---|
|
KPixmapSplitter()
Constructor, does nothing but initialize some default-values. |
protected |
KPixmapSplitter(java.lang.Class dummy)
|
Method Summary | |
---|---|
org.kde.qt.QRect |
coordinates(char ch)
Overloaded for convenience. |
org.kde.qt.QRect |
coordinates(int pos)
|
void |
dispose()
Delete the wrapped C++ instance ahead of finalize() |
protected void |
finalize()
Deletes the wrapped C++ instance |
boolean |
isDisposed()
Has the wrapped C++ instance been deleted? |
org.kde.qt.QSize |
itemSize()
|
org.kde.qt.QPixmap |
pixmap()
|
void |
setHSpacing(int spacing)
If there is space between columns in the given pixmap, you have to specify how many pixels there are. |
void |
setItemSize(org.kde.qt.QSize size)
Sets the size of the items you want to get out of the given pixmap. |
void |
setPixmap(org.kde.qt.QPixmap pixmap)
Sets the pixmap to be split. |
void |
setVSpacing(int spacing)
If there is space between rows in the given pixmap, you have to specify how many pixels there are. |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected KPixmapSplitter(java.lang.Class dummy)
public KPixmapSplitter()
Method Detail |
---|
public void setPixmap(org.kde.qt.QPixmap pixmap)
public org.kde.qt.QPixmap pixmap()
public void setItemSize(org.kde.qt.QSize size)
size.
public org.kde.qt.QSize itemSize()
public void setVSpacing(int spacing)
public void setHSpacing(int spacing)
public org.kde.qt.QRect coordinates(int pos)
public org.kde.qt.QRect coordinates(char ch)
protected void finalize() throws java.lang.InternalError
finalize
in class java.lang.Object
java.lang.InternalError
public void dispose()
public boolean isDisposed()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |