4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
10 * Full author contact details are available in file CREDITS.
17 #include "support/qstring_helpers.h"
31 /// method to get a Length from widgets (LengthCombo)
32 std::string widgetsToLength(QLineEdit const * input, LengthCombo const * combo);
33 /// method to get a Length from widgets (QComboBox)
34 Length widgetsToLength(QLineEdit const * input, QComboBox const * combo);
36 //FIXME It would be nice if defaultUnit were a default argument
37 /// method to set widgets from a Length
38 void lengthToWidgets(QLineEdit * input, LengthCombo * combo,
39 Length const & len, Length::UNIT default_unit);
40 /// method to set widgets from a string
41 void lengthToWidgets(QLineEdit * input, LengthCombo * combo,
42 std::string const & len, Length::UNIT default_unit);
43 /// method to set widgets from a Length with optional "auto" if zero
44 void lengthAutoToWidgets(QLineEdit * input, LengthCombo * combo,
45 Length const & len, Length::UNIT defaultUnit);
47 /// colors a widget red if invalid
48 void setValid(QWidget * widget, bool valid);
52 * qt_ - i18nize string and convert to QString
54 * Use this in qt4/ instead of _()
56 QString const qt_(char const * str, const char * comment = 0);
60 * qt_ - i18nize string and convert to QString
62 * Use this in qt4/ instead of _()
64 QString const qt_(std::string const & str);