diff options
author | Christof Pintaske <cp@openoffice.org> | 2001-08-30 11:39:13 +0000 |
---|---|---|
committer | Christof Pintaske <cp@openoffice.org> | 2001-08-30 11:39:13 +0000 |
commit | c0de6689813f5e1993269b4dfdbc00d7b3761be0 (patch) | |
tree | 74c34c5eacd77da81c0409b055e8cd7261702e34 /psprint | |
parent | a7daeb72a6586b74c48bea5e851f368524801b4d (diff) |
#91665# keep right things right
Diffstat (limited to 'psprint')
-rw-r--r-- | psprint/source/printergfx/bitmap_gfx.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/psprint/source/printergfx/bitmap_gfx.cxx b/psprint/source/printergfx/bitmap_gfx.cxx index b13dfa75f82c..816f4de7222f 100644 --- a/psprint/source/printergfx/bitmap_gfx.cxx +++ b/psprint/source/printergfx/bitmap_gfx.cxx @@ -2,9 +2,9 @@ * * $RCSfile: bitmap_gfx.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: cp $ $Date: 2001-05-31 11:43:15 $ + * last change: $Author: cp $ $Date: 2001-08-30 12:39:13 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -700,10 +700,10 @@ PrinterGfx::DrawPS2MonoImage (const PrinterBmp& rBitmap, const Rectangle& rArea) for (long nColumn = rArea.Left(); nColumn <= rArea.Right(); nColumn++) { - nBit = rBitmap.GetPixelIdx (nRow, nColumn); - nByte |= nBit << nBitPos; - nBitPos += 1; - if (nBitPos == 8) + nBit = rBitmap.GetPixelIdx (nRow, nColumn); + nByte |= nBit << (7 - nBitPos); + + if (++nBitPos == 8) { pEncoder->EncodeByte (nByte); nBitPos = 0; |