32 bool hasKeyboardFocus,
33 bool shouldDrawButtonAsHighlighted,
34 bool shouldDrawButtonAsDown)
noexcept
36 const float sat = hasKeyboardFocus ? 1.3f : 0.9f;
37 const Colour baseColour (buttonColour.withMultipliedSaturation (sat));
39 if (shouldDrawButtonAsDown)
return baseColour.
contrasting (0.2f);
40 if (shouldDrawButtonAsHighlighted)
return baseColour.
contrasting (0.1f);
47 const float tooltipFontSize = 13.0f;
48 const int maxToolTipWidth = 400;
64 const uint32 textButtonColour = 0xffbbbbff;
65 const uint32 textHighlightColour = 0x401111ee;
66 const uint32 standardOutlineColour = 0xb2808080;
68 static const uint32 standardColours[] =
188 0x1000440, 0x66dddddd,
189 0x1000441, 0x99111111,
191 0x1004000, 0xffd3d3d3,
192 0x1004001, 0xff000000,
194 0x1005000, 0xffffffff,
195 0x1005001, 0xff000000,
196 0x1005002, 0x66000000,
197 0x1005003, 0x80ffff00,
198 0x1005004, 0xffb6b600,
199 0x1005005, 0xff000000,
200 0x1005006, 0x4c000000,
202 0x1006000, 0xff1a1c27,
203 0x1006001, 0x99f1f1f1,
204 0x1006002, 0xfff1f1f1,
205 0x1006003, 0x99ba00ff,
206 0x1006004, 0xfff1f1f1,
208 0x1004500, 0xffffffff,
209 0x1004502, textHighlightColour,
210 0x1004503, 0xff000000,
211 0x1004504, 0x44999999,
212 0x1004505, 0x44000000,
214 0x1007000, 0xffe5e5e5,
215 0x1007001, 0xff000000,
217 0x100ad00, 0x00000000,
218 0x100ad01, 0xff000000,
247 const Colour& backgroundColour,
248 bool shouldDrawButtonAsHighlighted,
249 bool shouldDrawButtonAsDown)
254 const float outlineThickness =
button.isEnabled() ? ((shouldDrawButtonAsDown || shouldDrawButtonAsHighlighted) ? 1.2f : 0.7f) : 0.4f;
255 const float halfThickness = outlineThickness * 0.5f;
257 const float indentL =
button.isConnectedOnLeft() ? 0.1f : halfThickness;
258 const float indentR =
button.isConnectedOnRight() ? 0.1f : halfThickness;
259 const float indentT =
button.isConnectedOnTop() ? 0.1f : halfThickness;
260 const float indentB =
button.isConnectedOnBottom() ? 0.1f : halfThickness;
263 button.hasKeyboardFocus (
true),
264 shouldDrawButtonAsHighlighted,
265 shouldDrawButtonAsDown)
266 .withMultipliedAlpha (
button.isEnabled() ? 1.0f : 0.5f));
271 (
float)
width - indentL - indentR,
272 (
float)
height - indentT - indentB,
273 baseColour, outlineThickness, -1.0f,
274 button.isConnectedOnLeft(),
275 button.isConnectedOnRight(),
276 button.isConnectedOnTop(),
277 button.isConnectedOnBottom());
282 return Font (
jmin (15.0f, (
float) buttonHeight * 0.6f));
287 return getTextButtonFont (
b, buttonHeight).getStringWidth (
b.getButtonText()) + buttonHeight;
297 .withMultipliedAlpha (
button.isEnabled() ? 1.0f : 0.5f));
299 const int yIndent =
jmin (4,
button.proportionOfHeight (0.3f));
303 const int leftIndent =
jmin (fontHeight, 2 + cornerSize / (
button.isConnectedOnLeft() ? 4 : 2));
304 const int rightIndent =
jmin (fontHeight, 2 + cornerSize / (
button.isConnectedOnRight() ? 4 : 2));
305 const int textWidth =
button.getWidth() - leftIndent - rightIndent;
308 g.drawFittedText (
button.getButtonText(),
309 leftIndent, yIndent, textWidth,
button.getHeight() - yIndent * 2,
314 float x,
float y,
float w,
float h,
316 const bool isEnabled,
317 const bool shouldDrawButtonAsHighlighted,
318 const bool shouldDrawButtonAsDown)
320 const float boxSize =
w * 0.7f;
325 true, shouldDrawButtonAsHighlighted, shouldDrawButtonAsDown),
326 isEnabled ? ((shouldDrawButtonAsDown || shouldDrawButtonAsHighlighted) ? 1.1f : 0.5f) : 0.3f);
346 bool shouldDrawButtonAsHighlighted,
bool shouldDrawButtonAsDown)
348 if (
button.hasKeyboardFocus (
true))
354 float fontSize =
jmin (15.0f, (
float)
button.getHeight() * 0.75f);
355 const float tickWidth = fontSize * 1.1f;
358 tickWidth, tickWidth,
361 shouldDrawButtonAsHighlighted,
362 shouldDrawButtonAsDown);
365 g.setFont (fontSize);
370 g.drawFittedText (
button.getButtonText(),
372 .withTrimmedRight (2),
378 auto fontSize =
jmin (15.0f, (
float)
button.getHeight() * 0.75f);
379 auto tickWidth = fontSize * 1.1f;
381 Font font (fontSize);
390 bool toggleState =
button.getToggleState();
396 ?
jmin (16,
button.proportionOfHeight (0.25f))
401 g.setFont ((
float) textH);
405 .withMultipliedAlpha (
button.isEnabled() ? 1.0f : 0.4f));
407 g.drawFittedText (
button.getButtonText(),
408 2,
button.getHeight() - textH - 1,
409 button.getWidth() - 4, textH,
418 int numButtons,
Component* associatedComponent)
432 if (button1ShortCut == button2ShortCut)
440 else if (numButtons == 3)
442 aw->
addButton (button1, 1, button1ShortCut);
443 aw->
addButton (button2, 2, button2ShortCut);
456 int iconSpaceUsed = 0;
458 const int iconWidth = 80;
459 int iconSize =
jmin (iconWidth + 50, alert.
getHeight() + 20);
495 (
float) iconRect.
getX(), (
float) iconRect.
getY(),
504 iconSpaceUsed = iconWidth;
511 textArea.
getWidth() - iconSpaceUsed,
526 const int n = buttons.
size();
531 for (
int i = 0;
i <
n; ++
i)
561 double progress,
const String& textToShow)
566 g.fillAll (background);
568 if (progress >= 0.0f && progress < 1.0f)
575 true,
true,
true,
true);
580 g.setColour (foreground);
582 const int stripeWidth =
height * 2;
587 for (
float x = (
float) (- position);
x < (float) (
width + stripeWidth);
x += (float) stripeWidth)
588 p.addQuadrilateral (
x, 0.0f,
589 x + (
float) stripeWidth * 0.5f, 0.0f,
591 x - (
float) stripeWidth * 0.5f, (
float)
height);
602 true,
true,
true,
true);
605 g.setTiledImageFill (im, 0, 0, 0.85f);
612 g.setFont ((
float)
height * 0.6f);
620 const float radius = (float)
jmin (
w,
h) * 0.4f;
621 const float thickness = radius * 0.15f;
623 p.addRoundedRectangle (radius * 0.4f, thickness * -0.5f,
624 radius * 0.6f, thickness,
627 const float cx = (float)
x + (
float)
w * 0.5f;
628 const float cy = (float)
y + (
float)
h * 0.5f;
634 const uint32 n = (
i + 12 - animationIndex) % 12;
638 .translated (cx, cy));
656 bool shouldDrawButtonAsDown)
660 const auto w = (float)
width;
663 if (buttonDirection == 0)
664 p.addTriangle (
w * 0.5f,
h * 0.2f,
667 else if (buttonDirection == 1)
668 p.addTriangle (
w * 0.8f,
h * 0.5f,
671 else if (buttonDirection == 2)
672 p.addTriangle (
w * 0.5f,
h * 0.8f,
675 else if (buttonDirection == 3)
676 p.addTriangle (
w * 0.2f,
h * 0.5f,
680 if (shouldDrawButtonAsDown)
687 g.setColour (
Colour (0x80000000));
695 bool isScrollbarVertical,
696 int thumbStartPosition,
703 Path slotPath, thumbPath;
706 const float slotIndentx2 = slotIndent * 2.0f;
707 const float thumbIndent = slotIndent + 1.0f;
708 const float thumbIndentx2 = thumbIndent * 2.0f;
710 float gx1 = 0.0f, gy1 = 0.0f, gx2 = 0.0f, gy2 = 0.0f;
712 if (isScrollbarVertical)
715 (
float)
y + slotIndent,
716 (
float)
width - slotIndentx2,
717 (
float)
height - slotIndentx2,
718 ((
float)
width - slotIndentx2) * 0.5f);
722 (
float) thumbStartPosition + thumbIndent,
723 (
float)
width - thumbIndentx2,
724 (
float) thumbSize - thumbIndentx2,
725 ((
float)
width - thumbIndentx2) * 0.5f);
727 gx2 = (float)
x + (
float)
width * 0.7f;
732 (
float)
y + slotIndent,
733 (
float)
width - slotIndentx2,
734 (
float)
height - slotIndentx2,
735 ((
float)
height - slotIndentx2) * 0.5f);
739 (
float)
y + thumbIndent,
740 (
float) thumbSize - thumbIndentx2,
741 (
float)
height - thumbIndentx2,
742 ((
float)
height - thumbIndentx2) * 0.5f);
744 gy2 = (float)
y + (
float)
height * 0.7f;
748 Colour trackColour1, trackColour2;
762 trackColour2, gx2, gy2,
false));
763 g.fillPath (slotPath);
765 if (isScrollbarVertical)
767 gx1 = (float)
x + (
float)
width * 0.6f;
768 gx2 = (float)
x + (
float)
width;
772 gy1 = (float)
y + (
float)
height * 0.6f;
773 gy2 = (float)
y + (
float)
height;
777 Colour (0x19000000), gx2, gy2,
false));
778 g.fillPath (slotPath);
780 g.setColour (thumbColour);
781 g.fillPath (thumbPath);
789 if (isScrollbarVertical)
794 g.fillPath (thumbPath);
797 g.setColour (
Colour (0x4c000000));
824 Colour ,
bool isOpen,
bool )
833 g.setColour (
Colour (0xe5ffffff));
834 g.fillRect (boxArea);
836 g.setColour (
Colour (0x80000000));
837 g.drawRect (boxArea);
839 auto size = (float) boxSize * 0.5f + 1.0f;
840 auto centre = (float) (boxSize / 2);
842 g.fillRect ((
float)
x + ((
float) boxSize -
size) * 0.5f, (
float)
y + centre,
size, 1.0f);
845 g.fillRect ((
float)
x + centre, (
float)
y + ((
float) boxSize -
size) * 0.5f, 1.0f,
size);
881 int standardMenuItemHeight,
int& idealWidth,
int& idealHeight)
886 idealHeight = standardMenuItemHeight > 0 ? standardMenuItemHeight / 2 : 10;
892 if (standardMenuItemHeight > 0 && font.
getHeight() > (
float) standardMenuItemHeight / 1.3f)
893 font.
setHeight ((
float) standardMenuItemHeight / 1.3f);
895 idealHeight = standardMenuItemHeight > 0 ? standardMenuItemHeight :
roundToInt (font.
getHeight() * 1.3f);
902 int standardMenuItemHeight,
909 standardMenuItemHeight,
918 g.fillAll (background);
919 g.setColour (background.overlaidWith (
Colour (0x2badd8e6)));
943 background.withAlpha (0.0f),
944 0.0f, isScrollUpArrow ? ((
float)
height) : 0.0f,
949 auto hw = (float)
width * 0.5f;
950 auto arrowW = (float)
height * 0.3f;
951 auto y1 = (float)
height * (isScrollUpArrow ? 0.6f : 0.3f);
952 auto y2 = (float)
height * (isScrollUpArrow ? 0.3f : 0.6f);
955 p.addTriangle (hw - arrowW, y1,
965 bool isScrollUpArrow,
972 const bool isSeparator,
const bool isActive,
973 const bool isHighlighted,
const bool isTicked,
975 const String& shortcutKeyText,
981 r.removeFromTop (
r.getHeight() / 2 - 1);
983 g.setColour (
Colour (0x33000000));
984 g.fillRect (
r.removeFromTop (1));
986 g.setColour (
Colour (0x66ffffff));
987 g.fillRect (
r.removeFromTop (1));
993 if (textColourToUse !=
nullptr)
994 textColour = *textColourToUse;
1007 g.setColour (textColour);
1011 g.setOpacity (0.3f);
1015 auto maxFontHeight = (float) area.
getHeight() / 1.3f;
1022 auto iconArea =
r.removeFromLeft ((
r.getHeight() * 5) / 4).reduced (3).toFloat();
1024 if (icon !=
nullptr)
1031 g.fillPath (tick, tick.getTransformToScaleToFit (iconArea,
true));
1038 auto x = (float)
r.removeFromRight ((
int) arrowH).getX();
1039 auto halfH = (float)
r.getCentreY();
1042 p.addTriangle (
x, halfH - arrowH * 0.5f,
1043 x, halfH + arrowH * 0.5f,
1044 x + arrowH * 0.6f, halfH);
1049 r.removeFromRight (3);
1070 const auto hasSubMenu = item.
subMenu !=
nullptr
1088 const String& sectionName)
1093 g.drawFittedText (sectionName,
1099 const String& sectionName,
1114 false,
false,
false);
1118 0.0f, baseColour, 0.4f,
true,
true,
true,
true);
1120 g.fillAll (baseColour);
1131 .getStringWidth (itemText) +
menuBar.getHeight();
1135 int itemIndex,
const String& itemText,
1136 bool isMouseOverItem,
bool isMenuOpen,
1142 .withMultipliedAlpha (0.5f));
1144 else if (isMenuOpen || isMouseOverItem)
1200 g.setOpacity (1.0f);
1209 g.setOpacity (1.0f);
1223 int buttonX,
int buttonY,
int buttonW,
int buttonH,
ComboBox&
box)
1227 if (
box.isEnabled() &&
box.hasKeyboardFocus (
false))
1238 auto outlineThickness =
box.isEnabled() ? (isMouseButtonDown ? 1.2f : 0.5f) : 0.3f;
1241 box.hasKeyboardFocus (
true),
1242 false, isMouseButtonDown)
1243 .withMultipliedAlpha (
box.isEnabled() ? 1.0f : 0.5f);
1246 (
float) buttonX + outlineThickness, (
float) buttonY + outlineThickness,
1247 (
float) buttonW - outlineThickness * 2.0f, (
float) buttonH - outlineThickness * 2.0f,
1248 baseColour, outlineThickness, -1.0f,
1249 true,
true,
true,
true);
1251 if (
box.isEnabled())
1253 const float arrowX = 0.3f;
1254 const float arrowH = 0.2f;
1256 const auto x = (float) buttonX;
1257 const auto y = (float) buttonY;
1258 const auto w = (float) buttonW;
1259 const auto h = (float) buttonH;
1262 p.addTriangle (
x +
w * 0.5f,
y +
h * (0.45f - arrowH),
1263 x +
w * (1.0f - arrowX),
y +
h * 0.45f,
1264 x +
w * arrowX,
y +
h * 0.45f);
1266 p.addTriangle (
x +
w * 0.5f,
y +
h * (0.55f + arrowH),
1267 x +
w * (1.0f - arrowX),
y +
h * 0.55f,
1268 x +
w * arrowX,
y +
h * 0.55f);
1277 return Font (
jmin (15.0f, (
float)
box.getHeight() * 0.85f));
1287 label.setBounds (1, 1,
1288 box.getWidth() + 3 -
box.getHeight(),
1289 box.getHeight() - 2);
1308 auto font =
label.getLookAndFeel().getLabelFont (
label);
1314 g.drawFittedText (
box.getTextWhenNothingSelected(), textArea,
label.getJustificationType(),
1315 jmax (1, (
int) ((
float) textArea.getHeight() / font.getHeight())),
1316 label.getMinimumHorizontalScale());
1322 return label.getFont();
1329 if (!
label.isBeingEdited())
1331 auto alpha =
label.isEnabled() ? 1.0f : 0.5f;
1339 g.drawFittedText (
label.getText(), textArea,
label.getJustificationType(),
1340 jmax (1, (
int) ((
float) textArea.getHeight() / font.
getHeight())),
1341 label.getMinimumHorizontalScale());
1345 else if (
label.isEnabled())
1350 g.drawRect (
label.getLocalBounds());
1355 return label.getBorderSize();
1367 auto gradCol1 = trackColour.overlaidWith (
Colours::black.withAlpha (
slider.isEnabled() ? 0.25f : 0.13f));
1368 auto gradCol2 = trackColour.overlaidWith (
Colour (0x14000000));
1372 if (
slider.isHorizontal())
1374 const float iy = (float)
y + (
float)
height * 0.5f - sliderRadius * 0.5f;
1375 const float ih = sliderRadius;
1379 indent.addRoundedRectangle ((
float)
x - sliderRadius * 0.5f, iy,
1380 (
float)
width + sliderRadius, ih,
1385 const float ix = (float)
x + (
float)
width * 0.5f - sliderRadius * 0.5f;
1386 const float iw = sliderRadius;
1390 indent.addRoundedRectangle (ix, (
float)
y - sliderRadius * 0.5f,
1391 iw, (
float)
height + sliderRadius,
1395 g.fillPath (indent);
1397 g.setColour (
Colour (0x4c000000));
1402 float sliderPos,
float minSliderPos,
float maxSliderPos,
1412 const float outlineThickness =
slider.isEnabled() ? 0.8f : 0.3f;
1420 kx = (float)
x + (
float)
width * 0.5f;
1426 ky = (float)
y + (
float)
height * 0.5f;
1432 sliderRadius * 2.0f,
1433 knobColour, outlineThickness);
1440 sliderPos - sliderRadius,
1441 sliderRadius * 2.0f,
1442 knobColour, outlineThickness);
1447 (
float)
y + (
float)
height * 0.5f - sliderRadius,
1448 sliderRadius * 2.0f,
1449 knobColour, outlineThickness);
1454 auto sr =
jmin (sliderRadius, (
float)
width * 0.4f);
1457 minSliderPos - sliderRadius,
1458 sliderRadius * 2.0f, knobColour, outlineThickness, 1);
1461 jmin ((
float)
x + (
float)
width - sliderRadius * 2.0f,
1462 (
float)
x + (
float)
width * 0.5f),
1464 sliderRadius * 2.0f,
1471 auto sr =
jmin (sliderRadius, (
float)
height * 0.4f);
1474 jmax (0.0f, (
float)
y + (
float)
height * 0.5f - sliderRadius * 2.0f),
1475 sliderRadius * 2.0f, knobColour, outlineThickness, 2);
1478 maxSliderPos - sliderRadius,
1479 jmin ((
float)
y + (
float)
height - sliderRadius * 2.0f,
1480 (
float)
y + (
float)
height * 0.5f),
1481 sliderRadius * 2.0f,
1490 float sliderPos,
float minSliderPos,
float maxSliderPos,
1497 const bool isMouseOver =
slider.isMouseOverOrDragging() &&
slider.isEnabled();
1500 .withMultipliedSaturation (
slider.isEnabled() ? 1.0f : 0.5f),
1502 isMouseOver ||
slider.isMouseButtonDown());
1509 : (sliderPos - (
float)
x),
1513 slider.isEnabled() ? 0.9f : 0.3f,
1514 true,
true,
true,
true);
1527 slider.getWidth() / 2) + 2;
1531 const float rotaryStartAngle,
const float rotaryEndAngle,
Slider& slider)
1533 const float radius =
jmin ((
float)
width * 0.5f, (
float)
height * 0.5f) - 2.0f;
1534 const float centreX = (float)
x + (
float)
width * 0.5f;
1535 const float centreY = (float)
y + (
float)
height * 0.5f;
1536 const float rx = centreX - radius;
1537 const float ry = centreY - radius;
1538 const float rw = radius * 2.0f;
1539 const float angle = rotaryStartAngle + sliderPos * (rotaryEndAngle - rotaryStartAngle);
1540 const bool isMouseOver =
slider.isMouseOverOrDragging() &&
slider.isEnabled();
1547 g.setColour (
Colour (0x80808080));
1549 const float thickness = 0.7f;
1553 filledArc.
addPieSegment (rx, ry, rw, rw, rotaryStartAngle, angle, thickness);
1554 g.fillPath (filledArc);
1558 const float innerRadius = radius * 0.2f;
1560 p.addTriangle (-innerRadius, 0.0f,
1561 0.0f, -radius * thickness * 1.1f,
1564 p.addEllipse (-innerRadius, -innerRadius, innerRadius * 2.0f, innerRadius * 2.0f);
1572 g.setColour (
Colour (0x80808080));
1575 outlineArc.
addPieSegment (rx, ry, rw, rw, rotaryStartAngle, rotaryEndAngle, thickness);
1578 g.strokePath (outlineArc,
PathStrokeType (
slider.isEnabled() ? (isMouseOver ? 2.0f : 1.2f) : 0.3f));
1585 g.setColour (
Colour (0x80808080));
1588 p.addEllipse (-0.4f * rw, -0.4f * rw, rw * 0.8f, rw * 0.8f);
1591 p.addLineSegment (
Line<float> (0.0f, 0.0f, 0.0f, -radius), rw * 0.2f);
1665 auto textBoxPos =
slider.getTextBoxPosition();
1672 auto localBounds =
slider.getLocalBounds();
1674 auto textBoxWidth =
jmax (0,
jmin (
slider.getTextBoxWidth(), localBounds.getWidth() - minXSpace));
1675 auto textBoxHeight =
jmax (0,
jmin (
slider.getTextBoxHeight(), localBounds.getHeight() - minYSpace));
1735 screenPos.
y > parentArea.
getCentreY() ? screenPos.
y - (
h + 6) : screenPos.
y + 6,
1762 if (browseButton ==
nullptr || filenameBox ==
nullptr)
1767 if (
auto* tb =
dynamic_cast<TextButton*
> (browseButton))
1768 tb->changeWidthToFitText();
1777 bool isMouseOver,
bool ,
1791 int imageX,
int imageY,
int imageW,
int imageH,
1792 const Colour& overlayColour,
1796 if (!
button.isEnabled())
1797 imageOpacity *= 0.3f;
1805 g.setOpacity (imageOpacity);
1806 g.drawImageTransformed (*
image,
t,
false);
1811 g.setColour (overlayColour);
1812 g.drawImageTransformed (*
image,
t,
true);
1819 auto lineThickness =
jmin ((
float)
w, (
float)
h) * 0.075f;
1821 for (
float i = 0.0f;
i < 1.0f;
i += 0.3f)
1825 g.drawLine ((
float)
w *
i,
1833 g.drawLine ((
float)
w *
i + lineThickness,
1836 (
float)
h *
i + lineThickness,
1846 auto centreArea =
border.subtractedFrom (fullSize);
1850 g.excludeClipRegion (centreArea);
1852 g.setColour (
Colour (0x50000000));
1853 g.drawRect (fullSize);
1855 g.setColour (
Colour (0x19000000));
1856 g.drawRect (centreArea.expanded (1, 1));
1864 g.fillAll (
window.getBackgroundColour());
1873 int w,
int h,
int titleSpaceX,
int titleSpaceW,
1874 const Image* icon,
bool drawTitleTextOnLeft)
1879 const bool isActive =
window.isActiveWindow();
1882 window.getBackgroundColour().contrasting (isActive ? 0.15f : 0.05f), (
float)
h));
1892 if (icon !=
nullptr)
1898 textW =
jmin (titleSpaceW, textW + iconW);
1899 int textX = drawTitleTextOnLeft ? titleSpaceX
1900 :
jmax (titleSpaceX, (
w - textW) / 2);
1902 if (textX + textW > titleSpaceX + titleSpaceW)
1903 textX = titleSpaceX + titleSpaceW - textW;
1905 if (icon !=
nullptr)
1907 g.setOpacity (isActive ? 1.0f : 0.6f);
1908 g.drawImageWithin (*icon, textX, (
h - iconH) / 2, iconW, iconH,
1917 g.setColour (
window.getBackgroundColour().contrasting (isActive ? 0.7f : 0.4f));
1927 const Path& normalShape_,
1939 float alpha = shouldDrawButtonAsHighlighted ? (shouldDrawButtonAsDown ? 1.0f : 0.8f) : 0.55f;
1944 float x = 0,
y = 0, diam;
1963 g.fillEllipse (
x,
y, diam, diam);
1974 diam * 0.4f, diam * 0.4f,
true));
1990 const float crossThickness = 0.25f;
2012 Path fullscreenShape;
2014 fullscreenShape.
lineTo (0.0f, 100.0f);
2015 fullscreenShape.
lineTo (0.0f, 0.0f);
2016 fullscreenShape.
lineTo (100.0f, 0.0f);
2017 fullscreenShape.
lineTo (100.0f, 45.0f);
2018 fullscreenShape.
addRectangle (45.0f, 45.0f, 100.0f, 100.0f);
2029 int titleBarX,
int titleBarY,
2030 int titleBarW,
int titleBarH,
2034 bool positionTitleBarButtonsOnLeft)
2036 const int buttonW = titleBarH - titleBarH / 8;
2038 int x = positionTitleBarButtonsOnLeft ? titleBarX + 4
2039 : titleBarX + titleBarW - buttonW - buttonW / 4;
2041 if (closeButton !=
nullptr)
2043 closeButton->
setBounds (
x, titleBarY, buttonW, titleBarH);
2044 x += positionTitleBarButtonsOnLeft ? buttonW : -(buttonW + buttonW / 4);
2047 if (positionTitleBarButtonsOnLeft)
2048 std::swap (minimiseButton, maximiseButton);
2050 if (maximiseButton !=
nullptr)
2052 maximiseButton->
setBounds (
x, titleBarY, buttonW, titleBarH);
2053 x += positionTitleBarButtonsOnLeft ? buttonW : -buttonW;
2056 if (minimiseButton !=
nullptr)
2057 minimiseButton->
setBounds (
x, titleBarY, buttonW, titleBarH);
2077 return c.getScreenBounds();
2083 g.drawRoundedRectangle ({ (float)
width, (
float)
height }, 3.0f, 3.0f);
2087 return std::make_unique<FocusOutline> (std::make_unique<WindowProperties>());
2094 bool isMouseDragging)
2098 if (isMouseOver || isMouseDragging)
2100 g.fillAll (
Colour (0x190000ff));
2104 auto cx = (float)
w * 0.5f;
2105 auto cy = (float)
h * 0.5f;
2106 auto cr = (float)
jmin (
w,
h) * 0.4f;
2112 g.fillEllipse (cx - cr, cy - cr, cr * 2.0f, cr * 2.0f);
2120 const float textH = 15.0f;
2121 const float indent = 3.0f;
2122 const float textEdgeGap = 4.0f;
2129 auto y =
f.getAscent() - 3.0f;
2132 cs =
jmin (cs,
w * 0.5f,
h * 0.5f);
2133 auto cs2 = 2.0f * cs;
2135 auto textW =
text.isEmpty() ? 0
2137 jmax (0.0f,
w - cs2 - textEdgeGap * 2),
2138 (
float)
f.getStringWidth (
text) + textEdgeGap * 2.0f);
2139 auto textX = cs + textEdgeGap;
2142 textX = cs + (
w - cs2 - textW) * 0.5f;
2144 textX =
w - cs - textW - textEdgeGap;
2146 p.startNewSubPath (
x + textX + textW,
y);
2147 p.lineTo (
x +
w - cs,
y);
2150 p.lineTo (
x +
w,
y +
h - cs);
2153 p.lineTo (
x + cs,
y +
h);
2156 p.lineTo (
x,
y + cs);
2159 p.lineTo (
x + textX,
y);
2161 auto alpha =
group.isEnabled() ? 1.0f : 0.5f;
2164 .withMultipliedAlpha (alpha));
2169 .withMultipliedAlpha (alpha));
2181 return 1 + tabDepth / 3;
2194 if (
auto* extraComponent =
button.getExtraComponent())
2195 width +=
button.getTabbedButtonBar().isVertical() ? extraComponent->getHeight()
2196 : extraComponent->getWidth();
2198 return jlimit (tabDepth * 2, tabDepth * 8,
width);
2205 auto orientation =
button.getTabbedButtonBar().getOrientation();
2209 switch (orientation)
2220 switch (orientation)
2235 auto activeArea =
button.getActiveArea();
2236 auto w = (float) activeArea.getWidth();
2237 auto h = (float) activeArea.getHeight();
2242 if (
button.getTabbedButtonBar().isVertical())
2243 std::swap (
length, depth);
2246 const float overhang = 4.0f;
2248 switch (
button.getTabbedButtonBar().getOrientation())
2251 p.startNewSubPath (
w, 0.0f);
2252 p.lineTo (0.0f, indent);
2253 p.lineTo (0.0f,
h - indent);
2255 p.lineTo (
w + overhang,
h + overhang);
2256 p.lineTo (
w + overhang, -overhang);
2260 p.startNewSubPath (0.0f, 0.0f);
2261 p.lineTo (
w, indent);
2262 p.lineTo (
w,
h - indent);
2264 p.lineTo (-overhang,
h + overhang);
2265 p.lineTo (-overhang, -overhang);
2269 p.startNewSubPath (0.0f, 0.0f);
2270 p.lineTo (indent,
h);
2271 p.lineTo (
w - indent,
h);
2273 p.lineTo (
w + overhang, -overhang);
2274 p.lineTo (-overhang, -overhang);
2279 p.startNewSubPath (0.0f,
h);
2280 p.lineTo (indent, 0.0f);
2281 p.lineTo (
w - indent, 0.0f);
2283 p.lineTo (
w + overhang,
h + overhang);
2284 p.lineTo (-overhang,
h + overhang);
2290 p =
p.createPathWithRoundedCorners (3.0f);
2296 auto tabBackground =
button.getTabBackgroundColour();
2297 const bool isFrontTab =
button.isFrontTab();
2299 g.setColour (isFrontTab ? tabBackground
2300 : tabBackground.withMultipliedAlpha (0.9f));
2306 .withMultipliedAlpha (
button.isEnabled() ? 1.0f : 0.5f));
2313 return {
height * 0.6f };
2318 auto area =
button.getTextArea().toFloat();
2320 auto length = area.getWidth();
2321 auto depth = area.getHeight();
2323 if (
button.getTabbedButtonBar().isVertical())
2324 std::swap (
length, depth);
2331 switch (
button.getTabbedButtonBar().getOrientation())
2349 col =
button.getTabBackgroundColour().contrasting();
2351 auto alpha =
button.isEnabled() ? ((isMouseOver || isMouseDown) ? 1.0f : 0.8f) : 0.3f;
2357 g.drawFittedText (
button.getButtonText().trim(),
2358 0, 0, (
int)
length, (
int) depth,
2360 jmax (1, ((
int) depth) / 12));
2368 auto activeArea =
button.getActiveArea();
2370 (
float) activeArea.getY()));
2382 auto shadowSize = 0.2f;
2392 gradient.
point2.
x = (float)
w * (1.0f - shadowSize);
2398 gradient.
point2.
x = (float)
w * shadowSize;
2405 gradient.
point2.
y = (float)
h * (1.0f - shadowSize);
2411 gradient.
point2.
y = (float)
h * shadowSize;
2419 g.setGradientFill (gradient);
2420 g.fillRect (shadowRect.
expanded (2, 2));
2422 g.setColour (
Colour (0x80000000));
2428 auto thickness = 7.0f;
2429 auto indent = 22.0f;
2432 p.addEllipse (-10.0f, -10.0f, 120.0f, 120.0f);
2439 p.addEllipse (0.0f, 0.0f, 100.0f, 100.0f);
2440 p.addRectangle (indent, 50.0f - thickness, 100.0f - indent * 2.0f, thickness * 2.0f);
2441 p.addRectangle (50.0f - thickness, indent, thickness * 2.0f, 50.0f - indent - thickness);
2442 p.addRectangle (50.0f - thickness, 50.0f + thickness, thickness * 2.0f, 50.0f - indent - thickness);
2443 p.setUsingNonZeroWinding (
false);
2460 db->setImages (&normalImage, &overImage,
nullptr);
2476 0.0f, (
float) area.getY(),
2477 backgroundColour.withMultipliedSaturation (.5f),
2478 0.0f, (
float) area.getBottom(),
2483 g.fillRect (area.removeFromBottom (1));
2490 const String& columnName,
int ,
2491 int width,
int height,
bool isMouseOver,
bool isMouseDown,
2497 g.fillAll (highlightColour);
2498 else if (isMouseOver)
2499 g.fillAll (highlightColour.withMultipliedAlpha (0.625f));
2511 g.setColour (
Colour (0x99000000));
2523 const int outlineThickness = 1;
2537 background.darker (0.1f),
2550 bool isMouseOver,
bool isMouseDown,
2555 else if (isMouseOver)
2565 auto fontHeight =
jmin (14.0f, (
float)
height * 0.85f);
2566 g.setFont (fontHeight);
2568 g.drawFittedText (
text,
2578 auto buttonSize = (float)
height * 0.75f;
2579 auto buttonIndent = ((float)
height - buttonSize) * 0.5f;
2583 auto textX = (
int) (buttonIndent * 2.0f + buttonSize + 2.0f);
2605 g.drawFittedText (component.
getName(),
2606 3,
r.getY(),
r.getX() - 5,
r.getHeight(),
2612 const int textW =
jmin (200, component.
getWidth() / 3);
2618 return sectionTitle.
isEmpty() ? 0 : 22;
2625 if (cachedImage.
isNull())
2634 g.drawImageAt (cachedImage, 0, 0);
2655 const String& instructions)
2662 s.append (instructions,
Font (14.0f), colour);
2669 const String& fileSizeDescription,
2670 const String& fileTimeDescription,
2671 bool isDirectory,
bool isItemSelected,
2674 auto fileListComp =
dynamic_cast<Component*
> (&dcc);
2683 if (icon !=
nullptr && icon->
isValid())
2685 g.drawImageWithin (*icon, 2, 2,
x - 4,
height - 4,
2704 g.setFont ((
float)
height * 0.7f);
2706 if (
width > 450 && ! isDirectory)
2715 g.setFont ((
float)
height * 0.5f);
2720 g.drawFittedText (fileSizeDescription,
2721 sizeX, 0, dateX - sizeX - 8,
height,
2724 g.drawFittedText (fileTimeDescription,
2743 arrowPath.
addArrow ({ 50.0f, 100.0f, 50.0f, 0.0f }, 40.0f, 100.0f, 50.0f);
2747 arrowImage.
setPath (arrowPath);
2749 goUpButton->setImages (&arrowImage);
2764 if (previewComp !=
nullptr)
2766 auto previewWidth =
w / 3;
2769 w -= previewWidth + 4;
2774 const int controlsHeight = 22;
2775 const int upButtonWidth = 50;
2776 auto bottomSectionHeight = controlsHeight + 8;
2778 currentPathBox->
setBounds (
x,
y,
w - upButtonWidth - 6, controlsHeight);
2779 goUpButton->
setBounds (
x +
w - upButtonWidth,
y, upButtonWidth, controlsHeight);
2781 y += controlsHeight + 4;
2783 if (
auto listAsComp =
dynamic_cast<Component*
> (fileListComponent))
2785 listAsComp->setBounds (
x,
y,
w, browserComp.
getHeight() -
y - bottomSectionHeight);
2786 y = listAsComp->getBottom() + 4;
2789 filenameBox->
setBounds (
x + 50,
y,
w - 50, controlsHeight);
2804<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="706" height="532">
2806 <linearGradient id="a">
2807 <stop stop-color="#adf" offset="0"/>
2808 <stop stop-color="#ecfaff" offset="1"/>
2810 <linearGradient id="b" x1=".6" x2="0" y1=".9" xlink:href="#a"/>
2811 <linearGradient id="c" x1=".6" x2=".1" y1=".9" y2=".3" xlink:href="#a"/>
2813 <g class="currentLayer">
2814 <path d="M112.1 104c-8.2 2.2-13.2 11.6-11.3 21l68.3 342.7c1.9 9.4 10.1 15.2 18.4 13l384.3-104.1c8.2-2.2 13.2-11.6 11.3-21l-48-266a15.8 15.8 0 0 0-18.4-12.8l-224.2 38s-20.3-41.3-28.3-39.3z" display="block" fill="url(#b)" stroke="#446c98" stroke-width="7"/>
2815 <path d="M608.6 136.8L235.2 208a22.7 22.7 0 0 0-16 19l-40.8 241c1.7 8.4 9.6 14.5 17.8 12.3l380-104c8-2.2 10.7-10.2 12.3-18.4l38-210.1c.4-15.4-10.4-11.8-18-11.1z" display="block" fill="url(#c)" opacity=".8" stroke="#446c98" stroke-width="7"/>
2820 return folderImage.get();
2823const Drawable* LookAndFeel_V2::getDefaultDocumentFileImage()
2827<svg version="1" viewBox="-10 -10 450 600" xmlns="http://www.w3.org/2000/svg">
2828 <path d="M17 0h290l120 132v426c0 10-8 19-17 19H17c-9 0-17-9-17-19V19C0 8 8 0 17 0z" fill="#e5e5e5" stroke="#888888" stroke-width="7"/>
2829 <path d="M427 132H324c-9 0-17-9-17-19V0l120 132z" fill="#ccc"/>
2847 static const unsigned char data[] =
2849 109,0,224,168,68,0,0,119,67,108,0,224,172,68,0,128,146,67,113,0,192,148,68,0,0,219,67,0,96,110,68,0,224,56,68,113,0,64,51,68,0,32,130,68,0,64,20,68,0,224,
2850 162,68,108,0,128,3,68,0,128,168,68,113,0,128,221,67,0,192,175,68,0,0,207,67,0,32,179,68,113,0,0,201,67,0,224,173,68,0,0,181,67,0,224,161,68,108,0,128,168,67,
2851 0,128,154,68,113,0,128,141,67,0,192,138,68,0,128,108,67,0,64,131,68,113,0,0,62,67,0,128,119,68,0,0,5,67,0,128,114,68,113,0,0,102,67,0,192,88,68,0,128,155,
2852 67,0,192,88,68,113,0,0,190,67,0,192,88,68,0,128,232,67,0,224,131,68,108,0,128,246,67,0,192,139,68,113,0,64,33,68,0,128,87,68,0,0,93,68,0,224,26,68,113,0,
2853 96,140,68,0,128,188,67,0,224,168,68,0,0,119,67,99,101
2861 static const unsigned char data[] =
2863 109,0,0,17,68,0,96,145,68,108,0,192,13,68,0,192,147,68,113,0,0,213,67,0,64,174,68,0,0,168,67,0,64,174,68,113,0,0,104,67,0,64,174,68,0,0,5,67,0,64,
2864 153,68,113,0,0,18,67,0,64,153,68,0,0,24,67,0,64,153,68,113,0,0,135,67,0,64,153,68,0,128,207,67,0,224,130,68,108,0,0,220,67,0,0,126,68,108,0,0,204,67,
2865 0,128,117,68,113,0,0,138,67,0,64,82,68,0,0,138,67,0,192,57,68,113,0,0,138,67,0,192,37,68,0,128,210,67,0,64,10,68,113,0,128,220,67,0,64,45,68,0,0,8,
2866 68,0,128,78,68,108,0,192,14,68,0,0,87,68,108,0,64,20,68,0,0,80,68,113,0,192,57,68,0,0,32,68,0,128,88,68,0,0,32,68,113,0,64,112,68,0,0,32,68,0,
2867 128,124,68,0,64,68,68,113,0,0,121,68,0,192,67,68,0,128,119,68,0,192,67,68,113,0,192,108,68,0,192,67,68,0,32,89,68,0,96,82,68,113,0,128,69,68,0,0,97,68,
2868 0,0,56,68,0,64,115,68,108,0,64,49,68,0,128,124,68,108,0,192,55,68,0,96,129,68,113,0,0,92,68,0,224,146,68,0,192,129,68,0,224,146,68,113,0,64,110,68,0,64,
2869 168,68,0,64,87,68,0,64,168,68,113,0,128,66,68,0,64,168,68,0,64,27,68,0,32,150,68,99,101
2876void LookAndFeel_V2::drawLevelMeter (Graphics&
g,
int width,
int height,
float level)
2878 g.setColour (Colours::white.withAlpha (0.7f));
2879 g.fillRoundedRectangle (0.0f, 0.0f, (
float)
width, (
float)
height, 3.0f);
2880 g.setColour (Colours::black.withAlpha (0.2f));
2881 g.drawRoundedRectangle (1.0f, 1.0f, (
float)
width - 2.0f, (
float)
height - 2.0f, 3.0f, 1.0f);
2883 const int totalBlocks = 7;
2885 auto w = ((float)
width - 6.0f) / (
float) totalBlocks;
2887 for (
int i = 0;
i < totalBlocks; ++
i)
2895 g.fillRoundedRectangle (3.0f + (
float)
i *
w +
w * 0.1f,
2904void LookAndFeel_V2::drawKeymapChangeButton (Graphics&
g,
int width,
int height, Button& button,
const String& keyDescription)
2906 auto textColour = button.findColour (0x100ad01 ,
true);
2910 if (button.isEnabled())
2912 auto alpha = button.isDown() ? 0.3f : (button.isOver() ? 0.15f : 0.08f);
2913 g.fillAll (textColour.withAlpha (alpha));
2915 g.setOpacity (0.3f);
2919 g.setColour (textColour);
2920 g.setFont ((
float)
height * 0.6f);
2921 g.drawFittedText (keyDescription,
2923 Justification::centred, 1);
2927 const float thickness = 7.0f;
2928 const float indent = 22.0f;
2931 p.addEllipse (0.0f, 0.0f, 100.0f, 100.0f);
2932 p.addRectangle (indent, 50.0f - thickness, 100.0f - indent * 2.0f, thickness * 2.0f);
2933 p.addRectangle (50.0f - thickness, indent, thickness * 2.0f, 50.0f - indent - thickness);
2934 p.addRectangle (50.0f - thickness, 50.0f + thickness, thickness * 2.0f, 50.0f - indent - thickness);
2935 p.setUsingNonZeroWinding (
false);
2937 g.setColour (textColour.withAlpha (
button.isDown() ? 0.7f : (
button.isOver() ? 0.5f : 0.3f)));
2938 g.fillPath (
p,
p.getTransformToScaleToFit (2.0f, 2.0f, (
float)
width - 4.0f, (
float)
height - 4.0f,
true));
2941 if (
button.hasKeyboardFocus (
false))
2943 g.setColour (textColour.withAlpha (0.4f));
2951 return Font (18.0f);
2954Justification LookAndFeel_V2::getSidePanelTitleJustification (SidePanel& panel)
2956 return panel.isPanelOnLeft() ? Justification::centredRight
2957 : Justification::centredLeft;
2960Path LookAndFeel_V2::getSidePanelDismissButtonShape (SidePanel& panel)
2966void LookAndFeel_V2::drawBevel (Graphics&
g,
const int x,
const int y,
const int width,
const int height,
2967 const int bevelThickness,
const Colour& topLeftColour,
const Colour& bottomRightColour,
2968 const bool useGradient,
const bool sharpEdgeOnOutside)
2970 if (
g.clipRegionIntersects (Rectangle<int> (
x,
y,
width,
height)))
2972 auto& context =
g.getInternalContext();
2975 for (
int i = bevelThickness; --
i >= 0;)
2977 const float op = useGradient ? (float) (sharpEdgeOnOutside ? bevelThickness -
i :
i) / (float) bevelThickness
2980 context.setFill (topLeftColour.withMultipliedAlpha (op));
2982 context.setFill (topLeftColour.withMultipliedAlpha (op * 0.75f));
2984 context.setFill (bottomRightColour.withMultipliedAlpha (op));
2986 context.setFill (bottomRightColour.withMultipliedAlpha (op * 0.75f));
2993void LookAndFeel_V2::drawShinyButtonShape (Graphics&
g,
float x,
float y,
float w,
float h,
2994 float maxCornerSize,
const Colour& baseColour,
float strokeWidth,
2995 bool flatOnLeft,
bool flatOnRight,
bool flatOnTop,
bool flatOnBottom)
noexcept
2997 if (
w <= strokeWidth * 1.1f ||
h <= strokeWidth * 1.1f)
3000 auto cs =
jmin (maxCornerSize,
w * 0.5f,
h * 0.5f);
3003 outline.addRoundedRectangle (
x,
y,
w,
h, cs, cs,
3004 ! (flatOnLeft || flatOnTop),
3005 ! (flatOnRight || flatOnTop),
3006 ! (flatOnLeft || flatOnBottom),
3007 ! (flatOnRight || flatOnBottom));
3010 baseColour.overlaidWith (
Colour (0x070000ff)), 0.0f,
y +
h,
3013 cg.addColour (0.5, baseColour.overlaidWith (
Colour (0x33ffffff)));
3014 cg.addColour (0.51, baseColour.overlaidWith (
Colour (0x110000ff)));
3016 g.setGradientFill (cg);
3017 g.fillPath (outline);
3019 g.setColour (
Colour (0x80000000));
3025 const float diameter,
const Colour& colour,
3026 const float outlineThickness)
noexcept
3028 if (diameter <= outlineThickness)
3032 p.addEllipse (
x,
y, diameter, diameter);
3036 Colours::white.overlaidWith (colour.withMultipliedAlpha (0.3f)), 0,
y + diameter,
false);
3040 g.setGradientFill (cg);
3046 g.fillEllipse (
x + diameter * 0.2f,
y + diameter * 0.05f, diameter * 0.6f, diameter * 0.4f);
3049 x + diameter * 0.5f,
y + diameter * 0.5f,
3050 Colours::black.withAlpha (0.5f * outlineThickness * colour.getFloatAlpha()),
3051 x,
y + diameter * 0.5f,
true);
3054 cg.addColour (0.8,
Colours::black.withAlpha (0.1f * outlineThickness));
3056 g.setGradientFill (cg);
3059 g.setColour (
Colours::black.withAlpha (0.5f * colour.getFloatAlpha()));
3060 g.drawEllipse (
x,
y, diameter, diameter, outlineThickness);
3065 const float x,
const float y,
const float diameter,
3066 const Colour& colour,
const float outlineThickness,
3067 const int direction)
noexcept
3069 if (diameter <= outlineThickness)
3073 p.startNewSubPath (
x + diameter * 0.5f,
y);
3074 p.lineTo (
x + diameter,
y + diameter * 0.6f);
3075 p.lineTo (
x + diameter,
y + diameter);
3076 p.lineTo (
x,
y + diameter);
3077 p.lineTo (
x,
y + diameter * 0.6f);
3081 x + diameter * 0.5f,
3082 y + diameter * 0.5f));
3086 Colours::white.overlaidWith (colour.withMultipliedAlpha (0.3f)), 0,
y + diameter,
false);
3090 g.setGradientFill (cg);
3095 x + diameter * 0.5f,
y + diameter * 0.5f,
3096 Colours::black.withAlpha (0.5f * outlineThickness * colour.getFloatAlpha()),
3097 x - diameter * 0.2f,
y + diameter * 0.5f,
true);
3100 cg.addColour (0.7,
Colours::black.withAlpha (0.07f * outlineThickness));
3102 g.setGradientFill (cg);
3105 g.setColour (
Colours::black.withAlpha (0.5f * colour.getFloatAlpha()));
3110void LookAndFeel_V2::drawGlassLozenge (Graphics&
g,
3112 const Colour& colour,
float outlineThickness,
float cornerSize,
3113 bool flatOnLeft,
bool flatOnRight,
bool flatOnTop,
bool flatOnBottom)
noexcept
3115 if (
width <= outlineThickness ||
height <= outlineThickness)
3118 auto intX = (
int)
x;
3119 auto intY = (
int)
y;
3123 auto cs = cornerSize < 0 ?
jmin (
width * 0.5f,
height * 0.5f) : cornerSize;
3124 auto edgeBlurRadius =
height * 0.75f + (
height - cs * 2.0f);
3125 auto intEdge = (
int) edgeBlurRadius;
3129 ! (flatOnLeft || flatOnTop),
3130 ! (flatOnRight || flatOnTop),
3131 ! (flatOnLeft || flatOnBottom),
3132 ! (flatOnRight || flatOnBottom));
3135 ColourGradient cg (colour.darker (0.2f), 0,
y,
3136 colour.darker (0.2f), 0,
y +
height,
false);
3138 cg.addColour (0.03, colour.withMultipliedAlpha (0.3f));
3139 cg.addColour (0.4, colour);
3140 cg.addColour (0.97, colour.withMultipliedAlpha (0.3f));
3142 g.setGradientFill (cg);
3143 g.fillPath (outline);
3146 ColourGradient cg (Colours::transparentBlack,
x + edgeBlurRadius,
y +
height * 0.5f,
3147 colour.darker (0.2f),
x,
y +
height * 0.5f,
true);
3149 cg.addColour (jlimit (0.0, 1.0, 1.0 - (cs * 0.5f) / edgeBlurRadius), Colours::transparentBlack);
3150 cg.addColour (jlimit (0.0, 1.0, 1.0 - (cs * 0.25f) / edgeBlurRadius), colour.darker (0.2f).withMultipliedAlpha (0.3f));
3152 if (! (flatOnLeft || flatOnTop || flatOnBottom))
3154 Graphics::ScopedSaveState
ss (
g);
3156 g.setGradientFill (cg);
3157 g.reduceClipRegion (intX, intY, intEdge, intH);
3158 g.fillPath (outline);
3161 if (! (flatOnRight || flatOnTop || flatOnBottom))
3163 cg.point1.setX (
x +
width - edgeBlurRadius);
3164 cg.point2.setX (
x +
width);
3166 Graphics::ScopedSaveState
ss (
g);
3168 g.setGradientFill (cg);
3169 g.reduceClipRegion (intX + intW - intEdge, intY, 2 + intEdge, intH);
3170 g.fillPath (outline);
3174 auto leftIndent = (flatOnTop || flatOnLeft) ? 0.0f : cs * 0.4f;
3175 auto rightIndent = (flatOnTop || flatOnRight) ? 0.0f : cs * 0.4f;
3178 highlight.addRoundedRectangle (
x + leftIndent,
3180 width - (leftIndent + rightIndent),
3184 ! (flatOnLeft || flatOnTop),
3185 ! (flatOnRight || flatOnTop),
3186 ! (flatOnLeft || flatOnBottom),
3187 ! (flatOnRight || flatOnBottom));
3189 g.setGradientFill (ColourGradient (colour.brighter (10.0f), 0,
y +
height * 0.06f,
3190 Colours::transparentWhite, 0,
y +
height * 0.4f,
false));
3191 g.fillPath (highlight);
3194 g.setColour (colour.darker().withMultipliedAlpha (1.5f));
3195 g.strokePath (outline, PathStrokeType (outlineThickness));
Type jmin(const Type a, const Type b)
Definition MathsFunctions.h:60
Type jmax(const Type a, const Type b)
Definition MathsFunctions.h:48
#define noexcept
Definition DistrhoDefines.h:72
int dp
Definition Spc_Cpu.h:149
static void message(int level, const char *fmt,...)
Definition adplugdb.cpp:120
bool isNotEmpty() const noexcept
Definition String.h:244
Definition juce_AlertWindow.h:45
@ textColourId
Definition juce_AlertWindow.h:444
@ outlineColourId
Definition juce_AlertWindow.h:445
@ backgroundColourId
Definition juce_AlertWindow.h:443
void addButton(const String &name, int returnValue, const KeyPress &shortcutKey1=KeyPress(), const KeyPress &shortcutKey2=KeyPress())
Definition juce_AlertWindow.cpp:111
int getNumButtons() const
Definition juce_AlertWindow.cpp:143
MessageBoxIconType getAlertType() const noexcept
Definition juce_AlertWindow.h:69
bool containsAnyExtraComponents() const
Definition juce_AlertWindow.cpp:511
Definition juce_Array.h:56
int size() const noexcept
Definition juce_Array.h:215
void add(const ElementType &newElement)
Definition juce_Array.h:418
ElementType & getReference(int index) noexcept
Definition juce_Array.h:267
Definition juce_AttributedString.h:47
@ backgroundColourId
Definition juce_BooleanPropertyComponent.h:92
@ outlineColourId
Definition juce_BooleanPropertyComponent.h:93
Definition juce_BorderSize.h:42
Definition juce_BubbleComponent.h:47
@ above
Definition juce_BubbleComponent.h:69
@ left
Definition juce_BubbleComponent.h:71
@ below
Definition juce_BubbleComponent.h:70
@ right
Definition juce_BubbleComponent.h:72
@ outlineColourId
Definition juce_BubbleComponent.h:143
@ backgroundColourId
Definition juce_BubbleComponent.h:142
Definition juce_CallOutBox.h:61
Definition juce_CaretComponent.h:36
@ caretColourId
Definition juce_CaretComponent.h:65
static juce_wchar toLowerCase(juce_wchar character) noexcept
Definition juce_CharacterFunctions.cpp:33
Definition juce_ColourGradient.h:38
static ColourGradient horizontal(Colour colour1, float x1, Colour colour2, float x2)
Definition juce_ColourGradient.cpp:90
Point< float > point2
Definition juce_ColourGradient.h:195
static ColourGradient vertical(Colour colour1, float y1, Colour colour2, float y2)
Definition juce_ColourGradient.cpp:85
Point< float > point1
Definition juce_ColourGradient.h:195
Definition juce_Colour.h:38
Colour withAlpha(uint8 newAlpha) const noexcept
Definition juce_Colour.cpp:317
static JUCE_NODISCARD Colour greyLevel(float brightness) noexcept
Definition juce_Colour.cpp:484
Colour withMultipliedAlpha(float alphaMultiplier) const noexcept
Definition juce_Colour.cpp:333
bool isOpaque() const noexcept
Definition juce_Colour.cpp:312
JUCE_NODISCARD Colour contrasting(float amount=1.0f) const noexcept
Definition juce_Colour.cpp:491
bool isTransparent() const noexcept
Definition juce_Colour.cpp:307
Colour overlaidWith(Colour foregroundColour) const noexcept
Definition juce_Colour.cpp:343
Definition juce_ComboBox.h:49
@ arrowColourId
Definition juce_ComboBox.h:360
@ outlineColourId
Definition juce_ComboBox.h:358
@ focusedOutlineColourId
Definition juce_ComboBox.h:361
@ textColourId
Definition juce_ComboBox.h:357
@ buttonColourId
Definition juce_ComboBox.h:359
@ backgroundColourId
Definition juce_ComboBox.h:356
Definition juce_Component.h:36
bool isColourSpecified(int colourID) const
Definition juce_Component.cpp:2231
int getHeight() const noexcept
Definition juce_Component.h:274
int getX() const noexcept
Definition juce_Component.h:259
void setTopRightPosition(int x, int y)
Definition juce_Component.cpp:1267
void addAndMakeVisible(Component *child, int zOrder=-1)
Definition juce_Component.cpp:1554
bool hasKeyboardFocus(bool trueIfChildIsFocused) const
Definition juce_Component.cpp:3086
void setBounds(int x, int y, int width, int height)
Definition juce_Component.cpp:1147
void setSize(int newWidth, int newHeight)
Definition juce_Component.cpp:1262
Colour findColour(int colourID, bool inheritFromParent=false) const
Definition juce_Component.cpp:2219
static std::unique_ptr< AccessibilityHandler > createIgnoredAccessibilityHandler(Component &)
Definition juce_Component.cpp:3292
int getWidth() const noexcept
Definition juce_Component.h:271
bool isEnabled() const noexcept
Definition juce_Component.cpp:3104
Rectangle< int > getLocalBounds() const noexcept
Definition juce_Component.cpp:2283
String getName() const noexcept
Definition juce_Component.h:76
@ windowHasDropShadow
Definition juce_ComponentPeer.h:66
@ windowAppearsOnTaskbar
Definition juce_ComponentPeer.h:50
Definition juce_ConcertinaPanel.h:40
Definition juce_DirectoryContentsDisplayComponent.h:38
@ textColourId
Definition juce_DirectoryContentsDisplayComponent.h:96
@ highlightColourId
Definition juce_DirectoryContentsDisplayComponent.h:95
@ highlightedTextColourId
Definition juce_DirectoryContentsDisplayComponent.h:97
Definition juce_DocumentWindow.h:55
@ textColourId
Definition juce_DocumentWindow.h:236
@ closeButton
Definition juce_DocumentWindow.h:66
@ maximiseButton
Definition juce_DocumentWindow.h:65
@ minimiseButton
Definition juce_DocumentWindow.h:64
Definition juce_DrawableComposite.h:43
Definition juce_Drawable.h:38
static std::unique_ptr< Drawable > createFromSVG(const XmlElement &svgDocument)
Definition juce_SVGParser.cpp:1757
void drawWithin(Graphics &g, Rectangle< float > destArea, RectanglePlacement placement, float opacity) const
Definition juce_Drawable.cpp:102
Definition juce_DrawablePath.h:40
void setPath(const Path &newPath)
Definition juce_DrawablePath.cpp:42
std::unique_ptr< Drawable > createCopy() const override
Definition juce_DrawablePath.cpp:37
void setFill(const FillType &newFill)
Definition juce_DrawableShape.cpp:50
Definition juce_FileBrowserComponent.h:45
@ currentPathBoxTextColourId
Definition juce_FileBrowserComponent.h:226
@ filenameBoxBackgroundColourId
Definition juce_FileBrowserComponent.h:228
@ currentPathBoxBackgroundColourId
Definition juce_FileBrowserComponent.h:225
@ filenameBoxTextColourId
Definition juce_FileBrowserComponent.h:229
@ currentPathBoxArrowColourId
Definition juce_FileBrowserComponent.h:227
@ titleTextColourId
Definition juce_FileChooserDialogBox.h:142
Definition juce_File.h:45
Definition juce_FilePreviewComponent.h:44
@ backgroundColourId
Definition juce_FileSearchPathListComponent.h:70
Definition juce_FilenameComponent.h:71
Definition juce_Font.h:42
JUCE_NODISCARD Font withHeight(float height) const
Definition juce_Font.cpp:549
void setUnderline(bool shouldBeUnderlined)
Definition juce_Font.cpp:723
float getHeight() const noexcept
Definition juce_Font.cpp:735
int getStringWidth(const String &text) const
Definition juce_Font.cpp:742
void setHorizontalScale(float scaleFactor)
Definition juce_Font.cpp:671
JUCE_NODISCARD Font boldened() const
Definition juce_Font.cpp:702
@ bold
Definition juce_Font.h:51
void setHeight(float newHeight)
Definition juce_Font.cpp:568
Definition juce_GlyphArrangement.h:117
void createPath(Path &path) const
Definition juce_GlyphArrangement.cpp:748
void addFittedText(const Font &font, const String &text, float x, float y, float width, float height, Justification layout, int maximumLinesToUse, float minimumHorizontalScale=0.0f)
Definition juce_GlyphArrangement.cpp:310
Definition juce_GraphicsContext.h:660
Definition juce_GraphicsContext.h:45
Definition juce_GroupComponent.h:38
@ textColourId
Definition juce_GroupComponent.h:81
@ outlineColourId
Definition juce_GroupComponent.h:80
Definition juce_ImageEffectFilter.h:43
Definition juce_Image.h:58
int getWidth() const noexcept
Definition juce_Image.cpp:271
int getHeight() const noexcept
Definition juce_Image.cpp:272
bool isNull() const noexcept
Definition juce_Image.h:155
bool isValid() const noexcept
Definition juce_Image.h:147
@ ARGB
Definition juce_Image.h:67
Definition juce_Justification.h:41
@ centredRight
Definition juce_Justification.h:148
@ centred
Definition juce_Justification.h:138
@ centredLeft
Definition juce_Justification.h:143
@ horizontallyCentred
Definition juce_Justification.h:115
@ right
Definition juce_Justification.h:111
@ bottomLeft
Definition juce_Justification.h:173
Definition juce_KeyPress.h:40
static const int escapeKey
Definition juce_KeyPress.h:190
static const int returnKey
Definition juce_KeyPress.h:191
Definition juce_Label.h:41
@ outlineColourId
Definition juce_Label.h:108
@ backgroundColourId
Definition juce_Label.h:106
@ textColourId
Definition juce_Label.h:107
Label(const String &componentName=String(), const String &labelText=String())
Definition juce_Label.cpp:29
Definition juce_Line.h:47
@ textColourId
Definition juce_ListBox.h:498
@ backgroundColourId
Definition juce_ListBox.h:494
@ outlineColourId
Definition juce_ListBox.h:496
Definition juce_LookAndFeel_V2.cpp:1603
void mouseWheelMove(const MouseEvent &, const MouseWheelDetails &) override
Definition juce_LookAndFeel_V2.cpp:1607
std::unique_ptr< AccessibilityHandler > createAccessibilityHandler() override
Definition juce_LookAndFeel_V2.cpp:1609
SliderLabelComp()
Definition juce_LookAndFeel_V2.cpp:1605
void drawButtonBackground(Graphics &, Button &, const Colour &backgroundColour, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) override
Definition juce_LookAndFeel_V2.cpp:245
ImageEffectFilter * getSliderEffect(Slider &) override
Definition juce_LookAndFeel_V2.cpp:1639
void drawSpinningWaitAnimation(Graphics &, const Colour &colour, int x, int y, int w, int h) override
Definition juce_LookAndFeel_V2.cpp:618
void drawRotarySlider(Graphics &, int x, int y, int width, int height, float sliderPosProportional, float rotaryStartAngle, float rotaryEndAngle, Slider &) override
Definition juce_LookAndFeel_V2.cpp:1530
void drawTabAreaBehindFrontButton(TabbedButtonBar &, Graphics &, int w, int h) override
Definition juce_LookAndFeel_V2.cpp:2380
void drawTabbedButtonBarBackground(TabbedButtonBar &, Graphics &) override
Definition juce_LookAndFeel_V2.cpp:2378
void drawMenuBarBackground(Graphics &, int width, int height, bool isMouseOverBar, MenuBarComponent &) override
Definition juce_LookAndFeel_V2.cpp:1111
std::unique_ptr< DropShadower > createDropShadowerForComponent(Component &) override
Definition juce_LookAndFeel_V2.cpp:2066
void preparePopupMenuWindow(Component &) override
Definition juce_LookAndFeel_V2.cpp:1163
void drawConcertinaPanelHeader(Graphics &, const Rectangle< int > &area, bool isMouseOver, bool isMouseDown, ConcertinaPanel &, Component &panel) override
Definition juce_LookAndFeel_V2.cpp:1776
void drawProgressBar(Graphics &, ProgressBar &, int width, int height, double progress, const String &textToShow) override
Definition juce_LookAndFeel_V2.cpp:559
void drawPopupMenuBackgroundWithOptions(Graphics &, int width, int height, const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:930
BorderSize< int > getLabelBorderSize(Label &) override
Definition juce_LookAndFeel_V2.cpp:1353
void drawToggleButton(Graphics &, ToggleButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) override
Definition juce_LookAndFeel_V2.cpp:345
float getCallOutBoxCornerSize(const CallOutBox &) override
Definition juce_LookAndFeel_V2.cpp:2648
void drawStretchableLayoutResizerBar(Graphics &, int w, int h, bool isVerticalBar, bool isMouseOver, bool isMouseDragging) override
Definition juce_LookAndFeel_V2.cpp:2091
PopupMenu::Options getOptionsForComboBoxPopupMenu(ComboBox &, Label &) override
Definition juce_LookAndFeel_V2.cpp:1294
Font getSliderPopupFont(Slider &) override
Definition juce_LookAndFeel_V2.cpp:1644
int getAlertWindowButtonHeight() override
Definition juce_LookAndFeel_V2.cpp:537
static void drawGlassLozenge(Graphics &, float x, float y, float width, float height, const Colour &, float outlineThickness, float cornerSize, bool flatOnLeft, bool flatOnRight, bool flatOnTop, bool flatOnBottom) noexcept
Definition juce_LookAndFeel_V2.cpp:3090
void drawScrollbar(Graphics &, ScrollBar &, int x, int y, int width, int height, bool isScrollbarVertical, int thumbStartPosition, int thumbSize, bool isMouseOver, bool isMouseDown) override
Definition juce_LookAndFeel_V2.cpp:691
void layoutFileBrowserComponent(FileBrowserComponent &, DirectoryContentsDisplayComponent *, FilePreviewComponent *, ComboBox *currentPathBox, TextEditor *filenameBox, Button *goUpButton) override
Definition juce_LookAndFeel_V2.cpp:2754
bool shouldPopupMenuScaleWithTargetComponent(const PopupMenu::Options &options) override
Definition juce_LookAndFeel_V2.cpp:1165
void fillTextEditorBackground(Graphics &, int width, int height, TextEditor &) override
Definition juce_LookAndFeel_V2.cpp:1184
void drawTreeviewPlusMinusBox(Graphics &, const Rectangle< float > &area, Colour backgroundColour, bool isOpen, bool isMouseOver) override
Definition juce_LookAndFeel_V2.cpp:823
void drawPopupMenuColumnSeparatorWithOptions(Graphics &g, const Rectangle< int > &bounds, const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:1174
void changeToggleButtonWidthToFitText(ToggleButton &) override
Definition juce_LookAndFeel_V2.cpp:376
Font getSidePanelTitleFont(SidePanel &) override
Definition juce_LookAndFeel_V2.cpp:2929
void drawComboBox(Graphics &, int width, int height, bool isMouseButtonDown, int buttonX, int buttonY, int buttonW, int buttonH, ComboBox &) override
Definition juce_LookAndFeel_V2.cpp:1222
void getIdealPopupMenuItemSize(const String &text, bool isSeparator, int standardMenuItemHeight, int &idealWidth, int &idealHeight) override
Definition juce_LookAndFeel_V2.cpp:880
void paintToolbarButtonLabel(Graphics &, int x, int y, int width, int height, const String &text, ToolbarItemComponent &) override
Definition juce_LookAndFeel_V2.cpp:2559
void drawMenuBarItem(Graphics &, int width, int height, int itemIndex, const String &itemText, bool isMouseOverItem, bool isMenuOpen, bool isMouseOverBar, MenuBarComponent &) override
Definition juce_LookAndFeel_V2.cpp:1134
void drawPopupMenuBackground(Graphics &, int width, int height) override
Definition juce_LookAndFeel_V2.cpp:914
void drawTableHeaderBackground(Graphics &, TableHeaderComponent &) override
Definition juce_LookAndFeel_V2.cpp:2466
int getSliderThumbRadius(Slider &) override
Definition juce_LookAndFeel_V2.cpp:1523
void positionComboBoxText(ComboBox &, Label &) override
Definition juce_LookAndFeel_V2.cpp:1285
Font getAlertWindowFont() override
Definition juce_LookAndFeel_V2.cpp:553
void fillResizableWindowBackground(Graphics &, int w, int h, const BorderSize< int > &, ResizableWindow &) override
Definition juce_LookAndFeel_V2.cpp:1861
void drawScrollbarButton(Graphics &, ScrollBar &, int width, int height, int buttonDirection, bool isScrollbarVertical, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) override
Definition juce_LookAndFeel_V2.cpp:652
void drawLasso(Graphics &, Component &) override
Definition juce_LookAndFeel_V2.cpp:2521
Font getMenuBarFont(MenuBarComponent &, int itemIndex, const String &itemText) override
Definition juce_LookAndFeel_V2.cpp:1123
void drawAlertBox(Graphics &, AlertWindow &, const Rectangle< int > &textArea, TextLayout &) override
Definition juce_LookAndFeel_V2.cpp:451
AlertWindow * createAlertWindow(const String &title, const String &message, const String &button1, const String &button2, const String &button3, MessageBoxIconType iconType, int numButtons, Component *associatedComponent) override
Definition juce_LookAndFeel_V2.cpp:415
void drawFileBrowserRow(Graphics &, int width, int height, const File &file, const String &filename, Image *icon, const String &fileSizeDescription, const String &fileTimeDescription, bool isDirectory, bool isItemSelected, int itemIndex, DirectoryContentsDisplayComponent &) override
Definition juce_LookAndFeel_V2.cpp:2667
Component * getParentComponentForMenuOptions(const PopupMenu::Options &options) override
Definition juce_LookAndFeel_V2.cpp:1158
int getCallOutBoxBorderSize(const CallOutBox &) override
Definition juce_LookAndFeel_V2.cpp:2643
std::unique_ptr< FocusOutline > createFocusOutlineForComponent(Component &) override
Definition juce_LookAndFeel_V2.cpp:2071
Font getTextButtonFont(TextButton &, int buttonHeight) override
Definition juce_LookAndFeel_V2.cpp:280
void drawTableHeaderColumn(Graphics &, TableHeaderComponent &, const String &columnName, int columnId, int width, int height, bool isMouseOver, bool isMouseDown, int columnFlags) override
Definition juce_LookAndFeel_V2.cpp:2489
const Drawable * getDefaultFolderImage() override
Definition juce_LookAndFeel_V2.cpp:2800
int getDefaultMenuBarHeight() override
Definition juce_LookAndFeel_V2.cpp:2060
void drawLinearSliderBackground(Graphics &, int x, int y, int width, int height, float sliderPos, float minSliderPos, float maxSliderPos, const Slider::SliderStyle, Slider &) override
Definition juce_LookAndFeel_V2.cpp:1359
Button * createFilenameComponentBrowseButton(const String &text) override
Definition juce_LookAndFeel_V2.cpp:1754
int getTabButtonSpaceAroundImage() override
Definition juce_LookAndFeel_V2.cpp:2184
void drawButtonText(Graphics &, TextButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) override
Definition juce_LookAndFeel_V2.cpp:290
Font getComboBoxFont(ComboBox &) override
Definition juce_LookAndFeel_V2.cpp:1275
void getIdealPopupMenuItemSizeWithOptions(const String &text, bool isSeparator, int standardMenuItemHeight, int &idealWidth, int &idealHeight, const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:900
Button * createFileBrowserGoUpButton() override
Definition juce_LookAndFeel_V2.cpp:2738
Rectangle< int > getPropertyComponentContentPosition(PropertyComponent &) override
Definition juce_LookAndFeel_V2.cpp:2610
Rectangle< int > getTooltipBounds(const String &tipText, Point< int > screenPos, Rectangle< int > parentArea) override
Definition juce_LookAndFeel_V2.cpp:1727
Font getAlertWindowMessageFont() override
Definition juce_LookAndFeel_V2.cpp:548
void drawTooltip(Graphics &, const String &text, int width, int height) override
Definition juce_LookAndFeel_V2.cpp:1740
bool isProgressBarOpaque(ProgressBar &) override
Definition juce_LookAndFeel_V2.cpp:642
void drawPopupMenuUpDownArrow(Graphics &, int width, int height, bool isScrollUpArrow) override
Definition juce_LookAndFeel_V2.cpp:938
void drawTabButtonText(TabBarButton &, Graphics &, bool isMouseOver, bool isMouseDown) override
Definition juce_LookAndFeel_V2.cpp:2316
void drawPropertyComponentLabel(Graphics &, int width, int height, PropertyComponent &) override
Definition juce_LookAndFeel_V2.cpp:2596
Button * createSliderButton(Slider &, bool isIncrement) override
Definition juce_LookAndFeel_V2.cpp:1597
Label * createComboBoxTextBox(ComboBox &) override
Definition juce_LookAndFeel_V2.cpp:1280
void drawBubble(Graphics &, BubbleComponent &, const Point< float > &tip, const Rectangle< float > &body) override
Definition juce_LookAndFeel_V2.cpp:859
void drawLinearSliderThumb(Graphics &, int x, int y, int width, int height, float sliderPos, float minSliderPos, float maxSliderPos, const Slider::SliderStyle, Slider &) override
Definition juce_LookAndFeel_V2.cpp:1401
void fillTabButtonShape(TabBarButton &, Graphics &, const Path &, bool isMouseOver, bool isMouseDown) override
Definition juce_LookAndFeel_V2.cpp:2293
int getScrollbarButtonSize(ScrollBar &) override
Definition juce_LookAndFeel_V2.cpp:816
std::unique_ptr< Drawable > documentImage
Definition juce_LookAndFeel_V2.h:414
int getPopupMenuColumnSeparatorWidthWithOptions(const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:1178
int getTextButtonWidthToFitText(TextButton &, int buttonHeight) override
Definition juce_LookAndFeel_V2.cpp:285
int getPopupMenuBorderSize() override
Definition juce_LookAndFeel_V2.cpp:1167
LookAndFeel_V2()
Definition juce_LookAndFeel_V2.cpp:61
Button * createTabBarExtrasButton() override
Definition juce_LookAndFeel_V2.cpp:2426
Rectangle< int > getTabButtonExtraComponentBounds(const TabBarButton &, Rectangle< int > &textArea, Component &extraComp) override
Definition juce_LookAndFeel_V2.cpp:2201
void drawShinyButtonShape(Graphics &, float x, float y, float w, float h, float maxCornerSize, const Colour &, float strokeWidth, bool flatOnLeft, bool flatOnRight, bool flatOnTop, bool flatOnBottom) noexcept
Definition juce_LookAndFeel_V2.cpp:2973
static void drawGlassPointer(Graphics &, float x, float y, float diameter, const Colour &, float outlineThickness, int direction) noexcept
Definition juce_LookAndFeel_V2.cpp:3044
bool areLinesDrawnForTreeView(TreeView &) override
Definition juce_LookAndFeel_V2.cpp:848
Label * createSliderTextBox(Slider &) override
Definition juce_LookAndFeel_V2.cpp:1615
void drawLabel(Graphics &, Label &) override
Definition juce_LookAndFeel_V2.cpp:1325
ImageEffectFilter * getScrollbarEffect() override
Definition juce_LookAndFeel_V2.cpp:801
AttributedString createFileChooserHeaderText(const String &title, const String &instructions) override
Definition juce_LookAndFeel_V2.cpp:2654
void drawTabButton(TabBarButton &, Graphics &, bool isMouseOver, bool isMouseDown) override
Definition juce_LookAndFeel_V2.cpp:2363
void drawPopupMenuUpDownArrowWithOptions(Graphics &, int width, int height, bool isScrollUpArrow, const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:963
void drawPropertyPanelSectionHeader(Graphics &, const String &name, bool isOpen, int width, int height) override
Definition juce_LookAndFeel_V2.cpp:2575
Path getCrossShape(float height) override
Definition juce_LookAndFeel_V2.cpp:2839
int getSliderPopupPlacement(Slider &) override
Definition juce_LookAndFeel_V2.cpp:1649
Array< int > getWidthsForTextButtons(AlertWindow &, const Array< TextButton * > &) override
Definition juce_LookAndFeel_V2.cpp:524
int getPopupMenuBorderSizeWithOptions(const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:1169
bool areScrollbarButtonsVisible() override
Definition juce_LookAndFeel_V2.cpp:647
void drawDrawableButton(Graphics &, DrawableButton &, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) override
Definition juce_LookAndFeel_V2.cpp:387
static void drawBevel(Graphics &, int x, int y, int width, int height, int bevelThickness, const Colour &topLeftColour=Colours::white, const Colour &bottomRightColour=Colours::black, bool useGradient=true, bool sharpEdgeOnOutside=true)
Definition juce_LookAndFeel_V2.cpp:2946
void drawTickBox(Graphics &, Component &, float x, float y, float w, float h, bool ticked, bool isEnabled, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) override
Definition juce_LookAndFeel_V2.cpp:313
void drawPropertyComponentBackground(Graphics &, int width, int height, PropertyComponent &) override
Definition juce_LookAndFeel_V2.cpp:2590
void drawPopupMenuItemWithOptions(Graphics &, const Rectangle< int > &area, bool isHighlighted, const PopupMenu::Item &item, const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:1064
int getMinimumScrollbarThumbSize(ScrollBar &) override
Definition juce_LookAndFeel_V2.cpp:806
int getDefaultScrollbarWidth() override
Definition juce_LookAndFeel_V2.cpp:811
void drawLinearSlider(Graphics &, int x, int y, int width, int height, float sliderPos, float minSliderPos, float maxSliderPos, const Slider::SliderStyle, Slider &) override
Definition juce_LookAndFeel_V2.cpp:1489
void positionDocumentWindowButtons(DocumentWindow &, int titleBarX, int titleBarY, int titleBarW, int titleBarH, Button *minimiseButton, Button *maximiseButton, Button *closeButton, bool positionTitleBarButtonsOnLeft) override
Definition juce_LookAndFeel_V2.cpp:2028
void paintToolbarBackground(Graphics &, int width, int height, Toolbar &) override
Definition juce_LookAndFeel_V2.cpp:2532
Button * createToolbarMissingItemsButton(Toolbar &) override
Definition juce_LookAndFeel_V2.cpp:2544
void drawCornerResizer(Graphics &, int w, int h, bool isMouseOver, bool isMouseDragging) override
Definition juce_LookAndFeel_V2.cpp:1817
void drawImageButton(Graphics &, Image *, int imageX, int imageY, int imageW, int imageH, const Colour &overlayColour, float imageOpacity, ImageButton &) override
Definition juce_LookAndFeel_V2.cpp:1790
void drawGroupComponentOutline(Graphics &, int w, int h, const String &text, const Justification &, GroupComponent &) override
Definition juce_LookAndFeel_V2.cpp:2116
void drawCallOutBoxBackground(CallOutBox &, Graphics &, const Path &path, Image &cachedImage) override
Definition juce_LookAndFeel_V2.cpp:2622
void drawDocumentWindowTitleBar(DocumentWindow &, Graphics &, int w, int h, int titleSpaceX, int titleSpaceW, const Image *icon, bool drawTitleTextOnLeft) override
Definition juce_LookAndFeel_V2.cpp:1872
Path getTickShape(float height) override
Definition juce_LookAndFeel_V2.cpp:2825
void drawTextEditorOutline(Graphics &, int width, int height, TextEditor &) override
Definition juce_LookAndFeel_V2.cpp:1189
void drawResizableWindowBorder(Graphics &, int w, int h, const BorderSize< int > &border, ResizableWindow &) override
Definition juce_LookAndFeel_V2.cpp:1867
void drawResizableFrame(Graphics &, int w, int h, const BorderSize< int > &) override
Definition juce_LookAndFeel_V2.cpp:1841
void layoutFilenameComponent(FilenameComponent &, ComboBox *filenameBox, Button *browseButton) override
Definition juce_LookAndFeel_V2.cpp:1759
void drawPopupMenuSectionHeaderWithOptions(Graphics &, const Rectangle< int > &area, const String §ionName, const PopupMenu::Options &) override
Definition juce_LookAndFeel_V2.cpp:1098
void drawComboBoxTextWhenNothingSelected(Graphics &, ComboBox &, Label &) override
Definition juce_LookAndFeel_V2.cpp:1304
int getTreeViewIndentSize(TreeView &) override
Definition juce_LookAndFeel_V2.cpp:853
Font getTabButtonFont(TabBarButton &, float height) override
Definition juce_LookAndFeel_V2.cpp:2311
Font getAlertWindowTitleFont() override
Definition juce_LookAndFeel_V2.cpp:542
Font getLabelFont(Label &) override
Definition juce_LookAndFeel_V2.cpp:1320
int getTabButtonBestWidth(TabBarButton &, int tabDepth) override
Definition juce_LookAndFeel_V2.cpp:2189
Slider::SliderLayout getSliderLayout(Slider &) override
Definition juce_LookAndFeel_V2.cpp:1658
Button * createDocumentWindowButton(int buttonType) override
Definition juce_LookAndFeel_V2.cpp:1987
void drawPopupMenuItem(Graphics &, const Rectangle< int > &area, bool isSeparator, bool isActive, bool isHighlighted, bool isTicked, bool hasSubMenu, const String &text, const String &shortcutKeyText, const Drawable *icon, const Colour *textColour) override
Definition juce_LookAndFeel_V2.cpp:971
void paintToolbarButtonBackground(Graphics &, int width, int height, bool isMouseOver, bool isMouseDown, ToolbarItemComponent &) override
Definition juce_LookAndFeel_V2.cpp:2549
int getMenuWindowFlags() override
Definition juce_LookAndFeel_V2.cpp:1106
~LookAndFeel_V2() override
Definition juce_LookAndFeel_V2.cpp:242
void createTabButtonShape(TabBarButton &, Path &, bool isMouseOver, bool isMouseDown) override
Definition juce_LookAndFeel_V2.cpp:2233
static void drawGlassSphere(Graphics &, float x, float y, float diameter, const Colour &, float outlineThickness) noexcept
Definition juce_LookAndFeel_V2.cpp:3004
std::unique_ptr< Drawable > folderImage
Definition juce_LookAndFeel_V2.h:414
const Drawable * getDefaultDocumentFileImage() override
Definition juce_LookAndFeel_V2.cpp:2808
int getMenuBarItemWidth(MenuBarComponent &, int itemIndex, const String &itemText) override
Definition juce_LookAndFeel_V2.cpp:1128
int getTabButtonOverlap(int tabDepth) override
Definition juce_LookAndFeel_V2.cpp:2179
Font getPopupMenuFont() override
Definition juce_LookAndFeel_V2.cpp:875
CaretComponent * createCaretComponent(Component *keyFocusOwner) override
Definition juce_LookAndFeel_V2.cpp:1216
void drawPopupMenuSectionHeader(Graphics &, const Rectangle< int > &area, const String §ionName) override
Definition juce_LookAndFeel_V2.cpp:1086
int getAlertBoxWindowFlags() override
Definition juce_LookAndFeel_V2.cpp:518
int getPropertyPanelSectionHeaderHeight(const String §ionTitle) override
Definition juce_LookAndFeel_V2.cpp:2616
bool isColourSpecified(int colourId) const noexcept
Definition juce_LookAndFeel.cpp:100
void setColour(int colourId, Colour colour) noexcept
Definition juce_LookAndFeel.cpp:89
Colour findColour(int colourId) const noexcept
Definition juce_LookAndFeel.cpp:77
Definition juce_MouseEvent.h:39
Definition juce_Path.h:65
void addRoundedRectangle(float x, float y, float width, float height, float cornerSize)
Definition juce_Path.cpp:412
void startNewSubPath(float startX, float startY)
Definition juce_Path.cpp:216
void addPieSegment(float x, float y, float width, float height, float fromRadians, float toRadians, float innerCircleProportionalSize)
Definition juce_Path.cpp:525
void addTriangle(float x1, float y1, float x2, float y2, float x3, float y3)
Definition juce_Path.cpp:417
void addEllipse(float x, float y, float width, float height)
Definition juce_Path.cpp:446
AffineTransform getTransformToScaleToFit(float x, float y, float width, float height, bool preserveProportions, Justification justificationType=Justification::centred) const
Definition juce_Path.cpp:885
void addRectangle(float x, float y, float width, float height)
Definition juce_Path.cpp:323
void applyTransform(const AffineTransform &transform) noexcept
Definition juce_Path.cpp:821
void closeSubPath()
Definition juce_Path.cpp:292
void lineTo(float endX, float endY)
Definition juce_Path.cpp:233
Path createPathWithRoundedCorners(float cornerRadius) const
Definition juce_Path.cpp:1075
void addLineSegment(Line< float > line, float lineThickness)
Definition juce_Path.cpp:581
void addArrow(Line< float > line, float lineThickness, float arrowheadWidth, float arrowheadLength)
Definition juce_Path.cpp:593
void setUsingNonZeroWinding(bool isNonZeroWinding) noexcept
Definition juce_Path.cpp:168
Definition juce_PathStrokeType.h:42
void createStrokedPath(Path &destPath, const Path &sourcePath, const AffineTransform &transform=AffineTransform(), float extraAccuracy=1.0f) const
Definition juce_PathStrokeType.cpp:655
Definition juce_Point.h:42
ValueType y
Definition juce_Point.h:247
ValueType x
Definition juce_Point.h:246
Definition juce_ProgressBar.h:51
@ backgroundColourId
Definition juce_ProgressBar.h:95
@ foregroundColourId
Definition juce_ProgressBar.h:96
Definition juce_PropertyComponent.h:49
@ labelTextColourId
Definition juce_PropertyComponent.h:118
@ backgroundColourId
Definition juce_PropertyComponent.h:117
Definition juce_Rectangle.h:67
ValueType getRight() const noexcept
Definition juce_Rectangle.h:139
void setHeight(ValueType newHeight) noexcept
Definition juce_Rectangle.h:204
Rectangle< float > toFloat() const noexcept
Definition juce_Rectangle.h:873
Rectangle removeFromRight(ValueType amountToRemove) noexcept
Definition juce_Rectangle.h:542
ValueType getCentreX() const noexcept
Definition juce_Rectangle.h:145
Rectangle removeFromBottom(ValueType amountToRemove) noexcept
Definition juce_Rectangle.h:559
ValueType getHeight() const noexcept
Definition juce_Rectangle.h:136
ValueType getCentreY() const noexcept
Definition juce_Rectangle.h:148
Rectangle constrainedWithin(Rectangle areaToFitWithin) const noexcept
Definition juce_Rectangle.h:798
void setWidth(ValueType newWidth) noexcept
Definition juce_Rectangle.h:201
ValueType getBottom() const noexcept
Definition juce_Rectangle.h:142
ValueType getX() const noexcept
Definition juce_Rectangle.h:127
Rectangle removeFromTop(ValueType amountToRemove) noexcept
Definition juce_Rectangle.h:510
Rectangle getUnion(Rectangle other) const noexcept
Definition juce_Rectangle.h:719
ValueType getWidth() const noexcept
Definition juce_Rectangle.h:133
void setX(ValueType newX) noexcept
Definition juce_Rectangle.h:195
Rectangle reduced(ValueType deltaX, ValueType deltaY) const noexcept
Definition juce_Rectangle.h:485
Rectangle removeFromLeft(ValueType amountToRemove) noexcept
Definition juce_Rectangle.h:526
void setY(ValueType newY) noexcept
Definition juce_Rectangle.h:198
ValueType getY() const noexcept
Definition juce_Rectangle.h:130
void reduce(ValueType deltaX, ValueType deltaY) noexcept
Definition juce_Rectangle.h:474
Rectangle expanded(ValueType deltaX, ValueType deltaY) const noexcept
Definition juce_Rectangle.h:451
void setBounds(ValueType newX, ValueType newY, ValueType newWidth, ValueType newHeight) noexcept
Definition juce_Rectangle.h:191
Definition juce_RectanglePlacement.h:40
AffineTransform getTransformToFit(const Rectangle< float > &source, const Rectangle< float > &destination) const noexcept
Definition juce_RectanglePlacement.cpp:82
@ onlyReduceInSize
Definition juce_RectanglePlacement.h:106
@ centred
Definition juce_RectanglePlacement.h:119
@ stretchToFit
Definition juce_RectanglePlacement.h:90
Definition juce_ResizableWindow.h:52
@ backgroundColourId
Definition juce_ResizableWindow.h:312
Definition juce_SidePanel.h:44
@ titleTextColour
Definition juce_SidePanel.h:171
@ dismissButtonOverColour
Definition juce_SidePanel.h:174
@ dismissButtonDownColour
Definition juce_SidePanel.h:175
@ shadowBaseColour
Definition juce_SidePanel.h:172
@ backgroundColour
Definition juce_SidePanel.h:170
@ dismissButtonNormalColour
Definition juce_SidePanel.h:173
Definition juce_Slider.h:54
SliderStyle
Definition juce_Slider.h:62
@ LinearBarVertical
Definition juce_Slider.h:66
@ ThreeValueHorizontal
Definition juce_Slider.h:82
@ TwoValueHorizontal
Definition juce_Slider.h:77
@ LinearBar
Definition juce_Slider.h:65
@ LinearHorizontal
Definition juce_Slider.h:63
@ LinearVertical
Definition juce_Slider.h:64
@ ThreeValueVertical
Definition juce_Slider.h:85
@ TwoValueVertical
Definition juce_Slider.h:79
@ textBoxBackgroundColourId
Definition juce_Slider.h:874
@ textBoxTextColourId
Definition juce_Slider.h:873
@ rotarySliderFillColourId
Definition juce_Slider.h:870
@ textBoxHighlightColourId
Definition juce_Slider.h:875
@ textBoxOutlineColourId
Definition juce_Slider.h:876
@ trackColourId
Definition juce_Slider.h:869
@ backgroundColourId
Definition juce_Slider.h:866
@ rotarySliderOutlineColourId
Definition juce_Slider.h:871
@ thumbColourId
Definition juce_Slider.h:867
@ TextBoxRight
Definition juce_Slider.h:97
@ NoTextBox
Definition juce_Slider.h:95
@ TextBoxAbove
Definition juce_Slider.h:98
@ TextBoxBelow
Definition juce_Slider.h:99
@ TextBoxLeft
Definition juce_Slider.h:96
Definition juce_String.h:53
bool isEmpty() const noexcept
Definition juce_String.h:310
static String charToString(juce_wchar character)
Definition juce_String.cpp:359
bool isNotEmpty() const noexcept
Definition juce_String.h:316
@ outlineColourId
Definition juce_TabbedComponent.h:189
@ backgroundColourId
Definition juce_TabbedComponent.h:188
Definition juce_TextButton.h:39
@ textColourOnId
Definition juce_TextButton.h:80
@ buttonColourId
Definition juce_TextButton.h:73
@ buttonOnColourId
Definition juce_TextButton.h:76
@ textColourOffId
Definition juce_TextButton.h:79
Definition juce_TextEditor.h:43
@ backgroundColourId
Definition juce_TextEditor.h:209
@ highlightColourId
Definition juce_TextEditor.h:217
@ textColourId
Definition juce_TextEditor.h:212
@ outlineColourId
Definition juce_TextEditor.h:223
@ highlightedTextColourId
Definition juce_TextEditor.h:221
@ focusedOutlineColourId
Definition juce_TextEditor.h:226
@ shadowColourId
Definition juce_TextEditor.h:229
bool isReadOnly() const noexcept
Definition juce_TextEditor.cpp:1042
@ decimalKeyboard
Definition juce_TextInputTarget.h:84
Definition juce_TextLayout.h:41
void createLayoutWithBalancedLineLengths(const AttributedString &, float maxWidth)
Definition juce_TextLayout.cpp:261
float getWidth() const noexcept
Definition juce_TextLayout.h:223
void draw(Graphics &, Rectangle< float > area) const
Definition juce_TextLayout.cpp:197
float getHeight() const noexcept
Definition juce_TextLayout.h:226
@ backgroundColourId
Definition juce_TextPropertyComponent.h:121
@ outlineColourId
Definition juce_TextPropertyComponent.h:123
@ textColourId
Definition juce_TextPropertyComponent.h:122
static uint32 getMillisecondCounter() noexcept
Definition juce_Time.cpp:241
Definition juce_TreeView.h:657
@ dragAndDropIndicatorColourId
Definition juce_TreeView.h:872
@ oddItemsColourId
Definition juce_TreeView.h:874
@ linesColourId
Definition juce_TreeView.h:871
@ evenItemsColourId
Definition juce_TreeView.h:875
@ selectedItemBackgroundColourId
Definition juce_TreeView.h:873
@ backgroundColourId
Definition juce_TreeView.h:870
UINT_D64 w
Definition inflate.c:942
int * l
Definition inflate.c:1579
struct huft * t
Definition inflate.c:943
int y
Definition inflate.c:1588
unsigned d
Definition inflate.c:940
int g
Definition inflate.c:1573
register unsigned i
Definition inflate.c:1575
static ZCONST unsigned border[]
Definition inflate.c:749
unsigned s
Definition inflate.c:1555
unsigned x[BMAX+1]
Definition inflate.c:1586
unsigned f
Definition inflate.c:1572
static char filename[]
Definition features.c:5
static const char * title
Definition pugl.h:1747
static const char * name
Definition pugl.h:1582
static int int height
Definition pugl.h:1594
static int width
Definition pugl.h:1593
JSAMPIMAGE data
Definition jpeglib.h:945
#define TRANS(stringLiteral)
Definition juce_LocalisedStrings.h:208
static int JUCE_CDECL comp(const void *a, const void *b)
Definition lsp.c:298
std::string indent(const std::string &src, const std::string &indent)
Indent a string by another string (prefix each line).
Definition utils.cpp:135
const Colour transparentBlack
Definition juce_Colours.h:40
const Colour lightgrey
Definition juce_Colours.h:111
const Colour red
Definition juce_Colours.h:157
const Colour grey
Definition juce_Colours.h:93
const Colour black
Definition juce_Colours.h:50
const Colour darkgrey
Definition juce_Colours.h:67
const Colour lightblue
Definition juce_Colours.h:106
const Colour transparentWhite
Definition juce_Colours.h:41
const Colour white
Definition juce_Colours.h:180
const Colour blue
Definition juce_Colours.h:52
const Colour yellow
Definition juce_Colours.h:182
Definition juce_LookAndFeel_V2.cpp:30
static Colour createBaseColour(Colour buttonColour, bool hasKeyboardFocus, bool shouldDrawButtonAsHighlighted, bool shouldDrawButtonAsDown) noexcept
Definition juce_LookAndFeel_V2.cpp:31
static TextLayout layoutTooltipText(const String &text, Colour colour) noexcept
Definition juce_LookAndFeel_V2.cpp:45
Definition carla_juce.cpp:31
static Path createPathFromData(float height, const unsigned char *data, size_t size)
Definition juce_LookAndFeel_V2.cpp:2817
constexpr Type jmin(Type a, Type b)
Definition juce_MathsFunctions.h:106
unsigned int uint32
Definition juce_MathsFunctions.h:45
constexpr Type jmax(Type a, Type b)
Definition juce_MathsFunctions.h:94
MessageBoxIconType
Definition juce_MessageBoxOptions.h:31
@ WarningIcon
Definition juce_MessageBoxOptions.h:35
@ NoIcon
Definition juce_MessageBoxOptions.h:32
@ InfoIcon
Definition juce_MessageBoxOptions.h:37
Type jlimit(Type lowerLimit, Type upperLimit, Type valueToConstrain) noexcept
Definition juce_MathsFunctions.h:262
static std::unique_ptr< Drawable > createDrawableFromSVG(const char *data)
Definition juce_LookAndFeel_V2.cpp:2793
wchar_t juce_wchar
Definition juce_CharacterFunctions.h:42
std::unique_ptr< XmlElement > parseXML(const String &textToParse)
Definition juce_XmlDocument.cpp:41
unsigned char uint8
Definition juce_MathsFunctions.h:37
int roundToInt(const FloatType value) noexcept
Definition juce_MathsFunctions.h:465
@ window
Definition juce_AccessibilityRole.h:63
@ slider
Definition juce_AccessibilityRole.h:43
@ menuBar
Definition juce_AccessibilityRole.h:48
@ image
Definition juce_AccessibilityRole.h:42
@ progressBar
Definition juce_AccessibilityRole.h:60
@ button
Definition juce_AccessibilityRole.h:38
@ label
Definition juce_AccessibilityRole.h:44
@ group
Definition juce_AccessibilityRole.h:61
constexpr int numElementsInArray(Type(&)[N]) noexcept
Definition juce_MathsFunctions.h:344
png_uint_32 length
Definition png.c:2247
Definition juce_DropShadowEffect.h:36
void drawForPath(Graphics &g, const Path &path) const
Definition juce_DropShadowEffect.cpp:92
Definition juce_FocusOutline.h:54
static constexpr FloatType halfPi
Definition juce_MathsFunctions.h:388
static constexpr FloatType twoPi
Definition juce_MathsFunctions.h:385
static constexpr FloatType pi
Definition juce_MathsFunctions.h:382
Definition juce_MouseEvent.h:392
Definition juce_Slider.h:884
Rectangle< int > textBoxBounds
Definition juce_Slider.h:886
Rectangle< int > sliderBounds
Definition juce_Slider.h:885
const char * text
Definition swell-functions.h:167
int n
Definition crypt.c:458
uch * p
Definition crypt.c:594
return c
Definition crypt.c:175
int r
Definition crypt.c:458
uch h[RAND_HEAD_LEN]
Definition crypt.c:459
typedef int(UZ_EXP MsgFn)()
ss
Definition zipinfo.c:2292