Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

VrGUI.h

Go to the documentation of this file.
00001 /* -*- Mode: c++ -*- */ 00002 /* 00003 * Copyright 2001 Free Software Foundation, Inc. 00004 * 00005 * This file is part of GNU Radio 00006 * 00007 * GNU Radio is free software; you can redistribute it and/or modify 00008 * it under the terms of the GNU General Public License as published by 00009 * the Free Software Foundation; either version 2, or (at your option) 00010 * any later version. 00011 * 00012 * GNU Radio is distributed in the hope that it will be useful, 00013 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 * GNU General Public License for more details. 00016 * 00017 * You should have received a copy of the GNU General Public License 00018 * along with GNU Radio; see the file COPYING. If not, write to 00019 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00020 * Boston, MA 02111-1307, USA. 00021 */ 00022 /* 00023 * Copyright 1999 Massachusetts Institute of Technology 00024 * 00025 * Permission to use, copy, modify, distribute, and sell this software and its 00026 * documentation for any purpose is hereby granted without fee, provided that 00027 * the above copyright notice appear in all copies and that both that 00028 * copyright notice and this permission notice appear in supporting 00029 * documentation, and that the name of M.I.T. not be used in advertising or 00030 * publicity pertaining to distribution of the software without specific, 00031 * written prior permission. M.I.T. makes no representations about the 00032 * suitability of this software for any purpose. It is provided "as is" 00033 * without express or implied warranty. 00034 * 00035 */ 00036 00037 #ifndef VRGUI_H_ 00038 #define VRGUI_H_ 00039 00040 class QApplication; 00041 class QWidget; 00042 class QBoxLayout; 00043 class VrPlot; 00044 00045 class VrGUILayout { 00046 public: 00047 VrGUILayout(QWidget *arg_widget, QBoxLayout *arg_layout); 00048 VrGUILayout *vertical(int arg_width = -1); 00049 VrGUILayout *horizontal(int arg_width = -1); 00050 QBoxLayout *layout; 00051 QWidget *widget; 00052 }; 00053 00054 class VrGUI { 00055 public: 00056 VrGUI(int argc, char *argv[]); 00057 void start(); 00058 void processEvents(int arg_param); 00059 VrGUILayout *top; 00060 private: 00061 QApplication *app; 00062 }; 00063 00064 class VrGUIPlot { 00065 public: 00066 VrGUIPlot(VrGUILayout *layout, const char *xaxis_name, const char *yaxis_name, 00067 bool lines, double xmin, double xmax, double ymin, double ymax, 00068 int arg_points, int arg_divisions); 00069 void data(double *x, double *y, int arg_points); 00070 void clear(); 00071 void set_persistent(int arg_persistent); 00072 private: 00073 VrPlot *display; 00074 }; 00075 00076 class VrGUISlider { 00077 public: 00078 VrGUISlider(VrGUILayout *layout, void (*arg_callback)(double), 00079 const char *slider_name, float arg_min, float arg_max); 00080 }; 00081 00082 class VrGUINumber { 00083 public: 00084 VrGUINumber(VrGUILayout *layout, const char *arg_title, const char *arg_units, 00085 void (*arg_callback)(double), float arg_max, float arg_default); 00086 }; 00087 00088 class VrGUIButton { 00089 public: 00090 VrGUIButton(VrGUILayout *layout, const char *arg_title, void (*arg_callback)()); 00091 }; 00092 00093 class VrGUILabel { 00094 public: 00095 VrGUILabel(VrGUILayout *layout, const char *arg_value, int arg_center = 1, int arg_size = 14); 00096 }; 00097 00098 class VrGUISpace { 00099 public: 00100 VrGUISpace(VrGUILayout *layout, int arg_space); 00101 }; 00102 #endif

Generated on Wed Aug 4 02:22:05 2004 for GNU Radio by doxygen 1.3.8