467,075 Members | 1,044 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,075 developers. It's quick & easy.

Force printing in Black and white

Is there a way to force printing in black and white programatically?
Dec 6 '07 #1
  • viewed: 4501
Share:
3 Replies
Brian,

Are you in control of the application, or are you trying to do this
through another application?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Brian Cook" <br********@bnsf.comwrote in message
news:E3**********************************@microsof t.com...
Is there a way to force printing in black and white programatically?
Dec 6 '07 #2
Yes I am developing the application.

The customer wanted the RichTextBox background as Black, and the text in
Green. Printing is ugly with those color choices.
"Nicholas Paldino [.NET/C# MVP]" wrote:
Brian,

Are you in control of the application, or are you trying to do this
through another application?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Brian Cook" <br********@bnsf.comwrote in message
news:E3**********************************@microsof t.com...
Is there a way to force printing in black and white programatically?
Dec 7 '07 #3
On Fri, 07 Dec 2007 07:24:02 -0800, Brian Cook <br********@bnsf.comwrote:
Yes I am developing the application.

The customer wanted the RichTextBox background as Black, and the text in
Green. Printing is ugly with those color choices.
You can set the PageSettings.Color property to false when printing to
disable color printing.

However, keep in mind that this isn't going to change "ugly" into
"pretty". :) In the example you offer, one of two things will happen:

1) the printout will be converted to grayscale
2) the printout will be "posterized" (or quantized...basically, colors
converted to some closest matching shade of gray, possibly selected only
from black and white)

What happens exactly probably depends on the printer. Even in case #1,
you may find the text difficult to read, because green will come out as
some shade of gray. In case #2, green could actually get mapped to black,
making the text invisible.

IMHO, for situations like this, if you care about the quality of the
printout you need to add custom-handling code to change the colors before
printing so that you get a more readable printout. Depending on what
you're printing, you may have to modify the object being printed itself,
create a cloned object used for printing, or just include
printing-specific logic inside the object's drawing code.

As a first pass, you might just disable any background coloring when
printing. This will address most of the basic contrast issues you might
run into, and is a fairly common technique. It has the added benefit of
reducing ink/toner consumption (less ink is especially helpful, not just
because of the cost but also because you won't get a soggy mess of a
printout :) ).

Of course, make the behavior controllable by the user. You never know
when you'll have a user that really wants bad-looking printouts. :)

Pete
Dec 7 '07 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Arif | last post: by
reply views Thread by Mark Davison | last post: by
4 posts views Thread by Brett Baisley | last post: by
1 post views Thread by Dreamtime | last post: by
5 posts views Thread by kaosyeti@comcast.net via AccessMonster.com | last post: by
1 post views Thread by Sandy | last post: by
3 posts views Thread by jabslim via DotNetMonster.com | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.