Loading...
Searching...
No Matches

Detailed Description

Classes

class  CustomStyleFlatPushButton
 
class  CustomStyleFlatToolButton
 
class  CustomFusionStyle
 

Functions

void pixmapForBWMaskIcon (const QString &url, QPixmap *pixmapOut, BNThemeColor color=SidebarActiveIconColor, const QString &cacheSuffix="")
 
void initThemes ()
 
void resetUserThemes ()
 
void refreshUserThemes ()
 
std::vector< QString > getAvailableThemes ()
 
QString getActiveTheme ()
 
void setActiveTheme (const QString &name, bool saveToSettings=true)
 
bool isActiveThemeDark ()
 
bool isColorBlindMode ()
 
void setColorBlindMode (bool active)
 
void addJsonTheme (const char *json)
 
QColor getThemeColor (BNThemeColor color)
 
QColor getTokenColor (QWidget *widget, BNInstructionTextTokenType token)
 
QColor getTypeClassColor (const QWidget *widget, BNTypeClass typeClass)
 
std::optional< QColor > getSymbolColor (SymbolRef symbol)
 
std::optional< QColor > getSymbolColor (BNSymbolType type, BNSymbolBinding binding)
 
QColor avgColor (QColor a, QColor b)
 
QColor mixColor (QColor a, QColor b, uint8_t mix)
 
QColor getThemeHighlightColor (BNHighlightStandardColor color)
 

Class Documentation

◆ CustomStyleFlatPushButton

class CustomStyleFlatPushButton

Public Member Functions

 CustomStyleFlatPushButton (QWidget *parent=nullptr)
 

Constructor & Destructor Documentation

◆ CustomStyleFlatPushButton()

CustomStyleFlatPushButton::CustomStyleFlatPushButton ( QWidget * parent = nullptr)
inline

◆ CustomStyleFlatToolButton

class CustomStyleFlatToolButton

Public Member Functions

 CustomStyleFlatToolButton (QWidget *parent=nullptr)
 

Constructor & Destructor Documentation

◆ CustomStyleFlatToolButton()

CustomStyleFlatToolButton::CustomStyleFlatToolButton ( QWidget * parent = nullptr)
inline

◆ CustomFusionStyle

class CustomFusionStyle

Public Member Functions

 CustomFusionStyle (QStyle *parent)
 
virtual int pixelMetric (PixelMetric metric, const QStyleOption *option, const QWidget *widget) const override
 
virtual QIcon standardIcon (StandardPixmap standardIcon, const QStyleOption *option, const QWidget *widget) const override
 
virtual QPixmap standardPixmap (StandardPixmap standardPixmap, const QStyleOption *option, const QWidget *widget) const override
 
virtual QRect subElementRect (QStyle::SubElement element, const QStyleOption *option, const QWidget *widget) const override
 
virtual void drawPrimitive (PrimitiveElement element, const QStyleOption *option, QPainter *painter, const QWidget *widget) const override
 
virtual int styleHint (QStyle::StyleHint hint, const QStyleOption *option=nullptr, const QWidget *widget=nullptr, QStyleHintReturn *returnData=nullptr) const override
 

Constructor & Destructor Documentation

◆ CustomFusionStyle()

CustomFusionStyle::CustomFusionStyle ( QStyle * parent)

Member Function Documentation

◆ pixelMetric()

virtual int CustomFusionStyle::pixelMetric ( PixelMetric metric,
const QStyleOption * option,
const QWidget * widget ) const
overridevirtual

◆ standardIcon()

virtual QIcon CustomFusionStyle::standardIcon ( StandardPixmap standardIcon,
const QStyleOption * option,
const QWidget * widget ) const
overridevirtual

◆ standardPixmap()

virtual QPixmap CustomFusionStyle::standardPixmap ( StandardPixmap standardPixmap,
const QStyleOption * option,
const QWidget * widget ) const
overridevirtual

◆ subElementRect()

virtual QRect CustomFusionStyle::subElementRect ( QStyle::SubElement element,
const QStyleOption * option,
const QWidget * widget ) const
overridevirtual

◆ drawPrimitive()

virtual void CustomFusionStyle::drawPrimitive ( PrimitiveElement element,
const QStyleOption * option,
QPainter * painter,
const QWidget * widget ) const
overridevirtual

◆ styleHint()

virtual int CustomFusionStyle::styleHint ( QStyle::StyleHint hint,
const QStyleOption * option = nullptr,
const QWidget * widget = nullptr,
QStyleHintReturn * returnData = nullptr ) const
overridevirtual

Function Documentation

◆ pixmapForBWMaskIcon()

void pixmapForBWMaskIcon ( const QString & url,
QPixmap * pixmapOut,
BNThemeColor color = SidebarActiveIconColor,
const QString & cacheSuffix = "" )

◆ initThemes()

void initThemes ( )

◆ resetUserThemes()

void resetUserThemes ( )

◆ refreshUserThemes()

void refreshUserThemes ( )

◆ getAvailableThemes()

std::vector< QString > getAvailableThemes ( )

◆ getActiveTheme()

QString getActiveTheme ( )

◆ setActiveTheme()

void setActiveTheme ( const QString & name,
bool saveToSettings = true )

◆ isActiveThemeDark()

bool isActiveThemeDark ( )

◆ isColorBlindMode()

bool isColorBlindMode ( )

◆ setColorBlindMode()

void setColorBlindMode ( bool active)

◆ addJsonTheme()

void addJsonTheme ( const char * json)
Warning
If registering themes from a plugin, you will also need to manually swap to them
Parameters
json

◆ getThemeColor()

QColor getThemeColor ( BNThemeColor color)

◆ getTokenColor()

QColor getTokenColor ( QWidget * widget,
BNInstructionTextTokenType token )

◆ getTypeClassColor()

QColor getTypeClassColor ( const QWidget * widget,
BNTypeClass typeClass )

◆ getSymbolColor() [1/2]

std::optional< QColor > getSymbolColor ( SymbolRef symbol)

◆ getSymbolColor() [2/2]

std::optional< QColor > getSymbolColor ( BNSymbolType type,
BNSymbolBinding binding )

◆ avgColor()

QColor avgColor ( QColor a,
QColor b )

◆ mixColor()

QColor mixColor ( QColor a,
QColor b,
uint8_t mix )

◆ getThemeHighlightColor()

QColor getThemeHighlightColor ( BNHighlightStandardColor color)