# StandaloneFilterApp create the StandaloneFilterWindow with a transparent colour

**URL:** <https://forum.juce.com/t/standalonefilterapp-create-the-standalonefilterwindow-with-a-transparent-colour/17287>\
**Category:** Audio Plugins\
**Created:** [April 15, 2016, 7:14am UTC](https://forum.juce.com/t/standalonefilterapp-create-the-standalonefilterwindow-with-a-transparent-colour/17287 "2016-04-15T07:14:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kunitoki](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/kunitoki/32/15_2.png) [@kunitoki](https://forum.juce.com/u/kunitoki)\
**Post date:** [April 15, 2016, 7:14am UTC](https://forum.juce.com/t/standalonefilterapp-create-the-standalonefilterwindow-with-a-transparent-colour/17287/1 "2016-04-15T07:14:02Z")

</div>

The StandaloneFilterApp is creating an instance of a StandaloneFilterWindow with a transparentBlack colour (resulting in the titlebar being transparent)

```
mainWindow = new StandaloneFilterWindow (getApplicationName(), Colour(), nullptr, true);

```

Would be cool if this was injectable somehow.

---

<div class="post-metadata">

**Author:** ![mzuther](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/mzuther/32/635_2.png) [@mzuther](https://forum.juce.com/u/mzuther)\
**Post date:** [April 22, 2016, 4:33pm UTC](https://forum.juce.com/t/standalonefilterapp-create-the-standalonefilterwindow-with-a-transparent-colour/17287/2 "2016-04-22T16:33:52Z")

</div>

This has been added to JUCE 4.2.1 and works fine:

```
    virtual StandaloneFilterWindow* createWindow()
    {
        return new StandaloneFilterWindow (getApplicationName(),
                       Colours::white, nullptr, true);
    }

```

Thanks Jules! 🙂

However, I’m wondering how to correctly use this. The file `juce_StandaloneFilterApp.cpp` contains the macro

```
START_JUCE_APPLICATION (StandaloneFilterApp);

```

so when I subclass `StandaloneFilterWindow`, a stand-alone window with the base class will automatically be opened.

In order to open a stand-alone window with the subclass (to make use of the overridden `createWindow` method), I have to comment out the macro `START_JUCE_APPLICATION`. Am I missing something here?

---

<div class="post-metadata">

**Author:** ![mzuther](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/mzuther/32/635_2.png) [@mzuther](https://forum.juce.com/u/mzuther)\
**Post date:** [April 22, 2016, 5:44pm UTC](https://forum.juce.com/t/standalonefilterapp-create-the-standalonefilterwindow-with-a-transparent-colour/17287/3 "2016-04-22T17:44:50Z")

</div>

Another thing - I want the stand-alone to remember its current settings for the next session:

```
StandaloneFilterWindow *KmeterStandalone::createWindow()
{
    PropertiesFile::Options settings;

    settings.applicationName = "kmeter_stereo";
    settings.filenameSuffix = "ini";
    settings.folderName = ".config";

    PropertiesFile *propertiesFile = new PropertiesFile(settings);

    return StandaloneFilterWindow(getApplicationName(), Colours::black,
               propertiesFile, true);
}

void KmeterStandalone::shutdown()
{
    mainWindow->pluginHolder->savePluginState();
    mainWindow = nullptr;
}

```

However, I can’t access `savePluginState` because mainWindow is set to `private`. Could it be changed to `protected` instead?

```
protected:
    ScopedPointer<StandaloneFilterWindow> mainWindow;

```

That would be awesome! 🙂
