Fix coding style
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@1975 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
@@ -56,20 +56,20 @@ public:
|
||||
const QStyleOption * option = 0,
|
||||
const QWidget * widget = 0 ) const;
|
||||
|
||||
// LMMS Stuff
|
||||
// LMMS Stuff
|
||||
|
||||
virtual void drawFxLine(QPainter * _painter, const QWidget *_fxLine,
|
||||
const QString & _name, bool _active);
|
||||
virtual void drawFxLine(QPainter * _painter, const QWidget *_fxLine,
|
||||
const QString & _name, bool _active);
|
||||
|
||||
virtual void drawTrackContentBackground(QPainter * _painter,
|
||||
const QSize & _size, const int _pixelsPerTact);
|
||||
virtual void drawTrackContentBackground(QPainter * _painter,
|
||||
const QSize & _size, const int _pixelsPerTact);
|
||||
|
||||
virtual QColor color(LmmsStyle::ColorRole _role) const;
|
||||
virtual QColor color(LmmsStyle::ColorRole _role) const;
|
||||
|
||||
private:
|
||||
QImage colorizeXpm( const char * const * xpm, const QBrush & fill ) const;
|
||||
private:
|
||||
QImage colorizeXpm( const char * const * xpm, const QBrush & fill ) const;
|
||||
|
||||
QColor colors[LmmsStyle::NumColorRoles];
|
||||
QColor colors[LmmsStyle::NumColorRoles];
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -165,13 +165,15 @@ public:
|
||||
return( s_pluginFileHandling );
|
||||
}
|
||||
|
||||
static void setLmmsStyle( LmmsStyle * _style ) {
|
||||
s_lmmsStyle = _style;
|
||||
}
|
||||
static void setLmmsStyle( LmmsStyle * _style )
|
||||
{
|
||||
s_lmmsStyle = _style;
|
||||
}
|
||||
|
||||
static LmmsStyle * getLmmsStyle( void ) {
|
||||
return s_lmmsStyle;
|
||||
}
|
||||
static LmmsStyle * getLmmsStyle( void )
|
||||
{
|
||||
return s_lmmsStyle;
|
||||
}
|
||||
|
||||
private:
|
||||
static bool s_hasGUI;
|
||||
|
||||
@@ -35,87 +35,58 @@
|
||||
class LmmsStyle
|
||||
{
|
||||
public:
|
||||
enum ColorRole
|
||||
{
|
||||
AutomationBarFill,
|
||||
AutomationBarValue,
|
||||
AutomationSelectedBarFill,
|
||||
AutomationCrosshair,
|
||||
PianoRollStepNote,
|
||||
PianoRollSelectedNote,
|
||||
PianoRollDefaultNote,
|
||||
PianoRollEditHandle,
|
||||
PianoRollVolumeLevel,
|
||||
PianoRollPanningLevel,
|
||||
PianoRollSelectedLevel,
|
||||
TimelineForecolor,
|
||||
StandardGraphLine,
|
||||
StandardGraphHandle,
|
||||
StandardGraphHandleBorder,
|
||||
StandardGraphCrosshair,
|
||||
TextFloatForecolor,
|
||||
TextFloatFill,
|
||||
VisualizationLevelLow,
|
||||
VisualizationLevelMid,
|
||||
VisualizationLevelPeak,
|
||||
NumColorRoles
|
||||
};
|
||||
enum ColorRole
|
||||
{
|
||||
AutomationBarFill,
|
||||
AutomationBarValue,
|
||||
AutomationSelectedBarFill,
|
||||
AutomationCrosshair,
|
||||
PianoRollStepNote,
|
||||
PianoRollSelectedNote,
|
||||
PianoRollDefaultNote,
|
||||
PianoRollEditHandle,
|
||||
PianoRollVolumeLevel,
|
||||
PianoRollPanningLevel,
|
||||
PianoRollSelectedLevel,
|
||||
TimelineForecolor,
|
||||
StandardGraphLine,
|
||||
StandardGraphHandle,
|
||||
StandardGraphHandleBorder,
|
||||
StandardGraphCrosshair,
|
||||
TextFloatForecolor,
|
||||
TextFloatFill,
|
||||
VisualizationLevelLow,
|
||||
VisualizationLevelMid,
|
||||
VisualizationLevelPeak,
|
||||
NumColorRoles
|
||||
};
|
||||
|
||||
/* TODO: Still need to style:
|
||||
* combobox.cpp
|
||||
* fade_button.cpp
|
||||
* knob.cpp - Will be reimplemented to use image-strips
|
||||
* tab_widget.cpp
|
||||
* tool_button.cpp - Will be obsoleted in favor of real Qt toolbars
|
||||
*/
|
||||
/* TODO: Still need to style:
|
||||
* combobox.cpp
|
||||
* fade_button.cpp
|
||||
* knob.cpp - Will be reimplemented to use image-strips
|
||||
* tab_widget.cpp
|
||||
* tool_button.cpp - Will be obsoleted in favor of real Qt toolbars
|
||||
*/
|
||||
|
||||
|
||||
LmmsStyle()
|
||||
{
|
||||
}
|
||||
{
|
||||
}
|
||||
|
||||
virtual ~LmmsStyle()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
virtual void drawFxLine(QPainter * _painter, const QWidget *_fxLine,
|
||||
const QString & _name, bool _active) = 0;
|
||||
virtual void drawFxLine(QPainter * _painter, const QWidget *_fxLine,
|
||||
const QString & _name, bool _active) = 0;
|
||||
|
||||
virtual void drawTrackContentBackground(QPainter * _painter,
|
||||
const QSize & _size, const int _pixelsPerTact) = 0;
|
||||
virtual void drawTrackContentBackground(QPainter * _painter,
|
||||
const QSize & _size, const int _pixelsPerTact) = 0;
|
||||
|
||||
virtual QColor color(ColorRole _role) const = 0;
|
||||
virtual QColor color(ColorRole _role) const = 0;
|
||||
|
||||
/*
|
||||
virtual QPalette standardPalette( void ) const;
|
||||
|
||||
virtual void drawComplexControl(
|
||||
ComplexControl control,
|
||||
const QStyleOptionComplex * option,
|
||||
QPainter *painter,
|
||||
const QWidget *widget ) const;
|
||||
virtual void drawPrimitive( PrimitiveElement element,
|
||||
const QStyleOption *option,
|
||||
QPainter *painter,
|
||||
const QWidget *widget = 0 ) const;
|
||||
|
||||
virtual void drawControl( ControlElement element, const QStyleOption * option,
|
||||
QPainter * painter, const QWidget * widget ) const;
|
||||
|
||||
virtual int pixelMetric( PixelMetric metric,
|
||||
const QStyleOption * option = 0,
|
||||
const QWidget * widget = 0 ) const;
|
||||
|
||||
QSize sizeFromContents(ContentsType type, const QStyleOption *option,
|
||||
const QSize &size, const QWidget *widget) const;
|
||||
QRect subControlRect(ComplexControl control, const QStyleOptionComplex *option,
|
||||
SubControl subControl, const QWidget *widget) const;
|
||||
|
||||
|
||||
private:
|
||||
QImage colorizeXpm( const char * const * xpm, const QBrush & fill ) const;
|
||||
*/
|
||||
} ;
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user