Source/PluginEditor.cpp
/*
 This is generally where youll want to lay out
 the positions of any subcomponents in you Plugin.
 */
This is generally where youll want to lay out
the positions of any subcomponents in you Plugin.
This is generally where youll want to lay out the positions of any subcomponents in you Plugin .
void SimpleEQAudioProcessorEditor::resized()
{
    auto bounds = getLocalBounds();
    bounds.removeFromTop(10); 
    auto analyzerEnabledArea = bounds.removeFromTop(25);
    analyzerEnabledArea.setWidth(50);
    analyzerEnabledArea.setX(5);
    analyzerEnabledArea.removeFromTop(2);
    analyzerEnabledButton.setBounds(analyzerEnabledArea);
    bounds.removeFromTop(5);
    float hRatio = 25.f / 100.f; 
    auto responseArea = bounds.removeFromTop(bounds.getHeight() * hRatio); 
    responseCurveComponent.setBounds(responseArea);
    bounds.removeFromTop(10);
    bounds.removeFromBottom(10);
    auto lowCutArea = bounds.removeFromLeft(bounds.getWidth() * 0.33);
    auto highCutArea = bounds.removeFromRight(bounds.getWidth() * 0.5);
    lowcutBypassButton.setBounds(lowCutArea.removeFromTop(25));
    lowCutFreqSlider.setBounds(lowCutArea.removeFromTop(lowCutArea.getHeight() * 0.5)); 
    lowCutSlopeSlider.setBounds(lowCutArea);
    highcutBypassButton.setBounds(highCutArea.removeFromTop(25));
    highCutFreqSlider.setBounds(highCutArea.removeFromTop(highCutArea.getHeight() * 0.5));
    highCutSlopeSlider.setBounds(highCutArea);
    peakBypassButton.setBounds(bounds.removeFromTop(25));
    peakFreqSlider.setBounds(bounds.removeFromTop(bounds.getHeight() * 0.33));
    peakGainSlider.setBounds(bounds.removeFromTop(bounds.getHeight() * 0.5));
    peakQualitySlider.setBounds(bounds);
}
void SimpleEQAudioProcessorEditor :: resized ( ) { auto bounds = getLocalBounds ( ) ; bounds . removeFromTop ( 10 ) ; auto analyzerEnabledArea = bounds . removeFromTop ( 25 ) ; analyzerEnabledArea . setWidth ( 50 ) ; analyzerEnabledArea . setX ( 5 ) ; analyzerEnabledArea . removeFromTop ( 2 ) ; analyzerEnabledButton . setBounds ( analyzerEnabledArea ) ; bounds . removeFromTop ( 5 ) ; float hRatio = 25.f / 100.f ; auto responseArea = bounds . removeFromTop ( bounds . getHeight ( ) * hRatio ) ; responseCurveComponent . setBounds ( responseArea ) ; bounds . removeFromTop ( 10 ) ; bounds . removeFromBottom ( 10 ) ; auto lowCutArea = bounds . removeFromLeft ( bounds . getWidth ( ) * 0.33 ) ; auto highCutArea = bounds . removeFromRight ( bounds . getWidth ( ) * 0.5 ) ; lowcutBypassButton . setBounds ( lowCutArea . removeFromTop ( 25 ) ) ; lowCutFreqSlider . setBounds ( lowCutArea . removeFromTop ( lowCutArea . getHeight ( ) * 0.5 ) ) ; lowCutSlopeSlider . setBounds ( lowCutArea ) ; highcutBypassButton . setBounds ( highCutArea . removeFromTop ( 25 ) ) ; highCutFreqSlider . setBounds ( highCutArea . removeFromTop ( highCutArea . getHeight ( ) * 0.5 ) ) ; highCutSlopeSlider . setBounds ( highCutArea ) ; peakBypassButton . setBounds ( bounds . removeFromTop ( 25 ) ) ; peakFreqSlider . setBounds ( bounds . removeFromTop ( bounds . getHeight ( ) * 0.33 ) ) ; peakGainSlider . setBounds ( bounds . removeFromTop ( bounds . getHeight ( ) * 0.5 ) ) ; peakQualitySlider . setBounds ( bounds ) ; }
This is generally where youll want to lay out
the positions of any subcomponents in you Plugin.
This is generally where youll want to lay out the positions of any subcomponents in you Plugin .
/// bounding box for all the components
 ///adds padding to the to the top of the graph
 //JUCE_LIVE_CONSTANT(25) / 100.f;
 //change from 0.33 to 0.25 because I needed peak hz text to not overlap the slider thumb
 //this is where we create and position the sliders
 ///removes a rect of half the size
 ///gives the rest of the alloted space(which is half of it) to the slope slider
