コード例 #1
0
ファイル: Demo.peg.cpp プロジェクト: kmkolasinski/QtnProperty
QtnPropertySetSamplePS::QtnPropertySetSamplePS(QObject* parent)
    : QtnPropertySet(parent)
    , BoolProperty(*new QtnPropertyBool(this))
    , ButtonProperty(*new QtnPropertyButton(this))
    , ButtonLinkProperty(*new QtnPropertyButton(this))
    , RGBColor(*new QtnPropertyABColor(this))
    , FloatPropertySliderBox(*new QtnPropertyFloat(this))
    , DoubleProperty(*new QtnPropertyDouble(this))
    , FloatProperty(*new QtnPropertyFloat(this))
    , IntProperty(*new QtnPropertyInt(this))
    , UIntProperty(*new QtnPropertyUInt(this))
    , EnumProperty(*new QtnPropertyEnum(this))
    , EnumFlagsProperty(*new QtnPropertyEnumFlags(this))
    , QStringValue(*new QtnPropertyQString(this))
    , EnableSubPropertySet(*new QtnPropertyBool(this))
    , SubPropertySet(*new QtnPropertySetSubPropertySetType(this))
    , QPointProperty(*new QtnPropertyQPoint(this))
    , QSizeProperty(*new QtnPropertyQSize(this))
    , QRectProperty(*new QtnPropertyQRect(this))
    , QColorProperty(*new QtnPropertyQColor(this))
    , QFontProperty(*new QtnPropertyQFont(this))
    , SubPropertySet2(*new QtnPropertySetSubPropertySetType(this))
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #2
0
MainWindow::MainWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::MainWindow) {
    ui->setupUi(this);
    this->setFixedSize(this->width(), this->height());
    connectSlots();
}
コード例 #3
0
//---------------------------------------------------------
// Implementations
//---------------------------------------------------------
//-------------------------------------
MainWindow::MainWindow(QWidget *parent)
    : QMainWindow(parent), m_ui(new Ui::MainWindow), m_lblSongInfo(NULL) {
  m_ui->setupUi(this);
  m_ui->dockWidgetLyrics->setWindowTitle(tr("Lyrics"));
#ifdef Q_OS_WIN32
  if(QSysInfo::WindowsVersion == QSysInfo::WV_WINDOWS10)
    setStyleSheet("QToolBar { background-color: white;};");
#endif
  setupActions();
  setupTrayIcon();
  setupDockMenu();
  setupToolbar();
  connectSlots();
  restoreGeometryAndState();
  m_ui->stackedWidget->setCurrentIndex(PAGE_HOME);
  onPageChanged(PAGE_HOME);

  qApp->setWindowIcon(Icons::mellowPlayer());
  setWindowIcon(Icons::mellowPlayer());

  // Setup controllers
  new UpdateController(this);
  new PlayerController(this);
  new StreamingServicesController(this);
  new NotificationsController(this);
  new HotkeysController(this);
  new MPRIS2Controller(this);
  new LyricsController(this);
}
コード例 #4
0
ファイル: addressdialog.cpp プロジェクト: Karry/monav
AddressDialog::AddressDialog(QWidget *parent) :
		QDialog(parent),
		m_ui(new Ui::AddressDialog)
{
	m_ui->setupUi(this);
	// Windows Mobile Window Flags
	setWindowFlags( windowFlags() & ( ~Qt::WindowOkButtonHint ) );
	setWindowFlags( windowFlags() | Qt::WindowCancelButtonHint );

	bool increaseFontSize = true;
#ifdef Q_WS_MAEMO_5
	setAttribute( Qt::WA_Maemo5StackedWindow );
	m_ui->characterList->hide();
	increaseFontSize = false;
#endif

	m_skipStreetPosition = false;
	m_ui->suggestionList->setAlternatingRowColors( true );
	m_ui->characterList->setAlternatingRowColors( true );
	if ( increaseFontSize ) {
		QFont font = m_ui->suggestionList->font();
		font.setPointSize( font.pointSize() * 1.5 );
		m_ui->suggestionList->setFont( font );
		m_ui->characterList->setFont( font );
	}
	resetCity();
	connectSlots();
}
コード例 #5
0
ファイル: cdegs_main.cpp プロジェクト: Eltee/cdegs-aid
/*!
 \brief

 \fn cdegs_main::cdegs_main
 \param parent
*/
cdegs_main::cdegs_main(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::cdegs_main){
    ui->setupUi(this);

    connectSlots();
}
コード例 #6
0
DisplayMapControl::DisplayMapControl(GetDataDisplayMapInterface& inter,QObject* parent) : QObject(parent)
{
    map = new Map();
    //map->setGeometry(QRect(90,0,1000,600));
    connectSlots(inter);

    //
    ///FOR TESTING ONLY, REMOVE
    //
    /*for(int i=0;i<9;i++)
    {
        Area * a = new Area(i);

        Facility* c = new Facility(1234,"Johnson Hospital"+QString::number(i),0,0,0,QPoint(200+rand()%800,350+rand()%100));
        a->addFacility(c);
        for(int i=0;i<40;i++)
        {
            CareType ct = Convenience::intToCareType(rand()%2);
            c->addPatientToBed(new Patient("111-111-11"+QString::number(i),"fdsaf","Fdsaf",ct),ct);
        }
        this->addFacility(c);
        delete a;
    }
    for(int i=0;i<9;i++)
    {
        Area * a = new Area(i);
        Facility* c = new Facility(1234,"Johnson LTC Facil"+QString::number(i),0,0,rand()%40,QPoint(200+rand()%800,350+rand()%100));
        a->addFacility(c);
        for(int i=0;i<10;i++)
            c->addPatientToBed(new Patient("111-111-11"+QString::number(i),"fdsaf","Fdsaf",Convenience::intToCareType(EOBC::LTC)),Convenience::intToCareType(2));
        this->addFacility(c);
        delete a;
    }*/
}
コード例 #7
0
ファイル: test.peg.cpp プロジェクト: lexxmark/QtnProperty
QtnPropertySetAA::QtnPropertySetAA(QObject* parent)
    : QtnPropertySet(parent)
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #8
0
//=============================================================================
// Constructor of the class CCommunication.
//=============================================================================
CCommunication::CCommunication (QWidget *parent, const char *name, QSqlDatabase *db,
                                CUserData *current)
	: QWidget (parent,name)
{
  int   i;
  
  mContentChanged = false;
  mNew            = false;
  mDB             = db;
  mCurrentUser    = current;

  //----------------------------------------------------------------------------
  //  Create the layout
  //----------------------------------------------------------------------------
  mLayout = new QGridLayout (this, 10, 2, 10);

  //----------------------------------------------------------------------------
  //  Create four default rows consisting of combobox and lineedit.
  //----------------------------------------------------------------------------
  for (i = 0; i < 4; i++)
    slotAddLine();
  
  setReadonly (true);
  connectSlots();
}
コード例 #9
0
ファイル: WSlider.C プロジェクト: kdeforche/wt
PaintedSlider::PaintedSlider(WSlider *slider)
  : WPaintedWidget(),
    slider_(slider),
    sliderReleased_(this, "released")
{
  setStyleClass("Wt-slider-bg");

  slider_->addStyleClass
    (std::string("Wt-slider-")
     + (slider_->orientation() == Orientation::Horizontal ? "h" : "v"));

  if (slider_->positionScheme() == PositionScheme::Static) {
    slider_->setPositionScheme(PositionScheme::Relative);
    slider_->setOffsets(0, Side::Left | Side::Top);
  }

  manageWidget(fill_, std::unique_ptr<WInteractWidget>(new WContainerWidget()));
  manageWidget(handle_, slider_->createHandle());

  fill_->setPositionScheme(PositionScheme::Absolute);
  fill_->setStyleClass("fill");

  handle_->setPositionScheme(PositionScheme::Absolute);
  handle_->setStyleClass("handle");

  connectSlots();
}
コード例 #10
0
ファイル: configurationmanager.cpp プロジェクト: m4r71n/CopyQ
ConfigurationManager::ConfigurationManager(ItemFactory *itemFactory, QWidget *parent)
    : QDialog(parent)
    , ui(new Ui::ConfigurationManager)
    , m_options()
{
    ui->setupUi(this);
    connectSlots();
    setWindowIcon(appIcon());

    connect( ui->configTabShortcuts, &ConfigTabShortcuts::commandsSaved,
             this, &ConfigurationManager::commandsSaved );

    ui->spinBoxItems->setMaximum(Config::maxItems);

    if ( itemFactory && itemFactory->hasLoaders() )
        initPluginWidgets(itemFactory);
    else
        ui->tabItems->hide();

    initOptions();

    if (itemFactory)
        ui->configTabAppearance->createPreview(itemFactory);

    loadSettings();

    if (itemFactory)
        ui->configTabShortcuts->addCommands( itemFactory->commands() );
}
コード例 #11
0
ファイル: test.peg.cpp プロジェクト: lexxmark/QtnProperty
QtnPropertySetTest12::QtnPropertySetTest12(QObject* parent)
    : QtnPropertySet(parent)
    , p(*qtnCreateProperty<QtnPropertyEnum>(this))
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #12
0
ファイル: configurationmanager.cpp プロジェクト: m4r71n/CopyQ
ConfigurationManager::ConfigurationManager()
    : ui(new Ui::ConfigurationManager)
    , m_options()
{
    ui->setupUi(this);
    connectSlots();
    initOptions();
}
コード例 #13
0
Preferences::Preferences (QWidget* parent) : QWidget (parent)
{
    createWidgets();
    createLayouts();

    readSettings();
    connectSlots();
}
コード例 #14
0
ファイル: mainwindow.cpp プロジェクト: wuyusheng/ConfigExport
QWSMainWindow::QWSMainWindow()
{
	setWindowTitle(QStringLiteral("配置工具软件"));
	setMinimumSize(WINDOW_MIN_WIDHT, WINDOW_MIN_HEIGHT);

	init();
	connectSlots();
}
コード例 #15
0
ファイル: test.peg.cpp プロジェクト: lexxmark/QtnProperty
QtnPropertySetAllPropertyTypes::QtnPropertySetAllPropertyTypes(QObject* parent)
    : QtnPropertySet(parent)
    , bp(*qtnCreateProperty<QtnPropertyBool>(this))
    , bpc(*qtnCreateProperty<QtnPropertyBoolCallback>(this))
    , ip(*qtnCreateProperty<QtnPropertyInt>(this))
    , ipc(*qtnCreateProperty<QtnPropertyIntCallback>(this))
    , up(*qtnCreateProperty<QtnPropertyUInt>(this))
    , upc(*qtnCreateProperty<QtnPropertyUIntCallback>(this))
    , fp(*qtnCreateProperty<QtnPropertyFloat>(this))
    , fpc(*qtnCreateProperty<QtnPropertyFloatCallback>(this))
    , dp(*qtnCreateProperty<QtnPropertyDouble>(this))
    , dpc(*qtnCreateProperty<QtnPropertyDoubleCallback>(this))
    , sp(*qtnCreateProperty<QtnPropertyQString>(this))
    , spc(*qtnCreateProperty<QtnPropertyQStringCallback>(this))
    , rp(*qtnCreateProperty<QtnPropertyQRect>(this))
    , rpc(*qtnCreateProperty<QtnPropertyQRectCallback>(this))
    , pp(*qtnCreateProperty<QtnPropertyQPoint>(this))
    , ppc(*qtnCreateProperty<QtnPropertyQPointCallback>(this))
    , szp(*qtnCreateProperty<QtnPropertyQSize>(this))
    , szpc(*qtnCreateProperty<QtnPropertyQSizeCallback>(this))
    , ep(*qtnCreateProperty<QtnPropertyEnum>(this))
    , epc(*qtnCreateProperty<QtnPropertyEnumCallback>(this))
    , efp(*qtnCreateProperty<QtnPropertyEnumFlags>(this))
    , efpc(*qtnCreateProperty<QtnPropertyEnumFlagsCallback>(this))
    , cp(*qtnCreateProperty<QtnPropertyQColor>(this))
    , cpc(*qtnCreateProperty<QtnPropertyQColorCallback>(this))
    , fnp(*qtnCreateProperty<QtnPropertyQFont>(this))
    , fnpc(*qtnCreateProperty<QtnPropertyQFontCallback>(this))
    , bttn(*qtnCreateProperty<QtnPropertyButton>(this))
    , ppf(*qtnCreateProperty<QtnPropertyQPointF>(this))
    , ppfc(*qtnCreateProperty<QtnPropertyQPointFCallback>(this))
    , rpf(*qtnCreateProperty<QtnPropertyQRectF>(this))
    , rpfc(*qtnCreateProperty<QtnPropertyQRectFCallback>(this))
    , szpf(*qtnCreateProperty<QtnPropertyQSizeF>(this))
    , szpfc(*qtnCreateProperty<QtnPropertyQSizeFCallback>(this))
    , _b(true)
{
    
        _i =12;
        _ui = 9;
        _f = 0.2f;
        _d = 32.4;
        _s = "name";
        _r = QRect(10, 10, 10, 10);
        _rf = QRectF(10.1, 10.2, 10.3, 10.4);
        _p = QPoint(9, 2);
        _pf = QPointF(9.9, 2.2);
        _sz = QSize(33, 21);
        _szf = QSizeF(33.0, 21.9);
        _e = COLOR::RED;
        _ef = MASK::ONE|MASK::FOUR;
        _cl = QColor(Qt::red);
        _fn = QFont("Arial", 19);
    
    init();
    connectSlots();
    connectDelegates();
}
コード例 #16
0
ファイル: prefdialog.cpp プロジェクト: adaptee/qterm-hack
/* 
 *  Constructs a prefDialog which is a child of 'parent', with the 
 *  name 'name' and widget flags set to 'f'.
 *
 *  The dialog will by default be modeless, unless you set 'modal' to
 *  TRUE to construct a modal dialog.
 */
prefDialog::prefDialog( QWidget* parent, Qt::WFlags fl )
	: QDialog( parent, fl )
{

	ui.setupUi(this);
	connectSlots();
	loadSetting();

}
コード例 #17
0
Preferences::Preferences (QWidget* parent) : QWidget (parent) {
    createWidgets();
    createLayouts();

    readSettings();
    connectSlots();

    DS::log (DS::kInfoLevel, "MainWindow: Preferences widget created");
}
コード例 #18
0
ファイル: test.peg.cpp プロジェクト: lexxmark/QtnProperty
QtnPropertySetTest1::QtnPropertySetTest1(QObject* parent)
    : QtnPropertySet(parent)
    , a(*qtnCreateProperty<QtnPropertyInt>(this))
    , text(*qtnCreateProperty<QtnPropertyQString>(this))
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #19
0
SettingsWindow::SettingsWindow()
{
    createWidgets();
    createLayouts();
    connectSlots();

    readSettings();
    applySettings();
}
コード例 #20
0
ファイル: test.peg.cpp プロジェクト: lexxmark/QtnProperty
QtnPropertySetYY::QtnPropertySetYY(QObject* parent)
    : QtnPropertySet(parent)
    , rect(*qtnCreateProperty<QtnPropertyQRect>(this))
    , s(*qtnCreateProperty<QtnPropertyQString>(this))
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #21
0
RegionSelectorController::RegionSelectorController(RegionSelectorGui gui, RegionSelectorSettings settings, QObject* parent)
    : QObject(parent),
      gui(gui),
      settings(settings) {

    init();
    setupPresets();
    connectSlots();
}
コード例 #22
0
ファイル: test.peg.cpp プロジェクト: lexxmark/QtnProperty
QtnPropertySetSS::QtnPropertySetSS(QObject* parent)
    : QtnPropertySet(parent)
    , a(*qtnCreateProperty<QtnPropertyBool>(this))
    , aa(*qtnCreateProperty<QtnPropertySetAA>(this))
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #23
0
QtnPropertySetTextAttributes::QtnPropertySetTextAttributes(QObject* parent)
    : QtnPropertySet(parent)
    , WordWrap(*new QtnPropertyBool(this))
    , Height(*new QtnPropertyInt(this))
    , Color(*new QtnPropertyQColor(this))
{
    init();
    connectSlots();
    connectDelegates();
}
コード例 #24
0
Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);
    createObjects();
    configureGUI();
    printIpAddresses();
    connectSlots();
}
コード例 #25
0
ファイル: lintvplay.cpp プロジェクト: xtremekforever/lintv
LinTVPlay::LinTVPlay(QWidget *parent, const QString & filename)
    : m_parent(parent),
      m_device(filename)
{
    m_deviceType = LinTVDeviceInfo::File;
    m_mplayerProcess = new LinTVProcess(this);

    loadDefaultValues();
    connectSlots();
}
コード例 #26
0
ファイル: mainwindow.cpp プロジェクト: OlliD/StateMachine
MainWindow::MainWindow(QApplication *a, QWidget *parent) :
    QMainWindow(parent)
{
    MainWindow::quit= new QPushButton("Quit App");
    QObject::connect(quit, SIGNAL(clicked()), a, SLOT(quit()));
    domParser = new DOMParser();
    initGui();
    connectSlots();
    adapterMap = new QMap<QString, AgentInterface*>;
    initConnectors();
}
コード例 #27
0
ファイル: EventLogger.cpp プロジェクト: AHerridge/LibDS
/**
 * Connects the signals/slots between the \c DriverStation and the logger
 */
DSEventLogger::DSEventLogger()
{
    m_init = 0;
    m_dump = NULL;
    m_currentLog = "";

    init();

    saveDataLoop();
    connectSlots();
}
コード例 #28
0
KSPhrase::KSPhrase(QWidget *parent, const QString &caption)
  : KDialogBase(parent, "KSPhrase", true, caption, Ok|Apply|Cancel), m_edit(false), m_modified(false)
{
  m_create=true;
  initialize();
  enableButtonApply(false);

  setMainWidget(m_mainWidget);

  connectSlots();
}
コード例 #29
0
ファイル: note.cpp プロジェクト: bacchante95/fritzing
void Note::setText(const QString & text, bool check) {
	// disconnect the signal so it doesn't fire recursively
	disconnectSlots();
	QString oldText = text;
	m_graphicsTextItem->document()->setHtml(text);
	connectSlots();

	if (check) {
		QSizeF newSize;
		checkSize(newSize);
		forceFormat(0, m_graphicsTextItem->document()->characterCount());
	}
}
コード例 #30
0
ファイル: smengine.cpp プロジェクト: OlliD/ECAStateMachine
void SMEngine::startEngine(){

    widgetMap.insert("inputWidget", new InputWidget());
    widgetMap.insert("infoWidget", new InfoWidget());
    widgetMap.insert("dialogWidget", new DialogWidget());
    //widgetMap.insert("initialWidget", new InitialWidget(smGui));
    SMEngine::personData = new QList< QMap<QString, QString> >;
    SMEngine::widgetData = new QList< QMap<QString, QString> >;
    Logger::getInstance().log("SMEngine initialized", loglevel);
    parseXMLFile("fileName");   //TODO: change signature
    QVBoxLayout *layout = new QVBoxLayout();
    connectSlots();
}