zynaddsubfx

ZynAddSubFX open source synthesizer
Log | Files | Refs | Submodules | LICENSE

Fl_Osc_Pane.H (1550B)


      1 /*
      2   ZynAddSubFX - a software synthesizer
      3 
      4   Fl_Osc_Pane.H - OSC Subwindow
      5   Copyright (C) 2016 Mark McCurry
      6 
      7   This program is free software; you can redistribute it and/or
      8   modify it under the terms of the GNU General Public License
      9   as published by the Free Software Foundation; either version 2
     10   of the License, or (at your option) any later version.
     11 */
     12 #ifndef FL_OSC_PANE_H
     13 #define FL_OSC_PANE_H
     14 #include <FL/Fl_Group.H>
     15 #include <FL/Fl_Double_Window.H>
     16 #include <string>
     17 #include "Osc_DataModel.h"
     18 
     19 class Fl_Osc_Pane
     20 {
     21     public:
     22         Fl_Osc_Pane(void);
     23         class Fl_Osc_Interface *osc;
     24         std::string base;
     25         virtual std::string loc(void) const = 0;
     26         virtual void rebase(std::string new_base) = 0;
     27 };
     28 
     29 class Fl_Osc_Window:public Fl_Double_Window, public Fl_Osc_Pane
     30 {
     31     Osc_DataModel *title_ext;
     32     std::string rewrite_rule;
     33     std::string title_orig;
     34     std::string title_new;
     35     public:
     36         Fl_Osc_Window(int w, int h, const char *L=0);
     37         ~Fl_Osc_Window(void);
     38 
     39         void init(Fl_Osc_Interface *osc_, std::string loc_);
     40         virtual std::string loc(void) const;
     41         virtual void rebase(std::string new_base);
     42         void update();
     43         void update_title();
     44 };
     45 
     46 
     47 class Fl_Osc_Group:public Fl_Osc_Pane, public Fl_Group
     48 {
     49     public:
     50         Fl_Osc_Group(int x, int y, int w, int h, const char *L=0);
     51 
     52         std::string ext;
     53 
     54         virtual std::string loc(void) const;
     55         virtual void reext(std::string new_base);
     56         virtual void rebase(std::string new_ext);
     57 };
     58 #endif
     59