drumstick 2.9.0
C++ MIDI libraries using Qt objects, idioms, and style.
drumstick::widgets Namespace Reference

Drumstick Widgets library MIDI related widgets and functions. More...

Classes

class  PianoHandler
 The PianoHandler class callbacks. More...
 
class  PianoKeybd
 The PianoKeybd class. More...
 
class  PianoPalette
 The PianoPalette class. More...
 
class  PianoScene
 The PianoScene class is a QGraphicsScene composed by a number of graphics items: the piano keys. More...
 
class  RawKbdHandler
 The RawKbdHandler class callbacks. More...
 
class  SettingsFactory
 The SettingsFactory class holds a global QSettings object. More...
 

Typedefs

typedef QHash< int, int > KeyboardMap
 KeyboardMap. More...
 

Enumerations

enum  LabelVisibility { ShowNever , ShowMinimum , ShowActivated , ShowAlways }
 Labels Visibility. More...
 
enum  LabelAlteration { ShowSharps , ShowFlats , ShowNothing }
 Labels for Alterations. More...
 
enum  LabelOrientation { HorizontalOrientation , VerticalOrientation , AutomaticOrientation }
 Labels Orientation. More...
 
enum  LabelNaming { StandardNames , CustomNamesWithSharps , CustomNamesWithFlats }
 Labels Naming. More...
 
enum  LabelCentralOctave { OctaveNothing = -1 , OctaveC3 , OctaveC4 , OctaveC5 }
 Labels Central Octave. More...
 
enum  PalettePolicy {
  PAL_SINGLE = 0 , PAL_DOUBLE = 1 , PAL_CHANNELS = 2 , PAL_SCALE = 3 ,
  PAL_KEYS = 4 , PAL_FONT = 5 , PAL_HISCALE = 6
}
 The PalettePolicy enumeration. More...
 

Functions

bool DRUMSTICK_WIDGETS_EXPORT inputDriverIsConfigurable (const QString driver)
 inputDriverIsConfigurable More...
 
bool DRUMSTICK_WIDGETS_EXPORT outputDriverIsConfigurable (const QString driver)
 outputDriverIsConfigurable More...
 
bool DRUMSTICK_WIDGETS_EXPORT configureInputDriver (const QString driver, QWidget *parent)
 Input Driver configuration dialog Some RT input drivers can be configured. More...
 
bool DRUMSTICK_WIDGETS_EXPORT configureOutputDriver (const QString driver, QWidget *parent)
 Output Driver configuration dialog Some RT output drivers can be configured. More...
 
void DRUMSTICK_WIDGETS_EXPORT changeSoundFont (const QString driver, const QString fileName, QWidget *parent)
 Changes the sound font configuration Some RT output drivers accept soundfonts. More...
 
QString DRUMSTICK_WIDGETS_EXPORT libraryVersion ()
 libraryVersion returns the runtime library version as a QString More...
 
QDataStream & operator<< (QDataStream &stream, const PianoPalette &palette)
 Serialize a PianoPalette instance into a QDataStream. More...
 
QDataStream & operator>> (QDataStream &stream, PianoPalette &palette)
 Deserialize a PianoPalette instance from a QDataStream. More...
 

Variables

DRUMSTICK_WIDGETS_EXPORT KeyboardMap g_DefaultKeyMap
 Global Key Map Variable. More...
 
DRUMSTICK_WIDGETS_EXPORT KeyboardMap g_DefaultRawKeyMap
 Global Raw Key Map Variable. More...
 
const int DEFAULTSTARTINGKEY = 9
 Default starting key (A)
 
const int DEFAULTBASEOCTAVE = 1
 Default base octave.
 
const int DEFAULTNUMBEROFKEYS = 88
 Default number of piano keys.
 

Detailed Description

Drumstick Widgets library MIDI related widgets and functions.

Function Documentation

◆ changeSoundFont()

void changeSoundFont ( const QString  driver,
const QString  fileName,
QWidget *  parent 
)

Changes the sound font configuration Some RT output drivers accept soundfonts.

This function allows to change the soundfont file for a driver and store the setting. The FluidSynth and macOS DLS Synth drivers are currently supported.

Parameters
drivername of the driver
fileNamename of the soundfont file
parentoptional parent widget
Returns
true if configuration has changed

Definition at line 217 of file configurationdialogs.cpp.

◆ configureInputDriver()

bool configureInputDriver ( const QString  driver,
QWidget *  parent 
)

Input Driver configuration dialog Some RT input drivers can be configured.

This function provides a dialog box to show and edit the configurable parameters, and save the settings. Curremtly, only the Network driver is configurable.

Parameters
drivername of the driver
parentoptional parent widget
Returns
true if configuration has changed

Definition at line 123 of file configurationdialogs.cpp.

References BackendManager::inputBackendByName().

◆ configureOutputDriver()

bool configureOutputDriver ( const QString  driver,
QWidget *  parent 
)

Output Driver configuration dialog Some RT output drivers can be configured.

This function provides a dialog box to show and edit the configurable parameters, and save the settings. Curremtly the Network, FluidSynth, SonivoxEAS, and macOS DLS Synth drivers are configurable.

Parameters
drivername of the driver
parentoptional parent widget
Returns
true if configuration has changed

Definition at line 161 of file configurationdialogs.cpp.

References BackendManager::outputBackendByName().

◆ inputDriverIsConfigurable()

bool inputDriverIsConfigurable ( const QString  driver)

inputDriverIsConfigurable

Parameters
driverthe driver name
Returns
true if the input driver has a configuration dialog

Definition at line 53 of file configurationdialogs.cpp.

References BackendManager::inputBackendByName().

◆ libraryVersion()

QString libraryVersion ( )

libraryVersion returns the runtime library version as a QString

Returns
version string

Definition at line 243 of file configurationdialogs.cpp.

◆ operator<<()

QDataStream & operator<< ( QDataStream &  stream,
const PianoPalette palette 
)

Serialize a PianoPalette instance into a QDataStream.

Parameters
streama QDataStream
paletteinstance
Returns
the QDataStream

Definition at line 595 of file pianopalette.cpp.

◆ operator>>()

QDataStream & operator>> ( QDataStream &  stream,
PianoPalette palette 
)

Deserialize a PianoPalette instance from a QDataStream.

Parameters
streama QDataStream
paletteinstance
Returns
the QDataStream

Definition at line 611 of file pianopalette.cpp.

◆ outputDriverIsConfigurable()

bool outputDriverIsConfigurable ( const QString  driver)

outputDriverIsConfigurable

Parameters
driverthe driver name
Returns
true if the output driver has a configuration dialog

Definition at line 81 of file configurationdialogs.cpp.

References BackendManager::outputBackendByName().