• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

kstars

  • sources
  • kde-4.12
  • kdeedu
  • kstars
  • kstars
  • indi
indiproperty.h
Go to the documentation of this file.
1 /* INDI Property
2  Copyright (C) 2003 Jasem Mutlaq (mutlaqja@ikarustech.com)
3 
4  This application is free software; you can redistribute it and/or
5  modify it under the terms of the GNU General Public
6  License as published by the Free Software Foundation; either
7  version 2 of the License, or (at your option) any later version.
8 
9 
10  */
11 
12 #ifndef INDIPROPERTY_H_
13 #define INDIPROPERTY_H_
14 
15 #include <QLabel>
16 #include <QVBoxLayout>
17 #include <QHBoxLayout>
18 #include <indiproperty.h>
19 
20 #include "indicommon.h"
21 
22 class INDI_G;
23 class INDI_E;
24 
25 class KComboBox;
26 class KLed;
27 
28 class QLabel;
29 class QPushButton;
30 class QHBoxLayout;
31 class QVBoxLayout;
32 class QButtonGroup;
33 class QAbstractButton;
34 class QAction;
35 class QCheckBox;
36 
37 /* INDI property */
38 class INDI_P : public QObject
39 {
40  Q_OBJECT
41 public:
42  INDI_P(INDI_G *ipg, INDI::Property *prop);
43  ~INDI_P();
44 
45  /* Draw state LED */
46  void updateStateLED();
47 
48  /* Update menu gui */
49  void updateMenuGUI();
50 
51  void initGUI();
52 
53  /* First step in adding a new GUI element */
54  //void addGUI(XMLEle *root);
55 
56  /* Set Property's parent group */
57  //void setGroup(INDI_G *parentGroup) { pg = parentGroup; }
58 
59  void buildSwitchGUI();
60  void buildMenuGUI();
61  void buildTextGUI();
62  void buildNumberGUI();
63  void buildLightGUI();
64  void buildBLOBGUI();
65 
66  /* Setup the 'set' button in the property */
67  void setupSetButton(const QString &caption);
68 
69  void newTime();
70 
71  PGui getGUIType() { return guiType;}
72 
73  INDI_G *getGroup() { return pg;}
74 
75  QHBoxLayout * getContainer() { return PHBox; }
76 
77  const QString &getName() { return name; }
78 
79 
80 
81 
82 
83  //void addContainerWidget(QWidget *w);
84  void addWidget(QWidget *w);
85  void addLayout(QHBoxLayout *layout);
86 
87  INDI_E * getElement(const QString &elementName);
88 
89  QList<INDI_E *> getElements() { return elementList; }
90 private:
91 
92  INDI::Property *dataProp;
93  INDI_G *pg; /* parent group */
94  QCheckBox *enableBLOBC;
95  QLabel *labelW; /* Label widget */
96  QPushButton *setB; /* set button */
97  KLed *ledStatus; /* state LED */
98  PGui guiType; /* type of GUI, if any */
99 
100 
101  QSpacerItem *horSpacer; /* Horizontal spacer */
102  QHBoxLayout *PHBox; /* Horizontal container */
103  QVBoxLayout *PVBox; /* Vertical container */
104 
105  QButtonGroup *groupB; /* group button for radio and check boxes (Elements) */
106  KComboBox *menuC; /* Combo box for menu */
107 
108  QString name;
109 
110  QList<INDI_E*> elementList; /* list of elements */
111 
112 public slots:
113  void processSetButton();
114  void newSwitch(QAbstractButton * button);
115  void newSwitch(int index);
116  void newSwitch(const QString & name);
117 
118 
119  void sendBlob();
120  void sendSwitch();
121  void sendText();
122 
123  void setBLOBOption(int state);
124 };
125 
126 #endif
INDI_P
Definition: indiproperty.h:38
INDI_P::getElement
INDI_E * getElement(const QString &elementName)
Definition: indiproperty.cpp:669
INDI_P::sendBlob
void sendBlob()
Definition: indiproperty.cpp:596
QWidget
INDI_P::getContainer
QHBoxLayout * getContainer()
Definition: indiproperty.h:75
INDI_P::sendText
void sendText()
Definition: indiproperty.cpp:447
INDI_P::setupSetButton
void setupSetButton(const QString &caption)
Definition: indiproperty.cpp:538
INDI_P::addLayout
void addLayout(QHBoxLayout *layout)
Definition: indiproperty.cpp:555
INDI_E
Definition: indielement.h:44
INDI_P::getName
const QString & getName()
Definition: indiproperty.h:77
INDI_P::buildSwitchGUI
void buildSwitchGUI()
Definition: indiproperty.cpp:195
INDI_P::updateMenuGUI
void updateMenuGUI()
Definition: indiproperty.cpp:560
QObject
INDI_P::~INDI_P
~INDI_P()
Definition: indiproperty.cpp:681
INDI_P::getElements
QList< INDI_E * > getElements()
Definition: indiproperty.h:89
INDI_P::buildTextGUI
void buildTextGUI()
Definition: indiproperty.cpp:228
INDI_P::updateStateLED
void updateStateLED()
Definition: indiproperty.cpp:81
INDI_P::newTime
void newTime()
Definition: indiproperty.cpp:639
INDI_P::buildMenuGUI
void buildMenuGUI()
Definition: indiproperty.cpp:490
INDI_P::INDI_P
INDI_P(INDI_G *ipg, INDI::Property *prop)
Definition: indiproperty.cpp:59
INDI_G
Definition: indigroup.h:31
INDI_P::newSwitch
void newSwitch(QAbstractButton *button)
Definition: indiproperty.cpp:366
PGui
PGui
Definition: indicommon.h:46
INDI_P::sendSwitch
void sendSwitch()
Definition: indiproperty.cpp:429
INDI_P::buildLightGUI
void buildLightGUI()
Definition: indiproperty.cpp:295
INDI_P::addWidget
void addWidget(QWidget *w)
Definition: indiproperty.cpp:550
QLabel
INDI_P::buildNumberGUI
void buildNumberGUI()
Definition: indiproperty.cpp:263
indiproperty.h
indicommon.h
INDI_P::getGUIType
PGui getGUIType()
Definition: indiproperty.h:71
INDI_P::buildBLOBGUI
void buildBLOBGUI()
Definition: indiproperty.cpp:319
INDI_P::processSetButton
void processSetButton()
Definition: indiproperty.cpp:570
QList
INDI_P::getGroup
INDI_G * getGroup()
Definition: indiproperty.h:73
INDI_P::setBLOBOption
void setBLOBOption(int state)
Definition: indiproperty.cpp:357
INDI_P::initGUI
void initGUI()
Definition: indiproperty.cpp:112
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:36:20 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kstars

Skip menu "kstars"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal