+// -*- C++ -*-
/**
* \file iconpalette.h
- * Copyright 2001 the LyX Team
- * Read the file COPYING
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
*
* \author John Levon
+ *
+ * Full author contact details are available in file CREDITS
*/
#ifndef ICONPALETTE_H
#define ICONPALETTE_H
-#include <config.h>
+#ifdef __GNUG__
+#pragma interface
+#endif
-#include "LString.h"
-
#include <qwidget.h>
-
-#include <map>
+#include "LString.h"
+#include <utility>
+#include <vector>
class QPixmap;
class QPushButton;
/// add a button
void add(QPixmap const & pixmap, string name, string tooltip);
-
signals:
- void button_clicked(string);
-
+ void button_clicked(string const &);
protected:
virtual void resizeEvent(QResizeEvent * e);
-
protected slots:
virtual void clicked();
-
private:
- typedef std::map<QPushButton *, string> ButtonMap;
+ int maxcol_;
- int crow_;
- int ccol_;
-
QGridLayout * layout_;
-
- ButtonMap button_map_;
+
+ typedef std::pair<QPushButton *, string> Button;
+
+ std::vector<Button> buttons_;
};
#endif // ICONPALETTE_H