Songbook-Client  0.7
This application is a manager of customguitar songbooks
 All Classes Files Functions Variables Enumerations Enumerator Pages
Public Slots | Signals | Public Member Functions | Protected Member Functions
CCoverDropArea Class Reference

CCoverDropArea displays the cover of a song. More...

#include <song-header-editor.hh>

List of all members.

Public Slots

void clear ()
void update ()

Signals

void changed (const QMimeData *mimeData=0)
void coverChanged ()
void miniCoverChanged (const QPixmap &thumbnail)

Public Member Functions

 CCoverDropArea (CSongHeaderEditor *parent)
 Constructor.
Songsong ()
const QImage & cover ()
void setCover (const QImage &cover)
void setCover (const QString &filename)
CSongHeaderEditorparent () const
void setParent (CSongHeaderEditor *p)

Protected Member Functions

void dragEnterEvent (QDragEnterEvent *event)
void dragMoveEvent (QDragMoveEvent *event)
void dragLeaveEvent (QDragLeaveEvent *event)
void dropEvent (QDropEvent *event)
virtual void mousePressEvent (QMouseEvent *event)
virtual void mouseReleaseEvent (QMouseEvent *event)
virtual void contextMenuEvent (QContextMenuEvent *event)

Detailed Description

CCoverDropArea displays the cover of a song.

The cover area displays the cover of a song within a raised box. If there is no cover to display, it displays a generic image-missing icon. Clicking on the area prompts a file picker dialog where an external .jpg cover can be selected. The cover area also accepts drops from local .jpg files.

cover-drop-area.png
cover-drop-area2.png

Member Function Documentation

void CCoverDropArea::changed ( const QMimeData *  mimeData = 0)
signal

This signal is emitted whenever new data is dragged within the cover area.

See also:
coverChanged, miniCoverChanged
void CCoverDropArea::clear ( )
slot

Resets the background of the cover area.

const QImage & CCoverDropArea::cover ( )

Returns the cover of the song.

See also:
setCover
void CCoverDropArea::coverChanged ( )
signal

This signal is emitted whenever a new cover image is displayed.

See also:
coverChanged, miniCoverChanged
void CCoverDropArea::miniCoverChanged ( const QPixmap &  thumbnail)
signal

This signal is emitted whenever a new cover image is displayed.

See also:
coverChanged, miniCoverChanged
CSongHeaderEditor * CCoverDropArea::parent ( ) const

Returns the parent widget.

See also:
setParent
void CCoverDropArea::setCover ( const QImage &  cover)

Sets cover as the cover of the song.

See also:
cover
void CCoverDropArea::setCover ( const QString &  filename)

Sets the file at (absolute) path filename as the cover of the song. A .jpg file is expected.

See also:
cover
void CCoverDropArea::setParent ( CSongHeaderEditor p)

Sets p as the parent object.

See also:
parent
Song & CCoverDropArea::song ( )

Returns the Song object associated with this cover.

void CCoverDropArea::update ( )
slot

Updates the cover-related fields of the song according to current image.


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