#include "FuncRequest.h"
#include "Language.h"
-#include <QCloseEvent>
-
-using std::vector;
-using std::string;
+using namespace std;
namespace lyx {
namespace frontend {
}
-GuiCharacter::GuiCharacter(LyXView & lv)
- : GuiDialog(lv, "character"), font_(ignore_font),
+GuiCharacter::GuiCharacter(GuiView & lv)
+ : GuiDialog(lv, "character", qt_("Text Style")), font_(ignore_font),
toggleall_(false), reset_lang_(false)
{
setupUi(this);
- setViewTitle(_("Text Style"));
connect(okPB, SIGNAL(clicked()), this, SLOT(slotOK()));
connect(applyPB, SIGNAL(clicked()), this, SLOT(slotApply()));
connect(langCO, SIGNAL(activated(int)), this, SLOT(change_adaptor()));
connect(toggleallCB, SIGNAL(clicked()), this, SLOT(change_adaptor()));
+#ifdef Q_WS_MACX
+ // On Mac it's common to have tool windows which are always in the
+ // foreground and are hidden when the main window is not focused.
+ setWindowFlags(Qt::Tool);
+ autoapplyCB->setChecked(true);
+#endif
+
family = getFamilyData();
series = getSeriesData();
shape = getShapeData();
}
-void GuiCharacter::closeEvent(QCloseEvent * e)
-{
- slotClose();
- GuiDialog::closeEvent(e);
-}
-
-
template<class A, class B>
-static int findPos2nd(vector<std::pair<A, B> > const & vec, B const & val)
+static int findPos2nd(vector<pair<A, B> > const & vec, B const & val)
{
- typedef typename vector<std::pair<A, B> >::const_iterator
+ typedef typename vector<pair<A, B> >::const_iterator
const_iterator;
for (const_iterator cit = vec.begin(); cit != vec.end(); ++cit)
}
-Dialog * createGuiCharacter(LyXView & lv) { return new GuiCharacter(lv); }
+Dialog * createGuiCharacter(GuiView & lv) { return new GuiCharacter(lv); }
} // namespace frontend