Exemple #1
0
void KPCMCIAInfoPage::slotSuspendResume() {
    if (!(_card->status() & CARD_STATUS_BUSY))
      if (!(_card->status() & CARD_STATUS_SUSPEND)) {
         emit setStatusBar(i18n("Suspending card..."));
        _card->suspend();
      } else {
         emit setStatusBar(i18n("Resuming card..."));
        _card->resume();
      }
}
Exemple #2
0
void KPCMCIAInfoPage::slotInsertEject() {
      if (!(_card->status() & (CARD_STATUS_READY|CARD_STATUS_SUSPEND))) {
         emit setStatusBar(i18n("Inserting new card..."));
         _card->insert();
         _card->reset();
      } else {
         emit setStatusBar(i18n("Ejecting card..."));
         if (_card->status() & CARD_STATUS_SUSPEND)
           _card->resume();
         _card->eject();
      }
}
Exemple #3
0
void Ui::Ui_MainWindow::SBaction(bool checked){
	if(checked){
		statusbar = new QStatusBar(this);
		setStatusBar(statusbar);
		sboffset = 23;
		updateGeometries();
	} else{
		setStatusBar(0);
		sboffset = 0;
		updateGeometries();
	}
}
Exemple #4
0
void
MainWindow::init()
{
	makeUI();
	createActions();
	createConnects();
	createToolbars();
	//setStatusBar(statusBar());
	#if 0
	QMainWindow *qm = new QMainWindow();
	qm = (QMainWindow *) stackedWidget->currentWidget();
	setStatusBar(qm->statusBar());
	#endif
	setStatusBar(((QMainWindow *) stackedWidget->currentWidget())->statusBar());
}
Exemple #5
0
PmChart::PmChart() : QMainWindow(NULL)
{
    my.dialogsSetup = false;
    setIconSize(QSize(22, 22));

    setupUi(this);

    my.statusBar = new StatusBar;
    setStatusBar(my.statusBar);
    connect(my.statusBar->timeFrame(), SIGNAL(clicked()),
				this, SLOT(editSamples()));
    connect(my.statusBar->timeButton(), SIGNAL(clicked()),
				this, SLOT(optionsShowTimeControl()));

    my.timeAxisRightAlign = toolBar->height();
    toolBar->setAllowedAreas(Qt::RightToolBarArea | Qt::TopToolBarArea);
    connect(toolBar, SIGNAL(orientationChanged(Qt::Orientation)),
		this, SLOT(updateToolbarOrientation(Qt::Orientation)));
    updateToolbarLocation();
    setupEnabledActionsList();
    if (!globalSettings.initialToolbar && !outfile)
	toolBar->hide();

    toolbarAction->setChecked(true);
    my.toolbarHidden = !globalSettings.initialToolbar;
    my.consoleHidden = true;
    if (!pmDebug)
	consoleAction->setVisible(false);
    consoleAction->setChecked(false);

    if (outfile)
	QTimer::singleShot(0, this, SLOT(exportFile()));
    else
	QTimer::singleShot(PmChart::defaultTimeout(), this, SLOT(timeout()));
}
Exemple #6
0
//------------------------------------------------------------------------------
void MainWindow::setupStatusBar()
{
    mStatusBar = new QStatusBar(this);
    mStatusBar->setObjectName(QString::fromUtf8("mStatusBar"));

    mProgressBar = new QProgressBar(this);
    mStatusBar->addWidget(mProgressBar);

    mProgressLabel = new QLabel(this);
    mStatusBar->addWidget(mProgressLabel, 1);

    mProgressLabel->setText("");
    mProgressLabel->setVisible(false);

    mProgressBar->setFixedWidth(200);
    mProgressBar->setMinimum(0);
    mProgressBar->setMaximum(100);
    mProgressBar->setVisible(false);

    mTotalEntriesLabel = new QLabel(this);
    mTotalEntriesLabel->setText(tr("Total Entries : "));
    mStatusBar->addWidget(mTotalEntriesLabel, 1);

    setStatusBar(mStatusBar);
}
Exemple #7
0
mainwindow::mainwindow(essemu &sm, QWidget* parent): shop(sm) ,QMainWindow(parent) {
	tbl=0;
	setGeometry(150,100,705,400);
	setWindowTitle("GuitarShop");

	Menu= new QMenu("File",this);
	MenuT= new QMenu("Tabella",this);
	MenuS= new QMenu("Ricerca",this);
	menuBar()->addMenu(Menu);
	menuBar()->addMenu(MenuT);
	menuBar()->addMenu(MenuS);
	sttbar= new QStatusBar(this);
	setStatusBar(sttbar);

	//file
	New= new QAction("Nuovo",this);
	New->setShortcuts(QKeySequence::New);
	Close= new QAction("Chiudi",this);
	Close->setEnabled(false);
	Open= new QAction("Apri",this);
	Open->setShortcuts(QKeySequence::Open);
	Save= new QAction("Salva",this);
	Save->setShortcuts(QKeySequence::Save);
	Save->setEnabled(false);
	SaveAs= new QAction("Salva come...",this);
	SaveAs->setShortcuts(QKeySequence::SaveAs);
	SaveAs->setEnabled(false);
	Exit= new QAction("Exit",this);
	Exit->setShortcuts(QKeySequence::Close);
	Menu->addAction(New);
	Menu->addAction(Close);
	Menu->addAction(Open);
	Menu->addAction(Save);
	Menu->addAction(SaveAs);
	Menu->addAction(Exit);
	//tabella
	NRow= new QAction("Inserisci Chitarra",this);
	NRow->setEnabled(false);
	DRow= new QAction("Rimuovi Chitarra",this);
    DRow->setShortcut(QKeySequence::Delete);
	DRow->setEnabled(false);
	MenuT->addAction(NRow);
	MenuT->addAction(DRow);
	//ricerca
	Search= new QAction("Search",this);
	Search->setEnabled(false);
	CloseSearch= new QAction("Close Search", this);
	CloseSearch->setEnabled(false);
	MenuS->addAction(Search);
	MenuS->addAction(CloseSearch);
	
	connect(New,SIGNAL(triggered()),this,SLOT(newFile()));
	connect(Close,SIGNAL(triggered()),this,SLOT(closeFile()));
	connect(Open,SIGNAL(triggered()),this,SLOT(openFile()));
	connect(Save,SIGNAL(triggered()),this,SLOT(saveFile()));
	connect(SaveAs,SIGNAL(triggered()),this,SLOT(saveasFile()));
	connect(Exit,SIGNAL(triggered()),this,SLOT(close()));
    connect(Search,SIGNAL(triggered()),this,SLOT(activeSearch()));
    connect(CloseSearch,SIGNAL(triggered()),this,SLOT(closeSearch()));
}
Exemple #8
0
//Public
B9Edit::B9Edit(QWidget *parent, Qt::WFlags flags, QString infile)
	: QMainWindow(parent, flags)
{
	ui.setupUi(this);
    setAcceptDrops(true);
	setStatusBar(0);
	ui.mainToolBar->setMovable(false);
	ui.mainToolBar->setMaximumHeight(24);
	ui.mainToolBar->addAction(ui.actionNew_Job);
	ui.mainToolBar->addAction(ui.actionOpen_Exsisting_Job_File);
	ui.mainToolBar->addAction(ui.actionSave_To_Job);
	ui.mainToolBar->addSeparator();
	ui.mainToolBar->addAction(ui.actionShow_Slice_Window);

    pAboutBox = new aboutbox(this);


	pEditView = new SliceEditView(this);
	pEditView->pCPJ = &cPJ;
	pEditView->pBuilder = this;
	dirtied = false;
	continueLoading = true;
    if(infile == "")
    {
        newJob();
    }
    else
    {
        openJob(infile);
    }
}
void MainWindow::doShowParameterStatistic()
{
    if ( gv_PS.count() > 0 )
        showParameterStatistic( gv_PS );

    setStatusBar( tr( "Ready" ), 2 );
}
Exemple #10
0
void TopLevel::setupStatusBar()
{
  statusbar = new KStatusBar(this);
  statusbar->insertItem("", ID_GENERAL);
  statusbar->setInsertOrder(KStatusBar::LeftToRight);
  setStatusBar(statusbar);
}
void MainWindow::doSaveParameterStatisticPDF()
{
    if ( gv_PS.count() > 0 )
        saveParameterStatistic( gsl_FilenameList.at( 0 ), gv_PS, _FORMATPDF_ );

    setStatusBar( tr( "Done" ), 2 );
}
Exemple #12
0
MainWindow::MainWindow(QWidget* parent) : QMainWindow(parent),
   m_toolBar(this),
   m_aboutDialog(this),
   m_helpBrowser(this),
   m_viewerModel(this),
   m_viewerView(this),
   m_undoStack(this),
   m_undoStackView(&m_undoStack, this),
   m_viewer(m_viewerModel, this),
   m_viewerSelectionModel(&m_viewerModel, this),
   m_logMessageDialog(0),
   m_preferencesBrowser(this),
   m_quiInputDialog(0),
   m_shaderDialog(0)
{
   setStatusBar(0);
   setWindowTitle("IQmol");
   setWindowModified(false);
   setAcceptDrops(false);
   setWindowIcon(QIcon(":/resources/icons/iqmol.png"));

   createMenus();
   createLayout();
   createConnections(); 

   m_undoStack.setUndoLimit(Preferences::UndoLimit());
   m_undoStackView.setEmptyLabel("History:");
   m_viewerView.setModel(&m_viewerModel);
   m_viewerView.setSelectionModel(&m_viewerSelectionModel);
   m_viewer.setActiveViewerMode(Viewer::BuildAtom);

   m_viewer.setDefaultSceneRadius();
   m_viewer.resetView();
}
Exemple #13
0
void FMainWindow::initUI()
{
    titleBar = FTitleBar::getInstace();

    setObjectName(QString("FMainWindow"));
    QDesktopWidget* desktopWidget = QApplication::desktop();
    setMaximumSize(desktopWidget->availableGeometry().size());
    readSettings();

    setWindowFlags(Qt::FramelessWindowHint | Qt::WindowMinimizeButtonHint);
	
	setWindowTitle(sql.strtitle);

    pstatusbar = new QStatusBar;
    pstatusbar->setFixedHeight(35);
	pstatusbar->setStyleSheet(QString("QStatusBar::item{border: 0px}"));


	QString currentdatetime = QDateTime::currentDateTime().toString("yyyy-MM-dd  hh:mm:ss");  
	QString strcurrentuser=QApplication::translate("ConnectDB", "\345\275\223\345\211\215\347\224\250\346\210\267", 0, QApplication::UnicodeUTF8);
	QString strtime =QApplication::translate("ConnectDB", "\347\231\273\345\275\225\346\227\266\351\227\264", 0, QApplication::UnicodeUTF8);
	strcurrentuser +=":"+sql.struser+"   ";
	strtime+=":"+currentdatetime;
	QString str=strcurrentuser+strtime;
    pstatusbar->showMessage(str);
	setStatusBar(pstatusbar);


    trayicon = new QSystemTrayIcon(QIcon(QString(":/skin/images/his.ico")), this);
    trayicon->setObjectName(QString("trayicon"));
    trayicon->setToolTip(QString(qApp->applicationName()));
    trayicon->show();
}
// Create and initialize the UI.
FeaturesUI::FeaturesUI ( QWidget * parent ) : QMainWindow ( parent )
{
  doc = new FeaturesDoc ( this );
  QStatusBar * statusBar = new QStatusBar ( this );
  setStatusBar ( statusBar );
  QObject::connect ( doc, SIGNAL ( alert ( QString ) ),
                     statusBar, SLOT ( showMessage ( const QString & ) ) );
  // Create the main window.
  setFixedSize ( minWidth, minHeight );
  setWindowTitle ( "Features" );

  // Create the menu bar.
  QMenuBar * menuBar = new QMenuBar ( this );

  menuBar->addMenu ( createFileMenu ( menuBar ) );
  menuBar->addMenu ( createImageMenu ( menuBar ) );
  menuBar->addMenu ( createOptionsMenu ( menuBar ) );
  menuBar->addMenu ( createHelpMenu ( menuBar ) );

  setMenuBar ( menuBar );

  QWidget * widget = new QWidget ( this );
  QHBoxLayout * layout = new QHBoxLayout ( widget );

  // Create the subwindows for viewing the query and result images.
  queryView = new ImageView ( this );
  layout->addWidget ( queryView );

  resultView = new ImageView ( this );
  layout->addWidget ( resultView );

  widget->setLayout ( layout );

  setCentralWidget ( widget );
}
Exemple #15
0
UltraGridMainWindow::UltraGridMainWindow(QWidget *parent)
{
    setupUi(this); // this sets up GUI
    started = false;

    history = settings.getHistory();
    completer = new QCompleter(QStringList::fromSet(history), this);

    address->setCompleter(completer);
    address->completer()->setCompletionMode(QCompleter::PopupCompletion);

    // signals/slots
    connect( pushButton_start, SIGNAL( clicked() ), this, SLOT( doStart() ) );
    connect( pushButton_advanced, SIGNAL( clicked() ), this, SLOT( doAdvanced() ) );
    connect( pushButton_terminal, SIGNAL( clicked() ), this, SLOT( doTerminal() ) );
    connect( actionAbout, SIGNAL( triggered() ), this, SLOT( about() ) );
    connect( &process, SIGNAL( finished( int, QProcess::ExitStatus ) ),
             this, SLOT( UGHasFinished( int, QProcess::ExitStatus ) ) );

    connect( &process, SIGNAL( readyReadStandardOutput () ),
             this, SLOT( outputAvailable ()) );
    connect( &process, SIGNAL( readyReadStandardError () ),
             this, SLOT( outputAvailable ()) );

    setStatusBar(&statusBar);

    terminal = new Terminal(this);
}
Exemple #16
0
void MainWindow::exportBitmap()
{
  QString filter = "Images (";
  QList<QByteArray> formats = QImageWriter::supportedImageFormats();
  for(QList<QByteArray>::iterator i = formats.begin(); i != formats.end(); i++)
  {
    if(i != formats.begin())
    {
      filter += " ";
    }
    filter += "*." + *i;
  }
  filter += ")";

  QString filename = m_fileDialog.getSaveFileName("Save picture", filter);
  if (filename.isNull())
  {
    return;
  }

  SavePictureDialog dialog(this, m_ltsCanvas, filename);
  connect(&dialog, SIGNAL(statusMessage(QString)), this, SLOT(setStatusBar(QString)));
  dialog.exec();
  clearStatusBar();
}
Exemple #17
0
MainWindow::MainWindow(quint32 id, QWidget *parent) :
    QMainWindow(parent)
{
    m_id = id;
    m_hometab = NULL;

    setWindowTitle(titleString);
    setMinimumSize(600, 500);
    setWindowIcon(QIcon(":/icons/icon.png"));
    setAttribute(Qt::WA_DeleteOnClose);
    loadWindowParams();

    QApplication::setFont(Utils::getFontFromString(sConfig.get(CFG_STRING_APP_FONT)));

    setStatusBar(new QStatusBar(this));

    m_tabView = new TabView(this);
    connect(m_tabView, SIGNAL(statusBarMsg(QString,int)), statusBar(), SLOT(showMessage(QString,int)));
    connect(m_tabView, SIGNAL(closeWindow()),                          SLOT(close()));
    connect(m_tabView, SIGNAL(openHomeTab()),                          SLOT(openHomeTab()));
    connect(m_tabView, SIGNAL(closeHomeTab()),                         SLOT(closeHomeTab()));
    connect(m_tabView, SIGNAL(changeWindowTitle(QString)),             SLOT(changeWindowTitle(QString)));

    setCentralWidget(m_tabView);
    openHomeTab();
}
void MENU_KERNEL::ADD_STATUS_BAR_INFO()
{
    QStatusBar * status_bar = new QStatusBar;
    status_bar->setAttribute ( Qt::WA_DeleteOnClose );

    QString values_font = "Ouhod";
    status_bar->setStyleSheet ( "QStatusBar { background-color:rgb(240,240,240); } ; " );
    status_bar->setSizePolicy ( QSizePolicy::Expanding,QSizePolicy::Fixed );

    QLabel * label_kullanici_info    = CREATE_STATUS_BAR_LABEL();
    label_kullanici_info->setText ( QString ( tr("User  :  <span style=\"font-family:'%1'; \">%2 - %3</span>")).arg(values_font).arg(KULLANICI_KODU()).arg(KULLANICI_ADI()));

    QLabel * label_firma_info        = CREATE_STATUS_BAR_LABEL();
    label_firma_info->setText ( QString ( tr("Company  :  <span style=\"font-family:'%1'; \">%2 - %3</span>") ).arg(values_font).arg ( VERITABANI_ISMI() ).arg ( VERITABANI_TANIMI() ) );

    QLabel * label_bilgisayar_info   = CREATE_STATUS_BAR_LABEL();
    label_bilgisayar_info->setText ( QString ( tr("Computer  :  <span style=\"font-family:'%1'; \">%2 - %3</span>") ).arg(values_font).arg(BILGISAYAR_KODU()).arg(BILGISAYAR_ADI() ) );

    QLabel * label_program_info      = CREATE_STATUS_BAR_LABEL();
    label_program_info->setText ( QString ( "<span style=\"font-family:'%1'; \">%2 %3</span>" ).arg(values_font).arg(ADAK_PROGRAM_SHORTNAME(ADAK_DISPLAY_ID())).arg(ADAK_PROGRAM_VERSION(ADAK_DISPLAY_ID())));

    status_bar->insertPermanentWidget ( 0, label_firma_info      ,3 );
    status_bar->insertPermanentWidget ( 1, label_kullanici_info  ,3 );
    status_bar->insertPermanentWidget ( 2, label_bilgisayar_info ,3 );
    status_bar->insertPermanentWidget ( 3, label_program_info    ,0 );

    setStatusBar ( status_bar );
}
void MainWindow::doPrintParameterStatistic()
{
    if ( gv_PS.count() > 0 )
    {
        QTextDocument   textDocu;

        QPrinter        printer;
        QPrintDialog    printDialog( &printer, this );

        printer.setOrientation( QPrinter::Landscape );

        if ( printDialog.exec() == QDialog::Accepted )
        {
            QFileInfo   fi( gsl_FilenameList.at( 0 ) );
            QFont       textFont = QFont( gf_HeaderTextFont.family(), 10, 0, false );

            printer.setOutputFileName( tr( "" ) );
            textDocu.setHtml( createParameterStatisticOutputText( fi.fileName(), gv_PS ) );
            textDocu.setDefaultFont( textFont );
            textDocu.print( &printer );
        }

        update();
    }

    setStatusBar( tr( "Done" ), 2 );
}
Exemple #20
0
ChatWindow::ChatWindow(QString jid, QXmppClient *client, QWidget *parent) :
    QMainWindow(parent),
    m_jid(jid),
    m_client(client),
    m_selfState(QXmppMessage::Active),
    m_pausedTimer(new QTimer),
    m_inactiveTimer(new QTimer),
    m_goneTimer(new QTimer),
    m_statusBar(new QStatusBar),
    m_sendButton(new QPushButton),
    m_sendTip(new QLabel)
{
    ui.setupUi(this);

    setWindowTitle(QString(tr("Contact: %1")).arg(m_jid));

    m_editor = new MessageEdit();
    QVBoxLayout *layout = new QVBoxLayout();
    layout->addWidget(m_editor);
    layout->setMargin(0);
    ui.editorWarpwidget->setLayout(layout);
    m_editor->setFocus();

    m_sendButton->setText(tr("Send"));
    m_sendButton->setFixedHeight(m_statusBar->sizeHint().height());
    m_statusBar->addPermanentWidget(m_sendTip);
    m_statusBar->addPermanentWidget(m_sendButton);
    m_statusBar->setSizeGripEnabled(false);
    setStatusBar(m_statusBar);

    // init ui
    QXmppRoster::QXmppRosterEntry entry = m_client->getRoster().getRosterEntry(jidToBareJid(m_jid));
    ui.name->setText(entry.name());
    ui.jid->setText(m_jid);
    if (m_client->getRoster().getResources(jidToBareJid(m_jid)).isEmpty())
        ui.photo->setPixmap(QPixmap(":/images/user-identity-grey-100.png"));
    else
        ui.photo->setPixmap(QPixmap(":/images/user-identity-100.png"));

    connect(m_sendButton, SIGNAL(clicked()),
            this, SLOT(sendMessage()));
    connect(m_editor, SIGNAL(textChanged()),
            this, SLOT(sendComposing()));
    connect(m_pausedTimer, SIGNAL(timeout()),
            this, SLOT(pausedTimeout()));
    connect(m_inactiveTimer, SIGNAL(timeout()),
            this, SLOT(inactiveTimeout()));
    connect(m_goneTimer, SIGNAL(timeout()),
            this, SLOT(goneTimeout()));
    connect(ui.detailButton, SIGNAL(clicked()),
            this, SLOT(openContactInfoDialog()) );

    // action
    connect(ui.actionSendFile, SIGNAL(triggered()),
            this, SLOT(sendFileSlot()) );

    setAttribute(Qt::WA_QuitOnClose, false);
    setAttribute(Qt::WA_DeleteOnClose, true);
}
Exemple #21
0
ListEditView::ListEditView(RosegardenDocument *doc,
                           std::vector<Segment *> segments,
                           unsigned int cols,
                           QWidget *parent) :
    EditViewBase(doc, segments, parent),
    m_viewNumber( -1),
    m_viewLocalPropertyPrefix(makeViewLocalPropertyPrefix()),
    m_mainDockWidget(0),
    m_centralFrame(0),
    m_grid(0),
    m_mainCol(cols - 1),
    m_compositionRefreshStatusId(doc->getComposition().getNewRefreshStatusId()),
    m_needUpdate(false),
    m_pendingPaintEvent(0),
    m_havePendingPaintEvent(false),
    m_inCtor(true),
    m_timeSigNotifier(new EditViewTimeSigNotifier(doc))
{
    QPixmap dummyPixmap; // any icon will do
	
	
	/*
	m_mainDockWidget = new QDockWidget( "Rosegarden EditView DockWidget", this );
	m_mainDockWidget->setAllowedAreas( Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea );
	m_mainDockWidget->setFeatures( QDockWidget::AllDockWidgetFeatures );
	
	addDockWidget( Qt::LeftDockWidgetArea, m_mainDockWidget, Qt::Horizontal );
	*/
	m_mainDockWidget = 0;
	
	setStatusBar( new QStatusBar(this) );
/*	
	m_toolBar = new QToolBar( "Tool Bar", this );
	addToolBar( Qt::TopToolBarArea, m_toolBar );
	m_toolBar->setMinimumHeight( 16 );
	m_toolBar->setMinimumWidth( 40 );
*/	
    m_centralFrame = new QFrame(this);		//m_mainDockWidget);
    m_centralFrame->setObjectName("centralframe");
	m_centralFrame->setMinimumSize( 500, 300 );
	m_centralFrame->setMaximumSize( 2200, 1400 );
	
	// 
	m_grid = new QGridLayout(m_centralFrame);
	m_centralFrame->setLayout( m_grid );
	
	// Note: We add Widget bottom-right, so the grid gets the propper col,row count
	// NbLayoutRows, cols
	//m_grid->addWidget( new QWidget(this), NbLayoutRows, cols);
	
	
	//this->setLayout( new QVBoxLayout(this) );
	//this->layout()->addWidget( m_centralFrame );
	setCentralWidget( m_centralFrame );
	
//    m_mainDockWidget->setWidget(m_centralFrame);

    initSegmentRefreshStatusIds();
}
Exemple #22
0
MainWindow::MainWindow(QWidget *parent)
	: KXmlGuiWindow(parent)
{
	setWindowTitle(i18n("Silence"));
	Controller *controller = Controller::create();
	controller->setMainWindow(this);
	controller->setActionManager(new ActionManager(actionCollection()));


	centralwidgetstack = new QStackedWidget;
	setCentralWidget(centralwidgetstack);

	// ContentView
	contentview = new ContentView;
	centralwidgetstack->addWidget(contentview);
	controller->setContentView(contentview);

	nodepropertywidget = new NodePropertyWidget(i18n("Properties"), this);
	nodepropertywidget->hide();
	controller->setNodePropertyWidget(nodepropertywidget);

	// the treeview on the left side
	treeview = new TreeView(i18n("Nodes"), this);
	controller->setTreeView(treeview);

	// search sidebar
	searchnodesidebar = new SearchNodeSidebar(i18n("Search Nodes"), this);
	controller->setSearchNodeSidebar(searchnodesidebar);

	// navigation sidebar
	navigationsidebar = new NavigationSidebar(i18nc("title of the navigation sidebar", "Navigation"), this);
	controller->setNavigationSidebar(navigationsidebar);

	// information sidebar to show the metainfos
	infosidebar = new InfoSidebar(i18n("Information"), this);
	controller->setInfoSidebar(infosidebar);

	// docking the widgets
	addDockWidget(Qt::RightDockWidgetArea, navigationsidebar);
	addDockWidget(Qt::RightDockWidgetArea, infosidebar);
	addDockWidget(Qt::LeftDockWidgetArea, treeview);
	addDockWidget(Qt::LeftDockWidgetArea, treeview);
	tabifyDockWidget(treeview, searchnodesidebar);
	addDockWidget(Qt::LeftDockWidgetArea, nodepropertywidget);

	statusbar = new SiStatusBar;
	setStatusBar(statusbar);
	controller->setStatusBar(statusbar);

	controller->getTextEdit()->setVisible(false);
	controller->getRichTextEdit()->setVisible(false);

	viewmenu = new ViewMenu();
	connect(controller->getActionManager()->getGlobalAction(Actions::EXIT), SIGNAL(triggered()), this, SLOT(quit()));

	silencemenu = new SilenceMenu(actionCollection());

	setupGUI(QSize(1100, 600), Keys | StatusBar | Save | Create);
}
//! Initialisierungsroutine
void MainWindow::init()
{
  //! Signal-Slots verbinden
  //! Slot für die Überwachung verbinden
  connect(ui->acMonitoring, SIGNAL(triggered()), this, SLOT(acControling()));

  //! Slot für die Gebietsbehandlung verbinden
  connect(ui->acAreaHandling, SIGNAL(triggered()), this, SLOT(acAreaHandling()));

  //! Slot für die Disposition verbinden
  connect(ui->acAreaDispo, SIGNAL(triggered()), this, SLOT(acAreaDispo()));

  //! Slot für die Definition von Gebieten verbinden
  connect(ui->acDefArea, SIGNAL(triggered()), this, SLOT(acDefArea()));

  //! Slot für die Definition von Teilgebieten verbinden
  connect(ui->acDefAreaPart, SIGNAL(triggered()), this, SLOT(acDefAreaPart()));

  //! Slot für die Definition von Verkündigern verbinden
  connect(ui->acDefProphet, SIGNAL(triggered()), this, SLOT(acDefProphet()));

  //! Slot für die Suche verbinden
  connect(ui->acSearch, SIGNAL(triggered()), this, SLOT(acSearch()));

  //! Slot für das Beenden verbinden
  connect(ui->acExit, SIGNAL(triggered()), this, SLOT(acExit()));

  //! Slot für das Drucken von Gebieten
  connect(ui->acPrintArea, SIGNAL(triggered()), this, SLOT(acPrintArea()));

  //! Slot für das Definieren von Kompanien
  connect(ui->acDefCompany, SIGNAL(triggered()), this, SLOT(acCompanyWidget()));

  //! Slot für das Anzeigen von Informationen
  connect(ui->acInfo, SIGNAL(triggered()), this, SLOT(acInfoWidget()));

  //! Slot für das Anzeigen von Problemen
  connect(ui->acProblem, SIGNAL(triggered()), this, SLOT(acProblemWidget()));


  //! Zeiger auf NULL legen
  _AreaWidget = NULL;
  _AreaPartWidget = NULL;
  _AreaHandlingWidget = NULL;
  _AreaDispoWidget = NULL;
  _ProphetWidget = NULL;
  _ControlWidget = NULL;
  _SearchWidget = NULL;
  _PrintWidget = NULL;
  _CompanyWidget = NULL;
  _InfoWidget = NULL;
  _ProblemWidget = NULL;

  //! Fensterüberschrift setzen
  setWindowTitle(tr("Gebietsbearbeitung"));

  //! Statusleiste initialisieren
  setStatusBar();
}
Exemple #24
0
NormalWindow::NormalWindow(IMessageWidgets *AMessageWidgets, const Jid& AStreamJid, const Jid &AContactJid, Mode AMode)
{
	REPORT_VIEW;
	ui.setupUi(this);
	setAttribute(Qt::WA_DeleteOnClose,true);
	ui.spwMessageBox->setSpacing(3);

	FMessageWidgets = AMessageWidgets;

	FShownDetached = false;
	FCurrentThreadId = QUuid::createUuid().toString();

	FTabPageNotifier = NULL;

	FAddress = FMessageWidgets->newAddress(AStreamJid,AContactJid,this);

	FSubjectWidget = new QLineEdit(ui.spwMessageBox);
	FSubjectWidget->setPlaceholderText(tr("Subject"));
	ui.spwMessageBox->insertWidget(MNWW_SUBJECTWIDGET,FSubjectWidget);

	FInfoWidget = FMessageWidgets->newInfoWidget(this,ui.spwMessageBox);
	ui.spwMessageBox->insertWidget(MNWW_INFOWIDGET,FInfoWidget->instance());

	FViewWidget = FMessageWidgets->newViewWidget(this,ui.spwMessageBox);
	ui.spwMessageBox->insertWidget(MNWW_VIEWWIDGET,FViewWidget->instance(),100);

	FEditWidget = FMessageWidgets->newEditWidget(this,ui.spwMessageBox);
	FEditWidget->setEditToolBarVisible(false);
	FEditWidget->setSendShortcutId(SCT_MESSAGEWINDOWS_SENDNORMALMESSAGE);
	ui.spwMessageBox->insertWidget(MNWW_EDITWIDGET,FEditWidget->instance(),100);

	FToolBarWidget = FMessageWidgets->newToolBarWidget(this,ui.spwMessageBox);
	FToolBarWidget->toolBarChanger()->setSeparatorsVisible(false);
	ui.spwMessageBox->insertWidget(MNWW_TOOLBARWIDGET,FToolBarWidget->instance());

	ui.wdtReceiversTree->setLayout(new QVBoxLayout(ui.wdtReceiversTree));
	ui.wdtReceiversTree->layout()->setMargin(0);
	FReceiversWidget = FMessageWidgets->newReceiversWidget(this,ui.wdtReceivers);
	connect(FReceiversWidget->instance(),SIGNAL(addressSelectionChanged()),SLOT(onReceiverslAddressSelectionChanged()));
	FReceiversWidget->setAddressSelection(AStreamJid,AContactJid,true);
	ui.wdtReceiversTree->layout()->addWidget(FReceiversWidget->instance());

	FMenuBarWidget = FMessageWidgets->newMenuBarWidget(this,this);
	setMenuBar(FMenuBarWidget->instance());

	FStatusBarWidget = FMessageWidgets->newStatusBarWidget(this,this);
	setStatusBar(FStatusBarWidget->instance());

	Menu *menu = new Menu(ui.tlbReceivers);
	ui.tlbReceivers->setMenu(menu);
	connect(menu,SIGNAL(aboutToShow()),SLOT(onSelectReceiversMenuAboutToShow()));

	IconStorage::staticStorage(RSR_STORAGE_MENUICONS)->insertAutoIcon(ui.tlbReceivers,MNI_MESSAGEWIDGETS_SELECT);

	connect(Shortcuts::instance(),SIGNAL(shortcutActivated(const QString, QWidget *)),SLOT(onShortcutActivated(const QString, QWidget *)));

	setMode(AMode);
	onReceiverslAddressSelectionChanged();
}
Exemple #25
0
void MainWindow::createStatusBar()
{
    mStatusBar = new QStatusBar(this);
    mProgressBar = new QProgressBar(mStatusBar);
    mProgressBar->setValue(0);
    mStatusBar->addPermanentWidget(mProgressBar);
    setStatusBar(mStatusBar);
}
Exemple #26
0
void ScribusWin::setView(ScribusView* newView)
{
	m_View = newView;
	++m_Doc->viewCount;
	m_winIndex = ++m_Doc->viewID;
	setCentralWidget(newView);
	setStatusBar(0);
}
KTMainWindow::KTMainWindow(KTSplash *splash) : DMainWindow(), m_exposureSheet(0), m_scenes(0)
{
	DINIT;
	
	setObjectName("KTMainWindow_");
	
	m_osd = new KTOsd( centralWidget() );
	
	m_statusBar = new KTStatusBar(this);
	setStatusBar( m_statusBar );
	
	setWindowTitle(tr("KToon: 2D animation toolkit"));
	m_renderType = KToon::RenderType(DCONFIG->value("RenderType").toInt());
	
	
	m_projectManager = new KTProjectManager(this);
	splash->setMessage( tr("Setting up the project manager") );
	
	m_drawingSpace = new KTWorkspace;
	m_drawingSpace->setWindowIcon(QIcon(THEME_DIR+"/icons/illustration_mode.png"));
	m_drawingSpace->setScrollBarsEnabled( true );
	
	addWidget(m_drawingSpace, tr("Illustration"), true);
	
	m_animationSpace = new KTWorkspace;
	m_animationSpace->setWindowIcon(QIcon(THEME_DIR+"/icons/animation_mode.png"));
	m_animationSpace->setScrollBarsEnabled ( true );
	
	connect(m_animationSpace, SIGNAL(contextMenu( const QPoint& )), this, SLOT(showAnimationMenu( const QPoint& )));

	addWidget(m_animationSpace, tr("Animation"), true);
	
	splash->setMessage( tr("Loading action manager..."));
	m_actionManager = new DActionManager(this);
	
// 	Create the menubar;
	splash->setMessage( tr("Creating menu bar..."));
	setupActions();
	
	splash->setMessage( tr("Creating GUI..."));
	
	createGUI();
	
	setupMenu();
	
	m_pActiveTabWidget->setCurrentIndex( 0 );
	
	DCONFIG->beginGroup("TipOfDay");
	bool showTips = qvariant_cast<bool>(DCONFIG->value("ShowOnStart", true ));
	
	
	if ( showTips )
	{
		QTimer::singleShot(0, this, SLOT(showTipDialog()));
	}
	
	KTPluginManager::instance()->loadPlugins();
}
Exemple #28
0
MainWindow::MainWindow(QWidget *parent)
	: KXmlGuiWindow(parent)
{
	setWindowTitle(i18n("Silence"));
	controller = Controller::create();

	// ContentView
	contentview = new ContentView;
	setCentralWidget(contentview);
	controller->setContentView(contentview);


	nodepropertywidget = new NodePropertyWidget(i18n("Properties"), this);
	nodepropertywidget->hide();
	controller->setNodePropertyWidget(nodepropertywidget);

	// the treeview on the left side
	treeview = new TreeView(i18n("Nodes"), actionCollection(), this);
	controller->setTreeView(treeview);

	// search sidebar
	searchnodesidebar = new SearchNodeSidebar(i18n("Search Nodes"), this);
	controller->setSearchNodeSidebar(searchnodesidebar);

	// navigation sidebar
	navigationsidebar = new NavigationSidebar(i18n("Navigation"), this);
	controller->setNavigationSidebar(navigationsidebar);

	// information sidebar to show the meta-infos
	infosidebar = new InfoSidebar(i18n("Info"), this);
	controller->setInfoSidebar(infosidebar);

	// docking the widgets
	addDockWidget(Qt::RightDockWidgetArea, navigationsidebar);
	addDockWidget(Qt::RightDockWidgetArea, infosidebar);
	addDockWidget(Qt::LeftDockWidgetArea, treeview);
	addDockWidget(Qt::LeftDockWidgetArea, treeview);
	tabifyDockWidget(treeview, searchnodesidebar);
	addDockWidget(Qt::LeftDockWidgetArea, nodepropertywidget);

	statusbar = new SiStatusBar;
	setStatusBar(statusbar);
	controller->setStatusBar(statusbar);

	controller->setActionCollection(actionCollection());

	controller->getTextEdit()->setVisible(false);
	controller->getRichTextEdit()->setVisible(false);

	viewmenu = new ViewMenu(actionCollection());
	KAction *action = actionCollection()->addAction("exit");
	action->setText(i18n("&Exit"));
	action->setIcon(KIcon("application-exit"));
	connect(action, SIGNAL(triggered()), qApp, SLOT(quit()));

	setupGUI(QSize(1100, 600), Keys | StatusBar | Save | Create);
}
Exemple #29
0
GWorkBench::GWorkBench(QWidget *parent)
    : QMainWindow(parent) // 2012-01-10 to have a separate entry in the task bar
{
    InitBench();
    setStatusBar(0);

    // test for nested docks
    setDockNestingEnabled(true);
}
Exemple #30
0
void
MainWindow::init()
{
	makeUI();
	createActions();
	createConnects();
	setStatusBar(statusBar());
	attachWidget();
}