summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 00fdad6)
raw | patch | inline | side by side (parent: 00fdad6)
author | gouldtj <gouldtj@users.sourceforge.net> | |
Sun, 6 Jan 2008 21:51:15 +0000 (21:51 +0000) | ||
committer | gouldtj <gouldtj@users.sourceforge.net> | |
Sun, 6 Jan 2008 21:51:15 +0000 (21:51 +0000) |
Swapping arround some logic and setting up the grid lines so that major
ones are drawn when zoomed out correctly. This is lp:167422
ones are drawn when zoomed out correctly. This is lp:167422
src/display/canvas-grid.cpp | patch | blob | history |
index 20856709cfdfcd3251004f1ed1ec597289724cfa..0edcbd0ab0653480c2953016c44af1f51f514b7c 100644 (file)
for (y = syg, ylinenum = ylinestart; y < buf->rect.y1; y += sw[NR::Y], ylinenum++) {
gint const y0 = (gint) Inkscape::round(y);
- if (!scaled[NR::Y] && (ylinenum % empspacing) == 0) {
- grid_hline (buf, y0, buf->rect.x0, buf->rect.x1 - 1, empcolor);
- } else {
+ if (!scaled[NR::Y] && (ylinenum % empspacing) != 0) {
grid_hline (buf, y0, buf->rect.x0, buf->rect.x1 - 1, color);
+ } else {
+ grid_hline (buf, y0, buf->rect.x0, buf->rect.x1 - 1, empcolor);
}
}
gdouble x;
for (x = sxg, xlinenum = xlinestart; x < buf->rect.x1; x += sw[NR::X], xlinenum++) {
gint const ix = (gint) Inkscape::round(x);
- if (!scaled[NR::X] && (xlinenum % empspacing) == 0) {
- grid_vline (buf, ix, buf->rect.y0, buf->rect.y1, empcolor);
- } else {
+ if (!scaled[NR::X] && (xlinenum % empspacing) != 0) {
grid_vline (buf, ix, buf->rect.y0, buf->rect.y1, color);
+ } else {
+ grid_vline (buf, ix, buf->rect.y0, buf->rect.y1, empcolor);
}
}
} else {