#include "GuiApplication.h"
#include "GuiFontMetrics.h"
#include "GuiImage.h"
-
-#include "GuiApplication.h"
#include "qt_helpers.h"
-#include "support/debug.h"
#include "Language.h"
#include "LyXRC.h"
-#include "support/unicode.h"
+#include "support/debug.h"
#include <QPixmapCache>
#include <QTextLayout>
setFont(fi.font);
// We need to draw the text as LTR as we use our own bidi code.
setLayoutDirection(Qt::LeftToRight);
- // We need to draw the text as LTR as we use our own bidi code.
- setLayoutDirection(Qt::LeftToRight);
drawText(x, y, str);
//LYXERR(Debug::PAINTING, "draw " << string(str.toUtf8())
// << " at " << x << "," << y);
FontMetrics const & fm = theFontMetrics(font);
fm.buttonText(str, width, ascent, descent);
- button(x + 1, y - ascent, width - 2, descent + ascent, mouseHover);
- text(x + 4, y - 1, str, font);
+ static int const d = Inset::TEXT_TO_INSET_OFFSET / 2;
+
+ button(x + d, y - ascent, width - d, descent + ascent, mouseHover);
+ text(x + Inset::TEXT_TO_INSET_OFFSET, y, str, font);
}