Click here to Skip to main content
15,911,315 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
in my project i have a requirement to print labels vertically .So i did that by using a dll of Vertical Label (custom Control).it rotates vertically but the quality of Font is missing.please help me.
Posted
Updated 9-Jun-16 1:26am
v4
Comments
Sergey Alexandrovich Kryukov 9-Jun-16 2:27am    
In what line do you rotate anything?
Perhaps, in a "dll of vertical label"... but what is it?
—SA

We have no idea what the VerticalLabel control is or how it works: if you got the code from an article, then there is a "Add a Comment or Question" button at the bottom of that article, which causes an email to be sent to the author. They are then alerted that you wish to speak to them.
Posting this here relies on them "dropping by" and realising it is for them.

If you got it elsewhere, then you really need to start there and ask the person who wrote it!
 
Share this answer
 
It sounds weird. Not only I rotated text at arbitrary angle, but I've done arbitrary affine transform with text, and, as far as I remember, the quality of font rendering was quite good.

As you did not show any code rendering the text, I have no idea why it screwed up quality of rendering. Better ask the author of this code. I would guess it's the problems of option properties of the instance of System.Drawing.Graphics used. Better yet, if this is really a problem, throw out this lousy code and write your own.

I'll give you the idea. In the method System.Windows.Forms.Control.OnPaint you have to override, you will given the instance of System.Drawing.Graphics passed in event arguments parameter. Perform required affine transform on this instance:
Graphics.Transform Property (System.Drawing),
Matrix Class (System.Drawing.Drawing2D) (in particular, look at Rotate* methods).

Also, pay attention for the members related to rendering quality, read about them:
Graphics Class (System.Drawing).

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900