| @@ -509,6 +509,16 @@ int LookAndFeel::getAlertBoxWindowFlags() | |||||
| | ComponentPeer::windowHasDropShadow; | | ComponentPeer::windowHasDropShadow; | ||||
| } | } | ||||
| int LookAndFeel::getAlertWindowButtonHeight() | |||||
| { | |||||
| return 28; | |||||
| } | |||||
| const Font LookAndFeel::getAlertWindowFont() | |||||
| { | |||||
| return Font (12.0f); | |||||
| } | |||||
| void LookAndFeel::drawProgressBar (Graphics& g, ProgressBar& progressBar, | void LookAndFeel::drawProgressBar (Graphics& g, ProgressBar& progressBar, | ||||
| int width, int height, | int width, int height, | ||||
| double progress, const String& textToShow) | double progress, const String& textToShow) | ||||
| @@ -166,6 +166,10 @@ public: | |||||
| virtual int getAlertBoxWindowFlags(); | virtual int getAlertBoxWindowFlags(); | ||||
| virtual int getAlertWindowButtonHeight(); | |||||
| virtual const Font getAlertWindowFont(); | |||||
| /** Draws a progress bar. | /** Draws a progress bar. | ||||
| If the progress value is less than 0 or greater than 1.0, this should draw a spinning | If the progress value is less than 0 or greater than 1.0, this should draw a spinning | ||||
| @@ -179,7 +179,7 @@ void AlertWindow::addButton (const String& name, | |||||
| b->addShortcut (shortcutKey1); | b->addShortcut (shortcutKey1); | ||||
| b->addShortcut (shortcutKey2); | b->addShortcut (shortcutKey2); | ||||
| b->addButtonListener (this); | b->addButtonListener (this); | ||||
| b->changeWidthToFitText (28); | |||||
| b->changeWidthToFitText (getLookAndFeel().getAlertWindowButtonHeight()); | |||||
| addAndMakeVisible (b, 0); | addAndMakeVisible (b, 0); | ||||
| buttons.add (b); | buttons.add (b); | ||||
| @@ -363,8 +363,8 @@ void AlertWindow::paint (Graphics& g) | |||||
| { | { | ||||
| getLookAndFeel().drawAlertBox (g, *this, textArea, textLayout); | getLookAndFeel().drawAlertBox (g, *this, textArea, textLayout); | ||||
| g.setColour (Colours::black); | |||||
| g.setFont (12.0f); | |||||
| g.setColour (findColour (textColourId)); | |||||
| g.setFont (getLookAndFeel().getAlertWindowFont()); | |||||
| int i; | int i; | ||||
| for (i = textBoxes.size(); --i >= 0;) | for (i = textBoxes.size(); --i >= 0;) | ||||