Button::LookAndFeelMethods Struct Referenceabstract
juce_gui_basics » buttons

This abstract base class is implemented by LookAndFeel classes to provide button-drawing functionality. More...

Inheritance diagram for Button::LookAndFeelMethods:

## Public Member Functions

virtual | ~LookAndFeelMethods ()=default
virtual void | drawButtonBackground (Graphics &, Button &, const Colour &backgroundColour, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown)=0
virtual Font | getTextButtonFont (TextButton &, int buttonHeight)=0
virtual int | getTextButtonWidthToFitText (TextButton &, int buttonHeight)=0
virtual void | drawButtonText (Graphics &, TextButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown)=0
| Draws the text for a TextButton. More...
virtual void | drawToggleButton (Graphics &, ToggleButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown)=0
| Draws the contents of a standard ToggleButton. More...
virtual void | changeToggleButtonWidthToFitText (ToggleButton &)=0
virtual void | drawTickBox (Graphics &, Component &, float x, float y, float w, float h, bool ticked, bool isEnabled, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown)=0
virtual void | drawDrawableButton (Graphics &, DrawableButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown)=0

## Detailed Description

This abstract base class is implemented by LookAndFeel classes to provide button-drawing functionality.

## Constructor & Destructor Documentation

## ~LookAndFeelMethods()

virtual Button::LookAndFeelMethods::~LookAndFeelMethods | ( |  | ) |

virtual default

## Member Function Documentation

## drawButtonBackground()

virtual void Button::LookAndFeelMethods::drawButtonBackground | ( | Graphics & | ,
|  | Button & | ,
|  | const Colour & | backgroundColour,
|  | bool | shouldDrawButtonAsHighlighted,
|  | bool | shouldDrawButtonAsDown
| ) |  |

pure virtual

Implemented in LookAndFeel_V4, LookAndFeel_V2, LookAndFeel_V1, and LookAndFeel_V3.

## getTextButtonFont()

virtual Font Button::LookAndFeelMethods::getTextButtonFont | ( | TextButton & | ,
|  | int | buttonHeight
| ) |  |

pure virtual

Implemented in LookAndFeel_V4, and LookAndFeel_V2.

## getTextButtonWidthToFitText()

virtual int Button::LookAndFeelMethods::getTextButtonWidthToFitText | ( | TextButton & | ,
|  | int | buttonHeight
| ) |  |

pure virtual

Implemented in LookAndFeel_V2.

## drawButtonText()

virtual void Button::LookAndFeelMethods::drawButtonText | ( | Graphics & | ,
|  | TextButton & | ,
|  | bool | shouldDrawButtonAsHighlighted,
|  | bool | shouldDrawButtonAsDown
| ) |  |

pure virtual

Draws the text for a TextButton.

Implemented in LookAndFeel_V2.

## drawToggleButton()

virtual void Button::LookAndFeelMethods::drawToggleButton | ( | Graphics & | ,
|  | ToggleButton & | ,
|  | bool | shouldDrawButtonAsHighlighted,
|  | bool | shouldDrawButtonAsDown
| ) |  |

pure virtual

Draws the contents of a standard ToggleButton.

Implemented in LookAndFeel_V4, LookAndFeel_V2, and LookAndFeel_V1.

## changeToggleButtonWidthToFitText()

virtual void Button::LookAndFeelMethods::changeToggleButtonWidthToFitText | ( | ToggleButton & |  | ) |

pure virtual

Implemented in LookAndFeel_V4, and LookAndFeel_V2.

## drawTickBox()

virtual void Button::LookAndFeelMethods::drawTickBox | ( | Graphics & | ,
|  | Component & | ,
|  | float | x,
|  | float | y,
|  | float | w,
|  | float | h,
|  | bool | ticked,
|  | bool | isEnabled,
|  | bool | shouldDrawButtonAsHighlighted,
|  | bool | shouldDrawButtonAsDown
| ) |  |

pure virtual

Implemented in LookAndFeel_V4, LookAndFeel_V2, and LookAndFeel_V1.

## drawDrawableButton()

virtual void Button::LookAndFeelMethods::drawDrawableButton | ( | Graphics & | ,
|  | DrawableButton & | ,
|  | bool | shouldDrawButtonAsHighlighted,
|  | bool | shouldDrawButtonAsDown
| ) |  |

pure virtual

Implemented in LookAndFeel_V2.

The documentation for this struct was generated from the following file:

- juce_Button.h