KDE 4.7 PyKDE API Reference

- KDE's Python API

# KIconCanvas Class Reference

`from PyKDE4.kio import *`

Inherits: KListWidget → QListWidget → QListView → QAbstractItemView → QAbstractScrollArea → QFrame → QWidget → QObject

## Detailed Description

Icon canvas for KIconDialog.

## Signals
| finished ()
| nameChanged (QString a0)
| progress (int number)
| startLoading (int count)
## Methods
| __init__ (self, QWidget parent=0)
| __init__ (self, KIconCanvas a0)
QString | getCurrent (self)
| loadFiles (self, QStringList files)
| stopLoading (self)

## Signal Documentation

finished | ( |  | ) |

This signal is emitted when the loading of the icons has been finished.

Signal syntax:
  `QObject.connect(source, SIGNAL("finished()"), target_slot)`

nameChanged | ( | QString | a0
| ) |  |  |

Emitted when the current icon has changed.

Signal syntax:
  `QObject.connect(source, SIGNAL("nameChanged(const QString&)"), target_slot)`

progress | ( | int | number
| ) |  |  |

This signal is emitted whenever an icon has been loaded.

Parameters:

  | number | The number of the currently loaded item.

Signal syntax:
  `QObject.connect(source, SIGNAL("progress(int)"), target_slot)`

startLoading | ( | int | count
| ) |  |  |

This signal is emitted when the loading of the icons has started.

Parameters:

  | count | The number of icons to be loaded.

Signal syntax:
  `QObject.connect(source, SIGNAL("startLoading(int)"), target_slot)`

## Method Documentation

__init__ | ( | self, |
|  | QWidget | parent=0
| ) |  |  |

Creates a new icon canvas.

Parameters:

  | parent | The parent widget.

__init__ | ( | self, |
|  | KIconCanvas | a0
| ) |  |  |

QString getCurrent | ( |  | self ) |

Returns the current icon.

loadFiles | ( | self, |
|  | QStringList | files
| ) |  |  |

Load icons into the canvas.

stopLoading | ( |  | self ) |

Call this slot to stop the loading of the icons.