# eric6.E5Gui.E5AnimatedLabel

Module implementing a label widget showing an animated pixmap.

### Global Attributes

None

### Classes

E5AnimatedLabel | Class implementing a label widget showing an animated pixmap.

### Functions

None

## E5AnimatedLabel

Class implementing a label widget showing an animated pixmap.

### Derived from

QLabel

### Class Attributes

None

### Class Methods

None

### Methods

E5AnimatedLabel | Constructor
__animate | Private slot to animate the pixmap.
__loadAnimationFile | Private method to load an animation file.
getAnimationFile | Public method to get the name of the animation file.
getInterval | Public method to get the interval between the animated frames.
isActive | Public method to check, if the animation is active.
isAnimationFileLoaded | Public method to check, if the animation file was loaded.
reset | Public slot to reset the animation.
setAnimationFile | Public method to set the name of the animation file.
setInterval | Public method to set the interval between the animated frames.
setPixmap | Public slot to set the pixmap of the label.
start | Public slot to start the animation.
stop | Public slot to stop the animation.

### Static Methods

None

#### E5AnimatedLabel (Constructor)

E5AnimatedLabel(parent=None, *, animationFile="", interval=100)

Constructor

parent (QWidget)
  reference to the parent window
animationFile= (str)
  path to the file containing the animation data
interval= (int)
  interval in milliseconds between animation frames

#### E5AnimatedLabel.__animate

__animate()

Private slot to animate the pixmap.

#### E5AnimatedLabel.__loadAnimationFile

__loadAnimationFile(animationFile)

Private method to load an animation file.

animationFile (str)
  path to the file containing the animation data

#### E5AnimatedLabel.getAnimationFile

getAnimationFile()

Public method to get the name of the animation file.

Returns:
  path to the file containing the animation data

Return Type:
  str

#### E5AnimatedLabel.getInterval

getInterval()

Public method to get the interval between the animated frames.

Returns:
  interval in milliseconds between animation frames

Return Type:
  int

#### E5AnimatedLabel.isActive

isActive()

Public method to check, if the animation is active.

Returns:
  flag indicating an active animation

Return Type:
  bool

#### E5AnimatedLabel.isAnimationFileLoaded

isAnimationFileLoaded()

Public method to check, if the animation file was loaded.

Returns:
  flag indicating a successfully loaded animation file

Return Type:
  bool

#### E5AnimatedLabel.reset

reset()

Public slot to reset the animation.

#### E5AnimatedLabel.setAnimationFile

setAnimationFile(animationFile)

Public method to set the name of the animation file.

animationFile (str)
  path to the file containing the animation data

#### E5AnimatedLabel.setInterval

setInterval(interval)

Public method to set the interval between the animated frames.

interval (int)
  interval in milliseconds between animation frames

#### E5AnimatedLabel.setPixmap

setPixmap(pixmap)

Public slot to set the pixmap of the label.

Setting a standard pixmap will stop the animation and set the given pixmap without animating it. Thereafter the animation has to be restarted with the start() method.

pixmap (QPixmap)
  pixmap to be set

#### E5AnimatedLabel.start

start()

Public slot to start the animation.

#### E5AnimatedLabel.stop

stop()

Public slot to stop the animation.

Up