2006-03-05 17:24:44 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
/**
|
2007-08-31 05:53:55 +00:00
|
|
|
* \file GuiBranches.h
|
2006-03-05 17:24:44 +00:00
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
*
|
|
|
|
* \author Edwin Leuven
|
|
|
|
*
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
*/
|
|
|
|
|
2007-08-31 22:16:11 +00:00
|
|
|
#ifndef GUIBRANCHES_H
|
|
|
|
#define GUIBRANCHES_H
|
2006-03-05 17:24:44 +00:00
|
|
|
|
2007-08-31 05:53:55 +00:00
|
|
|
#include "GuiDocument.h"
|
2007-09-05 20:33:29 +00:00
|
|
|
#include "ui_BranchesUi.h"
|
2006-03-05 17:24:44 +00:00
|
|
|
#include "BranchList.h"
|
|
|
|
|
|
|
|
#include <QWidget>
|
|
|
|
|
|
|
|
#include <vector>
|
|
|
|
#include <string>
|
|
|
|
|
|
|
|
|
2006-05-04 07:31:46 +00:00
|
|
|
class QTreeWidgetItem;
|
2006-03-05 17:24:44 +00:00
|
|
|
|
2006-10-21 00:16:43 +00:00
|
|
|
namespace lyx {
|
|
|
|
|
2006-03-05 17:24:44 +00:00
|
|
|
class BufferParams;
|
|
|
|
|
|
|
|
namespace frontend {
|
|
|
|
|
2007-09-05 20:33:29 +00:00
|
|
|
class GuiBranches : public QWidget, public Ui::BranchesUi
|
2006-03-05 17:24:44 +00:00
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2007-08-31 05:53:55 +00:00
|
|
|
GuiBranches(QWidget * parent=0, Qt::WFlags f=0);
|
2006-04-05 23:56:29 +00:00
|
|
|
|
2006-03-05 17:24:44 +00:00
|
|
|
void update(BufferParams const & params);
|
|
|
|
void apply(BufferParams & params) const;
|
2006-03-20 17:25:02 +00:00
|
|
|
|
2006-06-30 14:37:33 +00:00
|
|
|
Q_SIGNALS:
|
2006-03-20 17:25:02 +00:00
|
|
|
void changed();
|
2006-03-05 17:24:44 +00:00
|
|
|
|
|
|
|
protected:
|
2006-05-04 07:31:46 +00:00
|
|
|
void toggleBranch(QTreeWidgetItem *);
|
2006-11-04 15:08:53 +00:00
|
|
|
void toggleColor(QTreeWidgetItem *);
|
2007-09-03 20:28:26 +00:00
|
|
|
void updateView();
|
2006-03-05 17:24:44 +00:00
|
|
|
|
2006-06-30 14:37:33 +00:00
|
|
|
protected Q_SLOTS:
|
2006-03-05 17:24:44 +00:00
|
|
|
void on_addBranchPB_pressed();
|
|
|
|
void on_removePB_pressed();
|
|
|
|
void on_activatePB_pressed();
|
2006-05-04 07:31:46 +00:00
|
|
|
void on_branchesTW_itemDoubleClicked(QTreeWidgetItem *, int);
|
2006-03-05 17:24:44 +00:00
|
|
|
void on_colorPB_clicked();
|
|
|
|
|
|
|
|
private:
|
|
|
|
/// Contains all legal branches for this doc
|
|
|
|
BranchList branchlist_;
|
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace frontend
|
|
|
|
} // namespace lyx
|
|
|
|
|
2007-08-31 22:16:11 +00:00
|
|
|
#endif // GUIBRANCHES
|