void AppearanceSettings::applyToLookAndFeel (LookAndFeel& lf) const { for (int i = 0; i < AppearanceColours::numColours; ++i) { Colour col; if (getColour (AppearanceColours::colours[i].name, col)) { if (AppearanceColours::colours[i].mustBeOpaque) col = Colours::white.overlaidWith (col); if (! AppearanceColours::colours[i].applyToEditorOnly) lf.setColour (AppearanceColours::colours[i].colourID, col); } } lf.setColour (ScrollBar::thumbColourId, lf.findColour (mainBackgroundColourId).contrasting().withAlpha (0.13f)); }
void AppearanceSettings::applyToLookAndFeel (LookAndFeel& lf) const { for (int i = 0; i < AppearanceColours::numColours; ++i) { Colour col; if (getColour (AppearanceColours::colours[i].name, col)) { if (AppearanceColours::colours[i].mustBeOpaque) col = Colours::white.overlaidWith (col); if (! AppearanceColours::colours[i].applyToEditorOnly) lf.setColour (AppearanceColours::colours[i].colourID, col); } } lf.setColour (ScrollBar::thumbColourId, IntrojucerLookAndFeel::getScrollbarColourForBackground (lf.findColour (mainBackgroundColourId))); }
void setupSquareLookAndFeelColours (LookAndFeel& laf) { const Colour baseColour (Colours::red); laf.setColour (Slider::thumbColourId, Colour::greyLevel (0.95f)); laf.setColour (Slider::textBoxOutlineColourId, Colours::transparentWhite); laf.setColour (Slider::rotarySliderFillColourId, baseColour); laf.setColour (Slider::rotarySliderOutlineColourId, Colours::white); laf.setColour (Slider::trackColourId, Colours::black); laf.setColour (TextButton::buttonColourId, Colours::white); laf.setColour (TextButton::textColourOffId, baseColour); laf.setColour (TextButton::buttonOnColourId, laf.findColour (TextButton::textColourOffId)); laf.setColour (TextButton::textColourOnId, laf.findColour (TextButton::buttonColourId)); }
void setupCustomLookAndFeelColours (LookAndFeel& laf) { laf.setColour (Slider::thumbColourId, Colour::greyLevel (0.95f)); laf.setColour (Slider::textBoxOutlineColourId, Colours::transparentWhite); laf.setColour (Slider::rotarySliderFillColourId, Colour (0xff00b5f6)); laf.setColour (Slider::rotarySliderOutlineColourId, Colours::white); laf.setColour (TextButton::buttonColourId, Colours::white); laf.setColour (TextButton::textColourOffId, Colour (0xff00b5f6)); laf.setColour (TextButton::buttonOnColourId, laf.findColour (TextButton::textColourOffId)); laf.setColour (TextButton::textColourOnId, laf.findColour (TextButton::buttonColourId)); }
void setupCustomLookAndFeelColours (LookAndFeel& laf) { //laf.setColour (Slider::thumbColourId, Colour::greyLevel (0.95f)); laf.setColour (Slider::textBoxOutlineColourId, Colours::black); laf.setColour(Slider::textBoxBackgroundColourId,Colour((0x00ffb5f6))); laf.setColour (Slider::rotarySliderFillColourId, Colours::darkorange); //laf.setColour (Slider::rotarySliderOutlineColourId, Colours::white); laf.setColour(Slider::thumbColourId, Colours::brown); laf.setColour (TextButton::buttonColourId, Colours::white); laf.setColour(TextButton::buttonOnColourId, laf.findColour(TextButton::textColourOffId)); //laf.setColour (TextButton::textColourOnId, laf.findColour (TextButton::buttonColourId)); //laf.setColour (TextButton::textColourOffId, Colour (0xff00b5f6)); laf.setColour(GroupComponent::textColourId, Colour(0xff000000)); //laf.setColour(Label::backgroundColourId, Colour(0x33ffffff)); };
//============================================================================== // GUI Look and Feel functions void SignalProcessorAudioProcessorEditor::setupSquareLookAndFeelColours (LookAndFeel& laf) { const Colour baseColour (Colours::red); laf.setColour (Slider::thumbColourId, Colour::greyLevel (0.95f)); laf.setColour (Slider::textBoxOutlineColourId, Colours::transparentWhite); laf.setColour (Slider::rotarySliderFillColourId, baseColour); laf.setColour (Slider::rotarySliderOutlineColourId, Colours::white); laf.setColour (Slider::trackColourId, Colours::white); laf.setColour (Slider::textBoxTextColourId, Colours::white); laf.setColour (TextButton::buttonColourId, Colours::white); laf.setColour (TextButton::textColourOffId, baseColour); laf.setColour (TextButton::buttonOnColourId, laf.findColour (TextButton::textColourOffId)); laf.setColour (TextButton::textColourOnId, laf.findColour (TextButton::buttonColourId)); laf.setColour (ToggleButton::textColourId, Colours::white); laf.setColour (Label::textColourId, Colours::white); laf.setColour (ComboBox::textColourId, Colours::white); laf.setColour (ComboBox::backgroundColourId, baseColour); laf.setColour (ComboBox::buttonColourId, Colours::black); laf.setColour (ComboBox::outlineColourId, Colours::transparentWhite); laf.setColour(TooltipWindow::textColourId, Colours::black); laf.setColour(TooltipWindow::backgroundColourId, Colour::fromRGB(192, 0, 0)); }
void launcherApplication::initialise(const String& commandLine) { File appDataDirectory(File::getSpecialLocation(File::userApplicationDataDirectory)); #if defined(JUCE_LINUX) || defined(JUCE_BSD) settingsDirectory = appDataDirectory.getChildFile(".tremulous"); #elif defined(JUCE_WINDOWS) settingsDirectory = appDataDirectory.getChildFile("Tremulous"); #elif defined(JUCE_MAC) settingsDirectory = appDataDirectory.getChildFile("Application Support").getChildFile("Tremulous"); #endif File logFile(settingsDirectory.getChildFile("launcher.log")); logger = new FileLogger(logFile, ProjectInfo::projectName, 0); Logger::setCurrentLogger(logger); // TODO: Parse arguments StringArray commandLineArray(getCommandLineParameterArray()); for (int i = 0; i < commandLineArray.size(); i++) { Logger::writeToLog(String("arg") + String(i) + String(": ") + commandLineArray[i]); } config = new IniFile(settingsDirectory.getChildFile("launcher.ini")); File defaultBasepath; File defaultHomepath(settingsDirectory); #if defined(JUCE_LINUX) || defined(JUCE_BSD) defaultBasepath = "/usr/local/games/tremulous"; #elif defined(JUCE_MAC) || defined(JUCE_WINDOWS) defaultBasepath = File::getSpecialLocation(File::globalApplicationsDirectory).getChildFile("Tremulous"); #endif config->setDefault("general", "overpath", defaultBasepath.getFullPathName()); config->setDefault("general", "basepath", defaultBasepath.getFullPathName()); config->setDefault("general", "homepath", defaultHomepath.getFullPathName()); config->setDefault("updater", "downloads", defaultBasepath.getChildFile("updater").getChildFile("downloads").getFullPathName()); #if defined(JUCE_LINUX) #if __x86_64__ String defaultPlatform("linux64"); #else String defaultPlatform("linux32"); #endif #elif defined(JUCE_BSD) && defined(__FreeBSD__) #if __x86_64__ String defaultPlatform("freebsd64"); #else String defaultPlatform("freebsd32"); #endif #elif defined(JUCE_MAC) String defaultPlatform("mac"); #elif defined(JUCE_WINDOWS) #if _WIN64 || __x86_64__ String defaultPlatform("win64"); #else String defaultPlatform("win32"); #endif #endif config->setDefault("updater", "platform", defaultPlatform); config->setDefault("updater", "channel", "release"); config->setDefault("updater", "checkForUpdates", 1); config->setDefault("updater", "verifySignature", 1); LookAndFeel *laf = &LookAndFeel::getDefaultLookAndFeel(); laf->setColour(AlertWindow::backgroundColourId, Colour(0xFF111111)); laf->setColour(AlertWindow::textColourId, Colour(0xFFFFFFFF)); laf->setColour(AlertWindow::outlineColourId, Colour(0xFF333333)); laf->setColour(TextButton::buttonColourId, Colour(0xFF333333)); laf->setColour(TextButton::textColourOffId, Colour(0xFFFFFFFF)); // Delete old launcher if it exists File launcherPath(File::getSpecialLocation(File::SpecialLocationType::currentApplicationFile)); File oldLauncherPath(launcherPath.getFullPathName() + ".old"); oldLauncherPath.deleteFile(); initLauncher(); }