Adds a focus outline to a component. More...
#include <juce_FocusOutline.h>
Classes | |
struct | OutlineWindowProperties |
Defines the focus outline window properties. More... | |
Public Member Functions | |
FocusOutline (std::unique_ptr< OutlineWindowProperties > props) | |
Creates a FocusOutline. | |
~FocusOutline () override | |
Destructor. | |
void | setOwner (Component *componentToFollow) |
Attaches the outline to a component. | |
Adds a focus outline to a component.
This object creates and manages a component that sits on top of a target component. It will track the position of the target component and will be brought to the front with the tracked component.
Use the Component::setHasFocusOutline() method to indicate that a component should have a focus outline drawn around it, and when it receives keyboard focus one of these objects will be created using the LookAndFeel::createFocusOutlineForComponent() method. You can override this method in your own LookAndFeel classes to draw a custom outline if required.
FocusOutline::FocusOutline | ( | std::unique_ptr< OutlineWindowProperties > | props | ) |
Creates a FocusOutline.
Call setOwner to attach it to a component.
|
override |
Destructor.
void FocusOutline::setOwner | ( | Component * | componentToFollow | ) |
Attaches the outline to a component.