Preset browser LAF Dialog modal
-
Hi mates, is there a function to control the preset browser modals LAF?
registerFunction("drawModalOverlay" does not seems to be the one.
Any tip??const var browserLaf = Content.createLocalLookAndFeel(); const var presetsFloatingTile = Content.getComponent("presetsFloatingTile"); browserLaf.registerFunction("drawModalOverlay", function(g, obj) { g.setColour(Colours.red); g.fillAll(); });
-
-
@d-healey thanks mate!!!
-
@d-healey ... LOL coming back!!
Can't figure out access to this guy:
-
@hisefilo What do you want to do with it?
-
@d-healey move it up. is obj.text but is not listening to me. maybe is an object pushing it down
-
@hisefilo show me your laf
-
const var browserLaf = Content.createLocalLookAndFeel(); const var presetsFloatingTile = Content.getComponent("presetsFloatingTile"); browserLaf.registerFunction("drawPresetBrowserDialog", function(g, obj) { var a = obj.area; var la = obj.labelArea; var h = 90; // g.drawDropShadow([a[0] - 50, a[1] - 50, a[2] + 100, a[3] + 100], Colours.withAlpha(Colours.black, 0.8), 20); //g.setColour(0xff2F2F34); g.setColour(0xff323232); g.fillRect([a[0] - 50, a[1] - 90, a[2] + 90, a[3] + 150]); //g.setColour(0xff161619); //g.setColour(Colours.blue); //g.fillRect([a[0] - 50, a[1] - 0, a[2] + 100, h]); g.setFont("Abel", 24); g.setColour(Colours.white); g.drawAlignedText(obj.title, [a[0] - 30, a[1] - 50, a[2] + 70, 20], "centred"); if (obj.text){ g.setFont("Abel", 24); g.setColour(Colours.red); g.drawAlignedText(obj.text, [a[0] + 10, a[1] + h + 10, a[2] - 20, a[3] - h - 200], "right"); } //g.setColour(Colours.withAlpha(Colours.white, 0.3)); //g.drawRect([a[0] - 50, a[1] - 50, a[2] + 100, a[3] + 100], 1); g.setFont("Abel", 18); g.setColour(Colours.white); if (obj.labelArea[2] != 0) { g.drawAlignedText(obj.text, [a[0], a[1] + 15, a[2], 20], "centred"); g.setColour(0xff161619); g.fillRoundedRectangle([la[0] - 5, la[1], la[2] + 10, la[3]], 5); } else { g.drawAlignedText(obj.text, [a[0], a[1] + 40, a[2], 20], "centred"); } }); presetsFloatingTile.setLocalLookAndFeel(browserLaf);
-
@hisefilo you're drawing obj.text in two places, is that intentional?
-
@d-healey No, is that I'm just an idiot LOL. Thanks mate. To many hours in front of my computer... I need a break