hydrogen 1.2.6
ShotList Class Reference

Shot List. More...

#include <ShotList.h>

Inheritance diagram for ShotList:
EventListener

Data Structures

class  Arg
 Buffer for construction of Q_ARGs. More...
 

Public Slots

void nextShot (void)
 

Public Member Functions

 ShotList (QString sShotsFilename)
 
 ShotList (QStringList shots)
 
 ~ShotList ()
 
void nextShotEvent () override
 
void shoot ()
 
- Public Member Functions inherited from EventListener
virtual ~EventListener ()
 
virtual void actionModeChangeEvent (int nValue)
 
virtual void bbtChangedEvent ()
 
virtual void driverChangedEvent ()
 
virtual void drumkitLoadedEvent ()
 
virtual void errorEvent (int nErrorCode)
 
virtual void gridCellToggledEvent ()
 
virtual void instrumentParametersChangedEvent (int nInstrumentNumber)
 
virtual void jacksessionEvent (int nValue)
 
virtual void jackTimebaseStateChangedEvent (int nValue)
 
virtual void jackTransportActivationEvent ()
 
virtual void loopModeActivationEvent ()
 
virtual void metronomeEvent (int nValue)
 
virtual void midiActivityEvent ()
 
virtual void midiMapChangedEvent ()
 
virtual void nextPatternsChangedEvent ()
 
virtual void noteOnEvent (int nInstrument)
 
virtual void patternEditorLockedEvent ()
 
virtual void patternModifiedEvent ()
 
virtual void playbackTrackChangedEvent ()
 
virtual void playingPatternsChangedEvent ()
 
virtual void playlistLoadSongEvent (int nIndex)
 
virtual void progressEvent (int nValue)
 
virtual void quitEvent (int nValue)
 
virtual void relocationEvent ()
 
virtual void selectedInstrumentChangedEvent ()
 
virtual void selectedPatternChangedEvent ()
 
virtual void songModeActivationEvent ()
 
virtual void songModifiedEvent ()
 
virtual void songSizeChangedEvent ()
 
virtual void soundLibraryChangedEvent ()
 
virtual void stackedModeActivationEvent (int nValue)
 
virtual void stateChangedEvent (H2Core::AudioEngine::State state)
 
virtual void tempoChangedEvent (int nValue)
 
virtual void timelineActivationEvent ()
 
virtual void timelineUpdateEvent (int nValue)
 
virtual void undoRedoActionEvent (int nValue)
 
virtual void updatePreferencesEvent (int nValue)
 
virtual void updateSongEvent (int nValue)
 
virtual void XRunEvent ()
 

Private Member Functions

void shoot (QString s)
 

Static Private Member Functions

static QWidget * findWidget (QString &sName)
 Find a widget by name.
 
static QWidget * findWidgetInheriting (QObject *pObject, const QString &sName)
 Find a widget which inherits the named class.
 

Private Attributes

int m_nNextShot
 
QStringList m_shots
 

Detailed Description

Shot List.

Utility for grabbing screenshots of widgets. Not a script, just a shot list.

Commands are word-oriented

  • grab <WidgetName|WidgetClass> – grab widget named "WidgetName" or of any class inheriting from "WidgetClass"
    • [ size <w> <h> ] – size of area to grab. 0 or (-)ve mean widget's entire width or height
    • [ ofset <x> <y> ] – offset from the widget's origin for beginning of grab
    • [ as <filename> ] – filename to save as, including file type extension
  • slot <widget> <slot> [<arg>...] – invoke a slot method on widget.
  • dump – dump object tree(s)
  • # <text> – commentary (note that the space is needed!)
  • fin – quit Hydrogen

By naming widgets appropriately and exposing their functionality as slots, it should be possible for the application to allow a lot of flexibility in how screenshots are set up in shot lists.

Definition at line 53 of file ShotList.h.

Constructor & Destructor Documentation

◆ ShotList() [1/2]

ShotList ( QStringList shots)

Definition at line 48 of file ShotList.cpp.

◆ ShotList() [2/2]

ShotList ( QString sShotsFilename)

Definition at line 33 of file ShotList.cpp.

◆ ~ShotList()

~ShotList ( )

Definition at line 54 of file ShotList.cpp.

Member Function Documentation

◆ findWidget()

QWidget * findWidget ( QString & sName)
staticprivate

Find a widget by name.

Definition at line 74 of file ShotList.cpp.

◆ findWidgetInheriting()

QWidget * findWidgetInheriting ( QObject * pObject,
const QString & sName )
staticprivate

Find a widget which inherits the named class.

Definition at line 60 of file ShotList.cpp.

◆ nextShot

void nextShot ( void )
slot

Definition at line 247 of file ShotList.cpp.

◆ nextShotEvent()

void nextShotEvent ( )
overridevirtual

Reimplemented from EventListener.

Definition at line 243 of file ShotList.cpp.

◆ shoot() [1/2]

void shoot ( )

Definition at line 236 of file ShotList.cpp.

◆ shoot() [2/2]

void shoot ( QString s)
private

Definition at line 91 of file ShotList.cpp.

Field Documentation

◆ m_nNextShot

int m_nNextShot
private

Definition at line 96 of file ShotList.h.

◆ m_shots

QStringList m_shots
private

Definition at line 95 of file ShotList.h.