Loading...
Searching...
No Matches
juce::Button::LookAndFeelMethods Struct Referenceabstract

## Detailed Description

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

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

- juce_gui_basics/buttons/juce_Button.h

Inheritance diagram for juce::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.
virtual void | drawToggleButton (Graphics &, ToggleButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown)=0
| Draws the contents of a standard ToggleButton.
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

## Constructors and Destructors

## ~LookAndFeelMethods()

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

virtual default

## Member Functions

## drawButtonBackground()

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

pure virtual

Implemented in juce::LookAndFeel_V1, juce::LookAndFeel_V2, juce::LookAndFeel_V3, and juce::LookAndFeel_V4.

References juce::Button::Button().

## getTextButtonFont()

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

pure virtual

Implemented in juce::LookAndFeel_V2, and juce::LookAndFeel_V4.

## getTextButtonWidthToFitText()

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

pure virtual

Implemented in juce::LookAndFeel_V2.

## drawButtonText()

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

pure virtual

Draws the text for a TextButton.

Implemented in juce::LookAndFeel_V2.

## drawToggleButton()

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

pure virtual

Draws the contents of a standard ToggleButton.

Implemented in juce::LookAndFeel_V1, juce::LookAndFeel_V2, and juce::LookAndFeel_V4.

## changeToggleButtonWidthToFitText()

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

pure virtual

Implemented in juce::LookAndFeel_V2, and juce::LookAndFeel_V4.

## drawTickBox()

virtual void juce::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 juce::LookAndFeel_V1, juce::LookAndFeel_V2, and juce::LookAndFeel_V4.

References juce::Component::Component(), h, juce::Component::isEnabled(), w, x, and y.

## drawDrawableButton()

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

pure virtual

Implemented in juce::LookAndFeel_V2.

### Purchase

Get JUCE

### Discover

What's New in JUCE Features

### Learn

Documentaion Tutorials Made with JUCE Resources

### Support

JUCE Forum Newsletter Archive

### About

Contact Us JUCE Legal JUCE Licensing FAQ

### Events

Audio Developer Conference
© Raw Material Software Limited