PainterBase & Painter::point(int x, int y, LColor::color c)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "point not called from "
"workarea::workhandler\n";
enum line_style ls,
enum line_width lw)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "line not called from "
"workarea::workhandler\n";
enum line_style ls,
enum line_width lw)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "lines not called from "
"workarea::workhandler\n";
enum line_style ls,
enum line_width lw)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "rectangle not called from "
"workarea::workhandler\n";
PainterBase & Painter::fillRectangle(int x, int y, int w, int h,
LColor::color col)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "fillrectangle not called from "
"workarea::workhandler\n";
PainterBase & Painter::fillPolygon(int const * xp, int const * yp, int np,
LColor::color col)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr <<"fillpolygon not called from "
"workarea::workhandler\n";
unsigned int w, unsigned int h,
int a1, int a2, LColor::color col)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "arc not called from "
"workarea::workhandler\n";
LColor::color col,
enum line_style ls, enum line_width lw)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "segments not called from "
"workarea::workhandler\n";
PainterBase & Painter::pixmap(int x, int y, int w, int h, Pixmap bitmap)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "workAreaExpose not called from "
"workarea::workhandler\n";
}
-PainterBase & Painter::text(int x, int y, char const * s, int ls,
+PainterBase & Painter::text(int x, int y, char const * s, size_t ls,
LyXFont const & f)
{
if (lyxrc.font_norm_type == LyXRC::ISO_10646_1) {
font2.setShape(LyXFont::UP_SHAPE);
font = &font2;
#endif
- encoding = &symbol_encoding;
+ encoding = encodings.symbol_encoding();
}
- for (int i = 0; i < ls; ++i) {
+ for (size_t i = 0; i < ls; ++i) {
Uchar c = encoding->ucs(s[i]);
xs[i].byte1 = c >> 8;
xs[i].byte2 = c & 0xff;
return *this;
}
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "text not called from "
"workarea::workhandler\n";
smallfont.decSize().decSize().setShape(LyXFont::UP_SHAPE);
char c;
int tmpx = x;
- for(int i = 0; i < ls; ++i) {
+ for(size_t i = 0; i < ls; ++i) {
c = s[i];
if (islower(static_cast<unsigned char>(c))) {
c = toupper(c);
XDrawString(display, owner.getPixmap(),
gc, tmpx, y, &c, 1);
tmpx += lyxfont::XTextWidth(smallfont, &c, 1);
- //tmpx += lyxfont::width(c, f);
} else {
lyxfont::XSetFont(display, gc, f);
XDrawString(display, owner.getPixmap(),
gc, tmpx, y, &c, 1);
tmpx += lyxfont::XTextWidth(f, &c, 1);
- //tmpx += lyxfont::width(c, f);
}
}
}
PainterBase & Painter::text(int x, int y, XChar2b const * s, int ls,
LyXFont const & f)
{
- if (lyxerr.debugging()) {
+ if (lyxerr.debugging(Debug::GUI)) {
if (!Lgb_bug_find_hack)
lyxerr << "text not called from "
"workarea::workhandler\n";