The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

49 lines
1.6KB

  1. /*
  2. ==============================================================================
  3. This file contains the basic framework code for a JUCE plugin editor.
  4. ==============================================================================
  5. */
  6. %%editor_cpp_headers%%
  7. //==============================================================================
  8. %%editor_class_name%%::%%editor_class_name%% (%%filter_class_name%%& p)
  9. : AudioProcessorEditor (&p),
  10. #if JucePlugin_Enable_ARA
  11. AudioProcessorEditorARAExtension (&p),
  12. #endif
  13. audioProcessor (p)
  14. {
  15. #if JucePlugin_Enable_ARA
  16. // ARA plugins must be resizable for proper view embedding
  17. setResizable (true, false);
  18. #endif
  19. // Make sure that before the constructor has finished, you've set the
  20. // editor's size to whatever you need it to be.
  21. setSize (400, 300);
  22. }
  23. %%editor_class_name%%::~%%editor_class_name%%()
  24. {
  25. }
  26. //==============================================================================
  27. void %%editor_class_name%%::paint (juce::Graphics& g)
  28. {
  29. // (Our component is opaque, so we must completely fill the background with a solid colour)
  30. g.fillAll (getLookAndFeel().findColour (juce::ResizableWindow::backgroundColourId));
  31. g.setColour (juce::Colours::white);
  32. g.setFont (15.0f);
  33. g.drawFittedText ("Hello World!", getLocalBounds(), juce::Justification::centred, 1);
  34. }
  35. void %%editor_class_name%%::resized()
  36. {
  37. // This is generally where you'll want to lay out the positions of any
  38. // subcomponents in your editor..
  39. }