smegghead
asked on
display font vertically
Does anybody out there know how to display a font on the screen vertically, i.e. so that the text would read ok if the monitor was turned on it's side ??
The reason I need this is that I'm displaying a grid where the column titles can be quite long, but the column widths are limited in size.
I've written a simple program to do this by printing the required text into a picturebox, then copying the pixels to the desired location, but reversing the x & y co-ordinates.
This works fine, but is fairly slow. Does anybody know of any OCX / DLL which does this quickly ???
The reason I need this is that I'm displaying a grid where the column titles can be quite long, but the column widths are limited in size.
I've written a simple program to do this by printing the required text into a picturebox, then copying the pixels to the desired location, but reversing the x & y co-ordinates.
This works fine, but is fairly slow. Does anybody know of any OCX / DLL which does this quickly ???
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Thanks for the points! Glad I could help!
Cheers!
Cheers!
ASKER
How can I switch it back to printing horizontally ??? can I print at any other angles, like 45 degrees ???
To print a 45 angle, change the following lines in the Vprint subroutine:
Font.lfEscapement = 350 '900
Font.lfOrientation = 350 '900
These both need to be the same number, otherwise, the font looks funky... You can experiment with the numbers to get the desired angles.
you can also use negative numbers. Try this:
Font.lfEscapement = -200 '900
Font.lfOrientation = -200 '900
If you're feeling generous, please open a new question with the title "FOR MCRIDER ONLY" and assign a couple of points to it so I get credit for this extra information...
Cheers!
Font.lfEscapement = 350 '900
Font.lfOrientation = 350 '900
These both need to be the same number, otherwise, the font looks funky... You can experiment with the numbers to get the desired angles.
you can also use negative numbers. Try this:
Font.lfEscapement = -200 '900
Font.lfOrientation = -200 '900
If you're feeling generous, please open a new question with the title "FOR MCRIDER ONLY" and assign a couple of points to it so I get credit for this extra information...
Cheers!
ASKER
No probs - I'll post another question in a few minutes....
ASKER
I had to change the hFont and HoldFont to Long rather than Integer but apart from that it's fine...